mcp-turboquant
Allows for the quantization of HuggingFace models into the GGUF format, making them compatible for local execution and deployment within the Ollama runtime.
mcp-turboquant
Self-contained Python MCP server for LLM quantization. Compress any HuggingFace model to GGUF, GPTQ, or AWQ format in a single tool call.
No external CLI required -- all quantization logic is embedded.
Install
pip install mcp-turboquantOr run directly with uvx:
uvx mcp-turboquantOptional backends
The info, check, and recommend tools work out of the box. For actual quantization, install the backend you need:
# GGUF (Ollama, llama.cpp, LM Studio)
pip install mcp-turboquant[gguf]
# GPTQ (vLLM, TGI)
pip install mcp-turboquant[gptq]
# AWQ (vLLM, TGI)
pip install mcp-turboquant[awq]
# Everything
pip install mcp-turboquant[all]Related MCP server: TurboQuant Tools
Configure
Claude Code
Add to ~/.claude/settings.json:
{
"mcpServers": {
"turboquant": {
"command": "mcp-turboquant"
}
}
}Or with uvx (no install needed):
{
"mcpServers": {
"turboquant": {
"command": "uvx",
"args": ["mcp-turboquant"]
}
}
}Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"turboquant": {
"command": "uvx",
"args": ["mcp-turboquant"]
}
}
}Tools
Tool | Description | Heavy deps? |
| Get model info from HuggingFace (params, size, architecture) | No |
| Check available quantization backends on the system | No |
| Hardware-aware recommendation for best format + bits | No |
| Quantize a model to GGUF/GPTQ/AWQ | Yes |
| Run perplexity evaluation on a quantized model | Yes |
| Push quantized model to HuggingFace Hub | No |
Examples
Once configured, ask Claude:
"Get info on meta-llama/Llama-3.1-8B-Instruct"
"What quantization format should I use for Mistral-7B on my machine?"
"Quantize meta-llama/Llama-3.1-8B to 4-bit GGUF"
"Check which quantization backends I have installed"
"Evaluate the perplexity of my quantized model at /path/to/model.gguf"
"Push my quantized model to myuser/model-GGUF on HuggingFace"
How it works
Claude / Agent <--> MCP Protocol (stdio) <--> mcp-turboquant (Python) <--> llama-cpp-python / auto-gptq / autoawqAll quantization logic runs in-process. No external CLI tools needed.
Run directly
# As a command
mcp-turboquant
# As a module
python -m mcp_turboquantLicense
MIT
Available Tools
6 toolscheckA
Check available quantization backends on this system.
Reports which quantization engines (GGUF/GPTQ/AWQ) are installed, whether PyTorch and transformers are available, GPU information (CUDA or Apple MPS), and system RAM.
No arguments required. Lightweight system check.
Returns: Dictionary of available backends and hardware info.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, but description fully covers behavioral impact: a read-only system check with no side effects. Could explicitly state non-destructive, but currently sufficient.
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?
Description is concise, front-loads purpose, and uses clear sections. Minor redundancy in 'No arguments required' and 'lightweight system check', but overall efficient.
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 parameters and an output schema noted, description fully specifies what the tool does and returns. No gaps given simplicity.
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 parameters with 100% schema coverage; description reinforces 'no arguments required' and explains return value, adding value beyond schema.
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?
Description clearly states the tool checks available quantization backends, listing specific engines and hardware info. It distinguishes from sibling tools like quantize or evaluate by focusing on system readiness.
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?
Indicates no arguments required and is lightweight, implying use as a preliminary check. Does not explicitly contrast with siblings, but context is adequate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
evaluateA
Run perplexity evaluation on a quantized model.
Measures model quality after quantization using perplexity scoring. Lower perplexity = better quality. Includes a quality assessment (EXCELLENT/GOOD/FAIR/DEGRADED/POOR).
Args: model_path: Path to the quantized model file (GGUF) or directory (GPTQ/AWQ). format: Format of the quantized model. One of 'gguf', 'gptq', 'awq'. bits: Bit width used during quantization (for quality context).
Returns: Perplexity score, quality assessment, and evaluation metadata.
| Name | Required | Description | Default |
|---|---|---|---|
| model_path | Yes | ||
| format | No | gguf | |
| bits | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided. Description discloses compute behavior (perplexity scoring) and output format, but does not mention side effects, permissions, or potential resource consumption. Adequate but not fully transparent for a compute-heavy tool.
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?
Well-structured with summary, Args, and Returns sections. Two sentences of purpose followed by bullet-like arguments. Slightly verbose but efficient overall.
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?
Covers key usage context (post-quantization), parameter details, and output description. With output schema present, the Returns section is sufficient. Missing edge cases or constraints (e.g., file size limits) but complete for typical use.
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%, but description provides detailed explanations for all three parameters (model_path, format, bits) including examples and context. Consistently adds meaning beyond schema metadata.
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?
Description clearly states 'Run perplexity evaluation on a quantized model', specifying the action and resource. It distinguishes from sibling tools (e.g., quantize, check, info) by focusing on evaluation after quantization.
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?
Explicitly indicates usage context: 'Measures model quality after quantization'. No explicit when-not-to-use or alternative tools, but the purpose is clear enough for an agent to infer appropriate use.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
infoA
Get model info from HuggingFace — parameters, size, architecture.
Lightweight call using the HuggingFace API. No GPU or heavy dependencies required.
Args: model: HuggingFace model ID (e.g. 'meta-llama/Llama-3.1-8B-Instruct') or local path to a model directory.
Returns: Model metadata including architecture, parameter count, size, hidden dimensions, number of layers, vocabulary size, and context length.
| Name | Required | Description | Default |
|---|---|---|---|
| model | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full burden. It explains the tool is lightweight and lists return values, but omits details like authentication requirements, rate limits, or error handling. This is adequate for a simple retrieval tool but lacks full transparency.
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?
The description is well-organized with an Args/Returns section, uses plain language, and contains no redundant information. Every sentence adds value, achieving conciseness without sacrificing clarity.
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?
Given the simple input (one parameter) and existence of an output schema, the description covers all necessary context: tool purpose, parameter details, and return values. It is fully self-contained and sufficient for an agent to invoke correctly.
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 compensate. It provides examples ('meta-llama/Llama-3.1-8B-Instruct'), specifies it can be a local path, and defines the parameter's format. This adds significant meaning beyond the raw schema, earning a high score.
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 clearly states the tool retrieves model info from HuggingFace, listing specific attributes (parameters, size, architecture). This verb+resource pair is distinct from sibling tools like 'check', 'evaluate', 'push', 'quantize', and 'recommend', which all serve different purposes.
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 notes it is a 'lightweight call using the HuggingFace API' with 'No GPU or heavy dependencies required,' providing context on when to use it. However, it does not explicitly state when not to use it or mention alternatives among sibling tools, though the distinct purpose makes this less critical.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
pushA
Push a quantized model to HuggingFace Hub.
Uploads all model files from the output directory to a HuggingFace repository. Generates a model card (README.md) with metadata. Requires HuggingFace authentication (huggingface-cli login or HF_TOKEN).
Args: repo_id: HuggingFace repository ID (e.g. 'username/model-GGUF-4bit'). model_dir: Local directory containing the quantized model files. model: Original model ID for the model card (optional). bits: Bit width used during quantization (for model card metadata).
Returns: Upload result with repository URL and file count.
| Name | Required | Description | Default |
|---|---|---|---|
| repo_id | Yes | ||
| model_dir | Yes | ||
| model | No | ||
| bits | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description discloses uploading files, generating a model card, requiring authentication, and returning a result. It does not mention overwrite behavior or potential issues, but covers key behavioral traits adequately.
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?
The description is mostly concise with clear sections for args and returns, but could be more structured (e.g., bullet points). It is not overly verbose.
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?
Given the tool has 4 parameters and an output schema, the description covers purpose, prerequisites, parameter meanings, and return values. It provides sufficient context for an agent to decide and invoke the tool correctly.
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 fully explains each parameter: repo_id format, model_dir as local directory, model for model card, bits for metadata. This adds value beyond the schema property 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?
The description clearly states the tool pushes a quantized model to HuggingFace Hub, uploading model files and generating a model card. It uses specific verbs and resources, and differentiates from sibling tools like check, evaluate, and quantize.
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 indicates when to use the tool (after quantization, with required HuggingFace authentication) and provides prerequisites, but does not explicitly state when not to use or compare with alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
quantizeA
Quantize a HuggingFace model to GGUF, GPTQ, or AWQ format.
This is a heavy operation that downloads and compresses the model. Requires appropriate backend dependencies to be installed.
Args: model: HuggingFace model ID (e.g. 'meta-llama/Llama-3.1-8B-Instruct') or local path to a model directory. format: Output format — gguf, gptq, or awq. Default: gguf. bits: Quantization bit width — 2, 3, 4, 5, or 8. Default: 4. output_dir: Directory to write output files. Default: temp directory. target: Deployment target. ollama/llamacpp/lmstudio force GGUF, vllm forces AWQ.
Returns: Quantization result with file paths, sizes, and compression ratios.
| Name | Required | Description | Default |
|---|---|---|---|
| model | Yes | ||
| format | No | gguf | |
| bits | No | ||
| output_dir | No | ||
| target | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must convey behavioral traits. It states the operation is heavy (downloads and compresses), but does not mention potential destruction (e.g., overwriting files in output_dir), idempotency, or authorization needs. The behavior is adequately described for basic use but lacks depth.
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?
The description is well-organized with separate sections for task description and parameters. It uses bullet-like 'Args' and 'Returns' formatting, making it scannable. No unnecessary sentences; each adds value.
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?
Given the presence of an output schema (return value explained) and 5 parameters with 1 required, the description covers all essentials. However, it could be more complete by mentioning prerequisites (e.g., installed backends) or potential errors. Still, it provides sufficient context for an agent to use the tool correctly.
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%, so the description must compensate entirely. It adds meaning to each parameter: model (HF ID or local path), format (enum with default), bits (enum with default), output_dir (default temp), and target (deployment targets with format constraints). The note about target forcing format is extra context beyond the schema.
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?
Description clearly states it quantizes HuggingFace models to specific formats (GGUF, GPTQ, AWQ). The verb 'quantize' is specific and the resource is well-defined. Sibling tools (check, evaluate, info, push, recommend) do not overlap, making this tool's purpose distinct.
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 notes that this is a heavy operation requiring dependencies, setting expectations. It provides default values and examples, but does not explicitly state when to use this tool over alternatives or when not to use it. The absence of sibling overlap makes this less critical.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
recommendA
Recommend best quantization format and bit width for a model.
Analyzes the model size and your hardware (GPU VRAM, Apple Silicon, system RAM) to suggest the optimal format (GGUF/GPTQ/AWQ) and bit width (2-8). Ranked recommendations with use-case explanations.
Args: model: HuggingFace model ID (e.g. 'meta-llama/Llama-3.1-8B-Instruct') or local path to a model directory.
Returns: Ranked recommendations with format, bits, reasoning, and use cases.
| Name | Required | Description | Default |
|---|---|---|---|
| model | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Describes the analysis but doesn't specify how hardware info is obtained (e.g., system detection vs. user input). No annotations provided, so some behavioral aspects remain implicit. However, no contradictions and no destructive actions are implied.
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?
Concise and well-structured: starts with purpose, then explains analysis, then lists arguments and returns. No extraneous information.
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?
Given the tool has one parameter and no annotations, the description provides sufficient context about input, output, and use cases. It is complete for a recommendation tool.
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 has 0% parameter description coverage, but the description fully compensates by explaining the 'model' parameter as a HuggingFace model ID or local path, adding significant meaning beyond the type string.
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?
Description clearly states the tool recommends quantization format and bit width, specifying it analyzes model size and hardware. Differentiates from siblings like 'quantize' (which likely performs the quantization) and others by focusing on recommendation.
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?
States the tool should be used when needing to select quantization settings based on model and hardware. While it doesn't explicitly list when not to use it, the context of siblings implies alternatives (e.g., use 'quantize' after getting recommendations).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
Each tool targets a distinct action in the quantization workflow: system check, model info, recommendation, quantization, evaluation, and upload. No overlap or ambiguity.
All tools use single imperative verbs (check, evaluate, info, push, quantize, recommend). 'Info' is a noun rather than verb, but the pattern is otherwise consistent and clear.
6 tools cover the entire quantization lifecycle without bloat or missing essentials. Each tool earns its place for a focused server purpose.
Covers system check, model info, recommendation, quantization, evaluation, and upload. Minor gap: no tool to list previously quantized models locally, but core workflow is complete.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP server for progressive tool usage at any scale (see https://klavis.ai)
QuLab MCP remote server (Streamable HTTP) for computational science and lab tools.
Hosted MCP server for LLM cost estimation, model comparison, and budget-aware routing.
Related MCP Servers
AlicenseAqualityAmaintenanceUnified MCP server for managing local model runtimes (Ollama, LM Studio, etc.), enabling provider-agnostic discovery, lifecycle management, hardware-fit checks, and delegated inference.16763Creative Commons Attribution Non Commercial No Derivatives 4.0 International- AlicenseNot gradedqualityAmaintenanceMCP server for compressing AI embeddings by 5-7x using TurboQuant (PolarQuant + QJL), with tools to compress, decompress, estimate savings, and embed+compress vectors.MIT
- AlicenseNot gradedqualityCmaintenanceConfigurable MCP server that lets you define LLM-powered tools via JSON, enabling easy integration of multiple models (GPT, Gemini, Claude, etc.) as MCP tools without writing Python code.6MIT
- FlicenseBqualityCmaintenanceLocal MCP server for token optimization, providing tools to compress code/JSON, optimize prompts, and manage placeholder-based content redaction and hydration to reduce LLM token usage.5
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/ShipItAndPray/mcp-turboquant'
If you have feedback or need assistance with the MCP directory API, please join our Discord server