Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,18 @@ jobs:
run: rye build

- name: Get GitHub OIDC Token
if: github.repository == 'stainless-sdks/isaacus-python'
if: |-
github.repository == 'stainless-sdks/isaacus-python' &&
!startsWith(github.ref, 'refs/heads/stl/')
id: github-oidc
uses: actions/github-script@v8
with:
script: core.setOutput('github_token', await core.getIDToken());

- name: Upload tarball
if: github.repository == 'stainless-sdks/isaacus-python'
if: |-
github.repository == 'stainless-sdks/isaacus-python' &&
!startsWith(github.ref, 'refs/heads/stl/')
env:
URL: https://pkg.stainless.com/s
AUTH: ${{ steps.github-oidc.outputs.github_token }}
Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.19.3"
".": "0.20.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 5
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/isaacus%2Fisaacus-baf5ebdd05d1b5192759a356c2701131c47cfb5b7239a49fcb94e68d4210648c.yml
openapi_spec_hash: 6ea786d56726e18156adf57915fcbe5f
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/isaacus%2Fisaacus-3fc0da1b03c07a47ee0a04ff61443710b99e6d24e8ba5986aab0b1c023c6f0d5.yml
openapi_spec_hash: 5992dd036e090cc43fa15ea5ff985f77
config_hash: 9040e7359f066240ad536041fb2c5185
20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
# Changelog

## 0.20.0 (2026-03-11)

Full Changelog: [v0.19.3...v0.20.0](https://github.com/isaacus-dev/isaacus-python/compare/v0.19.3...v0.20.0)

### Features

* **api:** add kanon-2-reranker ([e3f7e03](https://github.com/isaacus-dev/isaacus-python/commit/e3f7e03cac7b73838a31bec0e1d0507a67a41f13))
* **api:** drop mini models ([0031fe3](https://github.com/isaacus-dev/isaacus-python/commit/0031fe3c4a60500981031dd78fa4fd010fac7eec))


### Chores

* **ci:** skip uploading artifacts on stainless-internal branches ([54b727d](https://github.com/isaacus-dev/isaacus-python/commit/54b727d4799d95bce4143399039538f3c30c744f))
* **internal:** codegen related update ([025587b](https://github.com/isaacus-dev/isaacus-python/commit/025587b946c3ece7a34a346280dbd688880a7276))


### Documentation

* **api:** reworded descriptions ([dd1a29d](https://github.com/isaacus-dev/isaacus-python/commit/dd1a29da595815016f988cf5e6a03cc6b160daf8))

## 0.19.3 (2026-03-03)

Full Changelog: [v0.19.2...v0.19.3](https://github.com/isaacus-dev/isaacus-python/compare/v0.19.2...v0.19.3)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "isaacus"
version = "0.19.3"
version = "0.20.0"
description = "The official Python library for the isaacus API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
30 changes: 30 additions & 0 deletions src/isaacus/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ def __init__(

@cached_property
def embeddings(self) -> EmbeddingsResource:
"""Vectorize content with an Isaacus embedding model."""
from .resources.embeddings import EmbeddingsResource

return EmbeddingsResource(self)
Expand All @@ -110,6 +111,9 @@ def classifications(self) -> ClassificationsResource:

@cached_property
def rerankings(self) -> RerankingsResource:
"""
Score and rank documents by their relevance to queries with an Isaacus reranker.
"""
from .resources.rerankings import RerankingsResource

return RerankingsResource(self)
Expand All @@ -122,6 +126,7 @@ def extractions(self) -> ExtractionsResource:

@cached_property
def enrichments(self) -> EnrichmentsResource:
"""Enrich documents with an Isaacus enrichment model."""
from .resources.enrichments import EnrichmentsResource

return EnrichmentsResource(self)
Expand Down Expand Up @@ -296,6 +301,7 @@ def __init__(

@cached_property
def embeddings(self) -> AsyncEmbeddingsResource:
"""Vectorize content with an Isaacus embedding model."""
from .resources.embeddings import AsyncEmbeddingsResource

return AsyncEmbeddingsResource(self)
Expand All @@ -308,6 +314,9 @@ def classifications(self) -> AsyncClassificationsResource:

@cached_property
def rerankings(self) -> AsyncRerankingsResource:
"""
Score and rank documents by their relevance to queries with an Isaacus reranker.
"""
from .resources.rerankings import AsyncRerankingsResource

return AsyncRerankingsResource(self)
Expand All @@ -320,6 +329,7 @@ def extractions(self) -> AsyncExtractionsResource:

@cached_property
def enrichments(self) -> AsyncEnrichmentsResource:
"""Enrich documents with an Isaacus enrichment model."""
from .resources.enrichments import AsyncEnrichmentsResource

return AsyncEnrichmentsResource(self)
Expand Down Expand Up @@ -445,6 +455,7 @@ def __init__(self, client: Isaacus) -> None:

@cached_property
def embeddings(self) -> embeddings.EmbeddingsResourceWithRawResponse:
"""Vectorize content with an Isaacus embedding model."""
from .resources.embeddings import EmbeddingsResourceWithRawResponse

return EmbeddingsResourceWithRawResponse(self._client.embeddings)
Expand All @@ -457,6 +468,9 @@ def classifications(self) -> classifications.ClassificationsResourceWithRawRespo

@cached_property
def rerankings(self) -> rerankings.RerankingsResourceWithRawResponse:
"""
Score and rank documents by their relevance to queries with an Isaacus reranker.
"""
from .resources.rerankings import RerankingsResourceWithRawResponse

return RerankingsResourceWithRawResponse(self._client.rerankings)
Expand All @@ -469,6 +483,7 @@ def extractions(self) -> extractions.ExtractionsResourceWithRawResponse:

@cached_property
def enrichments(self) -> enrichments.EnrichmentsResourceWithRawResponse:
"""Enrich documents with an Isaacus enrichment model."""
from .resources.enrichments import EnrichmentsResourceWithRawResponse

return EnrichmentsResourceWithRawResponse(self._client.enrichments)
Expand All @@ -482,6 +497,7 @@ def __init__(self, client: AsyncIsaacus) -> None:

@cached_property
def embeddings(self) -> embeddings.AsyncEmbeddingsResourceWithRawResponse:
"""Vectorize content with an Isaacus embedding model."""
from .resources.embeddings import AsyncEmbeddingsResourceWithRawResponse

return AsyncEmbeddingsResourceWithRawResponse(self._client.embeddings)
Expand All @@ -494,6 +510,9 @@ def classifications(self) -> classifications.AsyncClassificationsResourceWithRaw

@cached_property
def rerankings(self) -> rerankings.AsyncRerankingsResourceWithRawResponse:
"""
Score and rank documents by their relevance to queries with an Isaacus reranker.
"""
from .resources.rerankings import AsyncRerankingsResourceWithRawResponse

return AsyncRerankingsResourceWithRawResponse(self._client.rerankings)
Expand All @@ -506,6 +525,7 @@ def extractions(self) -> extractions.AsyncExtractionsResourceWithRawResponse:

@cached_property
def enrichments(self) -> enrichments.AsyncEnrichmentsResourceWithRawResponse:
"""Enrich documents with an Isaacus enrichment model."""
from .resources.enrichments import AsyncEnrichmentsResourceWithRawResponse

return AsyncEnrichmentsResourceWithRawResponse(self._client.enrichments)
Expand All @@ -519,6 +539,7 @@ def __init__(self, client: Isaacus) -> None:

@cached_property
def embeddings(self) -> embeddings.EmbeddingsResourceWithStreamingResponse:
"""Vectorize content with an Isaacus embedding model."""
from .resources.embeddings import EmbeddingsResourceWithStreamingResponse

return EmbeddingsResourceWithStreamingResponse(self._client.embeddings)
Expand All @@ -531,6 +552,9 @@ def classifications(self) -> classifications.ClassificationsResourceWithStreamin

@cached_property
def rerankings(self) -> rerankings.RerankingsResourceWithStreamingResponse:
"""
Score and rank documents by their relevance to queries with an Isaacus reranker.
"""
from .resources.rerankings import RerankingsResourceWithStreamingResponse

return RerankingsResourceWithStreamingResponse(self._client.rerankings)
Expand All @@ -543,6 +567,7 @@ def extractions(self) -> extractions.ExtractionsResourceWithStreamingResponse:

@cached_property
def enrichments(self) -> enrichments.EnrichmentsResourceWithStreamingResponse:
"""Enrich documents with an Isaacus enrichment model."""
from .resources.enrichments import EnrichmentsResourceWithStreamingResponse

return EnrichmentsResourceWithStreamingResponse(self._client.enrichments)
Expand All @@ -556,6 +581,7 @@ def __init__(self, client: AsyncIsaacus) -> None:

@cached_property
def embeddings(self) -> embeddings.AsyncEmbeddingsResourceWithStreamingResponse:
"""Vectorize content with an Isaacus embedding model."""
from .resources.embeddings import AsyncEmbeddingsResourceWithStreamingResponse

return AsyncEmbeddingsResourceWithStreamingResponse(self._client.embeddings)
Expand All @@ -568,6 +594,9 @@ def classifications(self) -> classifications.AsyncClassificationsResourceWithStr

@cached_property
def rerankings(self) -> rerankings.AsyncRerankingsResourceWithStreamingResponse:
"""
Score and rank documents by their relevance to queries with an Isaacus reranker.
"""
from .resources.rerankings import AsyncRerankingsResourceWithStreamingResponse

return AsyncRerankingsResourceWithStreamingResponse(self._client.rerankings)
Expand All @@ -580,6 +609,7 @@ def extractions(self) -> extractions.AsyncExtractionsResourceWithStreamingRespon

@cached_property
def enrichments(self) -> enrichments.AsyncEnrichmentsResourceWithStreamingResponse:
"""Enrich documents with an Isaacus enrichment model."""
from .resources.enrichments import AsyncEnrichmentsResourceWithStreamingResponse

return AsyncEnrichmentsResourceWithStreamingResponse(self._client.enrichments)
Expand Down
2 changes: 1 addition & 1 deletion src/isaacus/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "isaacus"
__version__ = "0.19.3" # x-release-please-version
__version__ = "0.20.0" # x-release-please-version
6 changes: 6 additions & 0 deletions src/isaacus/resources/classifications/classifications.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
class ClassificationsResource(SyncAPIResource):
@cached_property
def universal(self) -> UniversalResource:
"""Classify documents with an Isaacus classification model."""
return UniversalResource(self._client)

@cached_property
Expand All @@ -44,6 +45,7 @@ def with_streaming_response(self) -> ClassificationsResourceWithStreamingRespons
class AsyncClassificationsResource(AsyncAPIResource):
@cached_property
def universal(self) -> AsyncUniversalResource:
"""Classify documents with an Isaacus classification model."""
return AsyncUniversalResource(self._client)

@cached_property
Expand Down Expand Up @@ -72,6 +74,7 @@ def __init__(self, classifications: ClassificationsResource) -> None:

@cached_property
def universal(self) -> UniversalResourceWithRawResponse:
"""Classify documents with an Isaacus classification model."""
return UniversalResourceWithRawResponse(self._classifications.universal)


Expand All @@ -81,6 +84,7 @@ def __init__(self, classifications: AsyncClassificationsResource) -> None:

@cached_property
def universal(self) -> AsyncUniversalResourceWithRawResponse:
"""Classify documents with an Isaacus classification model."""
return AsyncUniversalResourceWithRawResponse(self._classifications.universal)


Expand All @@ -90,6 +94,7 @@ def __init__(self, classifications: ClassificationsResource) -> None:

@cached_property
def universal(self) -> UniversalResourceWithStreamingResponse:
"""Classify documents with an Isaacus classification model."""
return UniversalResourceWithStreamingResponse(self._classifications.universal)


Expand All @@ -99,4 +104,5 @@ def __init__(self, classifications: AsyncClassificationsResource) -> None:

@cached_property
def universal(self) -> AsyncUniversalResourceWithStreamingResponse:
"""Classify documents with an Isaacus classification model."""
return AsyncUniversalResourceWithStreamingResponse(self._classifications.universal)
14 changes: 8 additions & 6 deletions src/isaacus/resources/classifications/universal/universal.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@


class UniversalResource(SyncAPIResource):
"""Classify documents with an Isaacus classification model."""

@cached_property
def with_raw_response(self) -> UniversalResourceWithRawResponse:
"""
Expand All @@ -47,7 +49,7 @@ def with_streaming_response(self) -> UniversalResourceWithStreamingResponse:
def create(
self,
*,
model: Literal["kanon-universal-classifier", "kanon-universal-classifier-mini"],
model: Literal["kanon-universal-classifier"],
query: str,
texts: SequenceNotStr[str],
is_iql: bool | Omit = omit,
Expand All @@ -61,8 +63,7 @@ def create(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> UniversalClassificationResponse:
"""
Classify the relevance of legal documents to a query with an Isaacus universal
legal AI classifier.
Classify documents with an Isaacus universal classification model.

Args:
model: The ID of the [model](https://docs.isaacus.com/models#universal-classification)
Expand Down Expand Up @@ -126,6 +127,8 @@ def create(


class AsyncUniversalResource(AsyncAPIResource):
"""Classify documents with an Isaacus classification model."""

@cached_property
def with_raw_response(self) -> AsyncUniversalResourceWithRawResponse:
"""
Expand All @@ -148,7 +151,7 @@ def with_streaming_response(self) -> AsyncUniversalResourceWithStreamingResponse
async def create(
self,
*,
model: Literal["kanon-universal-classifier", "kanon-universal-classifier-mini"],
model: Literal["kanon-universal-classifier"],
query: str,
texts: SequenceNotStr[str],
is_iql: bool | Omit = omit,
Expand All @@ -162,8 +165,7 @@ async def create(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> UniversalClassificationResponse:
"""
Classify the relevance of legal documents to a query with an Isaacus universal
legal AI classifier.
Classify documents with an Isaacus universal classification model.

Args:
model: The ID of the [model](https://docs.isaacus.com/models#universal-classification)
Expand Down
8 changes: 6 additions & 2 deletions src/isaacus/resources/embeddings.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@


class EmbeddingsResource(SyncAPIResource):
"""Vectorize content with an Isaacus embedding model."""

@cached_property
def with_raw_response(self) -> EmbeddingsResourceWithRawResponse:
"""
Expand Down Expand Up @@ -60,7 +62,7 @@ def create(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> EmbeddingResponse:
"""
Embed legal texts with an Isaacus legal AI embedder.
Vectorize content with an Isaacus embedding model.

Args:
model: The ID of the [model](https://docs.isaacus.com/models#embedding) to use for
Expand Down Expand Up @@ -118,6 +120,8 @@ def create(


class AsyncEmbeddingsResource(AsyncAPIResource):
"""Vectorize content with an Isaacus embedding model."""

@cached_property
def with_raw_response(self) -> AsyncEmbeddingsResourceWithRawResponse:
"""
Expand Down Expand Up @@ -153,7 +157,7 @@ async def create(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> EmbeddingResponse:
"""
Embed legal texts with an Isaacus legal AI embedder.
Vectorize content with an Isaacus embedding model.

Args:
model: The ID of the [model](https://docs.isaacus.com/models#embedding) to use for
Expand Down
Loading