Feat: Support Specifying OpenRouter Model Provider (#10550)

### What problem does this PR solve?
issue:
[#5787](https://github.com/infiniflow/ragflow/issues/5787)
change:
Support Specifying OpenRouter Model Provider

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
buua436
2025-10-16 09:39:59 +08:00
committed by GitHub
parent c99034f717
commit 4e86ee4ff9
4 changed files with 67 additions and 5 deletions

View File

@ -194,6 +194,9 @@ def add_llm():
elif factory == "Azure-OpenAI":
api_key = apikey_json(["api_key", "api_version"])
elif factory == "OpenRouter":
api_key = apikey_json(["api_key", "provider_order"])
llm = {
"tenant_id": current_user.id,
"llm_factory": factory,