Borrowing it
Nothing to install: this file belongs to blueman82/ai-counsel. 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/blueman82/ai-counsel/main/.claude/skills/mcp-server-enhancement/SKILL.mdgit clone --depth 1 https://github.com/blueman82/ai-counselWrote 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/skills/blueman82/ai-counsel/mcp-server-enhancement)<a href="https://agentmods.dev/skills/blueman82/ai-counsel/mcp-server-enhancement"><img src="https://agentmods.dev/badge/skills/blueman82/ai-counsel/mcp-server-enhancement/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/skills/blueman82/ai-counsel/mcp-server-enhancement"><img src="https://agentmods.dev/badge/skills/blueman82/ai-counsel/mcp-server-enhancement.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.00018 | $0.05382 |
| Opus 5 | $0.00009 | $0.02691 |
| Sonnet 5 | $0.00004 | $0.01076 |
| Haiku 4.5 | $0.00002 | $0.00538 |
Grade B, and why
mcp-server-enhancement scanned grade B with 2 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 10d 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.
Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
Add your server to `~/.claude/config/mcp.json`: Runs shell commandslowCapability
Expected in a hook, worth knowing in a rule or an instructions file.
result = subprocess.run( How it starts
The opening of the file, as written. The whole thing — 760 lines — stays where its author put it; the contents beside it link to each section on GitHub.
MCP Server Enhancement Skill
This skill provides a systematic approach to extending the AI Counsel MCP server (server.py) with new tools while maintaining protocol compliance, stdio safety, and proper error handling.
Architecture Overview
The AI Counsel MCP server communicates via stdio (stdin/stdout) using the Model Context Protocol. Key architectural constraints:
- Stdio Safety: stdout is RESERVED for MCP protocol JSON. All logging MUST go to file (
mcp_server.log) or stderr - Protocol Compliance: Tools must follow MCP specification for request/response format
- Type Safety: Use Pydantic models for all request/response validation
- Error Isolation: Tool failures should return structured error responses, not crash the server
- Async First: All tool handlers are async functions using asyncio
Current Tool Architecture
Tool 1: deliberate (Primary Tool)
- Purpose: Multi-round AI model deliberation with consensus building
- Handler:
call_tool()function (lines 242-327 in server.py) - Request Model:
DeliberateRequest(models/schema.py) - Response Model:
DeliberationResult(models/schema.py) - Engine: Uses
DeliberationEngine.execute()for orchestration
Tool 2: query_decisions (Decision Graph Tool)
- Purpose: Search and analyze past deliberations in decision graph memory
- Handler:
handle_query_decisions()function (lines 329-415 in server.py) - Request Schema: Inline in
list_tools()(lines 196-237) - Response: Custom JSON structure (not a Pydantic model)
- Conditional: Only exposed if
config.decision_graph.enabled == True
Step-by-Step: Adding a New MCP Tool
Step 1: Define Pydantic Request/Response Models
Location: models/schema.py
Create type-safe models for your tool's inputs and outputs:
# In models/schema.py
class NewToolRequest(BaseModel):
"""Model for new_tool request."""
parameter1: str = Field(
...,
min_length=1,
description="Description of parameter1"
)
parameter2: int = Field(
default=5,
ge=1,
le=10,
description="Integer parameter with range validation"
)
optional_param: Optional[str] = Field(
default=None,
description="Optional parameter"
)
class NewToolResponse(BaseModel):
"""Model for new_tool response."""
status: Literal["success", "partial", "failed"] = Field(
...,
description="Operation status"
)
result_data: str = Field(..., description="Main result data")
metadata: dict = Field(default_factory=dict, description="Additional metadata")
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.
- 10d ago First seen · 760 lines · 18 tokens per session scan B 18a1c1185166
mcp-server-enhancement is a skill published in the GitHub repository blueman82/ai-counsel (1 stars, last pushed 4mo ago), licensed MIT. It adds 18 tokens to every session and 5,382 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 2 findings (reads agent configuration directories, runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
mcp-protocol-suite
Model Context Protocol (MCP) tool integration for connecting external MCP servers, enterprise tools, and APIs.
agent-communication-protocol
Open protocol for AI agent interoperability enabling standardized communication between agents, applications, and humans across different frameworks.
mcp-patterns
MCP server building, advanced patterns, and security hardening. Use when building MCP servers, implementing tool handlers, choosing a transport, adding OAuth authentication, wiring MCP Apps UI with @mcp-ui, hardening MCP security, or debugging MCP integrations.
mail-time
Use when building, wiring, reviewing, or debugging MailTime and ostrio:mailer email queues for horizontally scaled Node.js, Bun, or Meteor apps. Trigger on MailTime, MongoQueue, RedisQueue, PostgresQueue, mailTimePreset, JoSk email scheduling, Redis Cluster / KeyDB Cluster / Valkey useHashTags, KeyDB…
a0-development
Develop or operate Agent Zero: projects, chats, tasks, framework, tools and API/WebUI.
composio
Build AI agents and apps with Composio - access 200+ external tools with Tool Router or direct execution.