Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

jonnyhoo/menkan

Repository files navigation

Menkan

Spec as Source — 意图即程序

OpenCode 插件,提供多代理系统、编排器和质量门禁。

安装

git clone https://github.com/jonnyhoo/menkan
cd menkan
bun install
bun run build
cd packages/opencode && bun link

在 OpenCode 配置目录链接:

cd ~/.config/opencode
bun link @menkan/opencode

创建插件加载器 ~/.config/opencode/plugin/menkan-opencode.ts:

export { default } from "@menkan/opencode"

配置

创建 ~/.config/opencode/oh-my-opencode.jsonc:

{
 "agents": {
 "oracle": { "model": "anthropic/claude-sonnet-4-20250514" },
 "explore": { "model": "anthropic/claude-sonnet-4-20250514" },
 "orchestrator-sisyphus": {
 "permission": { "task": "allow", "call_omo_agent": "allow" }
 }
 },
 "menkan": {
 "enabled": true,
 "mode": "full",
 "strictness": "medium"
 }
}

架构

menkan/
├── packages/
│ ├── gate/ # @menkan/gate - 状态机核心
│ │ ├── 状态机 (INIT → PRD → DESIGN → TASKS → CODE → REVIEW → MERGED)
│ │ ├── 质量门禁 (rule-validator, semantic-validator)
│ │ ├── AI 缺陷缓解 (loop-detector, circuit-breaker)
│ │ └── 学习闭环 (lesson-capture)
│ │
│ └── opencode/ # @menkan/opencode - OpenCode 插件
│ ├── 17 个专门化 Agents (5 层架构)
│ ├── 成熟 Hooks (session-recovery, preemptive-compaction, rules-injector)
│ └── Skills (code-review, pr-review-toolkit)

Agents

层级 Agent 职责
调度层 Sisyphus 主力编排器,多阶段工作流
orchestrator-sisyphus 超强调度器,委派所有工作
探索层 explore 代码库搜索专家
librarian 外部文档/OSS 专家
咨询层 oracle 高 IQ 调试 + 架构咨询
metis 计划前咨询
momus 计划审查
执行层 frontend-ui-ux-engineer 前端 UI/UX 专家
document-writer 技术文档专家

状态机

INIT → PRD_READY → DESIGN_READY → TASKS_READY → CODE_READY → REVIEW_PASSED → MERGED

三层闭环

  1. 规范执行 - CONSTITUTION.md 规则强制校验
  2. 语义验证 - LLM-as-Judge 内容质量评估
  3. 学习闭环 - 错误信号检测 → 经验提取 → 规则注入

使用

启动 OpenCode 后按 Tab 切换代理:

  • Sisyphus - 默认构建代理
  • Prometheus (Planner) - 规划代理
  • orchestrator-sisyphus - 编排器

License

SUL-1.0

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

AltStyle によって変換されたページ (->オリジナル) /