Skip to content

[Feature] Carry native sandbox image traces into training - #2366

Draft
ShilohYu wants to merge 1 commit into
review/pr2354-base-20261202from
feat/zerobench-on-pr2354
Draft

ShilohYu wants to merge 1 commit into
review/pr2354-base-20261202from
feat/zerobench-on-pr2354

Conversation

@ShilohYu

@ShilohYu ShilohYu commented Dec 2, 2026 •

Copy link
Copy Markdown
Collaborator

Sandbox image turns currently cannot carry native image inputs and inference token evidence through to training. This change forwards image requests through SessionServer, retains actual backend prompt/output IDs, logprobs, routes and image snapshots in TraceStore, and materializes HF image fields and Qwen positions into RolloutState. Each turn is an independent complete snapshot supervising only that turn's output.

Stacked on #2354: base InternLM:review/pr2354-base-20261202 at 4e690a7056dd268e2af6da9251d31415e70427cf, head c5c92988fa9157b304ae21130d48b6db403709f9 (one commit). The base already includes the merged #2346 TrainBatch contract. This PR does not include the independent #2348/#2364 in-process tool loop changes. Retarget main after #2354 merges.

The same commit adds image request body limits and the sandbox config build hook needed by the task-side H provider. It reuses the existing Trie, request ownership, segmented training, HF processor, Qwen MRoPE and Ray transfer helpers.

Validation:

  • Qwen3.6-35B-A3B on one H node with eight GPUs: real crop observations, update/checkpoint, cold resume and second update; launcher exit codes 0. Adam steps 1→2 and sampled parameters changed at both updates.
  • 75 image/Trie/segmentation/timeout regression cases passed; one Anthropic case initially failed because LMDeploy was missing from PYTHONPATH and passed on the corrected standalone rerun.
  • Two-image replay checked against actual HF pixel/grid/modality/position outputs; import boundary check and diff whitespace check passed.

Limits: embedded images and default image processing only; multimodal streaming and prefix sharing are deferred. Qwen short-run infrastructure acceptance does not establish accuracy, long-run stability or GLM acceptance. Companion Anthropic opt-in IDs: InternLM/lmdeploy#5232; current H acceptance uses native OpenAI requests.

Review dependency: the base branch is a fixed mirror of #2354 head, not a separate implementation or merge target. Review the incremental diff here; do not merge until #2354 is merged, then retarget to main and revalidate. Source and target branches are both hosted in InternLM/xtuner.

Follow-up incremental reviews: #2367 (native task factories) and #2368 (main #2327 trace selection).

This branch has not been deployed

No deployments
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