Skip to content

fix(memory): avoid unnecessary input and exhausted provider calls - #93

Merged
ScriptedAlchemy merged 2 commits into
mainfrom
codex/avoid-exhausted-memory
Nov 9, 2026
Merged

ScriptedAlchemy merged 2 commits into
mainfrom
codex/avoid-exhausted-memory

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Automatic memory extracts cited facts from a supplied exchange. Codex also reads the checkout's instruction files on every extraction, consuming input unrelated to that job. The automatic extractor could additionally start a provider whose usage snapshot already showed that the selected allowance was exhausted.

Exclude checkout instruction files for the Codex extraction operation while keeping the real working directory, provider settings, and selected model. Check the selected provider's model-specific allowance before launching an automatic extraction. A known reset re-enables subsequent jobs. Ordinary chat and checkout-aware generation such as PR writing still receive their usual context.

Verified with the installed Codex CLI's offline prompt renderer. A synthetic checkout instruction marker appeared 340 times before the change and zero times afterward. The regression test failed before the fix. The provider tests also cover exhausted windows with and without a reset time and an elapsed reset. Offline vp run check:changed origin/main passed, including 41 tests and three affected package typechecks.

GPT-6 family with a Sol reviewer, Codex desktop.

@changeset-bot

changeset-bot Bot commented Nov 8, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 8eb20ea

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@ScriptedAlchemy
ScriptedAlchemy merged commit 46c337c into main Nov 9, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant