execute
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseExecute
Execute
/execute/buildtask_typeexecutebuildNot this skill: (pull latest thread + DNA and work from conversation). (investigation tasks). Do not invent a third name.
/create/researchRepo is ambient: Cursor workspace — no GitHub connection.
/execute/buildtask_typeexecutebuild不适用于此 skill: (拉取最新 thread + DNA 并从 conversation 开展工作)。(调查任务)。不要自创第三个名称。
/create/research仓库是环境上下文: Cursor 工作区——无 GitHub 连接。
Triggers
触发条件
- or
/execute— start standby executor/build - or
/execute keep on— same; explicit keep-on/build keep on - After a task completes, keep on / I know / similar → stay in standby
- 或
/execute——启动待机执行器/build - 或
/execute keep on——同上;显式保持开启/build keep on - 任务完成后,keep on / I know 或类似表达 → 保持待机
API
API
- Base URL:
https://api.originmind.ai - →
GET /api/v1/tasks?status=pending&task_type=execute(user-wide standby){ data: [...] } - —
PATCH /api/v1/tasks/{id}|claim|complete(body requiresfail)conversation_id - Content kind also: —
POST /api/v1/creations{ project_id, title, content, status: "saved" } - Auth: or Bearer JWT
X-OriAI-Api-Key
- 基础 URL:
https://api.originmind.ai - →
GET /api/v1/tasks?status=pending&task_type=execute(用户范围待机){ data: [...] } - ——
PATCH /api/v1/tasks/{id}|claim|complete(请求体需要fail)conversation_id - 类型还包括:
content——POST /api/v1/creations{ project_id, title, content, status: "saved" } - 身份验证:或 Bearer JWT
X-OriAI-Api-Key
Bootstrap
初始化
Once per shell. Walk upward from cwd for then .
.env.env.localpowershell
. ./skills/create/scripts/bootstrap-originmind-env.ps1bash
source ./skills/create/scripts/bootstrap-originmind-env.shUser install:
. "$HOME/.cursor/skills/create/scripts/bootstrap-originmind-env.ps1"MISSING_KEY. ./skills/create/scripts/setup-oauth.ps1.envNever print full keys. PowerShell: never use for project id — use .
$pid$ProjectId每个 shell 会话执行一次。从 cwd 向上查找 ,然后查找 。
.env.env.localpowershell
. ./skills/create/scripts/bootstrap-originmind-env.ps1bash
source ./skills/create/scripts/bootstrap-originmind-env.sh用户安装:
. "$HOME/.cursor/skills/create/scripts/bootstrap-originmind-env.ps1"MISSING_KEY. ./skills/create/scripts/setup-oauth.ps1.env绝不打印完整密钥。PowerShell:绝不要将 用作 project id——请使用 。
$pid$ProjectIdStandby executor
待机执行器
- Bootstrap.
- Echo: standby, poll 10s, scope = all projects (user-wide pending execute), triggers = ≡
/execute./build - Enter poll loop. Do not invent a default project for listing.
Optional filter only when user names / / .
task_idconversation_idproject_id- 初始化。
- 输出:待机,每 10 秒轮询一次,范围 = 所有项目(用户范围的待处理 execute),触发器 = ≡
/execute。/build - 进入轮询循环。列出任务时,不要自创默认项目。
仅当用户指定 / / 时使用可选过滤条件。
task_idconversation_idproject_idPoll loop (every 10s)
轮询循环(每 10 秒)
standby:
idle_since = now
loop:
GET /api/v1/tasks?status=pending&task_type=execute
if data[] non-empty:
idle_since = now
for each task → Execute task
echo one-line summary; continue (do not exit)
else:
if now - idle_since >= 3 minutes → exit ("idle timeout")
if user says stop → exit
sleep 10| Exit | When |
|---|---|
| User stop | stop, enough, quit, |
| Idle timeout | 3 minutes with no pending tasks |
| Billing | 402 / 429 |
Keep-on: stay in standby; do not treat as stop.
standby:
idle_since = now
loop:
GET /api/v1/tasks?status=pending&task_type=execute
if data[] non-empty:
idle_since = now
for each task → Execute task
echo one-line summary; continue (do not exit)
else:
if now - idle_since >= 3 minutes → exit ("idle timeout")
if user says stop → exit
sleep 10| 退出 | 何时 |
|---|---|
| 用户停止 | stop、enough、quit、 |
| 空闲超时 | 连续 3 分钟没有待处理任务 |
| 计费 | 402 / 429 |
**Keep-on:**保持待机;不要视为停止。
Execute task
执行任务
Use and from the task row.
conversation_idproject_id-
Claim:
PATCH— 409 skip.{ "conversation_id", "action": "claim" } -
Context (optional): messages/transcript for that conversation. Read,
params.kind.params.instruction -
Branch on:
params.kindkind Action code Implement in the workspace from (+ optional transcript). Match repo conventions. No code dumps in the report.instructioncontent Write a creative document (plan, statement, brief, etc. — not source code). withPOST /api/v1/creations(same pattern as save-creation). Capture returned creation{ project_id, title, content, status: "saved" }.id -
Complete:json
{ "conversation_id": "{task.conversation_id}", "action": "complete", "results": { "content": "decision-level summary of what was done — no diffs, no syntax", "sources": [], "creation_id": "{uuid — content kind only, omit for code}" } } -
Fail:
PATCH+"action": "fail"."error" -
Echo task id, project id, conversation id, kind (|
code), one-line summary.content
使用任务行中的 和 。
conversation_idproject_id-
认领:
PATCH——遇到 409 时跳过。{ "conversation_id", "action": "claim" } -
**上下文(可选):**该 conversation 的 messages/transcript。读取、
params.kind。params.instruction -
根据分支处理:
params.kindkind 操作 code 根据 (+ 可选 transcript)在工作区中实现。遵循仓库约定。报告中不要转储代码。instructioncontent 撰写创意文档(计划、声明、简介等——不是源代码)。 ,请求体为POST /api/v1/creations(与 save-creation 模式相同)。获取返回的 creation{ project_id, title, content, status: "saved" }。id -
完成:json
{ "conversation_id": "{task.conversation_id}", "action": "complete", "results": { "content": "decision-level summary of what was done — no diffs, no syntax", "sources": [], "creation_id": "{uuid — content kind only, omit for code}" } } -
失败:
PATCH+"action": "fail"。"error" -
输出 task id、project id、conversation id、kind(|
code)及一行摘要。content
Errors
错误
| Code | Action |
|---|---|
| MISSING_KEY / 401 | Fix API key |
| 404 | Wrong ids |
| 409 | Skip; re-list next poll |
| 402 / 429 | Stop — https://app.originmind.ai/ |
| Code | 操作 |
|---|---|
| MISSING_KEY / 401 | 修复 API key |
| 404 | ids 错误 |
| 409 | 跳过;下次轮询时重新列出 |
| 402 / 429 | 停止——https://app.originmind.ai/ |
More detail
更多信息
- HTTP examples: reference.md
- HTTP 示例:reference.md