BeeBridge AIBeeBridge AI
API-Referenz
KI-Modell-APIsChatNatives OpenAI-Format
⚠️Compliance-Hinweis: Verwenden Sie dieses Projekt nur für rechtmäßig autorisierte API-Gateways, interne Verwaltung und private Bereitstellungen. Beachten Sie die Nutzungsbedingungen vorgelagerter Dienste, Plattformregeln, regulatorische Vorgaben und Anforderungen an die Inhaltssicherheit.

ChatCompletions-Format

Erstellt eine Modellantwort aus dem Gesprächsverlauf. Unterstützt Streaming-Antworten und Antworten ohne Streaming.

Kompatibel mit der OpenAI Chat Completions API.

POST
/v1/chat/completions
AuthorizationBearer <token>

Authentifizieren Sie sich mit einem Bearer-Token. Format: Authorization: Bearer sk-xxxxxx

Position: header

modelstring

Modell-ID

messages

Liste der Konversationsnachrichten

temperature?number

Sampling-Temperatur

Standardwert1
Bereich0 <= value <= 2
top_p?number

Parameter für Nucleus-Sampling

Standardwert1
Bereich0 <= value <= 1
n?integer

Anzahl der zu generierenden Elemente

Standardwert1
Bereich1 <= value
stream?boolean

Ob die Antwort gestreamt wird

Standardwertfalse
stream_options?
stop?string|

Stoppsequenzen

max_tokens?integer

Maximale Anzahl generierter Tokens

max_completion_tokens?integer

Maximale Anzahl von Vervollständigungs-Tokens

presence_penalty?number
Standardwert0
Bereich-2 <= value <= 2
frequency_penalty?number
Standardwert0
Bereich-2 <= value <= 2
logit_bias?
user?string
tools?
tool_choice?string|
response_format?
seed?integer
reasoning_effort?string

Denkaufwand (für Modelle mit Schlussfolgerungsfunktion)

Zulässige Werte"low" | "medium" | "high"
modalities?array<string>
audio?

Antworttext

application/json

application/json

application/json

curl -X POST "https://api.beeaicloud.com/v1/chat/completions" \  -H "Content-Type: application/json" \  -d '{    "model": "gpt-4",    "messages": [      {        "role": "system",        "content": "string"      }    ]  }'
{
  "id": "string",
  "object": "chat.completion",
  "created": 0,
  "model": "string",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "system",
        "content": "string",
        "name": "string",
        "tool_calls": [
          {
            "id": "string",
            "type": "function",
            "function": {
              "name": "string",
              "arguments": "string"
            }
          }
        ],
        "tool_call_id": "string",
        "reasoning_content": "string"
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 0,
    "completion_tokens": 0,
    "total_tokens": 0,
    "prompt_tokens_details": {
      "cached_tokens": 0,
      "text_tokens": 0,
      "audio_tokens": 0,
      "image_tokens": 0
    },
    "completion_tokens_details": {
      "text_tokens": 0,
      "audio_tokens": 0,
      "reasoning_tokens": 0
    }
  },
  "system_fingerprint": "string"
}
{
  "error": {
    "message": "string",
    "type": "string",
    "param": "string",
    "code": "string"
  }
}
{
  "error": {
    "message": "string",
    "type": "string",
    "param": "string",
    "code": "string"
  }
}

War diese Anleitung hilfreich?

ChatCompletions-Format | BeeBridge AI