Skip to content

Add support for Claude api #35

Open
cfiorini74 wants to merge 6 commits into
yorkeccak:mainfrom
cfiorini74:feature/claude-support
Open

Add support for Claude api #35
cfiorini74 wants to merge 6 commits into
yorkeccak:mainfrom
cfiorini74:feature/claude-support

Conversation

@cfiorini74

Copy link
Copy Markdown

Add optional support for Claude api

Cristopher Fiorini and others added 5 commits March 9, 2026 18:18
Introduces a shared model config layer so either OpenAI or Anthropic
can be used as the LLM provider, selected via LLM_PROVIDER env var.
OpenAI remains the default for backwards compatibility.

- Add src/lib/models.ts with getLargeModel/getSmallModel/getPowerModel helpers
- Refactor all agent files to import from models.ts instead of hardcoding openai()
- Install @ai-sdk/anthropic and upgrade @ai-sdk/openai to v3 for spec compatibility
- Model mapping: gpt-4o→claude-sonnet-4-6, gpt-4o-mini→claude-haiku-4-5, gpt-5→claude-opus-4-6

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Document OpenAI and Anthropic/Claude as provider options, update
env var examples with LLM_PROVIDER config in both self-hosted
and Valyu mode sections.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ties

- Replace experimental_output with generateObject() in researcher.ts (3 instances)
- Remove z.string().url() format validator (unsupported by Anthropic)
- Remove array minItems/maxItems constraints from planner and driver-generator schemas
- Replace z.record() with array of key-value objects in critic schema (unsupported additionalProperties)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@vercel

vercel Bot commented Mar 11, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the Valyu-Network Team on Vercel.

A member of the Team first needs to authorize it.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant