Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
f617346
docs(sdk): specify example params
stainless-app[bot] Oct 26, 2025
13eb93f
fix(client): close streams without requiring full consumption
stainless-app[bot] Oct 30, 2025
871fa54
chore(internal/tests): avoid race condition with implicit client cleanup
stainless-app[bot] Oct 31, 2025
84145f2
chore(internal): grammar fix (it's -> its)
stainless-app[bot] Nov 4, 2025
556d5d0
chore(package): drop Python 3.8 support
stainless-app[bot] Nov 11, 2025
89ef152
fix: compat with Python 3.14
stainless-app[bot] Nov 11, 2025
4d7b71d
fix(compat): update signatures of `model_dump` and `model_dump_json` …
stainless-app[bot] Nov 12, 2025
083d4b6
chore: add Python 3.14 classifier and testing
stainless-app[bot] Nov 22, 2025
c2ae554
fix: ensure streams are always closed
stainless-app[bot] Nov 28, 2025
9612e35
chore(deps): mypy 1.18.1 has a regression, pin to 1.17
stainless-app[bot] Nov 28, 2025
b53392a
chore: update lockfile
stainless-app[bot] Dec 3, 2025
ac22598
chore(docs): use environment variables for authentication in code sni…
stainless-app[bot] Dec 3, 2025
b89d4ce
fix(types): allow pyright to infer TypedDict types within SequenceNotStr
stainless-app[bot] Dec 9, 2025
0c4e7d4
chore: add missing docstrings
stainless-app[bot] Dec 9, 2025
669f50a
chore(internal): add missing files argument to base client
stainless-app[bot] Dec 16, 2025
2d500ed
chore: speedup initial import
stainless-app[bot] Dec 17, 2025
30ffab2
fix: use async_to_httpx_files in patch method
stainless-app[bot] Dec 18, 2025
577ad2c
release: 0.9.2
stainless-app[bot] Dec 18, 2025
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
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.9.1"
".": "0.9.2"
}
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 4
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/isaacus%2Fisaacus-6705b8e0baa0e4aad69a1c04e9876b352e40e0e5caf21e87e7b2c355e70c4e66.yml
openapi_spec_hash: 87d3cc80f5ddc5275e8a47d35f1a484e
config_hash: a85580968a69d8d6fadf96e5e2d6870e
config_hash: eb6af7379e9073b3ece2803bfcf65e68
32 changes: 32 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,37 @@
# Changelog

## 0.9.2 (2025-12-18)

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

### Bug Fixes

* **client:** close streams without requiring full consumption ([13eb93f](https://github.com/isaacus-dev/isaacus-python/commit/13eb93fea611507de440a4418b82de3aa8a06500))
* compat with Python 3.14 ([89ef152](https://github.com/isaacus-dev/isaacus-python/commit/89ef152681673c408e217ad44f51dba229f9d371))
* **compat:** update signatures of `model_dump` and `model_dump_json` for Pydantic v1 ([4d7b71d](https://github.com/isaacus-dev/isaacus-python/commit/4d7b71de78bdd83f00d16ec409c57cbe4dd01ebb))
* ensure streams are always closed ([c2ae554](https://github.com/isaacus-dev/isaacus-python/commit/c2ae554fd73a5f0d4c0f7eb9a2fa652669d38f2e))
* **types:** allow pyright to infer TypedDict types within SequenceNotStr ([b89d4ce](https://github.com/isaacus-dev/isaacus-python/commit/b89d4ce184708ad0737ba7fc77f1afe270a8eb50))
* use async_to_httpx_files in patch method ([30ffab2](https://github.com/isaacus-dev/isaacus-python/commit/30ffab28e37d4f940e69f2afe199fad830f57ba0))


### Chores

* add missing docstrings ([0c4e7d4](https://github.com/isaacus-dev/isaacus-python/commit/0c4e7d4039a6b60adccc39be7a98b9efdbbc3df4))
* add Python 3.14 classifier and testing ([083d4b6](https://github.com/isaacus-dev/isaacus-python/commit/083d4b600ddba22fc81c33da7dee079c97088c81))
* **deps:** mypy 1.18.1 has a regression, pin to 1.17 ([9612e35](https://github.com/isaacus-dev/isaacus-python/commit/9612e35c83634a774c507349b4cd211d4d8c2c84))
* **docs:** use environment variables for authentication in code snippets ([ac22598](https://github.com/isaacus-dev/isaacus-python/commit/ac2259872f666a3c0cdb57695623aa980e5bdf36))
* **internal/tests:** avoid race condition with implicit client cleanup ([871fa54](https://github.com/isaacus-dev/isaacus-python/commit/871fa54adcd54f3f5ffde794e4ae703e7913e6b7))
* **internal:** add missing files argument to base client ([669f50a](https://github.com/isaacus-dev/isaacus-python/commit/669f50a93bc5868ff80a48e0a29c4a53e362fa99))
* **internal:** grammar fix (it's -> its) ([84145f2](https://github.com/isaacus-dev/isaacus-python/commit/84145f233adddf8b55a24b0443a2f9c9dc5a4cbd))
* **package:** drop Python 3.8 support ([556d5d0](https://github.com/isaacus-dev/isaacus-python/commit/556d5d07c941f4e2c4b6e523756723ce5661c4b3))
* speedup initial import ([2d500ed](https://github.com/isaacus-dev/isaacus-python/commit/2d500ed45248bf120cd21236644d9573d563120b))
* update lockfile ([b53392a](https://github.com/isaacus-dev/isaacus-python/commit/b53392a51c7b7e8605880af51e53db044ad14d94))


### Documentation

* **sdk:** specify example params ([f617346](https://github.com/isaacus-dev/isaacus-python/commit/f617346d3262a45594d34357e97fc616f5ddf9e9))

## 0.9.1 (2025-10-19)

Full Changelog: [v0.9.0...v0.9.1](https://github.com/isaacus-dev/isaacus-python/compare/v0.9.0...v0.9.1)
Expand Down
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<!-- prettier-ignore -->
[![PyPI version](https://img.shields.io/pypi/v/isaacus.svg?label=pypi%20(stable))](https://pypi.org/project/isaacus/)

The Isaacus Python library provides convenient access to the Isaacus REST API from any Python 3.8+
The Isaacus Python library provides convenient access to the Isaacus REST API from any Python 3.9+
application. The library includes type definitions for all request params and response fields,
and offers both synchronous and asynchronous clients powered by [httpx](https://github.com/encode/httpx).

Expand Down Expand Up @@ -38,6 +38,7 @@ embedding_response = client.embeddings.create(
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
)
print(embedding_response.embeddings)
```
Expand Down Expand Up @@ -68,6 +69,7 @@ async def main() -> None:
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
)
print(embedding_response.embeddings)

Expand All @@ -91,14 +93,15 @@ pip install isaacus[aiohttp]
Then you can enable it by instantiating the client with `http_client=DefaultAioHttpClient()`:

```python
import os
import asyncio
from isaacus import DefaultAioHttpClient
from isaacus import AsyncIsaacus


async def main() -> None:
async with AsyncIsaacus(
api_key="My API Key",
api_key=os.environ.get("ISAACUS_API_KEY"), # This is the default and can be omitted
http_client=DefaultAioHttpClient(),
) as client:
embedding_response = await client.embeddings.create(
Expand All @@ -107,6 +110,7 @@ async def main() -> None:
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
)
print(embedding_response.embeddings)

Expand Down Expand Up @@ -167,6 +171,7 @@ try:
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
)
except isaacus.APIConnectionError as e:
print("The server could not be reached")
Expand Down Expand Up @@ -216,6 +221,7 @@ client.with_options(max_retries=5).embeddings.create(
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
)
```

Expand Down Expand Up @@ -245,6 +251,7 @@ client.with_options(timeout=5.0).embeddings.create(
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
)
```

Expand Down Expand Up @@ -289,6 +296,7 @@ client = Isaacus()
response = client.embeddings.with_raw_response.create(
model="kanon-2-embedder",
texts=["Are restraints of trade enforceable under English law?", "What is a non-compete clause?"],
task="retrieval/query",
)
print(response.headers.get('X-My-Header'))

Expand All @@ -313,6 +321,7 @@ with client.embeddings.with_streaming_response.create(
"Are restraints of trade enforceable under English law?",
"What is a non-compete clause?",
],
task="retrieval/query",
) as response:
print(response.headers.get("X-My-Header"))

Expand Down Expand Up @@ -423,7 +432,7 @@ print(isaacus.__version__)

## Requirements

Python 3.8 or higher.
Python 3.9 or higher.

## Contributing

Expand Down
24 changes: 13 additions & 11 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,30 +1,32 @@
[project]
name = "isaacus"
version = "0.9.1"
version = "0.9.2"
description = "The official Python library for the isaacus API"
dynamic = ["readme"]
license = "Apache-2.0"
authors = [
{ name = "Isaacus", email = "support@isaacus.com" },
]

dependencies = [
"httpx>=0.23.0, <1",
"pydantic>=1.9.0, <3",
"typing-extensions>=4.10, <5",
"anyio>=3.5.0, <5",
"distro>=1.7.0, <2",
"sniffio",
"httpx>=0.23.0, <1",
"pydantic>=1.9.0, <3",
"typing-extensions>=4.10, <5",
"anyio>=3.5.0, <5",
"distro>=1.7.0, <2",
"sniffio",
]
requires-python = ">= 3.8"

requires-python = ">= 3.9"
classifiers = [
"Typing :: Typed",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Operating System :: OS Independent",
"Operating System :: POSIX",
"Operating System :: MacOS",
Expand All @@ -46,7 +48,7 @@ managed = true
# version pins are in requirements-dev.lock
dev-dependencies = [
"pyright==1.1.399",
"mypy",
"mypy==1.17",
"respx",
"pytest",
"pytest-asyncio",
Expand Down Expand Up @@ -141,7 +143,7 @@ filterwarnings = [
# there are a couple of flags that are still disabled by
# default in strict mode as they are experimental and niche.
typeCheckingMode = "strict"
pythonVersion = "3.8"
pythonVersion = "3.9"

exclude = [
"_dev",
Expand Down
112 changes: 62 additions & 50 deletions requirements-dev.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12,40 +12,45 @@
-e file:.
aiohappyeyeballs==2.6.1
# via aiohttp
aiohttp==3.12.8
aiohttp==3.13.2
# via httpx-aiohttp
# via isaacus
aiosignal==1.3.2
aiosignal==1.4.0
# via aiohttp
annotated-types==0.6.0
annotated-types==0.7.0
# via pydantic
anyio==4.4.0
anyio==4.12.0
# via httpx
# via isaacus
argcomplete==3.1.2
argcomplete==3.6.3
# via nox
async-timeout==5.0.1
# via aiohttp
attrs==25.3.0
attrs==25.4.0
# via aiohttp
certifi==2023.7.22
# via nox
backports-asyncio-runner==1.2.0
# via pytest-asyncio
certifi==2025.11.12
# via httpcore
# via httpx
colorlog==6.7.0
colorlog==6.10.1
# via nox
dependency-groups==1.3.1
# via nox
dirty-equals==0.6.0
distlib==0.3.7
dirty-equals==0.11
distlib==0.4.0
# via virtualenv
distro==1.8.0
distro==1.9.0
# via isaacus
exceptiongroup==1.2.2
exceptiongroup==1.3.1
# via anyio
# via pytest
execnet==2.1.1
execnet==2.1.2
# via pytest-xdist
filelock==3.12.4
filelock==3.19.1
# via virtualenv
frozenlist==1.6.2
frozenlist==1.8.0
# via aiohttp
# via aiosignal
h11==0.16.0
Expand All @@ -58,80 +63,87 @@ httpx==0.28.1
# via respx
httpx-aiohttp==0.1.9
# via isaacus
idna==3.4
humanize==4.13.0
# via nox
idna==3.11
# via anyio
# via httpx
# via yarl
importlib-metadata==7.0.0
iniconfig==2.0.0
importlib-metadata==8.7.0
iniconfig==2.1.0
# via pytest
markdown-it-py==3.0.0
# via rich
mdurl==0.1.2
# via markdown-it-py
multidict==6.4.4
multidict==6.7.0
# via aiohttp
# via yarl
mypy==1.14.1
mypy-extensions==1.0.0
mypy==1.17.0
mypy-extensions==1.1.0
# via mypy
nodeenv==1.8.0
nodeenv==1.9.1
# via pyright
nox==2023.4.22
packaging==23.2
nox==2025.11.12
packaging==25.0
# via dependency-groups
# via nox
# via pytest
platformdirs==3.11.0
pathspec==0.12.1
# via mypy
platformdirs==4.4.0
# via virtualenv
pluggy==1.5.0
pluggy==1.6.0
# via pytest
propcache==0.3.1
propcache==0.4.1
# via aiohttp
# via yarl
pydantic==2.11.9
pydantic==2.12.5
# via isaacus
pydantic-core==2.33.2
pydantic-core==2.41.5
# via pydantic
pygments==2.18.0
pygments==2.19.2
# via pytest
# via rich
pyright==1.1.399
pytest==8.3.3
pytest==8.4.2
# via pytest-asyncio
# via pytest-xdist
pytest-asyncio==0.24.0
pytest-xdist==3.7.0
python-dateutil==2.8.2
pytest-asyncio==1.2.0
pytest-xdist==3.8.0
python-dateutil==2.9.0.post0
# via time-machine
pytz==2023.3.post1
# via dirty-equals
respx==0.22.0
rich==13.7.1
ruff==0.9.4
setuptools==68.2.2
# via nodeenv
six==1.16.0
rich==14.2.0
ruff==0.14.7
six==1.17.0
# via python-dateutil
sniffio==1.3.0
# via anyio
sniffio==1.3.1
# via isaacus
time-machine==2.9.0
tomli==2.0.2
time-machine==2.19.0
tomli==2.3.0
# via dependency-groups
# via mypy
# via nox
# via pytest
typing-extensions==4.12.2
typing-extensions==4.15.0
# via aiosignal
# via anyio
# via exceptiongroup
# via isaacus
# via multidict
# via mypy
# via pydantic
# via pydantic-core
# via pyright
# via pytest-asyncio
# via typing-inspection
typing-inspection==0.4.1
# via virtualenv
typing-inspection==0.4.2
# via pydantic
virtualenv==20.24.5
virtualenv==20.35.4
# via nox
yarl==1.20.0
yarl==1.22.0
# via aiohttp
zipp==3.17.0
zipp==3.23.0
# via importlib-metadata
Loading