Skip to content

Commit af5259d

Browse files
authored
Merge pull request #57 from zeroentropy-ai/release-please--branches--main--changes--next
release: 0.1.0-alpha.11
2 parents c52dcd7 + f61183d commit af5259d

9 files changed

Lines changed: 67 additions & 47 deletions

File tree

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.1.0-alpha.10"
2+
".": "0.1.0-alpha.11"
33
}

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 15
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/zeroentropy%2Fzeroentropy-9cd927800fd253f2116ab12aa496b086605bd31d295cb600b65d793203e1e9e7.yml
3-
openapi_spec_hash: cd7f6d9db9ae338091bc6da83e27f4a6
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/zeroentropy%2Fzeroentropy-5ff1b24060b908d169910a7366213eeb423b52d14b03cc16902923eb0ffac71a.yml
3+
openapi_spec_hash: fc50a1765bfbfe9a3da7ea9001e479d4
44
config_hash: e56152e1ee1a9273241d925702077e49

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Changelog
22

3+
## 0.1.0-alpha.11 (2026-03-03)
4+
5+
Full Changelog: [v0.1.0-alpha.10...v0.1.0-alpha.11](https://github.com/zeroentropy-ai/zeroentropy-python/compare/v0.1.0-alpha.10...v0.1.0-alpha.11)
6+
7+
### Features
8+
9+
* **api:** manual updates ([6654f01](https://github.com/zeroentropy-ai/zeroentropy-python/commit/6654f01491feb8233c146e2bc6bd678d42f7f810))
10+
311
## 0.1.0-alpha.10 (2026-03-03)
412

513
Full Changelog: [v0.1.0-alpha.9...v0.1.0-alpha.10](https://github.com/zeroentropy-ai/zeroentropy-python/compare/v0.1.0-alpha.9...v0.1.0-alpha.10)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "zeroentropy"
3-
version = "0.1.0-alpha.10"
3+
version = "0.1.0-alpha.11"
44
description = "The official Python library for the ZeroEntropy API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"

src/zeroentropy/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "zeroentropy"
4-
__version__ = "0.1.0-alpha.10" # x-release-please-version
4+
__version__ = "0.1.0-alpha.11" # x-release-please-version

src/zeroentropy/resources/models.py

Lines changed: 28 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ def embed(
5151
input: Union[str, SequenceNotStr[str]],
5252
input_type: Literal["query", "document"],
5353
model: str,
54+
dimensions: Optional[int] | Omit = omit,
55+
encoding_format: Literal["float", "base64"] | Omit = omit,
5456
latency: Optional[Literal["fast", "slow"]] | Omit = omit,
55-
output_dimensions: Optional[int] | Omit = omit,
56-
output_format: Literal["float", "base64"] | Omit = omit,
5757
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5858
# The extra values given here take precedence over values defined on the client or passed to this method.
5959
extra_headers: Headers | None = None,
@@ -78,24 +78,27 @@ def embed(
7878
[Slack](https://go.zeroentropy.dev/slack)!
7979
8080
Args:
81-
input: The string, or list of strings, to embed
81+
input: The string, or list of strings, to embed.
8282
8383
input_type: The input type. For retrieval tasks, either `query` or `document`.
8484
8585
model: The model ID to use for embedding. Options are: ["zembed-1"]
8686
87+
dimensions: The output dimensionality of the embedding model. For `zembed-1`, the available
88+
options are: [2560, 1280, 640, 320, 160, 80, 40].
89+
90+
encoding_format: The output format of the embedding. If `float`, an array of floats will be
91+
returned for each embeddings. If `base64`, a f32 little endian byte array will
92+
be returned, encoded as a base64 string. `base64` is significantly more
93+
efficient than `float`. The default is `float`.
94+
8795
latency: Whether the call will be inferenced "fast" or "slow". RateLimits for slow API
88-
calls are orders of magnitude higher, but you can expect >10 second latency.
96+
calls are orders of magnitude higher, but you can expect 2-20 second latency.
8997
Fast inferences are guaranteed subsecond, but rate limits are lower. If not
9098
specified, first a "fast" call will be attempted, but if you have exceeded your
9199
fast rate limit, then a slow call will be executed. If explicitly set to "fast",
92100
then 429 will be returned if it cannot be executed fast.
93101
94-
output_dimensions: The output dimensionality of the embedding model.
95-
96-
output_format: The output format of the embedding. `base64` is significantly more efficient
97-
than `float`. The default is `float`.
98-
99102
extra_headers: Send extra headers
100103
101104
extra_query: Add additional query parameters to the request
@@ -111,9 +114,9 @@ def embed(
111114
"input": input,
112115
"input_type": input_type,
113116
"model": model,
117+
"dimensions": dimensions,
118+
"encoding_format": encoding_format,
114119
"latency": latency,
115-
"output_dimensions": output_dimensions,
116-
"output_format": output_format,
117120
},
118121
model_embed_params.ModelEmbedParams,
119122
),
@@ -227,9 +230,9 @@ async def embed(
227230
input: Union[str, SequenceNotStr[str]],
228231
input_type: Literal["query", "document"],
229232
model: str,
233+
dimensions: Optional[int] | Omit = omit,
234+
encoding_format: Literal["float", "base64"] | Omit = omit,
230235
latency: Optional[Literal["fast", "slow"]] | Omit = omit,
231-
output_dimensions: Optional[int] | Omit = omit,
232-
output_format: Literal["float", "base64"] | Omit = omit,
233236
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
234237
# The extra values given here take precedence over values defined on the client or passed to this method.
235238
extra_headers: Headers | None = None,
@@ -254,24 +257,27 @@ async def embed(
254257
[Slack](https://go.zeroentropy.dev/slack)!
255258
256259
Args:
257-
input: The string, or list of strings, to embed
260+
input: The string, or list of strings, to embed.
258261
259262
input_type: The input type. For retrieval tasks, either `query` or `document`.
260263
261264
model: The model ID to use for embedding. Options are: ["zembed-1"]
262265
266+
dimensions: The output dimensionality of the embedding model. For `zembed-1`, the available
267+
options are: [2560, 1280, 640, 320, 160, 80, 40].
268+
269+
encoding_format: The output format of the embedding. If `float`, an array of floats will be
270+
returned for each embeddings. If `base64`, a f32 little endian byte array will
271+
be returned, encoded as a base64 string. `base64` is significantly more
272+
efficient than `float`. The default is `float`.
273+
263274
latency: Whether the call will be inferenced "fast" or "slow". RateLimits for slow API
264-
calls are orders of magnitude higher, but you can expect >10 second latency.
275+
calls are orders of magnitude higher, but you can expect 2-20 second latency.
265276
Fast inferences are guaranteed subsecond, but rate limits are lower. If not
266277
specified, first a "fast" call will be attempted, but if you have exceeded your
267278
fast rate limit, then a slow call will be executed. If explicitly set to "fast",
268279
then 429 will be returned if it cannot be executed fast.
269280
270-
output_dimensions: The output dimensionality of the embedding model.
271-
272-
output_format: The output format of the embedding. `base64` is significantly more efficient
273-
than `float`. The default is `float`.
274-
275281
extra_headers: Send extra headers
276282
277283
extra_query: Add additional query parameters to the request
@@ -287,9 +293,9 @@ async def embed(
287293
"input": input,
288294
"input_type": input_type,
289295
"model": model,
296+
"dimensions": dimensions,
297+
"encoding_format": encoding_format,
290298
"latency": latency,
291-
"output_dimensions": output_dimensions,
292-
"output_format": output_format,
293299
},
294300
model_embed_params.ModelEmbedParams,
295301
),

src/zeroentropy/types/model_embed_params.py

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,30 +12,36 @@
1212

1313
class ModelEmbedParams(TypedDict, total=False):
1414
input: Required[Union[str, SequenceNotStr[str]]]
15-
"""The string, or list of strings, to embed"""
15+
"""The string, or list of strings, to embed."""
1616

1717
input_type: Required[Literal["query", "document"]]
1818
"""The input type. For retrieval tasks, either `query` or `document`."""
1919

2020
model: Required[str]
2121
"""The model ID to use for embedding. Options are: ["zembed-1"]"""
2222

23-
latency: Optional[Literal["fast", "slow"]]
24-
"""Whether the call will be inferenced "fast" or "slow".
23+
dimensions: Optional[int]
24+
"""The output dimensionality of the embedding model.
2525
26-
RateLimits for slow API calls are orders of magnitude higher, but you can
27-
expect >10 second latency. Fast inferences are guaranteed subsecond, but rate
28-
limits are lower. If not specified, first a "fast" call will be attempted, but
29-
if you have exceeded your fast rate limit, then a slow call will be executed. If
30-
explicitly set to "fast", then 429 will be returned if it cannot be executed
31-
fast.
26+
For `zembed-1`, the available options are: [2560, 1280, 640, 320, 160, 80, 40].
3227
"""
3328

34-
output_dimensions: Optional[int]
35-
"""The output dimensionality of the embedding model."""
36-
37-
output_format: Literal["float", "base64"]
29+
encoding_format: Literal["float", "base64"]
3830
"""The output format of the embedding.
3931
40-
`base64` is significantly more efficient than `float`. The default is `float`.
32+
If `float`, an array of floats will be returned for each embeddings. If
33+
`base64`, a f32 little endian byte array will be returned, encoded as a base64
34+
string. `base64` is significantly more efficient than `float`. The default is
35+
`float`.
36+
"""
37+
38+
latency: Optional[Literal["fast", "slow"]]
39+
"""Whether the call will be inferenced "fast" or "slow".
40+
41+
RateLimits for slow API calls are orders of magnitude higher, but you can expect
42+
2-20 second latency. Fast inferences are guaranteed subsecond, but rate limits
43+
are lower. If not specified, first a "fast" call will be attempted, but if you
44+
have exceeded your fast rate limit, then a slow call will be executed. If
45+
explicitly set to "fast", then 429 will be returned if it cannot be executed
46+
fast.
4147
"""

src/zeroentropy/types/model_embed_response.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@
99

1010
class Result(BaseModel):
1111
embedding: Union[List[float], str]
12-
"""The embedding of the input text.
12+
"""The embedding of the input text, as an array of floats.
1313
1414
If `base64` format is requested, the response will be an fp32 little endian byte
15-
array, encoded as base64.
15+
array, encoded as a base64 string.
1616
"""
1717

1818

tests/api_resources/test_models.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ def test_method_embed_with_all_params(self, client: ZeroEntropy) -> None:
3232
input="string",
3333
input_type="query",
3434
model="model",
35+
dimensions=0,
36+
encoding_format="float",
3537
latency="fast",
36-
output_dimensions=0,
37-
output_format="float",
3838
)
3939
assert_matches_type(ModelEmbedResponse, model, path=["response"])
4040

@@ -135,9 +135,9 @@ async def test_method_embed_with_all_params(self, async_client: AsyncZeroEntropy
135135
input="string",
136136
input_type="query",
137137
model="model",
138+
dimensions=0,
139+
encoding_format="float",
138140
latency="fast",
139-
output_dimensions=0,
140-
output_format="float",
141141
)
142142
assert_matches_type(ModelEmbedResponse, model, path=["response"])
143143

0 commit comments

Comments
 (0)