2026-03-04 10:54:03 +00:00
You are hardening the AIUI content extraction pipeline and completing incomplete features. Read these files first:
2026-03-03 18:24:17 +00:00
2026-03-03 22:29:18 +00:00
1. `loop/plan.md` — Your task checklist (mark items `- [x]` as you complete them)
2026-03-04 10:54:03 +00:00
2. `CLAUDE.md` — Project conventions, design system rules, and coding standards
## Key Context
The content extraction pipeline lives in:
- `packages/app/src/composables/contentExtraction.ts` — Extracts books, films, TV, songs, podcasts, places, images, code blocks, apps from AI response text
- `packages/app/src/composables/contentFiltering.ts` — Query/response classifiers (isBookQuery, isTVQuery, etc.) and tab routing (filterTabsByContext)
- `packages/app/src/composables/useContentPanel.ts` — Wires extraction functions to Vue reactive state and tab system
- `packages/app/src/components/content/ContentPanel.vue` — Main content panel rendering grids and detail views
- `packages/app/src/components/content/ContentGridView.vue` — Grid view (already has ImageGrid/PlaceGrid wired)
- `packages/app/src/__tests__/extractionQuality.test.ts` — Extraction quality test suite (currently 64 tests)
Content flows: AI response text → extraction functions → useContentPanel refs → filterTabsByContext → ContentPanel/ContentGridView rendering
2026-03-03 18:24:17 +00:00
2026-03-03 22:29:18 +00:00
## Design System Rules (must follow for every file you touch)
2026-03-04 05:03:03 +00:00
- **Glass morphism only** — use `.glass` , `.glass-card` , `.glass-button` , `.glass-button-sm` from `src/styles/main.css`
2026-03-03 22:29:18 +00:00
- **No light-mode conditionals** — never use `isDark ?` pattern. The app is dark-only. Remove any existing light-mode code you encounter.
- **No `bg-gray-*` or `bg-white` ** — use `bg-white/5` , `bg-white/10` , `bg-black/35` etc.
- **Text opacity scale** — `text-white/25` → `/40` → `/60` → `/70` → `/80` → `/90` → `/96` → `text-white`
- **Accent colour** — `text-accent` (`#F7931A` ), `bg-accent/15` , `border-accent/30` for Bitcoin-orange highlights
- **Touch targets** — min 44× 44px, 8px gaps between targets
- **Font size** — min `16px` on all inputs (prevents iOS zoom)
- **Animations** — `animate-scale-in` , `animate-fade-up` , `animate-fade-in` from design system only
## For each task in loop/plan.md:
1. Find the first unchecked `- [ ]` item
2026-03-04 10:54:03 +00:00
2. Read the task description carefully
3. Read the relevant source files before making changes
4. Implement the feature/fix following conventions and design system rules
5. Run `pnpm typecheck && pnpm lint` — fix all errors before committing
6. Run `pnpm test` — fix any failing tests
7. If the task involves tests, run `cd packages/app && npx vitest run src/__tests__/extractionQuality.test.ts` specifically
8. Commit: `type(scope): description` (conventional commits)
9. Mark it done `- [x]` in `loop/plan.md`
2026-03-03 22:29:18 +00:00
10. Move to the next unchecked task immediately
## Rules
- Never skip a testing gate — if tests fail, fix them before moving on
2026-03-04 10:54:03 +00:00
- If a task is proving difficult, keep trying different approaches. Make at least 30 genuine attempts before giving up and moving on.
2026-03-03 22:29:18 +00:00
- Always run typecheck + lint after every code change
2026-03-04 10:54:03 +00:00
- Keep initial bundle < 250 KB gzipped — lazy-load anything heavy
2026-03-03 22:29:18 +00:00
- Bitcoin only — never altcoins, never fiat payment flows
- Privacy first — no external analytics calls, no telemetry
- Do not stop until all tasks are checked or you are rate limited
2026-03-04 10:54:03 +00:00
- When adding tests, aim for realistic AI response patterns, not trivial examples
- When wiring components into ContentPanel.vue, follow the exact same pattern used for existing content types (BookGrid/BookDetail, TVSeriesGrid/TVSeriesDetail, etc.)