Merge pull request #3715 from GhostXia/staging change 01ai endpoint
Signed| @@ -3417,7 +3417,7 @@ | |||
| 3417 | </form> | 3417 | </form> |
| 3418 | <div id="01ai_form" data-source="01ai"> | 3418 | <div id="01ai_form" data-source="01ai"> |
| 3419 | <h4> | 3419 | <h4> |
| 3420 | <a data-i18n="01.AI API Key" href="https://platform.01.ai/" target="_blank" rel="noopener noreferrer"> | 3420 | <a data-i18n="01.AI API Key" href="https://platform.lingyiwanwu.com/" target="_blank" rel="noopener noreferrer"> |
| 3421 | 01.AI API Key | 3421 | 01.AI API Key |
| 3422 | </a> | 3422 | </a> |
| 3423 | </h4> | 3423 | </h4> |
| @@ -49,7 +49,7 @@ const API_COHERE_V2 = 'https://api.cohere.ai/v2'; | |||
| 49 | const API_PERPLEXITY = 'https://api.perplexity.ai'; | 49 | const API_PERPLEXITY = 'https://api.perplexity.ai'; |
| 50 | const API_GROQ = 'https://api.groq.com/openai/v1'; | 50 | const API_GROQ = 'https://api.groq.com/openai/v1'; |
| 51 | const API_MAKERSUITE = 'https://generativelanguage.googleapis.com'; | 51 | const API_MAKERSUITE = 'https://generativelanguage.googleapis.com'; |
| 52 | const API_01AI = 'https://api.01.ai/v1'; | 52 | const API_01AI = 'https://api.lingyiwanwu.com/v1'; |
| 53 | const API_BLOCKENTROPY = 'https://api.blockentropy.ai/v1'; | 53 | const API_BLOCKENTROPY = 'https://api.blockentropy.ai/v1'; |
| 54 | const API_AI21 = 'https://api.ai21.com/studio/v1'; | 54 | const API_AI21 = 'https://api.ai21.com/studio/v1'; |
| 55 | const API_NANOGPT = 'https://nano-gpt.com/api/v1'; | 55 | const API_NANOGPT = 'https://nano-gpt.com/api/v1'; |
| @@ -116,7 +116,7 @@ router.post('/caption-image', async (request, response) => { | |||
| 116 | } | 116 | } |
| 117 | 117 | ||
| 118 | if (request.body.api === 'zerooneai') { | 118 | if (request.body.api === 'zerooneai') { |
| 119 | apiUrl = 'https://api.01.ai/v1/chat/completions'; | 119 | apiUrl = 'https://api.lingyiwanwu.com/v1/chat/completions'; |
| 120 | } | 120 | } |
| 121 | 121 | ||
| 122 | if (request.body.api === 'groq') { | 122 | if (request.body.api === 'groq') { |