Repository navigation
feat(sdk): add "max" to SquadReasoningEffort — unblocks Dependabot PR #1671 - #1693
Merged
Merged
Conversation
…1671 Copilot SDK 1.0.9 added ReasoningEffort = "max". Squad's SquadReasoningEffort type and VALID_REASONING_EFFORTS constant previously only permitted low|medium|high|xhigh, causing a type incompatibility when consuming the updated SDK. Changes: - adapter/types.ts: add "max" to SquadReasoningEffort union - config/models.ts: add "max" to VALID_REASONING_EFFORTS const (satisfies clause keeps it in sync with the type automatically) - Clamping logic (EFFORT_RANK, clampReasoningEffort) already handled max/xhigh equivalence — no changes needed - test/model-preference.test.ts: add 3 new tests for max as a first-class value Backwards compatible: existing callers using low/medium/high/xhigh are unaffected. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
🟡 Impact Analysis — PR #1693Risk tier: 🟡 MEDIUM 📊 Summary
🎯 Risk Factors
📦 Modules Affectedroot (1 file)
squad-sdk (2 files)
tests (1 file)
This report is generated automatically for every PR. See #733 for details. |
Contributor
🛫 PR Readiness Check
PR Scope: 📦🔧 Mixed (product + infrastructure)
|
| Status | Check | Details |
|---|---|---|
| ✅ | Single commit | 1 commit — clean history |
| ✅ | Not in draft | Ready for review |
| ✅ | Branch up to date | Up to date with dev |
| ❌ | Copilot review | No Copilot review yet — it may still be processing |
| ✅ | Changeset present | Changeset file found |
| ✅ | Scope clean | No .squad/ or docs/proposals/ files |
| ✅ | No merge conflicts | No merge conflicts |
| ✅ | Copilot threads resolved | 0 active Copilot thread(s) resolved (1 outdated skipped) |
| ✅ | CI passing | All checks passing |
Files Changed (4 files, +24 −2)
| File | +/− |
|---|---|
.changeset/max-reasoning-effort.md |
+5 −0 |
packages/squad-sdk/src/adapter/types.ts |
+1 −1 |
packages/squad-sdk/src/config/models.ts |
+1 −1 |
test/model-preference.test.ts |
+17 −0 |
Total: +24 −2
This check runs automatically on every push. Fix any ❌ items and push again.
See CONTRIBUTING.md and PR Requirements for details.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates Squad’s SDK-facing reasoning-effort types and runtime validation to recognize "max", aligning with Copilot SDK 1.0.9 and unblocking Dependabot PR #1671.
Changes:
- Add
"max"to theSquadReasoningEffortunion type used across the SDK adapter layer. - Extend the canonical runtime validation list (
VALID_REASONING_EFFORTS) to include"max". - Add tests verifying persistence and clamping behavior involving
"max", plus a patch changeset for@bradygaster/squad-sdk.
Show a summary per file
| File | Description |
|---|---|
packages/squad-sdk/src/adapter/types.ts |
Extends the SquadReasoningEffort union to include "max" for type compatibility with the updated Copilot SDK. |
packages/squad-sdk/src/config/models.ts |
Updates the canonical runtime list (VALID_REASONING_EFFORTS) to accept "max" in config read/write and validation paths. |
test/model-preference.test.ts |
Adds coverage for writing/reading "max" and for clamping behavior when "max" is present in supported efforts. |
.changeset/max-reasoning-effort.md |
Adds a patch changeset documenting the new "max" reasoning-effort support. |
Review details
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Lite
Comment on lines
816
to
+820
| * "auto" is a permitted stored sentinel that resolvers treat as "not set". | ||
| * Canonical runtime list — import this instead of duplicating. The `satisfies` | ||
| * clause keeps it in lock-step with the canonical {@link SquadReasoningEffort} type. | ||
| */ | ||
| export const VALID_REASONING_EFFORTS = ['low', 'medium', 'high', 'xhigh'] as const satisfies readonly SquadReasoningEffort[]; | ||
| export const VALID_REASONING_EFFORTS = ['low', 'medium', 'high', 'xhigh', 'max'] as const satisfies readonly SquadReasoningEffort[]; |
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.
Summary
Adds
"max"as a valid value forSquadReasoningEffort, unblocking Dependabot PR #1671 (deps: bump the minor-patch group with 4 updates).Root cause: Copilot SDK 1.0.9 added
ReasoningEffort = "max". Squad'sSquadReasoningEfforttype was"low" | "medium" | "high" | "xhigh"— missing"max", causing a type incompatibility when the updated SDK is consumed.Changes
packages/squad-sdk/src/adapter/types.ts: added"max"to theSquadReasoningEffortunionpackages/squad-sdk/src/config/models.ts: added"max"toVALID_REASONING_EFFORTSconst (thesatisfiesclause keeps type and runtime list in lock-step automatically)test/model-preference.test.ts: 3 new tests covering"max"as a first-class effort value.changeset/max-reasoning-effort.md: patch changeset for@bradygaster/squad-sdkThe clamping infrastructure (
EFFORT_RANK,clampReasoningEffort) already treatedmaxandxhighas rank-equivalent — no changes needed there.Backwards compatible: existing callers using
low/medium/high/xhighare unaffected.Validation
Relationship to Dependabot PR
This PR does not close Dependabot PR #1671 (Dependabot manages its own branch). Once this is merged to
dev, the@github/copilot-sdkbump in #1671 will be compatible with Squad's type system.Working as CAPCOM (SDK Expert)
Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com