Result - TypeScript SDK

Result type definition

The TypeScript SDK and docs are currently in beta. Report issues on GitHub.

A single rerank result

Example Usage

1import { Result } from "@openrouter/sdk/models/operations";
2
3let value: Result = {
4 document: {},
5 index: 0,
6 relevanceScore: 0.98,
7};

Fields

FieldTypeRequiredDescriptionExample
documentoperations.DocumentResponse✔️The document object echoing the original input (text and/or image)
indexnumber✔️Index of the document in the original input list0
relevanceScorenumber✔️Relevance score of the document to the query0.98