Catalog/rag-chebyshev-distance

Retrieval

Chebyshev (L-inf) distance API

Returns the L-infinity distance (largest single-dimension difference) and which dimension dominates. Answers 'What is the Chebyshev distance between these vectors?', 'Which dimension differs the most?'.

Price$0.01per request
MethodPOST
Route/v1/retrieval/chebyshev-distance
StatusLive
MIME typeapplication/json
Rate limit120/minute
Cache0s public
chebyshevl-infinitylinfdistancevectormetricretrievalrag
API URLhttps://x402.hexl.dev/v1/retrieval/chebyshev-distance
Integration docs
Example request
{
  "a": [
    0,
    0,
    0
  ],
  "b": [
    1,
    5,
    2
  ]
}
Example response
{
  "chebyshevDistance": 5,
  "dominantDimension": 1,
  "dimensions": 3,
  "formula": "max(|a_i - b_i|)"
}
Input schema
{
  "type": "object",
  "required": [
    "a",
    "b"
  ],
  "properties": {
    "a": {
      "type": "array",
      "items": {
        "type": "number"
      }
    },
    "b": {
      "type": "array",
      "items": {
        "type": "number"
      }
    }
  }
}
Output schema
{
  "type": "object",
  "additionalProperties": true
}