canvas

A live React-based workspace for presenting a standalone analytical result beside the conversation. It is saved as one .canvas.tsx file that the editor can compile and display.

In plain words
What is it for?
Use it to present quantitative analyses, billing investigations, security and architecture reviews, cross-system comparisons, financial analyses, trends, charts, timelines, interactive explorations, and larger tables.
Why use it?
It makes structured results easier to inspect when the deliverable is more than a short answer, such as a security audit, data analysis, chart, timeline, or large table. It is intended for the result itself, not merely for drafting text or changing another tool.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/xyruscode/ai-sync/canvas
Any agent
npx skills add XyrusCode/ai-sync --skill canvas
Clone the repo
git clone --depth 1 https://github.com/XyrusCode/ai-sync

Made for: Claude Code, Codex.

Per session 165 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,027 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 86% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00165 $0.02027
Opus 5 $0.00082 $0.01014
Sonnet 5 $0.00033 $0.00405
Haiku 4.5 $0.00016 $0.00203

Measured yesterday against content hash 85d0dfeafa70, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

canvas scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

The scan reads SKILL.md. This mod also ships 15 executable files (sdk/callout-tone-icons.d.ts, sdk/canvas-tokens.d.ts, sdk/chart-primitives.d.ts, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

86% identical to bitfun-canvas — 44 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/canvas/SKILL.md · 109 lines

How it starts

The opening of the file, as written. The whole thing — 109 lines — stays where its author put it; the contents beside it link to each section on GitHub.

A canvas is a single .canvas.tsx file the IDE compiles so the user can open it beside the chat. Follow the workflow below in order.

Workflow

1. Decide whether to use a canvas

The trigger is user intent, not response shape. Ask: would the user benefit from viewing this output as its own standalone artifact, separate from the chat? If the output is a means to an end (a drafted message, a code fix, a dashboard in another tool), skip the canvas.

Use a canvas when the agent produces new standalone analytical output:

  • Quantitative analyses and metrics breakdowns (e.g. "send 500 requests and tell me how many fail")
  • Billing or account investigations that surface structured findings from database queries
  • Security audits or architecture reviews with categorized findings
  • Cross-system data analyses and overlap reports
  • Structured data from MCP tools (Databricks, Datadog, etc.) where the data IS the deliverable
  • Financial analyses, margin decompositions, usage trend reports
  • Tables with more than a handful of rows that the user asked to see

Do NOT use a canvas when:

  • The user asks for work in a specific tool — "create a Datadog dashboard" means give them a Datadog dashboard, not a canvas
  • The user has a specific deliverable — "draft a support response", "fix this code", "make this PR"
  • The user is working within an existing artifact — improving an HTML dashboard, editing an existing file
  • The user is doing targeted debugging or active development, even if structured findings emerge along the way
  • Short factual answers, one-off file edits, or quick clarifying questions
  • MCP tools are queried as an intermediate step for a different deliverable (e.g. querying Stripe to draft a support reply)

2. Write the canvas

Location. Canvases live at /Users/<user>/.cursor/projects/<workspace>/canvases/<name>.canvas.tsx. The IDE only detects canvases written directly inside that exact directory — subfolders, alternate extensions, and other locations are not picked up. For a new canvas, always use the write file tool to create the .canvas.tsx file at that exact path; do not stop after telling the user the path or showing code in chat. Treat that managed canvases/ directory as pre-provisioned by Cursor itself: write the canvas file directly there and do not spend turns creating the directory with mkdir or checking whether it exists before writing. Listing its contents for other purposes (e.g. checking for existing canvases) is fine. If you can't determine the workspace directory from absolute paths already in your environment (terminals, transcripts, recently-viewed files), list ~/.cursor/projects/ rather than guessing. Use a descriptive kebab-case filename ending in .canvas.tsx; preserve acronym capitalization and lowercase the rest.

Read the full file on GitHub · 109 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 109 lines · 165 tokens per session scan A 85d0dfeafa70

Subscribe to this mod's changes

canvas is a skill published in the GitHub repository XyrusCode/ai-sync (2 stars, last pushed yesterday), licensed MIT. It adds 165 tokens to every session and 2,027 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it A with 0 findings. It is 86% identical to bitfun-canvas, differing in 44 lines, and is treated as a copy.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

babysit-pr

Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…

openai/codex · 114 tokens

imagegen

Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…

openai/codex · 113 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens