Repository navigation
feat(context)!: offload conditions decide granularity, and placeholders are typed (typescript) #5325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
lizradway
wants to merge
59
commits into
strands-agents:main
Choose a base branch
from
lizradway:lizradway/offload-conditions-ts
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+3,066
−1,349
Draft
feat(context)!: offload conditions decide granularity, and placeholders are typed (typescript) #5325
Changes from 18 commits
Commits
Show all changes
59 commits
Select commit
Hold shift + click to select a range
409f701
feat(context)!: redesign offload conditions in typescript
lizradway 7db98fc
test(context): fold offload condition tests into existing strategy tests
lizradway fddda55
refactor(context): return a plain object from the offload builders
lizradway c92baa1
fix(context): clarify offload builder error and percent threshold guard
lizradway 9ea9fa1
fix(context): skip a failed summarize run and continue with the rest
lizradway 1f9e95e
fix(context): leave the newest message alone in gated block offloads
lizradway f0833f4
fix(context): stop message truncation from re-eliding its own marker
lizradway 63e4f8a
refactor(context): rename blockThreshold back to threshold
lizradway 4ed6fcb
feat(context): reject a utilization token count larger than the conte…
lizradway a58a30d
Merge remote-tracking branch 'origin/main' into lizradway/offload-con…
lizradway cee79cc
docs(context): say utilization throws above the context window and cl…
lizradway 7790c77
feat(context)!: act on whole messages for target "*" and add a media …
lizradway 14eb3a9
feat(context): shorten each large message in place for truncate("*") …
lizradway 1cb19b9
fix(context): act on blocks of any size when no threshold is set
lizradway 2f794e5
feat(context): say a dropped media block was viewed before it was rem…
lizradway 844d157
fix(context): leave the task prompt to gated block strategies and rej…
lizradway 36adcd0
fix(context): require a context window for a token-count utilization
lizradway 6670fd5
fix(context): warn instead of throwing when a token-count utilization…
lizradway 0617f1a
fix(context): reject condition names that only match Object.prototype…
lizradway 41efdea
fix(context): reject a token-count utilization below 1,000
lizradway 3231184
docs(context): note that truncation detection matches on the text prefix
lizradway 15fd467
fix(context): reject eager media strategies and tighten offload checks
lizradway 8d0694f
fix(context): treat unmeasured media as over the threshold and guard …
lizradway 901c1c5
fix(context): subtract excluded tools from included ones in a mixed t…
lizradway 8b9108b
feat(context)!: accept only "N%" strings and whole numbers as offload…
lizradway 181260c
refactor(context): infer the condition rules shape instead of declari…
lizradway 7aeb480
fix(context-py): never stash or serve offload previews as originals
lizradway a264eab
fix(context-ts): never stash or serve offload previews as originals
lizradway 17c5c23
feat(context-ts): add OffloadedBlock, a typed placeholder for offload…
lizradway ec8ab18
refactor(context-ts): treat OffloadedBlock as a text turn across the …
lizradway b90933f
feat(context-ts): make removed messages retrievable from their marker
lizradway ec0d5eb
feat(context-ts): send OffloadedBlock as text wherever a provider or …
lizradway 856ef22
refactor(context-ts): every offload placeholder is an OffloadedBlock
lizradway cb04c8e
refactor(context-ts): read stash entries through the typed deserializers
lizradway 92be138
refactor(context-ts): one message-removal path, one text-turn predicate
lizradway 6e1c537
refactor(context-ts): drop the text-marker placeholder guard
lizradway 33789ae
fix(context-ts): keep an offload reference resolvable after history e…
lizradway 7794a26
refactor(context-ts): one way to copy a message or tool result with o…
lizradway 69df69a
refactor(context-ts): stash retrieve_context results like any other t…
lizradway c9951aa
test(context-ts): drop tests the typed placeholder made redundant
lizradway 09d43d8
refactor(context-ts): flatten the retrieval tool callback
lizradway 494c661
refactor(context-ts): split the offload base into target matching, hi…
lizradway 64dda15
refactor(context-ts): one table for the context manager presets
lizradway 6a73346
fix(context-ts): address the review of the OffloadedBlock branch
lizradway 7a1fdc5
refactor(context-ts): make OffloadedBlock a TextBlock
lizradway df6711f
refactor(context-ts): record an offload placeholder as an optional fi…
lizradway 8d29011
refactor(context-ts): name the message-level removal module message-t…
lizradway 7c2e46b
fix(context-ts): never store a placeholder under its original's key, …
lizradway 02737e9
refactor(context-ts): nest the offload placeholder under TextBlock.me…
lizradway 27f7227
feat(context)!: rename offload conditions and make .when() optional
lizradway b48a5bd
refactor(context-ts): fold typed offload placeholders into the offloa…
lizradway 6b07652
chore: merge main into offload conditions (typescript)
lizradway 3cb0d77
refactor(context-ts): move offload placeholder wording into one modul…
lizradway 0bf25bf
refactor(context-ts): keep the Percent type out of the public exports
lizradway 5bd28c3
refactor(context-ts): collapse the drop and summarize block paths and…
lizradway d4f13c6
test(context-ts): remove offload tests that other cases already cover
lizradway 3bcb01a
refactor(context-ts): replace RemovalPreview with a private async pla…
lizradway fbf703c
refactor(context-ts): name the truncated tool result type and call it…
lizradway 4bf5407
refactor(context-ts): store the offload target and eager flag instead…
lizradway File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.