Skip to main content
Glama
PROJECT_CHARTER.md4.66 kB
# PROJECT CHARTER: token-analyzer **Status:** FOUNDATIONAL **Created:** 2025-11-17 **Project Type:** Single-Branch (MCP Server) **Charter Version:** 1.0 (ORIGINAL) **Revisions:** None --- ⚠️ **IMMUTABILITY NOTICE** This charter preserves original project vision. Only edit for typo corrections, formatting fixes, or clarifications (logged in CHARTER_CHANGELOG.md). For scope/vision changes, create CHARTER_REVISION document in `/docs/charter/`. --- ## 1. Project Purpose MCP server developers and Claude Code power users need independent verification of token consumption to validate optimization efforts and configuration choices, but lack tools to measure actual token usage versus claimed usage from MCP servers—creating a "trust without verification" problem where token optimization claims cannot be validated objectively. This server addresses the measurement validation gap through independent tokenization analysis separate from MCP server self-reporting. The core insight is that independent verification using Claude's actual tokenizer provides ground truth for token consumption, enabling validation of optimization claims and informed context budget decisions. **Primary Objective:** Provide independent token consumption verification for MCP configurations through accurate token counting using Claude's tokenizer, context volume analysis against 200k limit, per-server overhead calculation, and verification reports enabling data-driven context budget optimization. ## 2. Success Criteria - [ ] Independent token counting using Claude's tokenizer - [ ] Context volume analysis against 200k token limit - [ ] MCP configuration scanning and server discovery - [ ] Per-server overhead breakdown in reports - [ ] Quick estimation mode for rapid overhead checking - [ ] Verification reports for validating optimization claims - [ ] Token count accuracy matches Claude Code's internal counting ## 3. Scope Boundaries **In Scope:** Independent token verification using Claude's tokenizer, context volume measurement, MCP configuration scanning, per-server overhead analysis, quick estimation mode, verification report generation, tool definition token accounting **Out of Scope:** Real-time token monitoring during sessions, cost optimization recommendations beyond reporting, integration with billing systems, multi-user analytics **Future Consideration:** Optimization suggestions based on usage patterns, historical token usage tracking, comparative analysis across configurations ## 4. Key Stakeholders | Role | Name/Entity | Interest | Influence Level | |------|-------------|----------|-----------------| | Developer | cordlesssteve | Validate token optimization claims | High | | MCP Server Developers | Server creators | Independent verification of efficiency | Medium | ## 5. Constraints **Time:** Analysis must complete in <30 seconds for typical configurations **Budget:** Zero-budget (local tokenization) **Technology:** Claude tokenizer, TypeScript, MCP configuration parsing **Resources:** Local analysis, no external services ## 6. Assumptions 1. Independent verification provides more trustworthy measurements than self-reporting 2. Developers value objective token usage data for optimization 3. Per-server breakdown reveals optimization opportunities 4. Quick estimation mode handles common validation needs ## 7. Known Risks | Risk | Probability | Impact | Mitigation | |------|------------|---------|------------| | Tokenizer divergence from Claude Code's actual tokenizer | Low | High | Regular validation, updates | | Analysis performance poor for large configurations | Low | Medium | Optimization, parallel processing | | Report interpretation ambiguity | Medium | Low | Clear metric definitions, examples | ## 8. Background & Context Token optimization for MCP configurations requires objective measurement. Independent verification tool enables validating claims like "reduces context by 70%" and comparing configuration alternatives. **Related Projects:** MCP servers (analysis targets), Claude Code (tokenization reference) ## 9. Dependencies **External:** Claude tokenizer library, MCP configuration files **Internal:** TypeScript analysis engine, MCP SDK for server introspection ## 10. Success Metrics - **Accuracy:** Token counts match Claude Code's internal counting within 1% - **Performance:** Analysis completes <30 seconds for 95% of configurations - **Usefulness:** At least 2 optimization insights discovered per analysis --- **Approved By:** cordlesssteve | **Approval Date:** 2025-11-17 This is the original charter. Changes logged in `/docs/charter/CHARTER_CHANGELOG.md`.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cordlesssteve/token-analyzer-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server