curl -X POST "https://api.lemondata.cc/v1/rerank" \ -H "Authorization: Bearer sk-your-api-key" \ -H "Content-Type: application/json" \ -d '{ "model": "BAAI/bge-reranker-v2-m3", "query": "What is machine learning?", "documents": [ "Machine learning is a subset of AI", "The weather is nice today", "Deep learning uses neural networks" ], "top_n": 2, "return_documents": true }'
{ "results": [ { "index": 0, "relevance_score": 0.95, "document": "Machine learning is a subset of AI" }, { "index": 2, "relevance_score": 0.82, "document": "Deep learning uses neural networks" } ], "model": "BAAI/bge-reranker-v2-m3", "usage": { "prompt_tokens": 45, "total_tokens": 45 } }
إعادة ترتيب المستندات بناءً على مدى صلتها بالاستعلام
BAAI/bge-reranker-v2-m3
qwen3-rerank
index
relevance_score
document
return_documents=true