mcp-server-decisions

mcp-server-decisions

Tracks architectural decisions with testable predictions, outcome validation, and in-band feedback nudges to close decision loops for AI agents and teams.

Category
访问服务器

README

<!-- mcp-name: io.github.Roberton003/mcp-server-decisions -->

<div align="center">

🧠 MCP Server: Decisions

Python 3.10+ License: MIT Registry GitHub

<p align="center"> <b>Architectural decision tracking with prediction validation and outcome gates.</b><br /> Record choices, state testable predictions, measure outcomes, and close the feedback loop for AI agents & teams. </p>


</div>

⚡ Zero External Dependencies • Stdlib-only Python • Append-only JSONL storage • Fully portable


📌 Key Features

  • 🎯 Decision Recording — Capture architectural choices with problem statement, solution, rejected alternatives, and target technologies.
  • 📈 Prediction Linking — Attach testable claims (latency, cost, scalability, reliability) tied to decisions.
  • ✅ Outcome Validation — Record measured results and automatically compute accuracy scores (0–100 scale).
  • 📊 Technology Performance Registry — Aggregate success rates and confidence metrics per technology over time.
  • 🚪 Outcome Gate Pattern — In-band nudges inside tool responses prevent decision feedback loops from leaking (3.8% → 14.5% closure rate).
  • ⚡ Zero Dependencies — Portable append-only JSONL log. No database servers, no migrations, no background daemons.

⚡ Quick Example

1️⃣ Record a Decision

# Agent or user records a choice:
record-decision(
  problem="Query latency exceeds SLA (p99 > 500ms)",
  chosen_solution="DuckDB + Parquet caching",
  rejected_alternatives=["Redis", "Elasticsearch"],
  technologies=["duckdb", "parquet"],
  predictions=[
    {"prediction_type": "LATENCY", "predicted_value": "p99 < 200ms"},
    {"prediction_type": "COST", "predicted_value": "< $50/month"}
  ]
)
# ➔ Returns: DEC-2026-0001, PRD-2026-0001, PRD-2026-0002

2️⃣ Record an Outcome

record-outcome(
  prediction_id="PRD-2026-0001",
  actual_value="p99 = 180ms",
  measurement_source="MONITORING",
  accuracy_score=95
)
# ➔ Returns: SUCCESS ✅ (95% accuracy)

3️⃣ Query Prior Decisions & Technology Stats

# Search past decisions before choosing a technology:
query-decisions(technology="duckdb", max_results=5)

# View aggregated technology performance:
python3 scripts/technology_performance_report.py
# ➔ Output:
# technology: duckdb  | successful: 12 | failed: 1 | avg_accuracy: 91.2% | confidence: HIGH

🚀 Quick Start & Setup

📦 Installation

# From PyPI (once published) or local editable install:
pip install -e .

🛠️ Client Configuration

Add to your MCP client configuration (e.g. Claude Desktop, Claude Code, Cursor, OpenCode):

{
  "mcpServers": {
    "mcp-server-decisions": {
      "type": "stdio",
      "command": "mcp-server-decisions"
    }
  }
}

For client-specific setup guides (Claude, OpenCode, Codex, Antigravity), see 📖 docs/INTEGRATIONS.md.


How It Works

The Loop

Decide → Predict → Implement → Measure → Validate → Learn → Next Decision
  1. Record a decision — Store the problem, chosen solution, alternatives, and technologies
  2. Make predictions — Attach testable claims (latency, cost, reliability, etc.)
  3. Implement — Build the system
  4. Measure results — Capture actual values from monitoring, logs, benchmarks
  5. Validate — The server calculates accuracy (0-100) and validation status (SUCCESS / PARTIAL_SUCCESS / FAILED)
  6. Learn — Review what worked via the Technology Performance Registry
  7. Next decision — Query past decisions before making new recommendations

The Outcome Gate Pattern

Decision loops leak because predictions aren't validated. This server embeds a reminder directly in tool responses:

Without Outcome Gate:

  • Decision is made → implementation starts → results come in → nobody checks if prediction was right

With Outcome Gate:

{
  "decision_id": "DEC-2026-0001",
  "status": "OK",
  "OUTCOME_GATE": "⚠️  2 prediction(s) from this session still lack outcomes: [PRD-2026-0001, PRD-2026-0002]. Record results via record-outcome before ending."
}

The nudge is in-band (inside the tool response), where agents are already looking. Result: 3.8% → 14.5% closure rate improvement (validated on internal tool).

Real Example: After recording a decision with 3 predictions, the response includes:

{
  "decision_id": "DEC-2026-0042",
  "prediction_ids": ["PRD-2026-0051", "PRD-2026-0052", "PRD-2026-0053"],
  "status": "OK",
  "OUTCOME_GATE": "⚠️  3 prediction(s) from this session still lack outcomes: [PRD-2026-0051, PRD-2026-0052, PRD-2026-0053]. Record results via record-outcome before ending."
}

Next query still shows the gate until all 3 outcomes are recorded. Once they are, the gate disappears automatically.

For the full pattern explanation, see docs/OUTCOME-GATE-PATTERN.md.

🏛️ Architecture & Tech Stack

  • Storage: Single append-only JSONL file (no database setup, no migrations, portable & git-friendly).
  • IDs: Sequential per calendar year (DEC-2026-0001, PRD-2026-0002, OUT-2026-0003).
  • Accuracy Scoring: Automatic classification (≥90 SUCCESS, 50–89 PARTIAL_SUCCESS, <50 FAILED).
  • Runtime: Stdlib-only Python 3.10+ (zero external pip runtime dependencies).
  • Protocol: Model Context Protocol (JSON-RPC 2.0 over stdio).

⚙️ Environment Variables

Variable Description Default Path
MCP_DECISIONS_LOG_PATH Path to the append-only JSONL log file ~/.local/share/mcp-decisions/decisions_log.json

📚 Documentation & Resources

Document Purpose
⚡ Quick Start 5-minute setup guide & first decision
🔌 Client Integrations Setup configs for Claude, OpenCode, Codex, Antigravity
📐 Architecture & Design Core design rationale & data models
💡 Detailed Examples Real JSON-RPC request/response payloads
🚪 Outcome Gate Pattern In-band feedback loop design philosophy
📖 Wiki FAQ and advanced topics

🧪 Development & Testing

Run unit & selftests locally:

python3 server.py --selftest
# ➔ ✅ All self-tests passed

See 📝 CONTRIBUTING.md to contribute features or fixes.


🗺️ Roadmap

  • [x] Core decision / prediction / outcome tracking
  • [x] Outcome Gate in-band nudges
  • [x] Technology Performance Registry
  • [ ] Web UI for browsing & searching decisions
  • [ ] Webhooks / notifications on low prediction accuracy
  • [ ] Pre-built decision templates & domain patterns

📄 License & Disclaimer

MIT © 2026 Roberton003 — See LICENSE.

This project is community-built and independent. It is not affiliated with any organization or standard-setting body.


<div align="center"> <b>Made for AI agents. Built for teams. Learn from every decision.</b> </div>

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选