TL;DR
HarnessAPI is a Python framework that streamlines the development of streaming APIs and MCP tools by unifying their codebase, reducing boilerplate, and automating multiple representations from a single source.
Contribution
It introduces a skill-first approach that automatically derives multiple API interfaces from a single handler and schema, simplifying deployment and maintenance.
Findings
Reduces framework boilerplate by 74% compared to manual dual-stack implementation.
Automatically generates streaming HTTP endpoints, OpenAPI UI, and MCP tools from one handler.
Supports dual-mode content negotiation for SSE and JSON clients without handler changes.
Abstract
Every Python function deployed as an LLM tool must today exist in two forms: an HTTP endpoint for human-facing clients and CI pipelines, and an MCP tool registration for agent runtimes such as Claude and Cursor. These representations share business logic yet diverge in all the surrounding machinery (routing, validation, serialisation, streaming, and schema maintenance), and they drift apart as the underlying code evolves. We present HarnessAPI, a Python framework that eliminates this duplication by treating a typed skill folder as the single source of truth. From one handler.py plus Pydantic schemas, the framework automatically derives a streaming HTTP endpoint with Server-Sent Events, an interactive OpenAPI/Swagger UI, and a zero-configuration MCP tool, all served from a single process. Dual-mode content negotiation lets the same handler serve SSE-streaming and JSON-returning clients…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
