CostGate
БесплатноНе проверенReduces AI token consumption by optimizing MCP tool definitions and responses, with a probe for measurement and a gate for filtered tool exposure and cost reduc
Описание
Reduces AI token consumption by optimizing MCP tool definitions and responses, with a probe for measurement and a gate for filtered tool exposure and cost reduction.
README
Gate your MCP. Cut your bill.
CostGate reduces AI token consumption by optimizing MCP tool definitions and responses.
Cursor-first, compatible with Claude Desktop and other MCP clients.
Languages: English (this file) · 日本語
Repository layout (monorepo)
costgate/
├── packages/
│ ├── schema/ @costgate/schema — shared log schema
│ ├── probe/ @costgate/probe — measurement MCP (npm)
│ ├── cli/ @costgate/cli — npm entry (launcher, Dashboard, hooks)
│ └── gate/ costgate-gate — gateway MCP (Go binary)
├── docs/
├── examples/
└── scripts/
See docs/structure.md for why Probe and Gate share one repo.
Packages
| Package | Dist | Description |
|---|---|---|
| @costgate/cli | npm | Recommended entry — init, Gate launcher, Dashboard, Cursor hooks |
| @costgate/probe | npm | Measurement MCP — baseline token usage, call stats, JSONL logs |
| costgate-gate | GitHub Releases | Gateway MCP (Go) — filtered tools, Shield, cost reduction |
| @costgate/schema | workspace | Shared JSON Schema for logs |
Quick start (production — recommended)
Install with Node only (no Go build). init downloads the Gate binary from GitHub Releases.
npx @costgate/cli@latest init
# Restart Cursor (reconnect MCP)
What init does:
~/.costgate/bin/costgate-gate— Go binary~/.cursor/mcp.json—npx @costgate/cli gate(Dashboard auto-start)~/.cursor/hooks.json— Shield, prompt-intent, etc.~/.costgate/backends.json— template (if missing)
Update: npx @costgate/cli update
Details: packages/cli/README.md · docs/releases.md
Global install (optional)
npm install -g @costgate/cli
costgate init
Quick start (developers — clone repo)
git clone https://github.com/YukiMiyatake/costgate.git
cd costgate
npm install
npm run build:gate # or ./scripts/install-gate.sh
cp examples/backends.github.json ~/.costgate/backends.json
npm run cursor:production # update mcp.json with local paths
npm run cursor:registry # install hooks
Docker only: docs/docker.md
Quick start (Probe — measurement only)
Option A — npx (published)
npx @costgate/probe@latest
Add to Cursor ~/.cursor/mcp.json:
{
"mcpServers": {
"costgate-probe": {
"command": "npx",
"args": ["-y", "@costgate/probe"],
"env": {
"COSTGATE_CONFIG": "~/.costgate/backends.json",
"COSTGATE_PROBE_LOG_DIR": "~/.costgate/logs"
}
}
}
}
Option B — from source
npm install
npm run build:probe
See examples/cursor/ for measurement configuration.
Gate (advanced — binary only)
Minimal setup without Dashboard or hooks:
./scripts/install-gate.sh # → ~/.local/bin/costgate-gate
costgate-gate --version
Example ~/.cursor/mcp.json: examples/cursor/mcp-gate-github.json
Build from repo: npm run build:gate (Go 1.25+)
Releases: GitHub Releases · docs/RELEASE.md
Filter mode (default): Tier A/B/C + discover_tools / invoke_tool. See packages/gate/README.md.
Compare reduction: npm run compare (definitions) · npm run compress-report (definitions + tool results).
Session breakdown: npm run session-report (fixed + variable + overall % scenarios).
Measured benchmarks: docs/benchmarks.md
Production Cursor setup (clone): npm run cursor:production — see examples/cursor/README.md.
Cloud metrics (opt-in): npm run cloud:upload — see costgate-cloud.
Plans (roadmap)
| Plan | Scope |
|---|---|
| Free (OSS) | CostGate — Probe + Gate + Dashboard |
| LoopGate Starter / Pro / Enterprise | Hosted LoopOps SaaS — see costgate-cloud (private) |
OSS vs Cloud feature split: docs/ecosystem/plans.md · 日本語
See docs/roadmap.md for OSS phase details.
Documentation
- Documentation languages
- Development roadmap · 日本語
- MCP Dashboard (users) · 日本語
- MCP token reduction survey · 日本語
- MCP Dashboard (developers) · 日本語
- Benchmarks & verification · 日本語
- Repository structure · 日本語
- OSS vs Cloud plans · 日本語
- Docker / Dev Container · 日本語
- Gate releases · 日本語
- Architecture · 日本語
- Log schema · 日本語
- Contributing · 日本語
License
MIT — see LICENSE
Установка CostGate
У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.
▸ github.com/YukiMiyatake/costgateFAQ
CostGate MCP бесплатный?
Да, CostGate MCP бесплатный — установка в пару кликов через Unyly без оплаты.
Нужен ли API-ключ для CostGate?
Нет, CostGate работает без API-ключей и переменных окружения.
CostGate — hosted или self-hosted?
Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.
Как установить CostGate в Claude Desktop, Claude Code или Cursor?
Открой CostGate на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.
Похожие MCP
Fetch
Web content fetching and conversion for efficient LLM usage.
AWS KB Retrieval
Retrieval from AWS Knowledge Base using Bedrock Agent Runtime.
автор: modelcontextprotocolSpring AI MCP Server
Provides auto-configuration for setting up an MCP server in Spring Boot applications.
llm-analysis-assistant
A very streamlined mcp client that supports calling and monitoring stdio/sse/streamableHttp, and can also view request responses through the /logs page. It also
автор: xuzexin-hzCompare CostGate with
Не уверен что выбрать?
Найди свой стек за 60 секунд
Автор?
Embed-бейдж для README
Похожее
Все в категории ai
