Spaces:
Build error
Build error
Download headroom/integrations/mcp/__init__.py from minhtudragon/headroom_3: direct link, hf CLI and curl.
- Browser
- Download file 931 Bytes
-
https://huggingface.co/spaces/minhtudragon/headroom_3/resolve/aac850be3e24202a5f857fc294cd291db6f4d3e0/headroom/integrations/mcp/__init__.py
- Command line
-
hf download hf://spaces/minhtudragon/headroom_3@aac850be3e24202a5f857fc294cd291db6f4d3e0/headroom/integrations/mcp/__init__.py
-
curl -L -o __init__.py https://huggingface.co/spaces/minhtudragon/headroom_3/resolve/aac850be3e24202a5f857fc294cd291db6f4d3e0/headroom/integrations/mcp/__init__.py
931 Bytes
| """MCP (Model Context Protocol) integration for Headroom. | |
| This package provides compression utilities for MCP tool results, | |
| helping reduce context usage when tools return large outputs. | |
| Example: | |
| from headroom.integrations.mcp import compress_tool_result | |
| # Compress large tool output | |
| result = compress_tool_result( | |
| tool_name="search", | |
| result=large_json_result, | |
| max_chars=5000, | |
| ) | |
| """ | |
| from .server import ( | |
| DEFAULT_MCP_PROFILES, | |
| HeadroomMCPClientWrapper, | |
| HeadroomMCPCompressor, | |
| MCPCompressionResult, | |
| MCPToolProfile, | |
| compress_tool_result, | |
| compress_tool_result_with_metrics, | |
| create_headroom_mcp_proxy, | |
| ) | |
| __all__ = [ | |
| "HeadroomMCPCompressor", | |
| "HeadroomMCPClientWrapper", | |
| "MCPCompressionResult", | |
| "MCPToolProfile", | |
| "compress_tool_result", | |
| "compress_tool_result_with_metrics", | |
| "create_headroom_mcp_proxy", | |
| "DEFAULT_MCP_PROFILES", | |
| ] | |