feat: add synthetic support#231
Draft
matthew-hre wants to merge 8 commits intomainfrom
Draft
Conversation
- Add 'synthetic' to ProviderType, ApiKeyProvider, and CLIENT_STORAGE_KEYS - Add SYNTHETIC_API_KEY to server env schema - Add synthetic utility model (GLM 4.7 Flash) - Add GLM 4.7 Flash to tool model options - Add 'glm-4.7-flash' to toolModelIds
Create synthetic.ts provider module using @ai-sdk/openai with Synthetic's OpenAI-compatible base URL (https://api.synthetic.new/v1/).
- Add synthetic to DIRECT_PROVIDER_MAP for direct model routing - Add synthetic to resolveUtilityProvider and resolveToolProvider - Wire createSyntheticProvider/buildSyntheticProviderOptions in service - Treat synthetic as a direct provider for PDF handling - Skip reasoning stripping for synthetic (OpenAI-compatible API)
- Add syncSyntheticProviderAvailability() to cross-reference Synthetic's /v1/models endpoint with the local models table - Wire into the cron sync-models route - Match Synthetic hf: prefixed IDs against OpenRouter model slugs
- Add Synthetic to integrations tab with logo and API key config - Include synthetic in all hasAnyChatKey checks across model hooks - Add synthetic to direct provider detection for PDF handling - Update API key status widget, prefetch, tools section, models tab - Update warning badge text to mention Synthetic
- Skip Synthetic-sourced models during OpenRouter cleanup - Insert Synthetic-only models (no OpenRouter equivalent) into models table - Clean up stale Synthetic-only models removed from Synthetic catalog - Add resolveProvider fallback for non-prefix-matched models (hf:org/Model)
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
matthew-hre
commented
Apr 20, 2026
Collaborator
Author
There was a problem hiding this comment.
It looks like there's some white in the middle of this SVG - we should clean that up
| <AlertCircle className="text-warning mt-0.5 size-5 shrink-0" /> | ||
| <div className="text-warning-foreground text-sm"> | ||
| No API key configured. Set up an API key (OpenRouter, OpenAI, or Anthropic) in | ||
| No API key configured. Set up an API key (OpenRouter, OpenAI, Anthropic, or Synthetic) in |
Collaborator
Author
There was a problem hiding this comment.
Let's change this to "(OpenRouter, OpenAI, Anthropic, etc.)" for the future
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.
opening a pr so i can leave some comments on it