1
110
近 7 天 18
33.1
生态多维模型
1 个月前
2026-07-10
快速安装与配置
opencode.json写入当前项目的 opencode.json,只对这个仓库生效。
opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-yaml-workflows@0.1.20"]
}写入 ~/.config/opencode/opencode.json,对所有项目生效。
~/.config/opencode/opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-yaml-workflows@0.1.20"]
}若你要在本地改造这个插件,先装到项目里再从本地路径引用。
shell
pnpm add -D opencode-yaml-workflowsopencode 启动时会通过内嵌运行时自动加载 npm 依赖并缓存至本地目录,无需手动在全局环境执行安装。
中文 | English
Run repeatable opencode workflows from YAML. Use /workflow to run an existing workflow, or ask it to create a new one for review, audit, research, migration, or any other multi-agent routine you want to keep, edit, and reuse.
Install
Add the plugin to your opencode config:
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-yaml-workflows"]
}
Restart opencode after changing the config.
For local development:
git clone https://github.com/dingyi222666/opencode-yaml-workflows
cd opencode-yaml-workflows
bun install
bun run build
Then point your config at the local path:
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["/absolute/path/to/opencode-yaml-workflows"]
}
Use
Put workflow files in one of these places:
~/.config/opencode/workflows/.opencode/workflows/.workflows/
Then run an existing workflow with:
/workflow review the current diff
Or ask the model to create a new workflow:
/workflow create a release-check workflow for this repo and save it
The model will either find a matching workflow, or generate a new YAML workflow from your request. If you ask it to save the result, it can write the workflow to .workflows/ or .opencode/workflows/ for reuse.
Why YAML?
Claude Code Dynamic Workflows generate JavaScript orchestration scripts at runtime. This plugin uses YAML instead, so the workflow is easy to read, diff, commit, and share with a team.
Use it when you want stable workflows that live with your project, such as code review, security audit, release checks, or recurring research.
Docs
Development
bun test
bun run check
bun run build
npm pack --dry-run
License
MIT