Skip to content

Compact tools/list for a typical sales agent is ~494 KB, nearly 4x AdCP's 128 KiB target, mostly output schemas #1909

Open

Description

@bokelley

Problem

get_tools_for_handler(..., schema_mode="compact"), the default serve() uses, still produces a tools/list page well over AdCP's 128 KiB target for a typical sales agent. Most of the size is response schemas.

AdCP asks:

Servers SHOULD paginate the live tool catalog so each page remains under the same 128 KiB target. … do not publish the full AdCP catalog, response schemas, or long reference prose in a session's tools/list result.

— AdCP 3.3, "Discovery responses stay small" (docs/building/concepts/managing-response-size.mdx)

Related: #1692 (closed), where compact mode replaced the fully inlined schemas.

Measured

adcp==10.0.0b17, get_tools_for_handler(ADCPHandler, advertise_all=True, adcp_version="3.2", schema_mode="compact"), filtered to 14 sales-agent tools, compact JSON:

Bytes
Whole tools/list page 494,053
All inputSchema 269,429
All outputSchema 220,946

The tools: get_adcp_capabilities, get_products, create_media_buy, update_media_buy, get_media_buys, get_media_buy_delivery, sync_creatives, list_creatives, list_creative_formats, list_accounts, sync_accounts, get_signals, activate_signal and provide_performance_feedback.

The largest entries are get_products (103,937 B), create_media_buy (97,703 B), update_media_buy (60,114 B), get_media_buys (37,765 B), get_media_buy_delivery (37,246 B) and sync_creatives (33,919 B).

For comparison, the static ADCP_TOOL_DEFINITIONS input schemas total 13,592 B for all 83 tools.

Why it matters

Suggested direction

  • Leave outputSchema out of tools/list by default. It's optional in MCP, AdCP asks agents not to publish response schemas there, and it's 45% of this page. An opt-in could keep it for clients that want it.
  • Bound the compact input schema further: root fields, plus required nested fields to one level, plus a pointer to the bundled schema for the rest. That keeps a 14-tool sales page under 128 KiB.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingclaude-triagedsdk-10SDK 10 (next branch, AdCP 3.3)

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions