Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: AltimateAI/altimate-code
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: AltimateAI/altimate-code
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: feat/anthropic-advisor-tool
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 2 commits
  • 15 files changed
  • 2 contributors

Commits on Apr 10, 2026

  1. feat: add Anthropic Advisor Tool support for cost-efficient Opus guid…

    …ance
    
    Enable a cheap executor model (Haiku/Sonnet) to consult Opus for strategic
    guidance via the Anthropic Advisor Tool API (`advisor-tool-2026-03-01`),
    achieving near-Opus quality at ~80% lower cost.
    
    - Patch `@ai-sdk/[email protected]` to support advisor tool (7 patch points
      across 4 dist files: `prepareTools`, streaming/non-streaming handlers,
      multi-turn message reconstruction)
    - Add `experimental.advisor` config schema with `enabled`, `model`,
      `max_uses` (capped at 10), and `caching` options
    - Inject advisor as provider-defined tool for Anthropic models (skipped
      for non-Anthropic providers with warning, skipped for small queries)
    - Add advisor system prompt guiding when to call `advisor()`
    - Track advisor iteration costs from `usage.iterations[]` at Opus rates
    - Add `advisor_call` telemetry event type
    - Add 27 unit tests covering tool injection, config validation, result
      parsing (3 subtypes), multi-turn reconstruction, cost tracking, and
      `prepareTools` SDK logic
    
    Co-Authored-By: Claude Opus 4.6 <[email protected]>
    suryaiyer95 and claude committed Apr 10, 2026
    Configuration menu
    Copy the full SHA
    45b8119 View commit details
    Browse the repository at this point in the history

Commits on Apr 14, 2026

  1. fix: harden Anthropic Advisor Tool for production readiness

    - Extract hardcoded server-side tool list to shared `ANTHROPIC_SERVER_SIDE_TOOLS` constant
    - Fix `JSON.parse` crash on compacted advisor results in multi-turn reconstruction
    - Add defense-in-depth `mcp_` prefix exclusion for server-side tools in message history
    - Add `providerExecuted: true` flag for server-side tools in `message-v2.ts`
    - Handle `isProviderExecuted` heuristic for server-executed tool results in `processor.ts`
    - Migrate `AnthropicAuthPlugin` from npm to internal plugin registration
    - SDK patch: full advisor tool support (Zod schemas, `prepareTools`, streaming/non-streaming
      handlers, multi-turn reconstruction)
    - Add 41 unit tests covering tool injection, config schema, result parsing, multi-turn
      reconstruction, cost tracking, compaction, `mcp_` prefix exclusion, and `providerExecuted` flag
    
    Co-Authored-By: Claude Opus 4.6 <[email protected]>
    suryaiyer95 and claude committed Apr 14, 2026
    Configuration menu
    Copy the full SHA
    9e159fc View commit details
    Browse the repository at this point in the history
Loading