Repository navigation
Mark the reviewer's execution choices as explicit when spawning it - #13
Merged
salemsayed merged 1 commit intoOct 26, 2026
Merged
Conversation
Owner
|
Thanks, Jack. This is merged and shipped in v0.1.5. It went in through #14, which also updates Advisor to bb 0.47.1 / SDK 0.6.79, so your commit is in main unchanged. An independent review found it correct against SDK 0.4.87 and 0.6.80 and confirmed both updated tests fail without the fix. #14 also adds assertions for the reasoning source on the remaining spawn paths: a saved Release: https://github.com/salemsayed/bb-plugin-advisor/releases/tag/v0.1.5 |
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.
Advisor chooses the reviewer's provider, model, permission mode and, when configured, reasoning level, then passes them to
bb.sdk.threads.spawnwithoutexecutionInputSources. BB therefore reports every field of the reviewer's first dispatch asnullinMessageDispatchHookContext.executionSources. The SDK documentsnullas "core resolved it from project/provider defaults" and tells hooks to check forexplicitbefore acting against a deliberate choice. Amessage.dispatchhook that holds or rejects default-model work would treat the reviewer as if nobody had chosen its model.This change sends
explicitforproviderId,modelandpermissionMode, and forreasoningLevelonly when Advisor sends a reasoning level. The spawned values do not change. Later messages to an existing reviewer are unaffected because this change only modifies reviewer creation.SDK 0.4.87, which this repository pins, declares the field on
threads.spawn.Validation:
server.test.tsnow check the sources: a saved model with a reasoning level, and the fallback to the primary model with no reasoning level. Both fail without theserver.tschange.npm run verify(typecheck, 128 tests, build) andnpm pack --dry-runpass on Node 24. The generated bundle is updated.Not tested: Node 22.19, which CI uses, or a live host with a dispatch hook installed. This corrects reported provenance; it does not fix a failure I observed with a specific hook.