Repository navigation
Studio: keep earlier messages in chats with images - #10944
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Review, GitHub Actions A/B, and real GPU UI evidencePinned head: GitHub Actions A/B (same workflow, same deps; the only difference is
Fresh- Real Studio, transformers vision path (NVIDIA L4,
Conclusion: before, once a chat had an image, the model only saw the newest question and the image. After, the whole chat reaches the model and it still reads the image. The three |
|
Confirmed this hits the collapse at studio/backend/core/inference/inference.py where an ordinary image turn is rebuilt from only the newest user text, dropping earlier questions and answers. Will get this reviewed. |
|
The image-history fix works on the tested head. Before this PR, recalling a code word from before an image turn returns Tested merge base Verification
Commands and environmentBoth revisions were installed with python -m pytest tests/test_vision_client_tools.py tests/test_chat_template_continuation.py tests/test_control_markup_neutralize_7066.py tests/test_sf_client_tools_passthrough.py tests/test_mlx_vlm_prompt_cache.py tests/test_truncated_answer_continuation.py tests/test_length_truncated_reasoning_continuation.py tests/test_runtime_context_length.py tests/test_context_overflow_truncation.py -q -p no:cacheprovider --timeout=40Frontend checks, from node --experimental-strip-types --test tests/vision-toggle-gating.test.ts tests/vision-toggle-config.test.ts tests/uncaptioned-image-empty-text-block.test.ts tests/chat-history-revision.test.tsGPU and browser scenarios used local API/Playwright harnesses, not additions to this PR. Linux x86_64, Python 3.13.14, RTX 5060 Ti 16 GB, NVIDIA driver 595.91.07, PyTorch 2.11.0+cu130, Transformers 5.5.0, PEFT 0.18.1, bitsandbytes 0.50.2. Unsloth Zoo pinned to Earlier CPU checks also passed the focused 87-test suite on head with Transformers 4.57.6 and 5.5.0, and on recorded merge Browser versions: Chrome 153.0.8010.36, Firefox 153.0, Edge 153.0.4234.32, Chromium 151.0.7922.34. Viewport 1440×1100, en-US, light theme, reduced motion. Captured UI requests use temperature 0 and max_tokens 4096; direct API probes use temperature 0 and max_tokens 64. UI evidenceChrome: Published screenshot files. Full local logs and original captures are retained; they are not included in the public media branch. LimitsAfter 25 filler exchanges, the 2B model answers Native macOS/Safari, Windows browsers, Apple MLX execution, other accelerators/model families, exhaustive dependency combinations, training, and long-duration performance were not tested locally. Screenshot token rates are observations, not controlled benchmarks. This review does not claim universal correctness. |
mahiatlinux
left a comment
There was a problem hiding this comment.
LGTM! Ready to merge.
Reviewed head fab6233. The real GPU and four-browser A/B checks confirm the image-history fix; no additional defect found within the tested scope. UI evidence, verification results, and remaining limits.
|
@codex review |
|
Codex Review: Didn't find any major issues. Hooray! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |





On image models that run through transformers, once a chat had a picture, every later reply only saw the newest message and the picture. Earlier questions and the model's own answers were dropped, so follow up questions got answers with no memory of the chat. On Mac, MLX already kept the full chat.
Studio now sends the whole chat, with the picture attached to the message that sent it.
Tested with Qwen2.5-VL-3B. Asked for a code word given at the start, main answered "7" and this branch answered "PELICAN-42". Asked to quote its last answer, main made one up and this branch quoted it. The model still reads the picture on later turns, and chats without pictures are unchanged. New tests fail on main, with no other new failures.