MCP: windowed get_message body reading#10
Closed
endolith wants to merge 1 commit into
Closed
Conversation
d19db97 to
0292d76
Compare
Add offset, max_chars, and center_at parameters to get_message. Response includes body_length, body_returned, and has_more for paging. Strips HTML from returned body. Adds bodyByteSlice UTF-8-safe slicing and contextWindow for centered reading. Co-authored-by: endolith <endolith@gmail.com>
0292d76 to
7c260cc
Compare
Owner
Author
|
Close in favor of #15 |
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.
Summary
Adds windowed body reading to
get_messageso LLM clients can page through large message bodies without flooding the context window.Changes
get_messagereturnsbody_length,body_returned,offset,has_moreinstead of the full bodymax_chars(default 2000, max 4000) andoffsetfor paging;center_atto center on a match fromsearch_in_messagebody_htmlfrom MCP responsesStack
Rebased onto
mainafter kenn-io#388 (pagination). Next: #8search_in_message, #9search_message_bodies.