advisor-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@advisor-mcpGet a second opinion on my rollout plan before I refactor the auth service"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
advisor-mcp
advisor-mcp is a model-agnostic MCP server that gives any agent an independent second opinion during a task. It is inspired by the Claude Code / Claude API advisor pattern: a faster executor does the work while a stronger model is consulted only at consequential decision points.
Implemented with the stable MCP TypeScript SDK v2 (@modelcontextprotocol/server 2.x, MCP spec 2026-07-28) and cross-checked against Claude Code 2.1.302 and MCP 2025-era clients. See docs/architecture.md for the research notes and design rationale.
The advisor is deliberately read-only. It cannot inspect the workspace, execute commands, or edit files. The calling agent supplies a compact evidence pack and remains responsible for verifying and applying the advice.
Why this differs from Claude Code's built-in advisor
Claude Code implements the advisor as a server-side tool. The API automatically passes the executor's full conversation, including tool calls and results, to a second model inside the same model request. The client cannot construct or alter that advisor context.
An MCP server is outside the host model request. It cannot see the host's full transcript. advisor-mcp therefore makes context explicit:
the agent chooses when to consult;
the agent sends goal, state, evidence, constraints, and the exact question;
the server keeps a lightweight session across consults;
every advisor call returns structured guidance, not actions.
This is less automatic than the proprietary Anthropic tool, but it works with any MCP-capable host and any sufficiently capable model provider.
Related MCP server: second-opinion-mcp
Design
Host agent
|
| tools/call: consult_advisor
v
advisor-mcp ---> redact secrets ---> provider (OpenAI-compatible / Anthropic)
| |
|<--------- validated JSON advice <----+
|
+--> per-session state (goal, constraints, decisions, call budget)Key properties:
Explicit context: the agent controls what the advisor sees.
Evidence-first prompt: facts, attempts, and observed output are separated from assumptions.
Structured output: advice is parsed into a fixed schema and validated before return.
Session handle: repeated consults carry forward goal, constraints, touched files, and prior advice.
Call budget: caps advisor usage per session to prevent consult loops.
Secret redaction: common credentials are removed before the provider request.
Provider-neutral: OpenAI-compatible Chat Completions by default, Anthropic Messages optionally.
Two transports: stdio for local hosts, Streamable HTTP for remote agents.
Deployment guards: bearer auth, Host/Origin allowlists, body/concurrency limits, and per-client rate limiting in HTTP mode.
Tools
Tool | Purpose |
| Ask for a plan critique, diagnosis, risk review, decision, completion review, or handoff summary. |
| Read the stored goal, constraints, decisions, open questions, call count, and recent consults. |
| Record durable state without spending an advisor call. |
| Delete session state when the task ends or changes fundamentally. |
| Report non-secret configuration without making a model request. |
consult_advisor accepts:
required:
session_id,kind,questioncontext:
goal,state,attempt,expected_outcome,constraints,evidence,context,options,files_touchedcontrol:
style,include_history,max_history_messages
kind is one of plan, stuck, review, risk, decision, or handoff.
Install
npm install
npm run buildNode.js 20.18 or later is required.
Configure
The server reads configuration from its process environment. It does not load .env files automatically.
OpenAI-compatible endpoint
export ADVISOR_PROVIDER=openai-compatible
export ADVISOR_MODEL=your-model-id
export ADVISOR_API_KEY=...
# Optional; the default is https://api.openai.com/v1
export ADVISOR_BASE_URL=https://api.openai.com/v1
node dist/index.jsOPENAI_API_KEY is accepted as a fallback for ADVISOR_API_KEY. Set ADVISOR_BASE_URL for OpenRouter, vLLM, Ollama, LM Studio, or another Chat Completions-compatible endpoint. A key is optional for local endpoints; if omitted no Authorization header is sent. Azure OpenAI's native API uses deployment paths and api-version; use a compatible gateway unless you add a dedicated adapter.
Some OpenAI-compatible servers reject max_completion_tokens. Set:
export ADVISOR_TOKEN_PARAM=max_tokensAnthropic
export ADVISOR_PROVIDER=anthropic
export ADVISOR_MODEL=claude-sonnet-4-6
export ANTHROPIC_API_KEY=...
node dist/index.jsADVISOR_API_KEY takes precedence over ANTHROPIC_API_KEY. This mode calls the ordinary Messages API; it does not reproduce Anthropic's server-side advisor tool or its encrypted advisor result.
Limits
Variable | Default | Meaning |
|
| Advisor output cap per call. |
|
| Provider timeout per attempt. |
|
| Evidence budget before truncation. |
|
| Advisor calls allowed per session. |
|
| Advisor calls allowed per session per minute. |
|
| Default advice style: |
|
|
|
|
| Session directory when file storage is enabled. |
Use ADVISOR_STORE=file when the host may restart the MCP process between consults. File names are hashed, directory and file permissions are restricted, but stored prompts and advice are still plaintext on disk. Choose memory for sensitive work.
Warning: do not configure an advisor that is weaker than the executor and expect a quality lift. The pattern works because the advisor contributes stronger judgment at selected moments.
Remote HTTP mode
Use HTTP when agents run on another machine, inside a container, or in a separate client that cannot launch a stdio process. The default transport is still stdio.
Start the server:
export ADVISOR_TRANSPORT=http
export ADVISOR_HTTP_HOST=0.0.0.0
export ADVISOR_HTTP_PORT=8787
export ADVISOR_HTTP_TOKEN="$(openssl rand -hex 32)"
export ADVISOR_PROVIDER=openai-compatible
export ADVISOR_MODEL=your-advisor-model
export ADVISOR_API_KEY=...
export ADVISOR_STORE=file
export ADVISOR_DATA_DIR=/srv/advisor-data
node dist/index.jsThe MCP endpoint is http://host:8787/mcp. Health is available without a token at http://host:8787/healthz. The server refuses to start without ADVISOR_HTTP_TOKEN unless the host is loopback and ADVISOR_HTTP_ALLOW_UNAUTHENTICATED_LOOPBACK=true.
Streamable HTTP request
-> Host / Origin policy
-> bearer token check
-> per-client request limit
-> concurrency limit
-> MCP 2026-07-28 handler (stateless transport)
-> advisor service (session_id-scoped state)Remote host configuration
Variable | Default | Meaning |
|
| Bind address. Use |
|
| Listen port. |
|
| MCP endpoint path. |
| empty | Bearer token; at least 16 characters, preferably 32 random bytes in hex. |
|
| Permit tokenless HTTP only on a loopback bind (development only). |
| empty | Comma-separated origin hostnames, or non-web wildcards such as |
| empty | Comma-separated Host hostnames. Set this in production. |
|
| Maximum MCP request body. |
|
| Concurrent MCP requests per process. |
|
| Requests per client IP per minute. |
|
| Trust |
Token-authenticated mode does not force localhost Host validation, so a reverse proxy may forward a public hostname. Set ADVISOR_HTTP_ALLOWED_HOSTS and ADVISOR_HTTP_ALLOWED_ORIGINS to constrain it. Non-browser clients normally omit Origin.
Connect a remote agent
Codex:
export ADVISOR_HTTP_TOKEN=...
codex mcp add advisor \
--url https://advisor.example.com/mcp \
--bearer-token-env-var ADVISOR_HTTP_TOKENClaude Code:
claude mcp add --transport http advisor \
https://advisor.example.com/mcp \
--header "Authorization: Bearer $ADVISOR_HTTP_TOKEN"Generic JSON:
{
"mcpServers": {
"advisor": {
"type": "streamable-http",
"url": "https://advisor.example.com/mcp",
"headers": {
"Authorization": "Bearer ${ADVISOR_HTTP_TOKEN}"
}
}
}
}If the client does not support headers or environment interpolation, terminate authentication at a reverse proxy and add the bearer token server-side.
Docker
export ADVISOR_HTTP_TOKEN="$(openssl rand -hex 32)"
export ADVISOR_MODEL=your-advisor-model
export ADVISOR_API_KEY=...
docker compose up -d --buildThe compose file binds the published port to 127.0.0.1; put a TLS reverse proxy in front of it or change the bind deliberately. The image runs as the unprivileged node user and keeps file sessions in the advisor-data volume.
For a public deployment:
Terminate TLS at a reverse proxy and forward to
http://127.0.0.1:8787.Set
ADVISOR_HTTP_ALLOWED_HOSTS=advisor.example.com.Set
ADVISOR_HTTP_ALLOWED_ORIGINSonly if browser clients call the endpoint.Keep
ADVISOR_HTTP_TOKENin a secret store, not in a committed env file.Run one replica or provide sticky routing by
session_id; file storage and in-process limits are not shared safely across replicas.
Connect to an MCP host
Codex
Add a stdio server in ~/.codex/config.toml:
[mcp_servers.advisor]
command = "node"
args = ["/absolute/path/to/advisorChou/dist/index.js"]
[mcp_servers.advisor.env]
ADVISOR_PROVIDER = "openai-compatible"
ADVISOR_MODEL = "your-advisor-model"
ADVISOR_API_KEY = "${ADVISOR_API_KEY}"
ADVISOR_STORE = "file"Then ask the agent to use consult_advisor at real decision points, or add that instruction to AGENTS.md. The server's own MCP instructions are also exposed to clients that display them.
Claude Code
claude mcp add advisor \
-e ADVISOR_PROVIDER=openai-compatible \
-e ADVISOR_MODEL=your-advisor-model \
-e ADVISOR_API_KEY="$ADVISOR_API_KEY" \
-- node /absolute/path/to/advisorChou/dist/index.jsClaude Code will still have its native advisor if enabled. Disable it with /advisor off when testing this server to avoid two independent mechanisms.
Generic JSON configuration
Most MCP hosts accept a stdio entry like:
{
"mcpServers": {
"advisor": {
"command": "node",
"args": ["/absolute/path/to/advisorChou/dist/index.js"],
"env": {
"ADVISOR_PROVIDER": "openai-compatible",
"ADVISOR_MODEL": "your-advisor-model",
"ADVISOR_API_KEY": "..."
}
}
}
}Do not put literal API keys in a repository-controlled host config. Prefer the host's secret or environment-variable mechanism.
Manage with Magpie / 通过 Magpie 管理
Magpie keeps MCP servers in its Library and writes them into every agent it manages (Claude Code, Codex, OpenCode, Cursor, ...) in each agent's own format.
Magpie 的 Library 统一管理 MCP server,并按各 agent 自己的格式写入它们的配置。
1. Local stdio server / 本地 stdio
# straight from GitHub (built on first install) / 直接从 GitHub 运行
magpie library mcp add advisor npx -y github:Fan-chou/advisor-mcp agents=none
# or from a local clone / 或使用本地 clone
git clone https://github.com/Fan-chou/advisor-mcp && cd advisor-mcp && npm ci && npm run build
magpie library mcp add advisor node "$PWD/dist/index.js" agents=noneThen open Magpie -> Library -> MCP servers -> advisor, fill in the environment variables (ADVISOR_PROVIDER, ADVISOR_MODEL, ADVISOR_API_KEY, ADVISOR_BASE_URL) and tick the agents that should get it (or run magpie library mcp agents advisor claude,codex).
然后在 Magpie -> Library -> MCP servers 打开 advisor,填写上面的环境变量,再勾选要启用它的 agent。
2. Remote server / 远程
magpie library mcp add advisor https://your-host/mcp agents=noneThen add the header Authorization: Bearer <ADVISOR_HTTP_TOKEN> on the server's page in Magpie. 远程方式必须带 bearer token。
3. Use Magpie as the advisor's upstream / 让 advisor 走 Magpie 网关
Magpie's gateway speaks the OpenAI-compatible API, so the advisor can use any model Magpie routes (for example a stronger model on your subscription):
ADVISOR_PROVIDER=openai-compatible
ADVISOR_BASE_URL=http://127.0.0.1:3425/v1 # your Magpie gateway port
ADVISOR_API_KEY=<a Magpie gateway key>
ADVISOR_MODEL=<a model name Magpie exposes>Recommended agent policy
Add instructions close to this to the host agent:
Use consult_advisor only at consequential decision points:
1. after reading enough context to understand the task, but before committing
to a non-obvious plan;
2. when the same error survives two genuine fix attempts;
3. before declaring a complex, risky, or broad change complete;
4. when evidence conflicts or two designs have material tradeoffs.
Do not consult for routine edits, simple lookups, or every turn. Reuse one
session_id per task. Send the goal, current state, exact question, concrete
evidence, constraints, and what was already tried. Redact secrets.
Treat advisor output as advice, not truth. Verify claims against files, tests,
and tool results. If the advice conflicts with observed evidence, report the
conflict instead of following it blindly.For a cheap executor, a turn-2 reminder can raise advisor usage. Do not use one blindly: Anthropic's own measurements show a badly timed nudge can reduce performance. Prefer outcome-based triggers such as "after two failed attempts" over a fixed turn number.
Session behavior
session_id is an opaque handle. A typical value is repo-name:task-slug. Reuse it for one task; reset it when the task ends. Avoid using one global session for unrelated work because stale constraints and decisions will contaminate new advice.
The service serializes concurrent calls for the same session. A call is counted before the provider request so crashes and retries cannot bypass the budget. Concurrent calls for different sessions can proceed independently.
Troubleshooting
configuration error: Missing ADVISOR_MODEL: set an explicit model ID.Provider returns HTTP 400 about a token field: set
ADVISOR_TOKEN_PARAM=max_tokens.Provider returns HTTP 401: check
ADVISOR_API_KEY,OPENAI_API_KEY, orANTHROPIC_API_KEYin the environment of the MCP process, not only your shell.limit_exceeded: reset the session or raiseADVISOR_MAX_CALLS_PER_SESSION.HTTP 401 from
/mcp: sendAuthorization: Bearer <ADVISOR_HTTP_TOKEN>;/healthzintentionally does not require it.HTTP 403 before JSON-RPC: check
ADVISOR_HTTP_ALLOWED_HOSTSandADVISOR_HTTP_ALLOWED_ORIGINS.HTTP 429: the client IP exceeded
ADVISOR_HTTP_REQUESTS_PER_MINUTE; wait forRetry-After.invalid_response: the provider could not produce the required JSON even after one repair attempt. Try a stronger model or inspect the provider compatibility.No advice history after restart: use
ADVISOR_STORE=file.
Development
npm run typecheck
npm test
npm run build
npm run checkTests use a fake provider and local HTTP servers; they do not call a paid model.
Verified locally:
43 unit, integration, provider, stdio, HTTP, and persistence tests pass;
the built server completes a full MCP call under Claude Code 2.1.302;
a raw 2025-06-18 handshake also lists all five tools successfully;
the HTTP runner serves
/healthzand rejects unauthenticated/mcpwith 401.
Limitations
The advisor does not see the full host transcript; context quality depends on the caller.
There is no automatic trigger. The host agent decides when to call.
Advice is advisory and can be wrong; independent verification is mandatory.
A single advisor call runs synchronously from the MCP client's perspective. Hosts may show a pause while it runs.
Provider-specific reasoning controls, prompt caching, and encrypted advisor results are not implemented.
HTTP mode uses a static bearer token, not OAuth; all clients share one advisor identity and call budget.
In-memory rate limits and per-session serialization are per process. Use sticky routing or a shared store before scaling horizontally.
License
MIT
Available Tools
5 toolsadvisor_healthAdvisor configuration healthARead-onlyIdempotent
Report non-secret configuration and verify that the configured provider has credentials. Does not make a model request.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint, idempotentHint, and openWorldHint=false. Beyond that, the description adds genuinely useful context: it discloses that only 'non-secret' config is reported (a security/privacy guarantee) and that it 'does not make a model request' (a side-effect boundary). These go beyond the annotations, though it stops short of explaining permissions or error modes when credentials are missing.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, tightly front-loaded with the core action, followed by the crucial side-effect clarification. No filler, every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-param read-only diagnostic with annotation coverage, the description supplies what matters: what is reported, what is verified, what is not done. Without an output schema it does not describe the response shape (e.g., per-provider pass/fail fields), which is the only remaining gap for an agent calling it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Zero-parameter tool, which is the baseline-4 case. There are no parameters to misinterpret, and the empty schema is fully consistent with a no-arg health check.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States specific operations: report non-secret configuration and verify configured provider credentials. The verb+resource is clear. It does not explicitly name or distinguish itself from the session-oriented siblings (get/consult/update/reset), relying on the reader to infer it is a distinct diagnostics tool rather than an advisor-session interaction.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description says what it does but gives no guidance on when to prefer it over siblings or when a health check is warranted. There are no exclusions or alternatives named, leaving the agent to infer the use case from the tool name alone.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
consult_advisorConsult an independent advisorA
Get an independent second opinion before committing to a non-obvious plan, after repeated failures, or before declaring complex work complete. Supply a compact evidence pack; the advisor cannot inspect your workspace. Each call counts toward the per-session call budget.
| Name | Required | Description | Default |
|---|---|---|---|
| goal | No | The user's task goal. | |
| kind | Yes | Consultation type. Choose based on the decision point. | |
| state | No | Current progress, observed behavior, and what has already been tried. | |
| style | No | ||
| attempt | No | The proposed approach or failed attempt to evaluate. | |
| context | No | Selected recent conversation or tool transcript. Prefer relevant excerpts over everything. | |
| options | No | Materially different options when asking for a decision. | |
| evidence | No | Concrete observations: errors, test output, stack traces, relevant code excerpts. | |
| question | Yes | The exact decision or question to answer. | |
| session_id | Yes | Stable handle for one task or conversation. Reuse it across consults. Generate one such as repo-name:task-id when starting. | |
| constraints | No | ||
| files_touched | No | ||
| include_history | No | Include prior consultations from this session. | |
| expected_outcome | No | Success criteria for the task. | |
| max_history_messages | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Both sentences of the second half add real context beyond the annotations: 'the advisor cannot inspect your workspace' explains why the evidence pack must be self-contained, and 'Each call counts toward the per-session call budget' discloses a cost constraint that annotations do not convey. It stops short of describing what form the advice comes back in or what the budget actually is, and annotations already cover the read-only/destructive profile.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, front-loaded with the decision triggers, then the input constraint, then the cost constraint. Every sentence earns its place with no restatement of the name or title.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 15-parameter, open-world consultation tool with no output schema, the description covers the essential decision context: when to call, that the advisor is blind to the workspace, and that calls consume budget. It leaves unstated what the response looks like and what the budget limit is, minor gaps against otherwise rich schema documentation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 73%, so most fields (goal, state, attempt, evidence, context, question, options) are already documented in the schema. The description contributes only the high-level framing of 'a compact evidence pack'; it says nothing about kind selection, session_id reuse, include_history, or the undocumented fields such as constraints, style, files_touched, and max_history_messages. Baseline 3 applies when the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb+resource ('Get an independent second opinion') backed by an advisor entity, which is clearly distinct from session-management siblings like get_advisor_session or reset_advisor_session. It never names those siblings explicitly, so the differentiation is implicit rather than spelled out.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It gives three concrete triggering conditions: before committing to a non-obvious plan, after repeated failures, and before declaring complex work complete. That is strong positive guidance, but it does not state when NOT to consult or which sibling to use for session inspection versus a fresh consult.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_advisor_sessionGet advisor session stateBRead-onlyIdempotent
Return the accumulated goal, constraints, decisions, open questions, attempted call count, and recent consults for a session_id.
| Name | Required | Description | Default |
|---|---|---|---|
| session_id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and closed-world scope, so safety is covered. The description contributes the shape of what is returned (goal, constraints, decisions, open questions, call count, recent consults), but says nothing about how many "recent consults" are included, behavior for an unknown/expired session_id, or whether state persists across resets.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
One sentence, front-loaded with the verb, with the returned fields enumerated as a compact list. No filler or repetition of the title.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema, the description correctly takes on the job of enumerating return values, which it does thoroughly. The remaining gap is operational: how to obtain a valid session_id and what an unknown id yields.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The single session_id parameter has 0% schema description coverage, so the description carries the burden of explaining it — yet it only restates "for a session_id" without saying where the id comes from (returned by consult_advisor? update_advisor_session?) or its format. It adds no meaning beyond the schema's type and length bounds.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb ("Return") and resource (accumulated session state for a session_id) and enumerates the exact fields returned, so an agent can tell it apart from consult_advisor, update_advisor_session, and reset_advisor_session. It stops short of explicitly naming those siblings, but the read-only state-recall framing is unmistakable.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no explicit when-to-use, when-not-to-use, or alternative named. Usage is only implied by the field list (you call it to recover prior context before consulting), leaving the agent to infer that this is the recall step in the advisor workflow.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
reset_advisor_sessionReset advisor sessionADestructive
Delete the stored state and call counter for a session_id. Use when the task is complete or the context has changed fundamentally.
| Name | Required | Description | Default |
|---|---|---|---|
| session_id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare destructiveHint=true, idempotentHint=false and readOnlyHint=false, so the safety profile is covered; the description usefully adds what exactly is lost (stored state and call counter) rather than leaving it to the agent to guess. It omits whether the deletion is recoverable and what happens to the session afterwards, but the core destruction scope is disclosed.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two tight sentences with the destructive action front-loaded and the usage condition second. Every clause earns its place and nothing is padded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a destructive, non-idempotent mutation with no output schema, the definition tells the agent what is removed and when to invoke it, but not the outcome for an invalid or already-reset session_id or whether the advisor session can be re-established. Adequate, with visible gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0% for the single required parameter, so the description must carry the burden, and it only restates the parameter name ('for a session_id') without explaining where the value comes from, its expected format, or whether an unknown id errors or is a no-op.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb and resource ('Delete the stored state and call counter') and scopes it to a single session_id. The delete semantics inherently separate it from get_advisor_session, update_advisor_session and consult_advisor, though it never names those siblings explicitly.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
'Use when the task is complete or the context has changed fundamentally' gives a concrete trigger condition that an agent can act on. It stops short of stating when not to use it (e.g. mid-conversation, or before harvesting results) or what to do instead of resetting.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
update_advisor_sessionUpdate advisor session stateAIdempotent
Record durable goal, constraints, touched files, or open questions without spending an advisor call.
| Name | Required | Description | Default |
|---|---|---|---|
| goal | No | ||
| session_id | Yes | ||
| add_constraints | No | ||
| add_files_touched | No | ||
| replace_open_questions | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare idempotent=true, destructive=false, openWorld=false, so the safety profile is covered; the description usefully adds that writes are 'durable' and cost-free relative to an advisor call. It omits what happens with an unknown session_id, whether omitted fields are preserved, and any confirmation of returned state.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single sentence with no filler, and the value proposition ('without spending an advisor call') is placed after the action so the agent reads what it does first.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a 5-parameter mutation tool with 0% schema coverage and no output schema, the description covers the field vocabulary but leaves merge semantics and failure behavior unexplained. Adequate to attempt a call, but not enough to call it confidently in edge cases.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0%, so the description must carry parameter meaning, and it does map loosely onto four of the five parameters (goal, constraints, touched files, open questions). However, it never clarifies append-vs-replace behavior (add_constraints vs replace_open_questions) or session_id's role, so the semantics only come from parameter names.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Uses a specific verb ('Record') with the concrete state fields it writes (goal, constraints, touched files, open questions), and the clause 'without spending an advisor call' implicitly separates it from consult_advisor. It never says 'session' outright and doesn't name reset_advisor_session or get_advisor_session as siblings, so differentiation is inferred rather than stated.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
'Without spending an advisor call' gives a clear selection rule: use this for cheap state persistence instead of invoking the advisor, which points an agent toward consult_advisor as the alternative. It stops short of explicit when-not guidance, such as not using it to retrieve or reset state.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
5 tool updates
v0.1.0- First observed
advisor_health - First observed
consult_advisor - First observed
get_advisor_session - First observed
reset_advisor_session - First observed
update_advisor_session
TDQS
Scored across 5 tools
Each tool has a clearly distinct role: read state (get), write state (update), clear state (reset), invoke the model (consult), and check configuration (health). The get-vs-consult distinction is well clarified by descriptions, so an agent can reliably pick the right tool.
Four tools follow a verb_noun pattern (get/update/reset_advisor_session, consult_advisor), but advisor_health breaks it with a noun-only, verbless form. The deviation is minor and still readable.
Five tools is well-scoped for a session-backed advisor: one core consult plus a minimal state lifecycle and a health check. Every tool earns its place with no redundancy.
The session lifecycle is covered (get, update, reset, consult, health), with creation implied on first write. Only minor gaps exist, such as no list/enumerate operation for existing sessions.
Maintenance
Related MCP Connectors
A paid remote MCP for OpenAI Codex agent coordination MCP, built to return verdicts, receipts, usage
Team memory for AI coding agents and code reviews, reviewed by humans and served over MCP.
A paid remote MCP for CodeG, built to return verdicts, receipts, usage logs, and audit-ready JSON.
Shared memory MCP server for Claude Code, Codex, Gemini CLI and Cursor. Cited, editable.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceEnables any MCP client to request an independent second opinion from a fresh Claude Code session without blocking, useful for plans, architecture, debugging, security reviews, and final checks.8 npmMIT
- AlicenseNot gradedqualityDmaintenanceMCP server that gives any AI coding tool a structured second opinion from another AI provider.10 npmMIT
- AlicenseNot gradedqualityBmaintenanceMCP servers that let Claude Code delegate to other coding CLIs (Copilot, Codex, Gemini) for cross-model second opinions, structured reviews, and multi-engine consultations.MIT
- AlicenseAqualityBmaintenanceEnables coding agents to request guarded code and architecture reasoning from multiple AI models through a single MCP server, with modes for direct answers, parallel councils, ordered chains, and structured debates, plus reusable context and audit tracing.28MIT