3.`/Users/dorian/Projects/AIUI/CLAUDE.md` — AIUI conventions and Archy integration rules
## Architecture Overview
AIUI runs in an iframe at `/dashboard/chat`. Communication happens via `window.postMessage()` through a ContextBroker (Archy side) and archyBridge (AIUI side). AIUI is quarantined — it never directly accesses Archy APIs.
-`/Users/dorian/Projects/AIUI/packages/app/src/composables/contentExtraction.ts` — Content tag extraction pipeline
-`/Users/dorian/Projects/AIUI/packages/app/src/composables/useContentPanel.ts` — Content panel state
## Coordination with AIUI Agent
A separate Claude agent is working on the AIUI repo simultaneously. Your job is the **Archy side only**:
- Expand the ContextBroker to serve real data for all categories
- Add new context categories for media, search, and local AI
- Wire up real store/RPC data instead of placeholders
- Deploy and test on the live server at 192.168.1.228
- DO NOT edit files in /Users/dorian/Projects/AIUI/ — the other agent handles that
## Content Handshake Protocol
AIUI's content pipeline uses `[[tag:data]]` syntax in AI responses to surface content. The AI needs context about what's available on the node to generate these tags. The handshake works like this:
1. AIUI sends `context:request` with category (e.g., `media`, `apps`, `files`)
2. Archy's ContextBroker checks permissions, fetches from stores/RPC, sanitizes
3. Returns data to AIUI which injects it into the AI's system prompt
4. AI generates responses with appropriate `[[film:id]]`, `[[song:id]]` tags referencing actual library content
5. AIUI's content extraction pipeline renders the tagged content in panels
## For each task in loop/plan.md:
1. Find the first unchecked `- [ ]` item
2. Read the task description carefully
3. Read the relevant source files before making changes
4. Implement following CLAUDE.md conventions (glass styling, TypeScript strict, etc.)
5. Run `cd neode-ui && npm run type-check` — fix all errors before continuing
6. Run `cd neode-ui && npm run build` — must succeed
7. Deploy to live server: `./scripts/deploy-to-target.sh --live`