Skip to main content

Inference API Overview

The Hindsight Inference API serves the models behind Hindsight's own retrieval to your applications directly:

EndpointWhat it doesCompatible with
POST /v1/rerankOrders documents by relevance to a queryCohere Rerank
POST /v1/embeddingsTurns text into vectors for semantic searchOpenAI Embeddings

Both endpoints speak an existing, widely supported format, so in most cases you switch by changing the base URL and API key in a client you already use.

Base URL​

https://inference.hindsight.vectorize.io/v1

Authentication​

The Inference API uses the same organization API keys as the rest of Hindsight Cloud. Send the key as a bearer token:

Authorization: Bearer hs_your_api_key

Create and manage keys from API Keys in the Inference console, or from the main Hindsight Cloud console. See API Keys.

Pricing and Credits​

Both endpoints bill on input tokens only. Neither produces output tokens.

EndpointPrice
Reranking$0.05 per 1M input tokens
Embeddings$0.01 per 1M input tokens

Charges come out of your organization's single credit balance, the same balance that pays for memory operations. There is no separate wallet to top up. See Billing.

Before each request, the API checks your balance against the most the request could cost. If the balance is too low it returns 402 without charging anything.

The Inference Console​

Signing in to the Inference console with your Hindsight Cloud account gives you:

  • Overview: the endpoint, model IDs, prices, and copy-paste quick-starts
  • Playground: run a query against your own documents with reranking or embeddings, side by side
  • Usage: input tokens, requests and cost over time, per product
  • API Keys: create and revoke keys for your organization
  • Billing: your shared credit balance and the per-product rates

Errors​

Errors return a JSON body with a detail message.

StatusMeaningWhat to do
400Invalid request (missing field, too many items, bad option)Fix the request; detail names the field
401Missing or invalid API keyCheck the Authorization header
402Not enough credits for this requestTop up from Billing
404Unknown modelUse the model ID shown in the console
429Capacity is busyRetry after the Retry-After header (seconds)
502The model backend failedRetry; contact support if it persists