fix(deps): update openai agents sdk to ^0.15.0 - #152
Merged
Conversation
1 task
There was a problem hiding this comment.
Code Review
This pull request upgrades the @openai/agents and @openai/agents-extensions dependencies to version ^0.15.0. To accommodate this upgrade and resolve type-declaration mismatches under exactOptionalPropertyTypes, lifecycle/getModel.ts has been refactored. Specifically, the getModel function now returns the core Model type, and its provider-specific logic has been extracted into a new helper function getLanguageModel. There are no review comments, so no further feedback is provided.
Bumps @openai/agents and @openai/agents-extensions from ^0.14.0 to ^0.15.0 (supersedes the Renovate PR #150, resolving its lockfile conflict by regenerating against current main). 0.15.0 adds an optional rawUsage field to core's ModelResponse. The AiSdkModel wrapper from @openai/agents-extensions declares its getResponse rawUsage as `Record<string, unknown> | undefined`, which is not assignable to core's `rawUsage?: Record<string, unknown>` under this repo's exactOptionalPropertyTypes. Have getModel return the core `Model` type and bridge that upstream declaration mismatch with a single cast so the --dts build type-checks again. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds a Build job to verify-pr.yaml that runs `npm run build` on pull requests, alongside the existing lint, format, and test jobs. The build runs tsup with --dts, so this gates PRs on a clean type-check and catches compile/type breakage from dependency bumps and refactors before merge (the @openai/agents 0.15.0 upgrade in this PR is one such case). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
dawsontoth
force-pushed
the
claude/pr-150-gha-build-step-7abb4a
branch
from
August 17, 2026 18:13
84fb53c to
99170f1
Compare
dawsontoth
marked this pull request as ready for review
August 17, 2026 18:15
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.
Supersedes Renovate #150. Bumps
@openai/agentsand@openai/agents-extensionsfrom^0.14.0to^0.15.0, adaptsgetModelto the SDK's newModeltyping, and adds a CI Build job so PRs are gated on a clean type-check — which is what surfaced the upgrade's type break in the first place.For the human reviewer
getModelnow returns core'sModeland casts theaisdk()result once. 0.15.0 adds an optionalrawUsagetoModelResponse; theAiSdkModelwrapper declares itsgetResponserawUsageasRecord<string, unknown> | undefined, which isn't assignable to core'srawUsage?: Record<string, unknown>under ourexactOptionalPropertyTypes.AiSdkModelgenuinelyimplements Model, so this is an upstream declaration quirk, not a runtime issue — I bridged it with a single cast at thegetModelboundary (and split provider selection intogetLanguageModelso there's exactly one cast) rather than sprinkling casts at the two call sites (AgentManager,compactConversation). Reversible; the alternative is per-call-site casts.verify-pr.yamlonly, notrelease.yaml. The release workflow already builds viaprepublishOnlybeforenpm publish, so a broken build fails the release regardless; the actual gap was PR-time validation. Say the word if you'd also like an explicit build step in release.Verification
Rebased onto current
main, so the0.15.0agents bump is validated alongside the recently landedaiv7 /@ai-sdk/*v4 majors (onlypackage.json+ the lockfile conflicted; kept main'sai ^7.0.0). Ran the full local gate against Node 24:npm run build→ tsup ESM +--dtstype-check succeed (fails onmain+bump without thegetModelchange — this is the break the new CI job catches).npm run lint(oxlint) → clean.npm run format(dprint) → clean.npm test(vitest) → 53 files, 345 tests passed.Review coverage
Authored by Claude (Opus 4.8). No outside cross-model review has run yet — flagging per Harper guidelines step 10; happy to run the
cross-model-reviewpre-push pass before this leaves draft.