canvasight-open
GitHub通过MCP打开Canvasight并验证原生小部件就绪状态。流程包括读取线程ID和项目路径,调用open_canvasight和await_canvasight_widget_ready,严格校验ready、verified等字段确认渲染完成,失败则路由至故障排查或处理传输关闭问题。
Trigger Scenarios
Install
npx skills add Niall-Young/Canvasight --skill canvasight-open -g -y
SKILL.md
Frontmatter
{
"name": "canvasight-open",
"description": "Open, reopen, attach, and verify Canvasight's Codex native widget, or explicitly open a browser fallback. Use when the user asks to start Canvasight, open the Canvasight workspace, 打开画布, 打开 Canvasight, 恢复最近项目, attach the current Codex task, or verify whether a native canvas actually became ready."
}
Canvasight Open
Use this skill to open Canvasight through MCP and verify the real native widget runtime.
Native Open Workflow
- Read the active task's
CODEX_THREAD_IDand current working directory from the shell. Require both a non-empty thread id and an absolute project path; pass them asthreadIdandprojectPath. - If the tools are not callable, use
tool_searchforcanvasight open_canvasight await_canvasight_widget_ready render_canvasight_canvas_widget. - Call
open_canvasightexactly once for this user-level open action, pass the explicitprojectPath, and retain the complete provisional result. Userender_canvasight_canvas_widgetonly as a compatibility alias, never as a second attempt to recover identity. Do not rely on a thread lookup or daemon default to infer the project: an unreadable or archived task must never silently open another folder's.scatterdocument. - Read
sessionIdandopenAttemptIdfrom the retained result'sstructuredContent. Tool completion is not evidence that the canvas rendered. - Immediately call
await_canvasight_widget_readywith those two ids and the samethreadId. Treat these two MCP calls as one indivisible user-level open action. Do not callopen_canvasightagain to recoversessionIdoropenAttemptId. If the first result or either id was lost, mark the openingunverified, do not reopen, and route diagnosis throughcanvasight-troubleshooting. - Report the canvas as opened or ready only when the result has
status: "ready",verified: true,displayMode: "fullscreen", and all ofreactMounted,projectHydrated,canvasRendered, andcanvasVisibleset totrue. - For
timeout,failed, missing identity/evidence, or a non-fullscreen instance, reportopenAttemptId,widgetInstanceId,stage, anderror, keep the native open resultunverified, and route diagnosis throughcanvasight-troubleshooting.
Do not replace step 5 with resource reads, daemon health, build output, MCP smoke tests, browser fallback, or visual assumptions. Do not loop on ready timeouts or silently open localhost.
opened = open_canvasight({ threadId, projectPath })
sessionId = opened.structuredContent.sessionId
openAttemptId = opened.structuredContent.openAttemptId
ready = await_canvasight_widget_ready({ sessionId, openAttemptId, threadId })
Recovery And Fallback
- When a native tool returns
Transport closed, reportcanvasight_mcp_transport_closedand check the installed plugin state. If the plugin version changed while Codex Desktop was running, reload/restart the Codex host before creating and tagging a new task; a new task alone can retain the old app-level registry. Browser fallback is not a native recovery. - When neither the native open tool nor
await_canvasight_widget_readyis available aftertool_search, report the missing capability. After an install or upgrade, require a Codex host reload/restart followed by a newly created and newly tagged task. Do not claim readiness. - Use
list_canvasight_recent_projectsandopen_canvasight_recent_projectto reopen a recent project, then apply the same instance-bound ready gate with its returnedsessionIdandopenAttemptId. - Use
open_canvasight_browser_fallbackonly when the user explicitly requests fallback or when diagnosing the browser surface. It queues Run payloads forawait_canvasight_runafter an explicit thread claim and never satisfies native-widget readiness. - Call
close_canvasightonly for a specific session that is no longer needed. It does not stop the project daemon.
After verified readiness, treat the project as active Canvasight context. Route later structured canvas-writing requests to canvasight-graph-writer; keep small direct commands and Run payloads on their normal paths.
Read references/open-workflow.md for the detailed contract and failure handling.
Version History
- 065406a Current 2026-07-19 09:56


