Skip to content

Validate compatibility and session-centric performance #367

Open

Description

@franciscojavierarceo

Parent RFC: #359

Summary

Establish shared conformance and performance evidence for the native, gRPC, and HTTP inference adapters. Capture the HTTP baseline early and use integrated results to determine migration readiness.

Acceptance criteria

  • Run shared Responses/Messages and representative harness scenarios for each declared supported profile, covering streaming/non-streaming output, reasoning, client-executed function calls, built-in tool rounds, continuation, forks, and compaction.
  • Verify equivalent model-visible input and public semantics, usage, cancellation, bounded slow-consumer behavior, and failure handling across supported adapters.
  • Extend the existing Benchmark KV-affine Responses routing and token artifacts #74 benchmark suite for native-versus-HTTP-versus-gRPC comparisons, including long contexts, concurrent load, tool pauses, event lag, eviction, and worker loss.
  • Measure TTFT, end-to-end and tail latency, CPU, memory, queue occupancy, transfer volume, cache reuse, selected endpoints, and recovery/fallback outcomes.
  • Separate routing/cache-residency benefits from transport, rendering, and tokenization benefits; report neutral and negative results with reproducible versions/configuration and raw samples.
  • Publish supported capability/model/version coverage, material gaps, and migration criteria after integrated validation of Implement native inference using shared vLLM libraries #362-Package and launch the integrated serving modes #366. Keep existing paths available until the agreed criteria are met.

Dependencies

No implementation prerequisite.

Baseline and test-harness work can start immediately. Final acceptance requires #362, #363, #364, #365, and #366; each implementation issue includes its own tests.

Related work and scope

Reuse #74 for KV-routing/token-artifact benchmark methodology and #211 for provider-conformance recordings. Coordinate #314's capability matrix and #110's deployment verification. This issue adds cross-adapter integration and migration evidence instead of starting a competing benchmark framework.

Activity

  1. StevenWang-CY commented on Oct 22, 2026

    @StevenWang-CY
    Contributor

    I'd like to take the HTTP-baseline part of this. Here is a first baseline from the existing response_provider suite, run outside the reference setup.

    Setup

    • agentic-api: a7dc7b5 (0.9.0), HTTP adapter, SQLite store, bound to 127.0.0.1 and pinned to 8 cores of a 2× Xeon Silver 4310 host.
    • Engine: vLLM 0.32.0 serving Qwen/Qwen3-4B-Instruct-2507-FP8 on one RTX 5060 Ti 16 GB, with --enable-auto-tool-choice --tool-call-parser hermes, priority scheduling and prefix caching. The gateway host reaches it through an SSH local forward (+0.45 ms per small request), and so does the direct arm.
    • Benchmark: response_provider --provider all --seed 20261022 on separate cores. All five arms start at one barrier and run at once, so each row below saw the same engine load.

    Transport workload. 4 tool rounds per turn, 10 turns per session. Per-turn latency, p50 / p95 in ms:

    Sessions per arm agentic-api WS agentic-api HTTP/SSE agentic-api JSON vLLM HTTP/SSE vLLM JSON Paired median, agentic-api − vLLM
    1 3,173 / 4,194 3,173 / 4,191 3,175 / 4,194 3,176 / 4,183 3,187 / 4,272 0 ms
    5 4,488 / 7,925 4,489 / 7,686 4,490 / 7,837 4,482 / 7,890 4,500 / 7,772 +3 ms
    10 6,099 / 10,949 6,102 / 10,953 6,094 / 10,977 6,072 / 10,945 6,097 / 10,975 +1 ms
    • Correctness. Task correctness was 100% / 98% / 99% on every arm. The one exception was vLLM JSON at 90% with one session per arm.
    • Request size. Client requests are 3.6–3.8 KB per turn through the gateway, against 8.4 KB direct.
    • Gateway cost. The gateway process used about 5.5 ms of CPU per Responses round: 8.6 s for about 1,500 rounds in 71 s at 10 sessions per arm, 12% of one core. Peak RSS was 44–54 MiB.

    History rehydration (depths 1, 5, 10, 25). With this 4B model every arm fails the recall at turn 2 (success 100 / 40 / 20 / 8%). That is identical across arms, so it confirms equal behavior but says nothing about depth; it needs a larger model.

    What this suggests. On this setup the HTTP adapter's latency cost is below the noise even at 50 concurrent tool loops, and the inference server dominates. The comparisons against #362–#366 should therefore look at CPU, memory and queueing under load, and at long contexts, rather than at latency at this scale.

    Next (glad to rescope):

    1. A concurrency sweep to saturation, with CPU, RSS and queue occupancy per arm.
    2. Long contexts, concurrent load and tool pauses from real agent traces, coordinated with @yinli-systems, who offered the single-engine KV pieces of this issue on [RFC]: Programmable KV Cache: Composable Policies for Agentic Serving vllm#57103. A replay driver over the SemiAnalysis Claude Code traces already keeps their subagent structure and think times, and I can share it.
    3. The same matrix on an 8B-class model, so that history rehydration runs deep.

    The exact script, each run's summary.md and the resource analysis are here. The per-turn turns.csv and run.json files are available on request, and I can land the runner in scripts/ if that helps.

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

    enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions