agent-orchestrator/packages
Ashish Huddar ca0b7ec2ce feat: add interactive canvas artifacts to session detail view
Adds Cursor-style "canvases" — interactive artifacts (markdown / diff /
table / stats) rendered in a right-side rail next to the session terminal
so structured agent output (diffs, test results, stats) doesn't get buried
in scrollback.

Architecture is plugin-friendly without inventing a new plugin slot:
agents emit JSON files at `{workspacePath}/.ao/canvases/{id}.json`, core
validates and serves them via `GET /api/sessions/[id]/canvases`, and the
web layer ships a fixed renderer set so third parties can produce data
without shipping React components into the supervisor dashboard. The
`CanvasProducer` interface is declared for v0.2 plugin invocation but not
yet called.

v0.1 also synthesizes a `core-git-diff` canvas from `git diff` against
the merge-base with `origin/<default>` (with local-ref + uncommitted +
untracked-file fallbacks), so the feature is useful for every session
even before any agent integration.

Hardened across 10 codex review passes:
- working-tree diffs (not just committed changes)
- merge-base against origin/<base>, not stale local ref
- untracked files included with file/byte/lstat caps
- `.ao/` files excluded from synthesized diffs
- reserved `core-` id prefix for synthesized canvases
- per-effect cancellation + sequence-guarded poll responses
- lstat (not stat) on canvas files to reject FIFO/symlink bypass
- partial-stdout recovery on oversized diffs
- session.projectId (not prefix-matching) for project resolution
- empty canvases for sessions without a workspacePath
- diff parser preserves `+++`/`---` content lines, strips marker prefix
- size caps: 256 KB per canvas, 32 canvases per session, 200 files /
  5000 lines per diff, 50 untracked files / 4 MB budget

Tests: 17 core + 8 web, all passing. Docs at docs/canvases.md.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-05 17:01:31 +05:30
..
ao chore: align workspace package.json versions with npm registry (#1587) 2026-05-01 15:31:04 +05:30
cli feat: add SQLite-backed activity event logging layer (#1528) 2026-05-01 21:13:20 +05:30
core feat: add interactive canvas artifacts to session detail view 2026-05-05 17:01:31 +05:30
integration-tests refactor(core): storage redesign — projectId-based paths, JSON metadata (#1466) 2026-04-28 17:55:53 +05:30
plugins Fix native restore fallback for Claude and Codex sessions (#1602) 2026-05-01 21:27:17 +05:30
web feat: add interactive canvas artifacts to session detail view 2026-05-05 17:01:31 +05:30