Files
KI-Diskussionen/AnythingLLM-OpenAI-Compatible-Integration.md

32 lines
1.4 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
## AnythingLLM & Azure OpenAI Gesprächsverlauf & Lösung
**Frage:** Ich möchte AnythingLLM im Generic OpenAI Modus mit Azure Foundry nutzen. Was muss ich eintragen?
**Diskussion:**
- Zunächst wurde empfohlen, im Generic OpenAI Modus folgende Werte zu setzen:
- API Base URL: https://kpa-az-ai-foundry.cognitiveservices.azure.com/
- API Key: <dein Azure-API-Key>
- Model: gpt-4.1
- Token Context Window & Max Tokens: 13107 (bzw. 131072, je nach Deployment)
- Hinweis: Die API-Version ist in AnythingLLM nicht konfigurierbar.
**Frage:** Wie viele Tokens sind mit gpt-4.1 möglich?
- Antwort: Bis zu 131072 Tokens (128k), wenn das Azure-Deployment dies unterstützt.
**Problem:**
Fehlermeldung: `Could not respond to message. 404 Resource not found`
**Analyse:**
- 404 bedeutet meist: Falscher Endpoint, Modelname oder API-Route.
- Es wurde empfohlen, die Base URL ggf. mit `/openai/deployments/<deployment>/chat/completions?api-version=...` zu ergänzen.
- Wichtig: Der Deployment-Name muss exakt stimmen.
**Lösung:**
Statt "Generic OpenAI Compatible" wurde im AnythingLLM Backend der Modus "Azure OpenAI" gewählt. Dort funktionierte der Endpoint sofort korrekt.
**Fazit:**
- Für Azure OpenAI immer den dedizierten "Azure OpenAI"-Modus in AnythingLLM nutzen, nicht den generischen OpenAI-Modus.
- Die relevanten Felder (Endpoint, API-Key, Deployment-Name) exakt wie in Azure angeben.
Damit ist die Integration erfolgreich abgeschlossen.