Skip to content

Commit 3d8edf8

Browse files
committed
SDK regeneration
1 parent b07c278 commit 3d8edf8

14 files changed

Lines changed: 179 additions & 48 deletions

reference.md

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1462,7 +1462,9 @@ client.graph.add(
14621462
<dl>
14631463
<dd>
14641464

1465-
Add data to the graph in batch mode. Episodes are processed sequentially in the order provided.
1465+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*`) instead.
1466+
1467+
Adds data to the graph in batch mode, processing episodes concurrently.
14661468
</dd>
14671469
</dl>
14681470
</dd>
@@ -1681,7 +1683,13 @@ Nested objects and arrays are not allowed.
16811683
<dl>
16821684
<dd>
16831685

1684-
**source_node_labels:** `typing.Optional[typing.Sequence[str]]` — The labels for the source node
1686+
**source_node_labels:** `typing.Optional[typing.Sequence[str]]`
1687+
1688+
The labels for the source node. At most one entity-type label may be
1689+
provided so that manually-added triples remain consistent with automatic
1690+
episode extraction, which assigns one best-match entity type per node.
1691+
The base "Entity" label is added implicitly by the graph layer on save
1692+
and does not need to be supplied here.
16851693

16861694
</dd>
16871695
</dl>
@@ -1724,7 +1732,13 @@ Nested objects and arrays are not allowed.
17241732
<dl>
17251733
<dd>
17261734

1727-
**target_node_labels:** `typing.Optional[typing.Sequence[str]]` — The labels for the target node
1735+
**target_node_labels:** `typing.Optional[typing.Sequence[str]]`
1736+
1737+
The labels for the target node. At most one entity-type label may be
1738+
provided so that manually-added triples remain consistent with automatic
1739+
episode extraction, which assigns one best-match entity type per node.
1740+
The base "Entity" label is added implicitly by the graph layer on save
1741+
and does not need to be supplied here.
17281742

17291743
</dd>
17301744
</dl>
@@ -2314,7 +2328,7 @@ client.graph.search(
23142328
<dl>
23152329
<dd>
23162330

2317-
**limit:** `typing.Optional[int]` — The maximum number of facts to retrieve. Defaults to 10. Limited to 50.
2331+
**limit:** `typing.Optional[int]` — The maximum number of facts to retrieve for non-auto scopes. Defaults to 10. Limited to 50. Ignored when scope=auto.
23182332

23192333
</dd>
23202334
</dl>
@@ -2340,9 +2354,8 @@ client.graph.search(
23402354

23412355
**reranker:** `typing.Optional[Reranker]`
23422356

2343-
Defaults to RRF. When scope=auto, this only affects graph-service retrieval
2344-
shape for graph facts, observations, and thread summaries; source-episode
2345-
retrieval uses RRF, and auto search applies its own internal rerank after retrieval.
2357+
Defaults to RRF. Ignored when scope=auto except node_distance and episode_mentions are rejected;
2358+
auto search always uses RRF retrieval and applies its own internal rerank after retrieval.
23462359

23472360
</dd>
23482361
</dl>
@@ -3117,7 +3130,7 @@ client = Zep(
31173130
client.thread.get(
31183131
thread_id="threadId",
31193132
limit=1,
3120-
cursor=1,
3133+
cursor=1000000,
31213134
lastn=1,
31223135
)
31233136

@@ -3295,7 +3308,9 @@ that are added to a user's graph.
32953308
<dl>
32963309
<dd>
32973310

3298-
Add messages to a thread in batch mode. This will process messages concurrently, which is useful for data migrations.
3311+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*` with `type: "thread_message"`) instead.
3312+
3313+
Adds messages to a thread in batch mode, processing messages concurrently.
32993314
</dd>
33003315
</dl>
33013316
</dd>

src/zep_cloud/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
GraphListResponse,
4949
GraphNodesRequest,
5050
GraphObservationsRequest,
51+
GraphSearchResponseMetadata,
5152
GraphSearchResults,
5253
GraphSearchScope,
5354
GraphThreadSummariesRequest,
@@ -140,6 +141,7 @@
140141
"GraphListResponse",
141142
"GraphNodesRequest",
142143
"GraphObservationsRequest",
144+
"GraphSearchResponseMetadata",
143145
"GraphSearchResults",
144146
"GraphSearchScope",
145147
"GraphThreadSummariesRequest",

src/zep_cloud/core/client_wrapper.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ def __init__(
2222

2323
def get_headers(self) -> typing.Dict[str, str]:
2424
headers: typing.Dict[str, str] = {
25-
"User-Agent": "zep-cloud/3.22.0",
25+
"User-Agent": "zep-cloud/3.20.0",
2626
"X-Fern-Language": "Python",
2727
"X-Fern-SDK-Name": "zep-cloud",
28-
"X-Fern-SDK-Version": "3.22.0",
28+
"X-Fern-SDK-Version": "3.20.0",
2929
**(self.get_custom_headers() or {}),
3030
}
3131
headers["Authorization"] = f"Api-Key {self.api_key}"

src/zep_cloud/graph/client.py

Lines changed: 32 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,9 @@ def add_batch(
364364
request_options: typing.Optional[RequestOptions] = None,
365365
) -> typing.List[Episode]:
366366
"""
367-
Add data to the graph in batch mode. Episodes are processed sequentially in the order provided.
367+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*`) instead.
368+
369+
Adds data to the graph in batch mode, processing episodes concurrently.
368370
369371
Parameters
370372
----------
@@ -469,7 +471,11 @@ def add_fact_triple(
469471
Nested objects and arrays are not allowed.
470472
471473
source_node_labels : typing.Optional[typing.Sequence[str]]
472-
The labels for the source node
474+
The labels for the source node. At most one entity-type label may be
475+
provided so that manually-added triples remain consistent with automatic
476+
episode extraction, which assigns one best-match entity type per node.
477+
The base "Entity" label is added implicitly by the graph layer on save
478+
and does not need to be supplied here.
473479
474480
source_node_name : typing.Optional[str]
475481
The name of the source node to add
@@ -485,7 +491,11 @@ def add_fact_triple(
485491
Nested objects and arrays are not allowed.
486492
487493
target_node_labels : typing.Optional[typing.Sequence[str]]
488-
The labels for the target node
494+
The labels for the target node. At most one entity-type label may be
495+
provided so that manually-added triples remain consistent with automatic
496+
episode extraction, which assigns one best-match entity type per node.
497+
The base "Entity" label is added implicitly by the graph layer on save
498+
and does not need to be supplied here.
489499
490500
target_node_name : typing.Optional[str]
491501
The name of the target node to add
@@ -835,7 +845,7 @@ def search(
835845
The graph_id to search in. When searching user graph, please use user_id instead.
836846
837847
limit : typing.Optional[int]
838-
The maximum number of facts to retrieve. Defaults to 10. Limited to 50.
848+
The maximum number of facts to retrieve for non-auto scopes. Defaults to 10. Limited to 50. Ignored when scope=auto.
839849
840850
max_characters : typing.Optional[int]
841851
Maximum total characters across all selected results when scope=auto. Defaults to 2500. Limited to 50000.
@@ -844,9 +854,8 @@ def search(
844854
weighting for maximal marginal relevance
845855
846856
reranker : typing.Optional[Reranker]
847-
Defaults to RRF. When scope=auto, this only affects graph-service retrieval
848-
shape for graph facts, observations, and thread summaries; source-episode
849-
retrieval uses RRF, and auto search applies its own internal rerank after retrieval.
857+
Defaults to RRF. Ignored when scope=auto except node_distance and episode_mentions are rejected;
858+
auto search always uses RRF retrieval and applies its own internal rerank after retrieval.
850859
851860
return_raw_results : typing.Optional[bool]
852861
When scope=auto, include the selected raw graph results alongside the materialized context block.
@@ -1381,7 +1390,9 @@ async def add_batch(
13811390
request_options: typing.Optional[RequestOptions] = None,
13821391
) -> typing.List[Episode]:
13831392
"""
1384-
Add data to the graph in batch mode. Episodes are processed sequentially in the order provided.
1393+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*`) instead.
1394+
1395+
Adds data to the graph in batch mode, processing episodes concurrently.
13851396
13861397
Parameters
13871398
----------
@@ -1494,7 +1505,11 @@ async def add_fact_triple(
14941505
Nested objects and arrays are not allowed.
14951506
14961507
source_node_labels : typing.Optional[typing.Sequence[str]]
1497-
The labels for the source node
1508+
The labels for the source node. At most one entity-type label may be
1509+
provided so that manually-added triples remain consistent with automatic
1510+
episode extraction, which assigns one best-match entity type per node.
1511+
The base "Entity" label is added implicitly by the graph layer on save
1512+
and does not need to be supplied here.
14981513
14991514
source_node_name : typing.Optional[str]
15001515
The name of the source node to add
@@ -1510,7 +1525,11 @@ async def add_fact_triple(
15101525
Nested objects and arrays are not allowed.
15111526
15121527
target_node_labels : typing.Optional[typing.Sequence[str]]
1513-
The labels for the target node
1528+
The labels for the target node. At most one entity-type label may be
1529+
provided so that manually-added triples remain consistent with automatic
1530+
episode extraction, which assigns one best-match entity type per node.
1531+
The base "Entity" label is added implicitly by the graph layer on save
1532+
and does not need to be supplied here.
15141533
15151534
target_node_name : typing.Optional[str]
15161535
The name of the target node to add
@@ -1900,7 +1919,7 @@ async def search(
19001919
The graph_id to search in. When searching user graph, please use user_id instead.
19011920
19021921
limit : typing.Optional[int]
1903-
The maximum number of facts to retrieve. Defaults to 10. Limited to 50.
1922+
The maximum number of facts to retrieve for non-auto scopes. Defaults to 10. Limited to 50. Ignored when scope=auto.
19041923
19051924
max_characters : typing.Optional[int]
19061925
Maximum total characters across all selected results when scope=auto. Defaults to 2500. Limited to 50000.
@@ -1909,9 +1928,8 @@ async def search(
19091928
weighting for maximal marginal relevance
19101929
19111930
reranker : typing.Optional[Reranker]
1912-
Defaults to RRF. When scope=auto, this only affects graph-service retrieval
1913-
shape for graph facts, observations, and thread summaries; source-episode
1914-
retrieval uses RRF, and auto search applies its own internal rerank after retrieval.
1931+
Defaults to RRF. Ignored when scope=auto except node_distance and episode_mentions are rejected;
1932+
auto search always uses RRF retrieval and applies its own internal rerank after retrieval.
19151933
19161934
return_raw_results : typing.Optional[bool]
19171935
When scope=auto, include the selected raw graph results alongside the materialized context block.

src/zep_cloud/graph/raw_client.py

Lines changed: 32 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -624,7 +624,9 @@ def add_batch(
624624
request_options: typing.Optional[RequestOptions] = None,
625625
) -> HttpResponse[typing.List[Episode]]:
626626
"""
627-
Add data to the graph in batch mode. Episodes are processed sequentially in the order provided.
627+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*`) instead.
628+
629+
Adds data to the graph in batch mode, processing episodes concurrently.
628630
629631
Parameters
630632
----------
@@ -765,7 +767,11 @@ def add_fact_triple(
765767
Nested objects and arrays are not allowed.
766768
767769
source_node_labels : typing.Optional[typing.Sequence[str]]
768-
The labels for the source node
770+
The labels for the source node. At most one entity-type label may be
771+
provided so that manually-added triples remain consistent with automatic
772+
episode extraction, which assigns one best-match entity type per node.
773+
The base "Entity" label is added implicitly by the graph layer on save
774+
and does not need to be supplied here.
769775
770776
source_node_name : typing.Optional[str]
771777
The name of the source node to add
@@ -781,7 +787,11 @@ def add_fact_triple(
781787
Nested objects and arrays are not allowed.
782788
783789
target_node_labels : typing.Optional[typing.Sequence[str]]
784-
The labels for the target node
790+
The labels for the target node. At most one entity-type label may be
791+
provided so that manually-added triples remain consistent with automatic
792+
episode extraction, which assigns one best-match entity type per node.
793+
The base "Entity" label is added implicitly by the graph layer on save
794+
and does not need to be supplied here.
785795
786796
target_node_name : typing.Optional[str]
787797
The name of the target node to add
@@ -1337,7 +1347,7 @@ def search(
13371347
The graph_id to search in. When searching user graph, please use user_id instead.
13381348
13391349
limit : typing.Optional[int]
1340-
The maximum number of facts to retrieve. Defaults to 10. Limited to 50.
1350+
The maximum number of facts to retrieve for non-auto scopes. Defaults to 10. Limited to 50. Ignored when scope=auto.
13411351
13421352
max_characters : typing.Optional[int]
13431353
Maximum total characters across all selected results when scope=auto. Defaults to 2500. Limited to 50000.
@@ -1346,9 +1356,8 @@ def search(
13461356
weighting for maximal marginal relevance
13471357
13481358
reranker : typing.Optional[Reranker]
1349-
Defaults to RRF. When scope=auto, this only affects graph-service retrieval
1350-
shape for graph facts, observations, and thread summaries; source-episode
1351-
retrieval uses RRF, and auto search applies its own internal rerank after retrieval.
1359+
Defaults to RRF. Ignored when scope=auto except node_distance and episode_mentions are rejected;
1360+
auto search always uses RRF retrieval and applies its own internal rerank after retrieval.
13521361
13531362
return_raw_results : typing.Optional[bool]
13541363
When scope=auto, include the selected raw graph results alongside the materialized context block.
@@ -2254,7 +2263,9 @@ async def add_batch(
22542263
request_options: typing.Optional[RequestOptions] = None,
22552264
) -> AsyncHttpResponse[typing.List[Episode]]:
22562265
"""
2257-
Add data to the graph in batch mode. Episodes are processed sequentially in the order provided.
2266+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*`) instead.
2267+
2268+
Adds data to the graph in batch mode, processing episodes concurrently.
22582269
22592270
Parameters
22602271
----------
@@ -2395,7 +2406,11 @@ async def add_fact_triple(
23952406
Nested objects and arrays are not allowed.
23962407
23972408
source_node_labels : typing.Optional[typing.Sequence[str]]
2398-
The labels for the source node
2409+
The labels for the source node. At most one entity-type label may be
2410+
provided so that manually-added triples remain consistent with automatic
2411+
episode extraction, which assigns one best-match entity type per node.
2412+
The base "Entity" label is added implicitly by the graph layer on save
2413+
and does not need to be supplied here.
23992414
24002415
source_node_name : typing.Optional[str]
24012416
The name of the source node to add
@@ -2411,7 +2426,11 @@ async def add_fact_triple(
24112426
Nested objects and arrays are not allowed.
24122427
24132428
target_node_labels : typing.Optional[typing.Sequence[str]]
2414-
The labels for the target node
2429+
The labels for the target node. At most one entity-type label may be
2430+
provided so that manually-added triples remain consistent with automatic
2431+
episode extraction, which assigns one best-match entity type per node.
2432+
The base "Entity" label is added implicitly by the graph layer on save
2433+
and does not need to be supplied here.
24152434
24162435
target_node_name : typing.Optional[str]
24172436
The name of the target node to add
@@ -2967,7 +2986,7 @@ async def search(
29672986
The graph_id to search in. When searching user graph, please use user_id instead.
29682987
29692988
limit : typing.Optional[int]
2970-
The maximum number of facts to retrieve. Defaults to 10. Limited to 50.
2989+
The maximum number of facts to retrieve for non-auto scopes. Defaults to 10. Limited to 50. Ignored when scope=auto.
29712990
29722991
max_characters : typing.Optional[int]
29732992
Maximum total characters across all selected results when scope=auto. Defaults to 2500. Limited to 50000.
@@ -2976,9 +2995,8 @@ async def search(
29762995
weighting for maximal marginal relevance
29772996
29782997
reranker : typing.Optional[Reranker]
2979-
Defaults to RRF. When scope=auto, this only affects graph-service retrieval
2980-
shape for graph facts, observations, and thread summaries; source-episode
2981-
retrieval uses RRF, and auto search applies its own internal rerank after retrieval.
2998+
Defaults to RRF. Ignored when scope=auto except node_distance and episode_mentions are rejected;
2999+
auto search always uses RRF retrieval and applies its own internal rerank after retrieval.
29823000
29833001
return_raw_results : typing.Optional[bool]
29843002
When scope=auto, include the selected raw graph results alongside the materialized context block.

src/zep_cloud/thread/client.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ def get(
244244
client.thread.get(
245245
thread_id="threadId",
246246
limit=1,
247-
cursor=1,
247+
cursor=1000000,
248248
lastn=1,
249249
)
250250
"""
@@ -325,7 +325,9 @@ def add_messages_batch(
325325
request_options: typing.Optional[RequestOptions] = None,
326326
) -> AddThreadMessagesResponse:
327327
"""
328-
Add messages to a thread in batch mode. This will process messages concurrently, which is useful for data migrations.
328+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*` with `type: "thread_message"`) instead.
329+
330+
Adds messages to a thread in batch mode, processing messages concurrently.
329331
330332
Parameters
331333
----------
@@ -672,7 +674,7 @@ async def main() -> None:
672674
await client.thread.get(
673675
thread_id="threadId",
674676
limit=1,
675-
cursor=1,
677+
cursor=1000000,
676678
lastn=1,
677679
)
678680
@@ -764,7 +766,9 @@ async def add_messages_batch(
764766
request_options: typing.Optional[RequestOptions] = None,
765767
) -> AddThreadMessagesResponse:
766768
"""
767-
Add messages to a thread in batch mode. This will process messages concurrently, which is useful for data migrations.
769+
Deprecated. Use the [Batch API](/adding-batch-data) (`client.batch.*` with `type: "thread_message"`) instead.
770+
771+
Adds messages to a thread in batch mode, processing messages concurrently.
768772
769773
Parameters
770774
----------

0 commit comments

Comments
 (0)