Skip to content

feat(canvas): add universal agent-authored CanvasSpec - #320

Merged
graphite-app[bot] merged 1 commit into
mainfrom
feat/universal-canvas
Sep 5, 2026
Merged

graphite-app[bot] merged 1 commit into
mainfrom
feat/universal-canvas

Conversation

@anandpant

@anandpant anandpant commented Sep 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • introduce CanvasSpec v1 as the single canonical rendered scene IR and migrate flowchart, mindmap, and sequence rendering onto it
  • add typed sketchi.createCanvas orchestration through the normal Worker route and existing Code Mode MCP docs/search/execute surface
  • compile deterministic row, column, grid, stack, align, and distribute layouts; render text, common shapes including polygon, lines, bound connectors, frames, groups, layers, z-order, and styling
  • persist scene, Excalidraw, and PNG artifacts with typed failures, telemetry, and bounded structural validation that permits intentional overlap
  • extend patching with insert, remove, replace, reorder, group, and ungroup while preserving stable IDs and connectivity safeguards
  • add executable ERD, architecture, timeline, dashboard, wireframe, and dense 120-element examples

Safety

CanvasSpec accepts typed drawing primitives only. This slice intentionally omits SVG, HTML, scripts, external URLs, data URLs, arbitrary fetches, vector paths, and asset references.

Test plan

  • pnpm nx run-many -t typecheck,test,build (17 projects, 52 tasks; 2 cache hits)
  • pnpm nx build-storybook diagram-ui
  • pnpm run test:deploy-scripts (79 tests)
  • pnpm nx run-many -t lint --projects=diagram-core,diagram-renderer,diagram-excalidraw,diagram-agent,playground,sketchi-cli --skip-nx-cache
  • focused core layout/validation tests, converter tests, agent runtime/contract tests, Worker route tests, MCP provider/docs tests, compatibility corpus, and dense 120-element coverage
  • local browser smoke against POST /api/v1/canvases/create, including visible node labels and PNG artifact rendering
  • local Streamable HTTP MCP smoke against /mcp: listed only docs/search/execute and executed sketchi.createCanvas through the real Worker Loader Code Mode path
  • executable example matrix invoked for ERD, architecture, timeline, dashboard, wireframe, and dense 120-element canvas
  • one independent Codex review completed; all five findings were addressed with focused regression coverage
  • final GitHub checks: 9 passed, 0 failed, 0 pending on 6e5b2081216d2f1b12a31bdd488155721d3b54a4

Proof limits

Browser, Worker route, artifact rendering, and MCP proof are local. Preview deployment checks passed, but no deployed preview smoke was performed or claimed. Nothing was merged.

Copy link
Copy Markdown
Collaborator Author

How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge - adds this PR to the back of the merge queue
  • fast - for urgent changes, fast-track this PR to the front of the merge queue

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@anandpant anandpant changed the title feat(canvas): add universal agent-authored canvas feat(canvas): add universal agent-authored CanvasSpec Sep 5, 2026
@anandpant
anandpant force-pushed the feat/universal-canvas branch from 554a1ca to f9d772b Compare September 5, 2026 19:08
@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Sketchi Web Preview

Status: deleted

Preview Worker cleanup has completed.

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Sketchi Icons Preview

Status: deleted

Preview Worker cleanup has completed.

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Sketchi Eval Harness Preview

Status: deleted

  • Surface: internal preview; not linked from public navigation
  • Project: eval-harness
  • Worker identity: sketchi-playground
  • Route policy: internal eval harness; no public product domain
  • Preview Worker: sketchi-playground-pr-320
  • Commit: a18540ea8b84
  • Workflow run: https://github.com/shpitdev/sketchi/actions/runs/33998228239

Preview Worker cleanup has completed.

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Sketchi Excalidraw Workspace Preview

Status: deleted

  • Surface: internal preview; not linked from public navigation
  • Project: excalidraw
  • Worker identity: sketchi-excalidraw
  • Route policy: internal canvas workspace; no public product domain
  • Preview Worker: sketchi-excalidraw-pr-320
  • Commit: a18540ea8b84
  • Workflow run: https://github.com/shpitdev/sketchi/actions/runs/33998228239

Preview Worker cleanup has completed.

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Sketchi Playground / Studio Preview

Status: deleted

  • Surface: public product preview
  • Project: playground
  • Worker identity: sketchi-studio
  • Route policy: playground.sketchi.app product surface; authenticated Studio remains unexposed
  • Preview Worker: sketchi-studio-pr-320
  • Commit: a18540ea8b84
  • Workflow run: https://github.com/shpitdev/sketchi/actions/runs/33998228239

Preview Worker cleanup has completed.

@graphite-app

graphite-app Bot commented Sep 5, 2026

Copy link
Copy Markdown

Merge activity

## Summary

- introduce CanvasSpec v1 as the single canonical rendered scene IR and migrate flowchart, mindmap, and sequence rendering onto it
- add typed sketchi.createCanvas orchestration through the normal Worker route and existing Code Mode MCP docs/search/execute surface
- compile deterministic row, column, grid, stack, align, and distribute layouts; render text, common shapes including polygon, lines, bound connectors, frames, groups, layers, z-order, and styling
- persist scene, Excalidraw, and PNG artifacts with typed failures, telemetry, and bounded structural validation that permits intentional overlap
- extend patching with insert, remove, replace, reorder, group, and ungroup while preserving stable IDs and connectivity safeguards
- add executable ERD, architecture, timeline, dashboard, wireframe, and dense 120-element examples

## Safety

CanvasSpec accepts typed drawing primitives only. This slice intentionally omits SVG, HTML, scripts, external URLs, data URLs, arbitrary fetches, vector paths, and asset references.

## Test plan

- `pnpm nx run-many -t typecheck,test,build` (17 projects, 52 tasks; 2 cache hits)
- `pnpm nx build-storybook diagram-ui`
- `pnpm run test:deploy-scripts` (79 tests)
- `pnpm nx run-many -t lint --projects=diagram-core,diagram-renderer,diagram-excalidraw,diagram-agent,playground,sketchi-cli --skip-nx-cache`
- focused core layout/validation tests, converter tests, agent runtime/contract tests, Worker route tests, MCP provider/docs tests, compatibility corpus, and dense 120-element coverage
- local browser smoke against `POST /api/v1/canvases/create`, including visible node labels and PNG artifact rendering
- local Streamable HTTP MCP smoke against `/mcp`: listed only docs/search/execute and executed `sketchi.createCanvas` through the real Worker Loader Code Mode path
- executable example matrix invoked for ERD, architecture, timeline, dashboard, wireframe, and dense 120-element canvas
- one independent Codex review completed; all five findings were addressed with focused regression coverage
- final GitHub checks: 9 passed, 0 failed, 0 pending on `6e5b2081216d2f1b12a31bdd488155721d3b54a4`

## Proof limits

Browser, Worker route, artifact rendering, and MCP proof are local. Preview deployment checks passed, but no deployed preview smoke was performed or claimed. Nothing was merged.
@graphite-app
graphite-app Bot force-pushed the feat/universal-canvas branch from 6e5b208 to a18540e Compare September 5, 2026 23:15
@graphite-app
graphite-app Bot merged commit a18540e into main Sep 5, 2026
10 checks passed
@graphite-app
graphite-app Bot deleted the feat/universal-canvas branch September 5, 2026 23:16
@graphite-app
graphite-app Bot deployed to production September 5, 2026 23:16 Active
@graphite-app
graphite-app Bot deployed to production September 5, 2026 23:16 Active
@graphite-app
graphite-app Bot deployed to production September 5, 2026 23:16 Active
@graphite-app
graphite-app Bot deployed to production September 5, 2026 23:16 Active
@graphite-app
graphite-app Bot deployed to production September 5, 2026 23:16 Active
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant