FastGPT apps को एक custom OpenAI-compatible base URL पर चलाएं।
Updated 2026-07-29
Current FastGPT models को UI में configure करता है: OpenAI protocol के साथ Account, Model Providers के तहत एक channel add करें, proxy address के तौर पर https://api.apisrouter.com/v1, और एक key। Claude, GPT, DeepSeek, GLM, Kimi, और Qwen ids फिर आपके knowledge bases और workflows को power करते हैं।
Quick answer: Model Providers page पर एक channel।
v4.8.23 से, FastGPT अपनी खुद की model-aggregation layer (AI Proxy) और एक model-configuration UI ship करता है, तो एक custom endpoint को अब अलग OneAPI deployment या hand-edited config.json की ज़रूरत नहीं है। Account खोलें, फिर Model Providers, Model Channels tab पर switch करें, और Add Channel क्लिक करें। Protocol type को OpenAI set करें, channel को नाम दें, proxy address field में https://api.apisrouter.com/v1 डालें (base URL, पूरा request path नहीं), अपनी key paste करें, और वे model ids select या type करें जिन्हें channel serve करे। Models tab पर वापस, जो ids आपने add किए उन्हें enable करें और built-in connectivity test चलाएं। इसके बाद, हर FastGPT app, knowledge base, और workflow node उन models को select कर सकता है। Docs bilingual हैं और releases के बीच labels shift करते हैं (doc.fastgpt.io English entry है), तो flow, channel, protocol, base URL, key, models को exact wording की बजाय stable part मानें।
Channel Name: APIsRouter
Protocol Type: OpenAI
Proxy URL: https://api.apisrouter.com/v1
API Key: sk-YOUR-APISROUTER-KEY
Models: claude-sonnet-4-6, deepseek-v4-flash,
glm-5.2, qwen3.7-plus, kimi-k2.6
then: enable the models + run the connection testFastGPT model traffic कैसे route करता है।
FastGPT (GitHub पर labring, लगभग 29K stars) एक Chinese-origin knowledge-base और workflow platform है: QA extraction और vector search वाले datasets, visual Flow orchestration, और sharing व API access वाले published apps। इस सबका resolution configuration layer में registered models पर होता है। एक channel एक routing rule है: ये model ids, यह base URL, यह key। Requests FastGPT से standard chat completions के तौर पर निकलती हैं जिसमें plain string के तौर पर model id होता है, यही वजह है कि एक multi-vendor gateway एक single channel के तौर पर fit हो जाता है। Channel layer वो operational features भी carry करती है जो आप otherwise खुद बनाते: एक model load balancing के लिए कई channels में रह सकता है, और model mapping FastGPT को एक नाम expose करने देती है जबकि provider को एक अलग id string भेजती है। Older versions पर self-hosters के लिए, direct wiring अभी भी मौजूद है: FastGPT का classic environment pair platform को किसी भी OpenAI-compatible base पर point करता है, docker-compose environment में OPENAI_BASE_URL और CHAT_API_KEY, config.json में llmModels के तहत declared models के साथ। यह काम करता है, लेकिन UI path वह जगह है जहां project shift हुआ है, और नए deployments को वहीं से शुरू करना चाहिए।
Asia angle: दोनों model worlds के लिए एक balance।
FastGPT का user base भारी मात्रा में Chinese-speaking है, और इसका typical deployment regional models को Western models के साथ mix करता है: Chinese knowledge bases के लिए GLM या Qwen, volume के लिए DeepSeek, जहां answer polish product हो वहां Claude या GPT। Directly served करने पर, यह mix मुश्किल है, क्योंकि DeepSeek, Zhipu, Moonshot, और Alibaba हर एक अलग bill करते हैं, और कुछ को दुनिया के एक तरफ या दूसरी तरफ से pay करना अजीब है। एक channel के through, यह mix सिर्फ एक model list है: glm-5.2, qwen3.7-plus, kimi-k2.6, deepseek-v4-flash, और claude-haiku-4-5-20251001 साथ-साथ, एक prepaid balance, कोई card requirement नहीं, ids सीधे catalog से। Asia की teams बिना Western card के Claude और GPT पाती हैं; Western teams बिना regional sign-ups के Chinese models पाती हैं। एक ही knowledge base Chinese queries का GLM पर और English queries का Claude पर जवाब दे सकता है, per app routed। अगर आप इसकी बजाय legacy environment wiring चलाते हैं, तो वही endpoint directly drop-in होता है; base URL convention में /v1 suffix शामिल है, और FastGPT इसमें /chat/completions जैसे route paths append करता है।
# docker-compose environment, pre-AI-Proxy versions
OPENAI_BASE_URL=https://api.apisrouter.com/v1
CHAT_API_KEY=sk-YOUR-APISROUTER-KEY
# models declared in config.json under llmModelsKnowledge bases और flows के लिए models चुनना।
चूंकि हर enabled id एक key से bill होती है, models compare करना एक node-setting change है। एक ही app की दो copies में दो candidates pin करें, असली सवालों का एक हफ्ता चलाएं, और answer quality पर अपने judgment के साथ APIsRouter console में per-model split पढ़ें।
- Retrieved chunks पर dataset QA और answer generation volume work है: deepseek-v4-flash और glm-5.2 bilingual corpora पर per-question cost को flat रखते हैं।
- qwen3.7-plus और kimi-k2.6 regional picks हैं जो test करने लायक हैं जब answers को natively Chinese में पढ़ना ज़रूरी हो; generation quality Chinese models में retrieval से ज़्यादा वैरी करती है।
- claude-haiku-4-5-20251001 mixed-language deployments के लिए fast Western tier है; उन specific apps में claude-sonnet-4-6 पर step up करें जहां synthesis quality product है।
- Workflow nodes per run fire होते हैं, तो एक five-node flow हर node में जो भी id है उसे multiply करता है; fast ids classification और routing nodes में रखें, और answer node पर खर्च करें।
- Index और extraction models chat models से अलग configure होते हैं; जिस embedding id को आप bind करते हैं उसके around index rebuild करने से पहले confirm करें कि endpoint उसे serve करता है।
जितना उपयोग उतना भुगतान · आधिकारिक मूल्य से कम
Selected models are priced below official list prices. Exact input, output, cache, and per-request prices are shown for each model.
| मॉडल | आधिकारिक मूल्य | हमारा मूल्य |
|---|---|---|
| GLM-5.2 | $1.14 / $4.00 per M | $1.10 / $4.00 per M |
| DeepSeek V4 Flash | $0.14 / $0.28 per M | $0.10 / $0.30 per M |
| Qwen 3.7 Plus | $0.29 / $1.14 per M | $0.30 / $1.10 per M |
| Kimi K2.6 | $0.95 / $4.00 per M | $1.00 / $4.00 per M |
| Claude Haiku 4.5 20251001 | $1.00 / $5.00 per M | $0.80 / $4.00 per M |
FastGPT के लिए specific failure modes।
Base URL convention उन लोगों को trip करता है जो दूसरे tools से आते हैं: FastGPT proxy field में /v1-suffixed base चाहता है और खुद /chat/completions append करता है, जबकि इसका custom-model form (एक अलग feature, channels bypass करने वाले one-off models के लिए) पूरी request URL चाहता है जिसमें /v1/chat/completions शामिल हो। Paste करने से पहले जान लें आप किस field में हैं। एक model जो channel में exist करता है लेकिन apps में selectable नहीं है, इसका मतलब है इसे channel में add किया गया लेकिन configuration के models side पर enable नहीं किया गया; दोनों lists अलग हैं, और connectivity test सिर्फ channel साबित करता है। पुराने tutorials सबसे बड़ा hazard हैं। FastGPT guides के सालों तक एक OneAPI sidecar और config.json edits assume किए हैं; current versions पर Model Providers UI दोनों की जगह लेता है, और दोनों approaches (env wiring plus channels) एक साथ mix करना requests को कहीं ऐसी जगह route कर देता है जहां आप देख नहीं रहे। एक layer चुनें और उसे पूरी तरह configure करें। Model-not-found errors वही usual free-text problem हैं: channel में id gateway की /v1/models spelling से exactly match होनी चाहिए, version suffixes शामिल। Copy करें, type न करें।
कौन FastGPT को एक gateway के through route करता है।
- Bilingual teams जो GLM, Qwen, Kimi, और DeepSeek को Claude और GPT ids के साथ एक deployment, एक balance, एक usage log में mix करती हैं।
- Asia की teams जो बिना Western card के prepaid balance पर Western frontier models चाहती हैं, और Western teams जो बिना regional billing के Chinese models चाहती हैं।
- Self-hosters जो एक OneAPI sidecar replace कर रहे हैं: gateway multi-vendor part serve करता है, FastGPT के built-in channels routing part serve करते हैं।
- Agencies जो FastGPT पर client knowledge bases चलाती हैं, हर client को उसकी अपनी key से meter करते हुए ताकि model spend per project खुद-ब-खुद report हो।
- Builders जो fixed corpora पर answer models compare करते हैं, जहां हर candidate एक vendor account नहीं बल्कि एक channel entry है।
Endpoint verify करें और पहले सवाल को debug करें।
पहले models listing curl करें और output से ids copy करके channel में डालें; फिर जिस id को default बनाने की योजना है उसके against एक chat completion चलाएं। दोनों pass होने पर, gateway वाला half proven है। FastGPT के अंदर, channel connectivity test इस्तेमाल करें, फिर datasets को involve करने से पहले एक minimal app में एक सवाल पूछें। Authentication errors channel key की तरफ इशारा करते हैं; not-found id spelling की तरफ; connection errors proxy URL या container egress की तरफ, क्योंकि endpoint तक आपके browser को नहीं बल्कि FastGPT server को पहुंचना है। अगर एक dataset app fail होता है जहां एक plain chat app काम करता है, तो problem channel में नहीं बल्कि dataset की अपनी model bindings में है। जब सवाल चलने लगें, APIsRouter console per-request model, token counts, और spend दिखाता है। Knowledge-base traffic कई छोटी, input-heavy requests है, और per-key usage view वह जगह है जहां एक deployment की असली cost profile दिखती है, per model, per day, Chinese और Western ids एक ही page पर।
curl -s https://api.apisrouter.com/v1/models \
-H "Authorization: Bearer $APISROUTER_API_KEY" | head -50
curl -s https://api.apisrouter.com/v1/chat/completions \
-H "Authorization: Bearer $APISROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"glm-5.2",
"messages":[{"role":"user","content":"ping"}]}'अक्सर पूछे जाने वाले प्रश्न
मैं FastGPT में custom base URL कैसे add करूं?
Current versions पर, UI के through: Account, Model Providers, Model Channels, protocol OpenAI, proxy URL https://api.apisrouter.com/v1, अपनी key, और model ids के साथ Add Channel। Older versions पर, environment में OPENAI_BASE_URL और CHAT_API_KEY set करें और config.json में models declare करें।
क्या proxy URL में /v1 शामिल है?
हां, channel के proxy field में /v1-suffixed base enter करें और FastGPT खुद /chat/completions append करता है। अलग custom-model form अपवाद है: यह /v1/chat/completions सहित पूरी request URL लेता है। जिस field में हैं उससे convention match करें।
क्या मुझे अभी भी FastGPT के साथ OneAPI चाहिए?
नहीं। v4.8.23 से FastGPT अपनी aggregation layer UI में channel management के साथ bundle करता है, और एक multi-vendor gateway वो हिस्सा cover करता है जो OneAPI handle करता था। दोनों layers एक साथ चलाना काम करता है लेकिन routing को समझना मुश्किल बनाता है; नए deployments को सिर्फ channels configure करने चाहिए।
क्या FastGPT एक channel में Chinese और Western models mix कर सकता है?
हां। Channel हर model id को एक plain string के तौर पर forward करता है, तो glm-5.2, qwen3.7-plus, kimi-k2.6, deepseek-v4-flash, और claude-sonnet-4-6 एक channel और एक key share कर सकते हैं, per app और per workflow node selectable।
मेरा channel model apps में selectable क्यों नहीं है?
Model Providers UI में एक id को channel में add करना और model को use के लिए enable करना अलग steps हैं। Models list पर model enable करें, फिर app या node dropdown फिर से check करें; per-app model permissions भी filter कर सकती हैं कि कोई given team क्या देखती है।
इसके लिए मुझे कौन-से FastGPT docs पर भरोसा करना चाहिए?
doc.fastgpt.io पर current model-configuration section। FastGPT की configuration surface v4.8.2x era में substantially बदली, और OneAPI sidecars या hand-edited llmModels blocks describe करने वाले पुराने third-party tutorials अब UI-first flow से match नहीं करते।