跳转至

向量嵌入embedding&重排reranker

一、嵌入embedding

curl https://api.4allapi.com/v1/embeddings \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk-你的key" \
  -d '{
    "input": "你的文本内容",
    "model": "text-embedding-ada-002"
  }'

二、重排reranker

curl https://api.4allapi.com/v1/rerank \
  -H "Authorization: Bearer sk-你的key" \
  -H 'accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
    "query": "ping",
    "documents": ["pong"],
    "model": "Qwen/Qwen3-Reranker-8B"
  }'


4All API 页脚

4All API · 一站式AI大模型API聚合平台 | 价格 | 联系我们

© 2025 4All API. All rights reserved.