fix(gateway): expose native image cache paths to tools - #20971
Closed
LeonSGP43 wants to merge 1 commit into
Closed
Conversation
Collaborator
|
Competing PR: #20906 also fixes #20899 with a broader approach (per-chat attachment cache in base platform + Telegram-specific handling across 4 files). This PR takes a narrower approach — injecting path text into the message context only for native image routing in Maintainers: these overlap on #20899. Consider which scope is preferred or if they can be merged. |
Contributor
|
This appears to be implemented on current main by the shared native image routing path. Automated hermes-sweeper review evidence:
This only closes the narrow overlap in this PR; the broader attachment-cache discussion in #20899 / #20906 remains a separate maintainer decision. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #20899
Summary
Why
Telegram photos are already cached locally before reaching the agent, but when native image routing is selected the model receives pixels inline and the text context did not include the cached path. That leaves file/terminal tools without an obvious handle for requests like “put this image in this folder.”
Verification
scripts/run_tests.sh tests/gateway/test_native_image_buffer_isolation.py tests/gateway/test_telegram_documents.py tests/gateway/test_telegram_photo_interrupts.py43 passed in 1.87sgit diff --check