Repository navigation
feat(classify)!: classify() takes the types to choose among as types and answers each document's or page's type - #726
Merged
Merged
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
…` and answers each document's or page's `type` BREAKING CHANGE: classify(document, classes, ...) is classify(document, types, ...), and a completed job's 'class' (and each page's) is 'type'. The API takes "types" and answers "type" from the same release of the server on, so 0.8.0 and 0.8.1 calls get a 422 once it is deployed. Users name these document types, not classes, and Python cannot write d.class or a model field named class. Page Classify was one day old with almost no users, so it is renamed now.
rejojer
force-pushed
the
feat/classify-types
branch
from
November 29, 2026 20:10
7f6b0dd to
78f68ec
Compare
types and answers each document's or page's type, as Page Split names themtypes and answers each document's or page's type
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
classify()now takes the types to choose among astypesand answerstype, where 0.8.0 and 0.8.1 saidclassesandclass. Code written against those two releases breaks; the change ships in 0.8.2.Users call these document types, not classes, and Python cannot write
d.classor declare a model field namedclass. Page Classify was a day old and had almost no users, so it is renamed now.Changes
classify(document, types, *, ...): the second parameter istypes(wasclasses). It takes the same shapes:{name: description}, a list of names, one name, or a list of{"name", "description"}.type(granularity"document") and eachpages[]entry'stype(granularity"page") replaceclass.Nonestill means none of the types fits.CloudAPI.create_classify()sends{"types": ...}, and the docstrings follow.Release
The server side is VectifyAI/pageindex-compute#1014: it takes
configuration.typesand answerstype, and a request still sendingclassesgets a 422 that names it. Merge and release this only once #1014 is on Prod. Before then,typesgets a 422; after it, 0.8.0 and 0.8.1 get one.Verification
tests/test_client.pyare renamed: the configuration sent carriestypes, and results readtype.maintoo with the litellm installed here.