
Promptbudget Mcp
Exposes a single tool, `truncate_to_token_budget`, that lets Claude count tokens and fit text into a context window mid-task without hallucinating character offsets or chunk boundaries. The logic is ported from the author's `promptbudget` Rust crate but implemented in plain JavaScript so you don't need a toolchain. Useful when you're chaining prompts, building RAG pipelines, or need deterministic truncation that respects token limits rather than guessing at string slices. Part of a fourteen-server collection that replaces operations LLMs commonly fumble,regex, CSV parsing, timezone math,with real implementations they can call as tools.
- tool
- 1
- transport
- STDIO
- last updated
- May 11, 2026
Tools
1 toolsPublic tool metadata for what this MCP can expose to an agent.
truncate_to_token_budgetLLM needs to fit text into a context window mid-task
LLM needs to fit text into a context window mid-task
No parameter schema in public metadata yet.
Sponsors
Readme
mcp-stack
Fourteen small MCP servers for everyday LLM / RAG / agent work. Each ships independently on npm, listed in the official MCP Registry, and is callable from Claude Desktop, Cursor, Cline, Windsurf, Zed, and any other MCP-compatible client.
RAG / agent helpers
| Package | Tools | When to install |
|---|---|---|
@mukundakatta/promptbudget-mcp | truncate_to_token_budget | LLM needs to fit text into a context window mid-task |
@mukundakatta/citecite-mcp | inject_citations, parse_citations, strip_citations | Round-trip [1] [2] markers in RAG outputs |
@mukundakatta/ragmetric-mcp | recall_at_k, hit_at_k, mrr, ndcg_at_k, evaluate_batch | LLM helps score retrieval quality |
@mukundakatta/ragdrift-mcp | interpret_drift_score, recommend_thresholds, explain_drift_dimensions | LLM diagnoses RAG drift alerts |
Reliable transforms LLMs reach for tools instead of imagining
Details
- Repository
- github.com/mukundakatta/mcp-stack
- Category
- AI & LLM Tools
- Package
@mukundakatta/promptbudget-mcp- Transport
- STDIO
- Registry
- MCP registry, active