feat: add TokenMix as a model provider#12630
Open
TokenMixAi wants to merge 1 commit into
Open
Conversation
TokenMix (https://tokenmix.ai) is an OpenAI-compatible API gateway that exposes DeepSeek, Qwen, Kimi, GLM, MiniMax and other models through a single endpoint and API key. - Add Tokenmix LLM class (core/llm/llms/Tokenmix.ts), extending OpenAI - Register it in core/llm/llms/index.ts - Add tokenmix to the openai-adapters provider union + routing - Add an Add-Model GUI tile (AUTODETECT models via /v1/models) - Add docs page + nav entry
Contributor
|
I have read the CLA Document and I hereby sign the CLA You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot. |
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.
Description
Adds TokenMix as a model provider. TokenMix is an OpenAI-compatible API gateway that exposes DeepSeek, Qwen, Kimi, GLM, MiniMax and other models through a single endpoint (
https://api.tokenmix.ai/v1) and one API key, so it slots in as a standard OpenAI-compatible provider.Usage:
Changes
core/llm/llms/Tokenmix.ts— new provider class extendingOpenAI(mirrorsTensorix/zAI)core/llm/llms/index.ts— registerTokenmixinLLMClassespackages/openai-adapters/src/types.ts— addtokenmixto theOpenAIConfigSchemaprovider unionpackages/openai-adapters/src/index.ts— routetokenmixthroughopenAICompatible(...)gui/src/pages/AddNewModel/configs/providers.ts— Add-Model tile (models auto-detected via/v1/models)docs/customize/model-providers/more/tokenmix.mdx+docs/docs.json— docs page and nav entryChecklist
packages/openai-adapterstypechecks clean (tsc --noEmit)Tensorix,zAI)Tests
The provider is a thin OpenAI-compatible wrapper following the same pattern as existing gateways (
Tensorix,zAI,Nebius). No new test fixtures were added, consistent with those providers.Summary by cubic
Adds TokenMix as a new OpenAI-compatible provider so you can use DeepSeek, Qwen, Kimi, GLM, MiniMax, and more through one endpoint and API key.
Default base is https://api.tokenmix.ai/v1 and default model is deepseek/deepseek-v4-pro.
Tokenmixprovider class extendingOpenAIwithapiBasehttps://api.tokenmix.ai/v1/and default modeldeepseek/deepseek-v4-pro.core/llm/llms/index.tsandpackages/openai-adapters(provider union +openAICompatible(...)routing)./v1/models.Written for commit 9133615. Summary will update on new commits.