一键导入
plan
Manage a Plan — a document referencing separate task documents, each with a goal, dependencies, artifacts, and a linked spec.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Manage a Plan — a document referencing separate task documents, each with a goal, dependencies, artifacts, and a linked spec.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Create and manage todo list documents (TodoDoc). Use for task lists, checklists, and simple project tracking.
Read and write a Datalog database document (DatalogDoc) by Automerge URL. Use when working with Datalog facts, rules, or constraints — asserting or retracting facts, reading the current database state, running queries, or checking for constraint violations.
Manage a Spec Collection — a single document containing multiple specs, each with a goal, named document references, and JavaScript verification scripts.
Write a plain-JS canvas tool for an existing datatype and place it on a Paper canvas via toolUrl embed. Use when asked to create a custom view or UI for an existing document type.
Read and write a Datalog database document (DatalogDoc) by Automerge URL. Use when working with Datalog facts, rules, or constraints — asserting or retracting facts, reading the current database state, running queries, or checking for constraint violations/conflicts.
Domain-specific API for creating and configuring an llm-petrinet — set system prompts, add optimizers/evaluators/problems, and read back the current configuration.
基于 SOC 职业分类
| name | plan |
| description | Manage a Plan — a document referencing separate task documents, each with a goal, dependencies, artifacts, and a linked spec. |
Manage a PlanDoc that references separate TaskDoc documents. Each task has a goal, dependencies on other tasks, named artifact documents, and a link to the spec it fulfills.
const { createPlan, getPlan } = await workspace.import("skills/plan/index.js");
// PlanDoc shape
{
tasks: AutomergeUrl[] // references to separate TaskDoc documents
}
// TaskDoc shape (separate document)
{
goal: string,
dependsOn: AutomergeUrl[], // URLs of prerequisite task documents
artifacts: Record<string, AutomergeUrl>, // named output documents this task produces
specDocUrl: AutomergeUrl // the spec this task fulfills
}
createPlan(workspace) (sync)Creates a new, empty PlanDoc. Do NOT await — workspace.createDoc() is synchronous.
Returns { handle, url }.
const { createPlan } = await workspace.import("skills/plan/index.js");
const { url } = createPlan(workspace);
getPlan(workspace, url) (async)Returns a read/write interface for the PlanDoc at url. Must be awaited.
| Method | Description |
|---|---|
getTasks() | Returns a copy of the task URL array. |
addTask(goal, specDocUrl) | Creates a new TaskDoc document, appends its URL to the plan. Returns a task handle with .url. |
getTask(url) (async) | Finds the task document at url and returns a task handle. |
removeTask(url) | Removes the task URL from the plan's tasks array. |
A task handle wraps a separate Automerge document. It is returned by addTask() or getTask().
| Property / Method | Description |
|---|---|
.url | The task document's AutomergeUrl. |
getGoal() | Returns the task's goal string. |
setGoal(goal) | Sets the task's goal. |
getSpecDocUrl() | Returns the URL of the linked spec. |
setSpecDocUrl(url) | Sets the linked spec URL. |
getDependsOn() | Returns a copy of the dependsOn URL array. |
addDependency(taskUrl) | Adds a dependency on another task (no-op if already present). |
removeDependency(taskUrl) | Removes a dependency. |
getArtifacts() | Returns a copy of the artifacts record. |
setArtifact(name, url) | Sets a named artifact document URL. |
removeArtifact(name) | Removes a named artifact. |
A task's artifacts correspond to the requiredDocs of its linked spec. The artifact keys should match the required doc names declared in the spec. For example, if a spec declares addRequiredDoc("schedule"), the task should have setArtifact("schedule", scheduleUrl).
const { createPlan, getPlan } = await workspace.import("skills/plan/index.js");
const { createDatalog } = await workspace.import("skills/datalog/index.js");
// Create the plan
const { url: planUrl } = createPlan(workspace);
const plan = await getPlan(workspace, planUrl);
// Create an empty schedule document as an artifact placeholder
const erSchedule = createDatalog(workspace, "ER Schedule");
// Add a task linked to a spec, with an artifact
const erTask = plan.addTask("Generate ER department schedule", erSpecUrl);
erTask.setArtifact("schedule", erSchedule.url);
// Add another task that depends on the first
const globalTask = plan.addTask("Validate cross-department constraints", globalSpecUrl);
globalTask.addDependency(erTask.url);