---
title: "Universal classification"
method: POST
path: "/classifications/universal"
tags: ["Classifications"]
---

# Universal classification

`POST /classifications/universal`

Classify documents with an Isaacus universal classification model.

## Request body

- UniversalClassificationRequest — A request to classify the relevance of documents to a query with an Isaacus universal classification model.
  - `model` 'kanon-universal-classifier', required — The ID of the [model](https://docs.isaacus.com/models#universal-classification) to use for universal classification.
  - `query` string, required — The [Isaacus Query Language (IQL)](https://docs.isaacus.com/iql) query or, if IQL is disabled, the statement, to evaluate the texts against. The query must contain at least one non-whitespace character. Unlike the texts being classified, the query cannot be so long that it exceeds the maximum input length of the universal classifier.
  - `texts` string[], required — The texts to classify. Each text must contain at least one non-whitespace character.
  - `is_iql` boolean — Whether the query should be interpreted as an [IQL](https://docs.isaacus.com/iql) query or else as a statement.
  - `scoring_method` 'auto' | 'chunk_max' | 'chunk_avg' | 'chunk_min' — The method to use for producing an overall confidence score. `auto` is the default scoring method and is recommended for most use cases. Currently, it is equivalent to `chunk_max`. In the future, it will automatically select the best method based on the model and inputs. `chunk_max` uses the highest confidence score of all of the texts' chunks. `chunk_avg` averages the confidence scores of all of the texts' chunks. `chunk_min` uses the lowest confidence score of all of the texts' chunks.
  - `chunking_options` ChunkingOptions — Options for how to split text into smaller chunks.
    - `size` integer, nullable — A whole number greater than or equal to 1.
    - `overlap_ratio` number, nullable — A number greater than or equal to 0 and less than 1.
    - `overlap_tokens` integer, nullable — A whole number greater than or equal to 0.

## Response `200`

Classifications of the relevance of documents to a query produced by an Isaacus universal classification model.

- UniversalClassificationResponse
  - `classifications` UniversalClassification[], required — The classifications of the texts, by relevance to the query, in order from highest to lowest confidence score.
    - `index` integer, required — The index of the text in the input array of texts, starting from `0` (and, therefore, ending at the number of texts minus `1`).
    - `score` number, required — A score of the likelihood that the query expressed about the text is supported by the text. A score greater than `0.5` indicates that the text supports the query, while a score less than `0.5` indicates that the text does not support the query.
    - `chunks` UniversalClassificationChunk[], nullable, required — The text as broken into chunks by [semchunk](https://github.com/isaacus-dev/semchunk), each chunk with its own confidence score, ordered from highest to lowest score. If no chunking occurred, this will be `null`.
      - `index` integer, required — The original position of the chunk in the outputted list of chunks before sorting, starting from `0` (and, therefore, ending at the number of chunks minus `1`).
      - `start` integer, required — The index of the character in the original text where the chunk starts, beginning from `0`.
      - `end` integer, required — The index of the character immediately after the last character of the chunk in the original text, beginning from `0` (such that, in Python, the chunk is equivalent to `text[start:end]`).
      - `score` number, required — The model's score of the likelihood that the query expressed about the chunk is supported by the chunk. A score greater than `0.5` indicates that the chunk supports the query, while a score less than `0.5` indicates that the chunk does not support the query.
      - `text` string, required — The text of the chunk.
  - `usage` UniversalClassificationUsage, required — Statistics about the usage of resources in the process of classifying the text.
    - `input_tokens` integer, required — The number of tokens inputted to the model.

## Other responses

- `400` — The request was invalid or could not be processed.
- `401` — The API key you provided does not exist, is expired or revoked, or is not authorized to access this resource.
- `402` — Your account is overdue, please pay any outstanding invoices to continue using our services.
- `403` — You are not allowed to access this resource.
- `413` — The request is larger than the server is willing or able to process.
- `500` — An unexpected error occurred while processing the request.

## Changes

> 29 revisions in range; 2 could not be searched.

- **2026-03-11** `3fc0da1b03c0` — 3 breaking
  - the `model` request property const value `kanon-universal-classifier` was added
  - removed the enum value `kanon-universal-classifier` of the request property `model`
  - removed the enum value `kanon-universal-classifier-mini` of the request property `model`
- **2026-03-09** `0768ad934de9` — 1 info
  - the `query` request property's maxLength was increased from `5000` to `10000000`
- **2026-02-04** `eb64c01e148b` — 1 warning
  - the `chunking_options/oneOf[subschema #1: Chunking options]/overlap_tokens/oneOf[subschema #1: Non-negative integer]/` request property's min was set to `0.00`

[Change history](https://skmtc.dev/isaacus-dev/apis/isaacus-api/changes/classifications/universal/post.md)

---

[API](https://skmtc.dev/isaacus-dev/apis/isaacus-api.md) · [All operations](https://skmtc.dev/isaacus-dev/apis/isaacus-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/isaacus-dev/isaacus-api/revisions/b650dd142971/schema)
