Reorder
Given a hint, the model will return one or more predicted completions and can also return the probability of the surrogate marker for each position. Complete creation for the provided prompts and parameters Official…
POST
/v1/rerankBody Parametersapplication/json
documents* array
List of documents to rerank
items string string
instruct* string
Rerank instruction / extra notes
model* string
Model name / model ID
query* string
Query text
top_n* integer
Return the top N results
Responses
200 application/json
response-200 object
properties choices* array
List of candidate results
created* integer
Creation time (Unix timestamp)
id* string
Resource or task ID
object* string
Object type identifier, e.g. chat.completion
usage* object
Token usage statistics
400 Bad request or validation failed application/json
response-400 object
properties error* object
401 Missing or invalid API Key application/json
response-401 object
1{
2"documents": [
3"文本排序模型广泛用于搜索引擎 and 推荐系统中,它们根据文本相关性对候选文本进行排序",
4"量子计算是计算科学的一个前沿领域",
5"预训练语言模型的发展给文本排序模型带来了新的进展"
6],
7"instruct": "Given a web search query, retrieve relevant passages that answer the query.",
8"model": "qwen3-rerank",
9"query": "什么是文本排序模型",
10"top_n": 2
11}
1curl -X POST "https://api.digislash.com/v1/rerank" \
2-H "Authorization: Bearer <API Key>" \
3-H "Content-Type: application/json" \
4-d '{
5"documents": [
6"文本排序模型广泛用于搜索引擎 and 推荐系统中,它们根据文本相关性对候选文本进行排序",
7"量子计算是计算科学的一个前沿领域",
8"预训练语言模型的发展给文本排序模型带来了新的进展"
9],
10"instruct": "Given a web search query, retrieve relevant passages that answer the query.",
11"model": "qwen3-rerank",
12"query": "什么是文本排序模型",
13"top_n": 2
14}'
1▼{
2▼"choices": [
3▶{ 3 keys }
4],
5"created": 1677652288,
6"id": "chatcmpl-123",
7"object": "chat.completion",
8▼"usage": {
9"completion_tokens": 12,
10"prompt_tokens": 9,
11"total_tokens": 21
12}
13}
