Skip to content

[Feature Request] Add "name" field for Non Openai-Compatible Provider / Fix logic for identify different provider #2102

@Ja-hard

Description

@Ja-hard

现状描述

如图所示,本次测试仅请求了一次 gpt-5.4

  • 真实情况走的是 Openai-Compatible 协议的 bohe
  • 实际提示走了 Gemini 协议的 Provider #1
Image

配置文件

openai-compatibility:
  - name: bohe
    base-url: https://x
    api-key-entries:
      - api-key: sk-bohe
    models:
      - name: gpt-5.4
        alias: gpt-default
gemini-api-key:
  - api-key: sk-bohe
    base-url: https://x
    models:
      - name: gemini-3.1-pro-high
        alias: gemini-pro

预期特性

  1. 为 google / openai-responses / anthropic 等非 openai-compatible 格式的 provider 添加各自的 "name" 属性。
  2. 修复 provider 识别逻辑,现在的策略可能是通过 key 识别?建议采用更唯一的识别字段,比如限制每种的协议的 provider 不允许拥有相同的 "name" 字段,然后通过 ${provider.protocol}+${provider.name} 的方式区分不同 provider.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions