Portal Documentation

Living documentation for the Agentic Hub β€” portal features, workflows, entities, architecture, and design decisions.

πŸ‘‹ Welcome

This is the canonical reference for everything in the Adrian Portal (hub.adrian.my). It covers every entity, API endpoint, design decision, and architectural pattern.

Why this exists: Design decisions and rationale get lost when task folders are archived and context is compressed. These docs persist the why, not just the what.

🫁 The Two Loops

The Hub breathes through two complementary loops β€” one creates, one learns. Together they form a self-improving system.

πŸ”¨ Creation Loop (剡造) β€” exhale
🧭 Vision β€” WHY?
↓
🌳 Nexus β€” WHERE?
↓
πŸ”΄ Problems β€” WHAT HURTS?
↓
πŸ“ Projects β€” BUILD WHAT?
↓
πŸ“‹ Tasks β€” DO IT
FEEDS
🫁
FEEDS
πŸ’‘ Insight Loop (升華) β€” inhale
β˜€οΈ Raw Content β€” WHAT CAME IN?
↓
πŸ§ͺ Distillery β€” KEEP WHAT?
↓
🧠 Knowledge Base β€” STRUCTURE
↓
πŸ“– Wiki β€” PUBLISH

⚑ Quick Reference

API Endpoints (18)

Endpoint Methods Purpose
/api/tasks GET/POST/PATCH/DELETE Task lifecycle + tech tree
/api/feedback GET/POST/PATCH/DELETE Actionable inbox items
/api/comments GET/POST Append-only audit trail
/api/reports GET/POST/PATCH/DELETE Report metadata registry
/api/messages GET/POST/PATCH/DELETE Agent chatroom channels
/api/remote-jobs GET/POST/PATCH/DELETE Bifrost job queue
/api/velocity GET/POST/DELETE Time tracking entries
/api/logs GET/POST/DELETE Session log entries
/api/dashboard GET Aggregated dashboard stats
/api/projects GET/POST/PATCH/DELETE Project metadata + grouping
/api/problems GET/POST/PATCH/DELETE Problem registry (Creation Loop)
/api/nexus GET/POST/PATCH Vision tree nodes
/api/distill GET/POST/PATCH Distillery pipeline items
/api/learnings GET/POST Knowledge items from Insight Loop
/api/preferences GET/PATCH User preferences + settings
/api/workflow-usage GET/POST Workflow invocation tracking (CE8)

Key Concepts

Concept Location What
Two Loops Architecture Creation Loop (剡造) builds. Insight Loop (升華) learns. Together they breathe.
Local-first Agents β†’ files Agents write local files. D1 is the portal's read layer. Clara syncs.
Dual-write Logs, velocity POST to API + write local .md. Both are sources of truth for different consumers.
Soft-delete All D1 tables Never DELETE. PATCH status to archived. History is preserved.
CLI > raw API Portal CLI portal command handles auth, URLs, error formatting. 7 command groups.