Skip to content

Add experimental engine-client serving path (typed engine contract)#21

Open
QiJune wants to merge 1 commit into
mainfrom
prototype_1
Open

Add experimental engine-client serving path (typed engine contract)#21
QiJune wants to merge 1 commit into
mainfrom
prototype_1

Conversation

@QiJune

@QiJune QiJune commented Jul 14, 2026

Copy link
Copy Markdown
Owner

New package tensorrt_llm/executor/engine_client/: a typed, versioned, iteration-level request/response contract between the serving frontend and the engine (token deltas + explicit terminal frames over a strict msgpack codec), with an in-process client, exactly-once response routing, and frontend-side response assembly.

When TorchLlmArgs.experimental_engine_client is enabled (or TLLM_EXPERIMENTAL_ENGINE_CLIENT=1), eligible OpenAI streaming requests run through this path and skip the per-request rank-0 GenerationResult; ineligible requests fall back to the existing path transparently. With the flag off there is no behavior change.

Includes unit/replay/GPU test suites and design docs in the package.

@coderabbitai summary

Description

Test Coverage

PR Checklist

Please review the following before submitting your PR:

  • PR description clearly explains what and why. If using CodeRabbit's summary, please make sure it makes sense.

  • PR Follows TRT-LLM CODING GUIDELINES to the best of your knowledge.

  • Test cases are provided for new code paths (see test instructions)

  • If PR introduces API changes, an appropriate PR label is added - either api-compatible or api-breaking. For api-breaking, include BREAKING in the PR title.

  • Any new dependencies have been scanned for license and vulnerabilities

  • CODEOWNERS updated if ownership changes

  • Documentation updated as needed

  • Update tava architecture diagram if there is a significant design change in PR.

  • The reviewers assigned automatically/manually are appropriate for the PR.

  • Please check this after reviewing the above items as appropriate for this PR.

GitHub Bot Help

To see a list of available CI bot commands, please comment /bot help.

New package tensorrt_llm/executor/engine_client/: a typed, versioned,
iteration-level request/response contract between the serving frontend
and the engine (token deltas + explicit terminal frames over a strict
msgpack codec), with an in-process client, exactly-once response
routing, and frontend-side response assembly.

When TorchLlmArgs.experimental_engine_client is enabled (or
TLLM_EXPERIMENTAL_ENGINE_CLIENT=1), eligible OpenAI streaming requests
run through this path and skip the per-request rank-0 GenerationResult;
ineligible requests fall back to the existing path transparently. With
the flag off there is no behavior change.

Includes unit/replay/GPU test suites and design docs in the package.

Signed-off-by: junq <22017000+QiJune@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant