Spec Driven Development
MCP Server that facilitates spec-driven development workflows, not just Vibe Coding.
作者提供的说明(英文原文)
Step-by-step observability for MCP agent workflows
这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。
我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。
选择你使用的 AI 应用,然后复制设置。
MCP_API_KEY, MCP_JWT_SECRET标为机密的值是你账户的钥匙。千万不要分享给别人,也不要粘贴到聊天里。
你需要
你用的是哪个应用?
在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。
打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json
{
"mcpServers": {
"agent-trace-inspector": {
"command": "npx",
"args": [
"-y",
"mcp-agent-trace-inspector"
],
"env": {
"MCP_API_KEY": "your-value",
"MCP_JWT_SECRET": "your-value"
}
}
}
}在终端中运行这条命令
claude mcp add agent-trace-inspector --env MCP_API_KEY=your-value --env MCP_JWT_SECRET=your-value -- npx -y mcp-agent-trace-inspector运行前请先填写空着的值。
粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json
{
"mcpServers": {
"agent-trace-inspector": {
"command": "npx",
"args": [
"-y",
"mcp-agent-trace-inspector"
],
"env": {
"MCP_API_KEY": "your-value",
"MCP_JWT_SECRET": "your-value"
}
}
}
}浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。
粘贴到项目中的 .vscode/mcp.json
{
"servers": {
"agent-trace-inspector": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"mcp-agent-trace-inspector"
],
"env": {
"MCP_API_KEY": "your-value",
"MCP_JWT_SECRET": "your-value"
}
}
}
}浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。
这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。
你的选择通过 Cookie 保存在这台设备上,无需账户。
这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。
它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。
我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月7日
注册名称已通过 GitHub 账户 dbsectrainer 验证,该账户拥有此仓库
我们还没有从 GitHub 读取这个仓库
我们还没有从 GitHub 读取这个仓库
它在你的电脑上运行,没有互联网端点
在你的电脑上运行,改用本地设置
它在你的电脑上运行;我们只能读取互联网端点的工具列表
与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。
它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。
你需要填写:MCP_API_KEY, MCP_JWT_SECRET
它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。
GitHub 仓库最后更新于–,最新版本(1.0.1)于3天前进入注册中心。
支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。
同一分类中有:Spec Driven Development, Remote Desktop Commander, Master CSS
同一分类中其他作者的服务器,按星标数排序。
如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i
MCP Server that facilitates spec-driven development workflows, not just Vibe Coding.
Remote Desktop Commander: use files, terminal and processes on your own computers from any AI app.
Inspect Master CSS classes, generated CSS, and project stylesheets from your AI client.
按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。
Local-first, MCP-native observability for agent workflows. Every tool call, prompt transformation, latency, token estimate, and cost estimate is recorded in a local SQLite database — no cloud account, no API key, and no traces leaving your machine.
Built specifically for MCP rather than bolted onto a generic LLM proxy.
Tools · Configuration · HTTP transport · Verification · Known limitations · Contributing
mcp-agent-trace-inspector is an MCP server. Agents call its tools to start a trace, record each step they take, and finish the trace. Humans then inspect summaries, compare runs, export a self-contained HTML dashboard, export OTLP/JSON spans, or stream the compliance audit log.
Agent / MCP client
│ trace_start → trace_step → trace_end ▼ MCP Agent Trace Inspector ├── SQLite (~/.mcp/traces.db) ├── JSONL audit log (~/.mcp/trace-inspector-audit.jsonl) └── tools: summaries, diffs, HTML, OTLP/JSON, retention, alerts
node:sqlite; traces survive restarts and never require a service.cl100k_base tokenizer plus a configurable pricing table; no API calls and no billing-account data.resourceSpans → scopeSpans → spans documents.| Layer | Choice |
|---|---|
| Runtime | Node.js ≥ 22.13 (ESM, built-in node:sqlite) |
| Language | TypeScript 5, strict mode |
| Protocol | @modelcontextprotocol/sdk (tools, resources, prompts) |
| HTTP | Express 5 + MCP Streamable HTTP transport |
| Storage | SQLite through node:sqlite |
| Tokenization | gpt-tokenizer (cl100k_base) |
| CLI | yargs |
| Tests | Vitest + V8 coverage |
| Lint / formatting | ESLint + Prettier |
| CI | GitHub Actions (install, audit, lint, format, test, build) |
node:sqlite first became available in Node 22.5.0 behind --experimental-sqlite; it is unflagged from 22.13.0. This project does not pass the flag.Add the server to your MCP client configuration:
{
"mcpServers": { "trace-inspector": { "command": "npx", "args": ["-y", "mcp-agent-trace-inspector@latest"] } } }
Use a project-specific database:
{
"mcpServers": { "trace-inspector": { "command": "npx", "args": [ "-y", "mcp-agent-trace-inspector@latest", "--db=~/traces/my-project.db" ] } } }
Then ask your agent to trace its own work:
Start a trace named "test-run" with trace_start.
Record a trace_step for each tool you call, including that tool's input and output. Call trace_end when you are done, then call get_trace_summary for the trace.
The summary contains the step count, estimated token total, total recorded latency, wall-clock duration, cost estimate, and reasoning-chain detection. Tracing is explicit: the inspector records steps when the agent calls trace_step; it does not intercept other MCP servers automatically.
npm ci
npm run build node dist/index.js --db=~/.mcp/traces.db
Development mode runs TypeScript directly and logs MCP protocol messages on stderr:
npm run dev -- --db=/tmp/traces.db
HTTP mode is useful for a local team instance or a container. It is stateless: every POST gets a fresh MCP server and transport, there is no Mcp-Session-Id, and the endpoint does not offer a server-initiated SSE stream. Send every JSON-RPC message as its own POST /mcp request.
node dist/index.js --db=~/.mcp/traces.db --http-port=3000 --http-host=127.0.0.1
Initialize the endpoint:
curl -s http://127.0.0.1:3000/mcp \
-H 'Content-Type: application/json' \ -H 'Accept: application/json, text/event-stream' \ -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"curl","version":"1"}}}'
The response is an SSE frame. Call a tool:
curl -s http://127.0.0.1:3000/mcp \
-H 'Content-Type: application/json' \ -H 'Accept: application/json, text/event-stream' \ -d '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"list_traces","arguments":{}}}'
| Behavior | Value |
|---|---|
| Endpoint | POST /mcp |
GET / DELETE /mcp | 405 with Allow: POST |
| Default bind address | 127.0.0.1 (loopback only) |
| Request body limit | 10 MB |
| Rate limit | 60 requests / 60 s per validated API key or client IP |
| Auth (optional) | X-API-Key and/or Authorization: Bearer |
| DNS-rebinding guard | Host header must be localhost/127.0.0.1 when bound to loopback |
Set one or both environment variables before starting the server:
MCP_API_KEY=change-me \
MCP_JWT_SECRET=change-me-too \ node dist/index.js --http-port=3000 --http-host=127.0.0.1
MCP_API_KEY is set, every HTTP request must send X-API-Key: .MCP_JWT_SECRET is set, every HTTP request must send Authorization: Bearer ; exp and nbf claims are checked.--http-host=0.0.0.0 is allowed but the server warns. Put TLS and an authenticating reverse proxy in front of any non-loopback deployment; do not expose the raw endpoint to an untrusted network.
When the server is bound to loopback behind a reverse proxy, the proxy must rewrite the Host header to 127.0.0.1: . The loopback DNS-rebinding guard rejects other Host values with 403 by design.
| Flag | Default | Description |
|---|---|---|
--db, --db-path | ~/.mcp/traces.db | SQLite database file. ~ is expanded. :memory: is supported for tests. |
--retention-days | 0 | On startup, delete traces older than N days. 0 disables. |
--pricing-table | built-in table | JSON file of { "model": { "input": number, "output": number } }. Merged over built-in rates. |
--no-token-count | false | Disable automatic token counting (token_count values become null). |
--http-port | unset | Start in HTTP mode on this port (1–65535) instead of stdio. |
--http-host | 127.0.0.1 | HTTP bind address. Prefer loopback unless authentication and TLS are used. |
--help | — | Show usage. |
--version | — | Print the package version. |
The server does not load .env files automatically. Export variables in your shell or configure them in your MCP client.
| Variable | Default | Purpose |
|---|---|---|
MCP_API_KEY | unset | HTTP only: require X-API-Key on every request. |
MCP_JWT_SECRET | unset | HTTP only: require a valid HS256 Bearer JWT. |
MCP_AUDIT_LOG_PATH | ~/.mcp/trace-inspector-audit.jsonl | Compliance audit log path. Created owner-readable/writable (0600). |
MCP_SLACK_WEBHOOK | unset | Slack incoming-webhook URL used when an alert fires. |
MCP_ALERT_WEBHOOK | unset | Generic JSON webhook URL used when an alert fires. |
See .env.example for a copy-paste template. Never commit real secrets or database files; both are ignored by .gitignore.
The server exposes 13 tools. Tool annotations mark state-changing tools (readOnlyHint: false) and destructive retention (destructiveHint: true).
| Tool | Purpose |
|---|---|
trace_start | Begin a trace. Returns a trace_id. Pass "auto" or an empty string for a generated name. |
trace_step | Record one step for a running trace. Steps are rejected after trace_end. |
trace_end | Mark a trace completed, evaluate alert rules, and return fired alerts. Repeated calls are idempotent. |
trace_step requires trace_id, tool_name, input (object), and output (object). token_count must be a non-negative integer; latency_ms must be a finite, non-negative number. Caller-supplied token counts are used as-is.
| Tool | Purpose |
|---|---|
list_traces | List traces, newest first. Optional positive-integer limit. |
get_trace_summary | Step/token/latency totals, duration, cost estimate, reasoning detection. |
| compare_traces | Diff two traces: aggregates, tool coverage, and per-position steps.
只显示了开头部分;其余内容请在仓库中阅读