Skip to main content
Glama

Agent Conductor

icohangar-ops/agent-conductor MCP server

MCP Registry npm PyPI Conformance

Cubiczan stack — Profile · CHP · 你在这里: agent-conductor

AGENTS.md 进,受治理的代理团队出。

Agent Conductor 是一个 MCP 服务器,它将编码代理生态系统已趋同的两大约定 —— AGENTS.md 操作手册和 SKILL.md 技能 —— 从被动文档转变为主动编排层, 并以共识加固的决策引擎为高风险更改把关。


问题

每一个严肃的代理工具 —— Claude Code、Cursor、Copilot、Codex、Gemini CLI —— 现在都会读取仓库根目录下的 AGENTS.md 和一批 SKILL.md 文件。 但这两大约定都是靠自觉的文本:

  • 没有任何东西编译契约。不可协商的规则、层边界和验证清单以 markdown 形式存在,代理可能内化,也可能不内化。

  • 没有任何东西把关决策。一个即将重写你评分模型的代理,与一个重命名变量的代理,以同样的信心推进。

  • 没有任何东西验证清单是否执行。"交接前运行 npm test" 只是建议,不是门禁。

Conductor 让这些约定变得可执行 —— 无需任何代理工具做出更改。它以标准 MCP 服务器形式发布, 因此任何支持 MCP 的工具都能免费获得契约编译、技能发现和决策把关。

Related MCP server: @event4u/agent-config

工作原理

MCP client (Claude Code / Cursor / Copilot / ...)
        │  stdio (JSON-RPC, MCP)
        ▼
┌────────────────────────────────────────────────┐
│ TypeScript front end (src/)                    │
│   contract/parser.ts   AGENTS.md → contract    │
│   skills/loader.ts     SKILL.md discovery      │
│   server.ts            7 MCP tools             │
└────────────────┬───────────────────────────────┘
                 │  newline-delimited JSON, child stdio
                 ▼
┌────────────────────────────────────────────────┐
│ Python decision engine (engine/)               │
│   bridge.py → PyPI consensus-hardening-protocol│
│   R0 gates · foundation attacks · lifecycle    │
└────────────────────────────────────────────────┘

三大能力组:

  1. 契约 — 将 AGENTS.md 编译为结构化的使命、不可协商规则、层级的做/不做边界、验证门禁、技能推荐和范围外清单。

  2. 技能 — 跨项目和个人的范围发现 SKILL.md 技能,采用渐进式披露:元数据约消耗 100 个 token,正文仅在需要时加载。

  3. 决策 — 通过 Consensus Hardening Protocol 为工作把关:工作开始前的低成本 R0 合理性检查,以及高风险更改锁定前的对抗性基础攻击检查。

快速开始

npx -y @cubiczan/agent-conductor
pip install consensus-hardening-protocol   # required for decision_* tools

npm: @cubiczan/agent-conductor · PyPI: consensus-hardening-protocol

要求:Node 23+(原生运行 TypeScript)和 Python 3.10+,并安装已发布的 CHP 包。

git clone https://github.com/icohangar-ops/agent-conductor.git
cd agent-conductor
npm install
pip install -r engine/requirements.txt
npm test            # TypeScript tests (parser, skills, live engine bridge)
npm run test:engine # Python bridge protocol tests
npm run build

在 Claude Code 中注册:

claude mcp add agent-conductor -- node /path/to/agent-conductor/dist/index.js

或在任何 MCP 客户端的 JSON 配置中:

{
  "mcpServers": {
    "agent-conductor": {
      "command": "npx",
      "args": ["-y", "@cubiczan/agent-conductor"]
    }
  }
}

如果您的 Python 3 不在 python3 路径下,请设置 CONDUCTOR_PYTHON。

然后,在任何一个包含 AGENTS.md 的项目中:

"加载此项目的代理契约,列出其验证门禁,并对我即将进行的更改运行一次 decision_adversary 检查。"

工具参考

contract_load

将 AGENTS.md(或 CLAUDE.md)编译为结构化契约。接受文件路径或项目目录;默认为当前工作目录。

// input
{ "path": "examples/pipeline-pulse" }

// output (abridged — real output from the bundled example)
{
  "source": "examples/pipeline-pulse/AGENTS.md",
  "title": "AGENTS.md — Pipeline Pulse CRM",
  "mission": "Pipeline Pulse CRM is a lightweight, local-first pipeline review dashboard...",
  "rules": [
    "Deterministic logic — same inputs → same scores, labels, and summaries...",
    "Logic in crm.js — keep main.js thin (fetch, render, events).",
    "... (6 total)"
  ],
  "layers": [
    { "layer": "src/crm.js", "role": "Domain logic",
      "do": "Deterministic scoring, filtering, summaries", "dont": "DOM manipulation" }
  ],
  "gates": [
    { "name": "Code change checklist", "commands": ["npm test"], "notes": "" },
    { "name": "Before completion", "commands": [], "notes": "npm test — all green...\n..." }
  ],
  "skills": [
    { "task": "CRM scoring / forecast changes", "skill": "obra/test-driven-development",
      "url": "https://github.com/obra/superpowers/...", "why": "Tests-first changes to deterministic logic" }
  ],
  "outOfScope": ["External CRM integrations (Salesforce, HubSpot, etc.)", "..."],
  "sectionCount": 28
}

解析器是无损的:它无法识别的小节会逐字保留,因此非传统 AGENTS.md 中的任何内容都不会被丢弃。

contract_verification

仅返回验证门禁 —— 即工作交接前必须通过的具名清单和 shell 命令。将其与代理的工作流配合使用:运行命令,确认成功,然后宣布完成。

skills_list

发现从项目根目录可见的 SKILL.md 技能。仅元数据。

// input
{ "projectRoot": "examples/pipeline-pulse" }

// output
{
  "skills": [
    {
      "name": "pipeline-scoring",
      "description": "Explain and modify scoreDealRisk weights in src/crm.js with matching test updates...",
      "version": "0.1.0",
      "scope": "project"
    }
  ]
}

搜索顺序(每个技能名称首次命中者优先):

优先级

路径

范围

1

<project>/.conductor/skills/*/SKILL.md

项目

2

<project>/.claude/skills/*/SKILL.md

项目

3

<project>/.cursor/skills/*/SKILL.md

项目

4

~/.claude/skills/*/SKILL.md

个人

5

~/.cursor/skills/*/SKILL.md

个人

skill_load

加载指定技能的完整 SKILL.md 正文 —— 渐进式披露的按需部分。仅当任务与技能描述匹配时才调用它。

decision_gate

Consensus Hardening Protocol R0 门禁:成本最低、杠杆最高的检查,在开展工作之前运行。

// input
{ "solvable": true, "scoped": false, "valid": true, "worth_it": true }

// output
{ "verdict": "HALT", "results": { "Solvable": "PASS", "Scoped": "FATAL", "Valid": "PASS", "Worth_it": "PASS" } }

任何 FATAL 答案都会中止:在把 token 浪费在一个未界定范围、未被理解或不值得解决的问题之前,停下来重新框定。

decision_adversary

针对高风险更改的一次性对抗性检查:CHP 攻击主张的基础,为其打分 0–100,并返回魔鬼代言人式的发现以及会话状态。

// input
{
  "claim": "Change scoreDealRisk stale-activity weight from 20 to 30",
  "context": "Tests updated; label distribution checked against fixture"
}

// output
{
  "status": "EXPLORING",          // or HALT / REFRAME_REQUIRED
  "foundation_score": 77,
  "findings": [
    "Treat every financial number as unverified until tied to source data.",
    "Require explicit flip criteria for any provisional recommendation."
  ],
  "verification_failures": ["PENDING third-party validation"],
  "report": "## TriangulationRunner Adversary Pass\n..."
}

状态映射到 CHP 决策生命周期 (EXPLORING → PROVISIONAL_LOCK → LOCKED,带有 HALT 和 REFRAME_REQUIRED 出口):EXPLORING 表示主张在攻击中幸存,工作可以继续走向锁定;HALT/REFRAME_REQUIRED 表示基础失败。

engine_status

对 Python 引擎子进程进行健康检查。返回 { ok, engine: "chp", version }。

解析器识别的内容

contract_load 基于约定,而非基于模式。它提取现实世界中 AGENTS.md 文件实际使用的模式:

契约字段

来源约定

mission

第一个 Mission / Purpose / Overview 小节

rules

Non-negotiables > Engineering rules > 通用 rules 下的列表项(按优先级排序,因此通用的 "Product rules" 小节永远不会遮蔽明确的不可协商项)

layers

架构类标题下第一个包含 Layer 列的表

gates

清单 / 验证 / 完成前标题下的 Shell 代码块 + 列表项

skills

包含 Task / Skill / Why 列的表;链接解析为文本 + URL

outOfScope

范围外 / 非目标标题下的列表

sections

所有内容,逐字保留 —— 无损回退

代码围栏内的标题会被忽略;表格容忍标题中的强调;提取的文本会去除 markdown 链接和强调。

编写技能

技能是包含带 YAML 前置元数据的 SKILL.md 的目录:

---
name: pipeline-scoring
description: Explain and modify scoreDealRisk weights in src/crm.js with matching test updates. Use when changing deal risk scoring, risk labels, or forecast thresholds.
version: 0.1.0
tools: [Read, Edit, Bash]
---

# Pipeline Scoring

Step-by-step instructions the agent follows when the task matches...

质量标准(继承自 awesome-agent-skills 标准):带有可匹配关键词的第三人称描述,元数据约 100 个 token,正文不超过 500 行,无机器特定的绝对路径,仅声明技能所需的工具。

随附的示例 —— examples/pipeline-pulse —— 是一个完整的真实世界 AGENTS.md 外加一个项目范围的技能,也是测试套件所编译的内容。

项目结构

.
├── AGENTS.md                  # This repo's own contract (compiles with itself)
├── ARCHITECTURE.md            # Design decisions and component detail
├── src/
│   ├── index.ts               # stdio entrypoint
│   ├── server.ts              # MCP server: 7 tools
│   ├── contract/              # AGENTS.md → AgentContract compiler
│   ├── skills/                # SKILL.md loader + registry
│   ├── engine/chpBridge.ts    # Python engine client
│   └── utils/logger.ts        # stderr-only logging (stdout is the transport)
├── engine/
│   ├── bridge.py              # JSON-over-stdio router → PyPI `chp`
│   ├── requirements.txt       # consensus-hardening-protocol pin
│   ├── NOTICE.md              # attribution for the published engine
│   └── test_bridge.py         # protocol tests
├── examples/pipeline-pulse/   # real AGENTS.md fixture + example skill
└── test/                      # node:test suites (run the .ts directly)

开发

pip install -r engine/requirements.txt
npm test            # TypeScript tests — includes a live engine round-trip
npm run test:engine # Python-side protocol tests
npx tsc --noEmit    # type check
npm run build       # emit dist/
npm run dev         # run the server from source (Node type stripping)

内部规则(完整版位于本仓库自己的 AGENTS.md 中):

  1. stdout 是神圣的 —— MCP 传输层独占它;桥接两侧的所有日志都输出到 stderr。

  2. 零新增 Node 运行时依赖 —— 仅 @modelcontextprotocol/sdk 和 zod;markdown/frontmatter 保持手写。CHP 是 PyPI 依赖。

  3. 仅可擦除的 TypeScript —— 源码必须在 Node 的类型剥离下运行(无枚举、无参数属性)。

  4. CHP 通过 PyPI —— 安装 consensus-hardening-protocol;不要在 engine/ 下重新内置。协议修复属于上游。

  5. Python 3.10+ —— 已发布包的要求。

路线图

版本

主题

范围

v0.2

执行

将 contract_verification 门禁作为真实子进程执行并返回通过/失败证据 —— 将"读取契约"转变为"执行契约"

v0.3

编排

通过 MCP 暴露 decision_lock + 网格会话工具(在已发布的 CHP 之上进行多代理审议)

v0.4

注册表

从远程目录(awesome-agent-skills 格式)安装经过审查的技能,并附带来源审查提示

来源

Conductor 刻意复用经过验证的组件,而不是重写它们:

组件

来源

许可证

决策引擎(PyPI)

consensus-hardening-protocol

MIT

MCP 服务器 + 注册表形态

onchainmind

MIT

技能质量标准

VoltAgent/awesome-agent-skills

—

示例夹具

Pipeline Pulse CRM 操作手册

fixture

有关双语言设计,请参阅 engine/NOTICE.md 和 ARCHITECTURE.md。


Cubiczan stack

| 治理 | consensus-hardening-protocol · agent-conductor · compliance-as-code-agent · cleanmandate | | 平台 | cubiczan-mcp-server · operational-intelligence · software-factory |

Conductor 将 AGENTS.md + SKILL.md 编译为 MCP 工具,并通过 CHP 路由高风险决策——这与 Metabocommand 用于财务审批的锁模型相同。

许可证

MIT — 参见 LICENSE。内置的第三方组件保留其原始 MIT 许可证。

Available Tools

7 tools
contract_loadA

Compile an AGENTS.md operating manual into a structured agent contract: mission, non-negotiable rules, layer responsibilities, verification gates, recommended skills, and out-of-scope list. Pass a file path or a project directory (defaults to the current working directory).

Inputs: path.

contract_verificationA

Return the verification gates from a project's agent contract — the named checklists and shell commands that must pass before work is handed off. Run these and confirm success before declaring any task complete.

Inputs: path.

decision_adversaryA

Run a one-shot Consensus Hardening Protocol adversarial pass against a claim or proposed change: CHP attacks its foundations, scores them 0-100, and returns findings plus a session status (EXPLORING / HALT / REFRAME_REQUIRED). Use before locking any high-stakes decision.

Inputs: claim (required), context, high_stakes.

decision_gateA

Run the Consensus Hardening Protocol R0 gate on a proposed decision: is it solvable, scoped, valid, and worth making at all? Any FATAL answer returns HALT — stop and reframe before doing the work.

Inputs: valid (required), scoped (required), solvable (required), worth_it (required).

engine_statusA

Health/readiness probe for the CHP decision engine (Python subprocess). By default returns a cheap readiness snapshot (running, last exit code, restart-backoff state) WITHOUT spawning Python. Pass probe=true to also issue a live ping that warms/spawns the subprocess.

Inputs: probe.

skill_loadA

Load the full SKILL.md body for a named skill — the on-demand half of progressive disclosure. Call only when the current task matches the skill's description.

Inputs: name (required), projectRoot.

skills_listA

Discover SKILL.md skills visible from a project root (project-scope .conductor/.claude/.cursor skill dirs, then personal ones). Returns metadata only (~100 tokens per skill); use skill_load for the full body.

Inputs: projectRoot.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.1/5.0

    Scored across 7 tools

    Disambiguation5/5

    Each tool targets a distinct responsibility: contract compilation, verification gate retrieval, skill discovery, skill body loading, decision gating, adversarial review, and engine health. Even the two decision tools are clearly separated by depth: one is a lightweight pre-check, the other is a full adversarial pass.

    Naming Consistency4/5

    The naming generally follows a resource_prefix_action pattern (contract_load, skills_list, decision_gate), but there are minor inconsistencies: contract_verification and engine_status are noun-phrase rather than verb-action, and skills_list/skill_load mix plural and singular forms. The pattern is still readable and predictable overall.

    Tool Count5/5

    Seven tools is well-scoped for the server's purpose: two for contracts, two for skills, two for decision support, and one operational health probe. Each tool fills a distinct slot with no obvious bloat or redundancy.

    Completeness4/5

    The core workflows are covered: contracts can be loaded and verified, skills can be discovered and loaded, and decisions can be gated and adversarial-tested. Minor gaps exist, such as the lack of a tool to explicitly execute verification gates or persist/review decision outcomes, but agents can work around these with shell commands and existing server behavior.

    Maintenance

    ActivityNo data
    ResponsivenessSyncing

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables offline AI agent automation with embedded local LLM (Qwen 2.5), sandboxed file operations through AgentFS, and dynamic skill loading. Exposes capabilities via MCP with tri-state safety guards for private, air-gapped environments without network connectivity or API costs.
      -
    • A
      license
      B
      quality
      A
      maintenance
      Universal AI Agent OS — governed skills, rules, and commands for AI coding assistants (Claude Code, Augment, Cursor, Copilot, Windsurf). Read-only MCP bridge serves prompts and resources from a release-pinned content bundle.
      29
      2,615 npm
      20
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Multi-server MCP aggregator with 266 skills, an orchestration runtime, fleet/claims coordination, and hook-driven session governance for autonomous Claude/Cursor/Gemini agent runs.
      4
      MIT