Repository navigation
Native conversation history retains contributor protection - #859
Merged
Merged
Conversation
Observe the native response body before releasing marked frames and keep every contributing handle across buffered automatic work. Explicit actions retain observation without becoming automatic capture. Signed-off-by: zlareb1 <[email protected]>
A shared monotonic patch could expire a freshly loaded model-call policy before the bearer test reached its first request. Exercise the same attributed token rotation at two clock epochs without changing the policy clock. Signed-off-by: zlareb1 <[email protected]>
Keep constructor and callback contributors across client rebinding. Treat history reads and additions as automatic work while preserving observed explicit pop and clear operations. Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Keep diagnostics attached to the naturally attempted shape and size so a cost failure identifies its own incomplete parse or walk. Keep the original timing judge, inputs and limits. Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]> # Conflicts: # tests/unit/test_code_regex_cost.py
Signed-off-by: zlareb1 <[email protected]>
7 tasks done
Compose the existing lane diagnostics so hosted CI records each failing size and completion state. Keep the cost workload, thresholds, parser bounds and native history implementation unchanged. Signed-off-by: zlareb1 <[email protected]>
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.
Related: #840
Related: #849
Related: #850
Related: #861
Changelog category (leave one):
Changelog entry (one or two sentences a user of Loom can read without the diff; the release pull request collects these into the release notes):
Python and TypeScript native conversation history retain protection for its contributing conversation families across client rebinding. Marked replies stop later automatic history reads and writes while explicit history deletion remains available.
Why
The native session can outlive its creating context and use a rebound Loom client. Looking only at the current client loses the original conversation's protection authority. Retaining constructor and callback contributors keeps that authority with the conversation instance.
Scope and risk
Both native session implementations retain constructor-bound and callback-bound client families; Python also retains ambient callback contributors through the private framework helper. History reads and additions use the existing automatic SDK controls; each item write checks protection before the next item. Response observation still runs before content returns, including through credential refresh.
A first complete marked history reply may return its items after durable protection. Further pagination, hydration and automatic writes refuse. Explicit pop and clear operations retain response observation without capture suppression. Model-selected tools keep their explicit behavior. Each instance belongs to one logical conversation family; restoring it requires the same application-owned capsule. Native user and session ids only route stored history.
The sender inventory renews the two reviewed adapter source hashes and moves four TypeScript reference keys whose invocation-control arguments changed. Operation names, wire payloads and exception categories and reasons remain unchanged. No capsule, host binding, capability declaration or platform qualification is added.
Compatibility, rollout and rollback
Tests
pytest -q sdk/python/tests/test_openai_agents.py -k "native_history or keeps_items_in_order_across_pages_and_repeats or pop_item_removes_and_returns_the_latest_item".vitest run --pool=forks --maxWorkers=1 --no-file-parallelism src/integrations/openai-agents.test.ts -t "LoomSession conversation protection|keeps items in order across pages, with repeats|pops the latest item and clears only its own session".AI assistance in the code (leave one; writing this description with AI is fine):
AI-generated: Codex wrote the change; fresh independent whole-diff review and final-head CI are required before merge.
I can explain every line of this diff and how it interacts with the rest of Loom.
Checklist