Repository navigation
Conversation
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
3 tasks done
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.
Human comments
What was wrong
With Account Pooler routing on, the plugin points Claude Code's
ANTHROPIC_BASE_URLat the local hub. Claude Code only gives Opus models without a[1m]suffix their native 1M context window when the base URL is unset orapi.anthropic.com, or when_CLAUDE_CODE_ASSUME_FIRST_PARTY_BASE_URLis set. Every pooled Claude Code session therefore ran Opus with a 200k window and compacted or failed withPrompt is too longfar below what the pooled account allows. Since 0.44.0 the model catalog has no[1m]variant, so users have no in-app way around it. Root cause and the Claude Code source excerpt are in #4207.What changed
plugins/account-pool/src/server.ts: theclaude-codeenv contribution now adds_CLAUDE_CODE_ASSUME_FIRST_PARTY_BASE_URL=1next toANTHROPIC_BASE_URL,ANTHROPIC_AUTH_TOKENandENABLE_TOOL_SEARCH, following the existingENABLE_TOOL_SEARCHoverride. The hub forwards to Anthropic's API with the pooled account's own credentials, so Claude Code now applies the same model limits as with a direct login. Bypassed threads and instances that neutralise inherited routing get nothing new.docs/configuration.mdand the plugins guide template (bb-guide-plugins.md) name the new variable and why it is set.HOST_DAEMON_PROTOCOL_VERSIONbump, no catalog change.[1m]catalog entries) and 3 (the 200k placeholder before the first result) are not part of this PR.anthropicUpstreamBaseUrl, the same wayENABLE_TOOL_SEARCHis. A custom upstream still has to accept the pooled accounts' Anthropic credentials, so it is Anthropic's API or a pass-through in front of it.How you verified
plugins/account-pool/src/server.test.ts: the two tests that pin the fullclaude-codecontribution (direct hub and nested proxy) now expect_CLAUDE_CODE_ASSUME_FIRST_PARTY_BASE_URL=1. Against the previousserver.tsboth fail (2 failed, 158 passed); with the change they pass.pnpm exec turbo run test typecheck --filter=bb-plugin-account-pool --force: 323 tests passed, typecheck passed.@bb/templatestests: 46 passed.test/plugin-scaffold-external.test.tsfails the same way onmainin my environment (npm packis blocked by my sandbox) and was left out.oxlinton the changed TypeScript files: clean.oxfmt --check: clean except the existingstoredConfigexpression inserver.ts, which is already flagged onmain; left unchanged.node scripts/check-source-nul.mjsandnode scripts/check-provider-literal-ratchet.mjs: clean.ANTHROPIC_BASE_URLpointing at the hub:claude -p "say ok" --model claude-opus-5-5 --setting-sources "" --output-format jsonreportsmodelUsage["claude-opus-5-5"].contextWindowas 200000 without the variable and 1000000 with_CLAUDE_CODE_ASSUME_FIRST_PARTY_BASE_URL=1. Since 2026-09-28 the same variable has been set for all pooled Claude Code sessions on this machine through~/.claude/settings.json; new sessions report a 1M window.Fixes #4207
🤖 Generated with Claude Code