π‘ Feature Request: JSON β XML Compression for MCP Schema (47% Prompt Reduction) #1301
shariqriazz
started this conversation in
1. Feature requests
Replies: 1 comment 1 reply
-
This sounds super interesting / useful! I feel like we could easily put this behavior behind a new Experimental feature flag so folks try try it out |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey team,
Iβve implemented a compression utility that converts verbose JSON-based MCP schemas into a compact XML format β reducing system prompt footprint significantly while preserving all tool functionality.
π Problem
MCP tools currently define schemas in JSON, which:
In a real-world case, a single MCP tool schema used 1,718 words β and thatβs just the structure.
β What Iβve done
I built a utility that:
No changes are needed to existing tools β just swap the JSON blob with the XML one in the prompt.
π§ͺ Details
π Results
Let me know if you're interested and I can PR the utility or share integration steps.
This change helps make MCP-based prompts much more efficient while remaining 100% compatible with the current tool engine.
Beta Was this translation helpful? Give feedback.
All reactions