Borrowing it
Nothing to install: this file belongs to zhmxiaowo/opencode-simple. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/zhmxiaowo/opencode-simple/main/.opencode/commands/spec.mdgit clone --depth 1 https://github.com/zhmxiaowo/opencode-simpleWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/zhmxiaowo/opencode-simple/spec)<a href="https://agentmods.dev/commands/zhmxiaowo/opencode-simple/spec"><img src="https://agentmods.dev/badge/commands/zhmxiaowo/opencode-simple/spec/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/zhmxiaowo/opencode-simple/spec"><img src="https://agentmods.dev/badge/commands/zhmxiaowo/opencode-simple/spec.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00023 | $0.00421 |
| Opus 5.5 | $0.00009 | $0.00168 |
| Sonnet 5.5 | $0.00005 | $0.00084 |
| Haiku 4.5 | $0.00002 | $0.00042 |
Grade A, and why
spec 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 3mo ago.
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.
What it actually says
/spec — Spec-First 快捷方式
/plan的轻量版本 — 只输出 SPEC 部分,跳过实施步骤分解。
说明
/spec 与 /plan 共享同一个 planner agent 和同一套 Spec-First 流程(MCP 文档研究 → SPEC 输出 → 等待确认),区别仅在于:
| 命令 | 输出内容 |
|---|---|
/plan |
SPEC + 实施步骤 + 风险评估(完整) |
/spec |
仅 SPEC(API 设计、数据模型、依赖、编译计划) |
工作流程
- 需求确认 — 提取功能名称、技术栈、核心需求
- MCP 文档研究 — 并行调用
context7(官方文档)+exa-web-search(社区实践) - 输出 SPEC — 生成包含以下章节的规范文档:
- API / 接口设计(精确到可直接复制到代码)
- 数据模型
- 依赖项及版本
- 编译验证计划(具体命令)
- 已知限制 & 兼容性
- 参考文档链接
- 等待确认 — 必须等用户明确确认后方可编码
参数
/spec Unity PlayerController/spec Cocos 2D骨骼动画/spec UE5 Gameplay Ability System/spec React Dashboard
何时用 /spec,何时用 /plan
- 小功能 / 单文件改动 →
/spec足够 - 多文件 / 跨模块 / 需要分阶段实施 → 用
/plan(包含 SPEC + 完整步骤)
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.
- 3mo ago First seen · 43 lines · 23 tokens per session scan A 2e518d3a52a5
spec is a command published in the GitHub repository zhmxiaowo/opencode-simple (2 stars, last pushed 8mo ago), licensed MIT. It adds 23 tokens to every session and 421 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
spec compared with commands from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| speczhmxiaowo/opencode-simple | Command | 2 | 8mo ago | MIT | A | 23 | Claude Code, OpenCode |
| checklistgithub/spec-kit | Command | 153k | today | MIT | A | 13 | Claude Code |
| clarifygithub/spec-kit | Command | 153k | today | MIT | A | 27 | Claude Code |
| specifygithub/spec-kit | Command | 153k | today | MIT | A | 13 | Claude Code |
| analyzegithub/spec-kit | Command | 153k | today | MIT | A | 26 | Claude Code |
| convergegithub/spec-kit | Command | 153k | today | MIT | A | 35 | Claude Code |
| implementgithub/spec-kit | Command | 153k | today | MIT | A | 14 | Claude Code |