From d7c7b7ce306442d088605229fc585b3919d72d6a Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Wed, 14 Oct 2026 01:00:43 +0000 Subject: [PATCH 1/3] [fern-generated] Update SDK Generated by Fern CLI Version: unknown Generators: - fernapi/fern-python-sdk: 5.39.2 --- .fern/metadata.json | 6 +- README.md | 60 ++++++++++++++++ pyproject.toml | 3 +- reference.md | 61 +++++++++++++--- src/zep_cloud/__init__.py | 12 ++++ src/zep_cloud/core/client_wrapper.py | 4 +- src/zep_cloud/graph/client.py | 47 ++++++++----- .../graph/document_summary/client.py | 6 +- .../graph/document_summary/raw_client.py | 6 +- src/zep_cloud/graph/observation/client.py | 6 +- src/zep_cloud/graph/observation/raw_client.py | 6 +- src/zep_cloud/graph/raw_client.py | 63 ++++++++++------- src/zep_cloud/graph/thread_summary/client.py | 6 +- .../graph/thread_summary/raw_client.py | 6 +- src/zep_cloud/types/__init__.py | 12 ++++ src/zep_cloud/types/batch_items_response.py | 6 ++ .../types/document_summary_list_filters.py | 58 +-------------- src/zep_cloud/types/edge_search_filters.py | 5 -- src/zep_cloud/types/episode_search_filters.py | 34 +++++++++ src/zep_cloud/types/node_search_filters.py | 11 --- .../types/observation_list_filters.py | 70 +------------------ .../types/observation_search_filters.py | 5 ++ src/zep_cloud/types/rejected_batch_item.py | 27 +++++++ .../types/thread_summary_list_filters.py | 58 +-------------- .../types/thread_summary_search_filters.py | 29 ++++++++ 25 files changed, 342 insertions(+), 265 deletions(-) create mode 100644 src/zep_cloud/types/episode_search_filters.py create mode 100644 src/zep_cloud/types/observation_search_filters.py create mode 100644 src/zep_cloud/types/rejected_batch_item.py create mode 100644 src/zep_cloud/types/thread_summary_search_filters.py diff --git a/.fern/metadata.json b/.fern/metadata.json index 58ef1f0b..9f92fc3a 100644 --- a/.fern/metadata.json +++ b/.fern/metadata.json @@ -12,10 +12,10 @@ }, "pyproject_python_version": "^3.10" }, - "originGitCommit": "9ad0803521b69af693f92404ec41770231c3cb8e", + "originGitCommit": "3bad6dc94b415e5291ffa6b5e67e06422c97660b", "originGitCommitIsDirty": true, "invokedBy": "ci", - "requestedVersion": "4.0.0rc2", + "requestedVersion": "4.0.0", "ciProvider": "github", - "sdkVersion": "4.0.0rc2" + "sdkVersion": "4.0.0" } \ No newline at end of file diff --git a/README.md b/README.md index c861b306..c775b5f8 100644 --- a/README.md +++ b/README.md @@ -33,18 +33,78 @@ pip install zep-cloud > [!NOTE] > Zep Cloud [overview](https://help.getzep.com/concepts) and [cloud sdk guide](https://help.getzep.com/sdks). +### Community Installation +```bash +pip install zep-python +``` +> [!NOTE] +> Zep Community Edition [quick start](https://help.getzep.com/ce/quickstart) and [sdk guide](https://help.getzep.com/ce/sdks). + +### Zep v0.x Compatible SDK +You can install Zep v0.x compatible sdk by running: +```bash +pip install "zep-python>=1.5.0,<2.0.0" +``` +> [!NOTE] +> Zep v0.x [quick start](https://help.getzep.com/ce/legacy/deployment/quickstart) and [sdk guide](https://help.getzep.com/ce/legacy/sdk). + ### How Zep works Zep persists and recalls chat histories, and automatically generates summaries and other artifacts from these chat histories. It also embeds messages and summaries, enabling you to search Zep for relevant context from past conversations. Zep does all of this asynchronously, ensuring these operations don't impact your user's chat experience. Data is persisted to database, allowing you to scale out when growth demands. +Zep also provides a simple, easy to use abstraction for document vector search called Document Collections. This is designed to complement Zep's core context features, but is not designed to be a general purpose vector database. + Zep allows you to be more intentional about constructing your prompt: 1. automatically adding a few recent messages, with the number customized for your app; 2. a summary of recent conversations prior to the messages above; 3. and/or contextually relevant summaries or messages surfaced from the entire chat session. +4. and/or relevant Business data from Zep Document Collections. + +Zep Cloud offers: +- **Fact Extraction:** Automatically build fact tables from conversations, without having to define a data schema upfront. +- **Dialog Classification:** Instantly and accurately classify chat dialog. Understand user intent and emotion, segment users, and more. Route chains based on semantic context, and trigger events. +- **Structured Data Extraction:** Quickly extract business data from chat conversations using a schema you define. Understand what your Assistant should ask for next in order to complete its task. You will also need to provide a Zep Project API key to your zep client. You can find out about zep projects in our [cloud docs](https://help.getzep.com/projects.html) +### Using LangChain Zep Classes with `zep-python` + +(Currently only available on release candidate versions) + +In the pre-release version `zep-python` sdk comes with `ZepChatMessageHistory` and `ZepVectorStore` +classes that are compatible with [LangChain's Python expression language](https://python.langchain.com/docs/expression_language/) + +In order to use these classes in your application, you need to make sure that you have +`langchain_core` package installed, please refer to [Langchain's docs installation section](https://python.langchain.com/docs/get_started/installation#langchain-core). + +We support `langchain_core@>=0.1.3<0.2.0` + +You can import these classes in the following way: + +```python +from zep_cloud.langchain import ZepChatMessageHistory, ZepVectorStore +``` + +### Running Examples +You will need to set the following environment variables to run examples in the `examples` directory: + +```dotenv +# Please use examples/.env.example as a template for .env file + +# Required +ZEP_API_KEY=# Your Zep Project API Key +ZEP_COLLECTION=# used in ingestion script and in vector store examples +OPENAI_API_KEY=# Your OpenAI API Key + +# Optional (If you want to use langsmith with LangServe Sample App) +LANGCHAIN_TRACING_V2=true +LANGCHAIN_API_KEY= +LANGCHAIN_PROJECT=# If not specified, defaults to "default" +``` + + + ## Installation ```sh diff --git a/pyproject.toml b/pyproject.toml index aeec4dab..e4121b92 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,11 +1,10 @@ [project] name = "zep-cloud" dynamic = ["version"] -version = "4.0.0rc2" [tool.poetry] name = "zep-cloud" -version = "4.0.0rc2" +version = "4.0.0" description = "" readme = "README.md" authors = [] diff --git a/reference.md b/reference.md index 977e5a93..f554c037 100644 --- a/reference.md +++ b/reference.md @@ -2670,7 +2670,7 @@ client.graph.set_ontology(
-Edge search does not support node_labels or exclude_node_labels. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. +Edge search does not support node_labels, exclude_node_labels, or content_policy_violated. content_policy_violated is supported on episode search only. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes.
@@ -2824,6 +2824,20 @@ Required when reranker is mmr.
+#### 📝 Description + +
+
+ +
+
+ +Episode search supports only the metadata_filters and content_policy_violated filters. Every other filter returns unsupported_filter. +
+
+
+
+ #### 🔌 Usage
@@ -2929,7 +2943,7 @@ timeout, Zep returns the results without the filter.
-**filters:** `typing.Optional[SearchFilters]` — Filters constraining which items are returned. +**filters:** `typing.Optional[EpisodeSearchFilters]` — Filters constraining which items are returned.
@@ -2980,7 +2994,7 @@ Required when reranker is mmr.
-Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, or target_node_uuids. These filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. +Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, target_node_uuids, date_filters, or content_policy_violated. content_policy_violated is supported on episode search only. The edge filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. To filter nodes by created_at, use graph.node.list.
@@ -3134,6 +3148,20 @@ Required when reranker is mmr.
+#### 📝 Description + +
+
+ +
+
+ +Observation search supports no filters. Every filter returns unsupported_filter. +
+
+
+
+ #### 🔌 Usage
@@ -3239,7 +3267,7 @@ timeout, Zep returns the results without the filter.
-**filters:** `typing.Optional[SearchFilters]` — Filters constraining which items are returned. +**filters:** `typing.Optional[ObservationSearchFilters]` — Filters constraining which items are returned.
@@ -3282,6 +3310,20 @@ Required when reranker is mmr.
+#### 📝 Description + +
+
+ +
+
+ +Thread-summary search supports only the metadata_filters filter, which matches the metadata of the thread episodes. Every other filter returns unsupported_filter. +
+
+
+
+ #### 🔌 Usage
@@ -3387,7 +3429,7 @@ timeout, Zep returns the results without the filter.
-**filters:** `typing.Optional[SearchFilters]` — Filters constraining which items are returned. +**filters:** `typing.Optional[ThreadSummarySearchFilters]` — Filters constraining which items are returned.
@@ -13263,7 +13305,8 @@ client.agent.trace_import.run.item.list( Lists the document summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. -You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. +You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. +`date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error.
@@ -15831,7 +15874,8 @@ client.graph.node.list_neighbors( Lists the observations of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. -You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. +You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, `metadata_filters`, and `content_policy_violated`. +`date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error.
@@ -16019,7 +16063,8 @@ client.graph.observation.get( Lists the thread summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. -You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. +You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. +`date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error.
diff --git a/src/zep_cloud/__init__.py b/src/zep_cloud/__init__.py index 3cbb5e14..cee48966 100644 --- a/src/zep_cloud/__init__.py +++ b/src/zep_cloud/__init__.py @@ -200,6 +200,7 @@ EpisodeDebugLog, EpisodeListFilters, EpisodePage, + EpisodeSearchFilters, ErrorBody, Graph, GraphContentPolicy, @@ -256,6 +257,7 @@ Observation, ObservationListFilters, ObservationPage, + ObservationSearchFilters, ObservationSteering, ObservationType, Ontology, @@ -274,6 +276,7 @@ PropertyFilterOperator, PropertyFilterValue, PropertyFilterValueThreeItem, + RejectedBatchItem, RenameAgentTaskFamilyResponse, RoleType, SearchFilters, @@ -309,6 +312,7 @@ ThreadSummary, ThreadSummaryListFilters, ThreadSummaryPage, + ThreadSummarySearchFilters, TraceConnection, TraceConnectionPage, TraceConnectionProvider, @@ -597,6 +601,7 @@ "EpisodeDebugLog": ".types", "EpisodeListFilters": ".types", "EpisodePage": ".types", + "EpisodeSearchFilters": ".types", "ErrorBody": ".types", "ForbiddenError": ".errors", "Graph": ".types", @@ -658,6 +663,7 @@ "Observation": ".types", "ObservationListFilters": ".types", "ObservationPage": ".types", + "ObservationSearchFilters": ".types", "ObservationSteering": ".types", "ObservationType": ".types", "Ontology": ".types", @@ -676,6 +682,7 @@ "PropertyFilterOperator": ".types", "PropertyFilterValue": ".types", "PropertyFilterValueThreeItem": ".types", + "RejectedBatchItem": ".types", "RenameAgentTaskFamilyResponse": ".types", "RoleType": ".types", "SearchEdgesRequestReranker": ".graph", @@ -721,6 +728,7 @@ "ThreadSummary": ".types", "ThreadSummaryListFilters": ".types", "ThreadSummaryPage": ".types", + "ThreadSummarySearchFilters": ".types", "TraceConnection": ".types", "TraceConnectionPage": ".types", "TraceConnectionProvider": ".types", @@ -1006,6 +1014,7 @@ def __dir__(): "EpisodeDebugLog", "EpisodeListFilters", "EpisodePage", + "EpisodeSearchFilters", "ErrorBody", "ForbiddenError", "Graph", @@ -1067,6 +1076,7 @@ def __dir__(): "Observation", "ObservationListFilters", "ObservationPage", + "ObservationSearchFilters", "ObservationSteering", "ObservationType", "Ontology", @@ -1085,6 +1095,7 @@ def __dir__(): "PropertyFilterOperator", "PropertyFilterValue", "PropertyFilterValueThreeItem", + "RejectedBatchItem", "RenameAgentTaskFamilyResponse", "RoleType", "SearchEdgesRequestReranker", @@ -1130,6 +1141,7 @@ def __dir__(): "ThreadSummary", "ThreadSummaryListFilters", "ThreadSummaryPage", + "ThreadSummarySearchFilters", "TraceConnection", "TraceConnectionPage", "TraceConnectionProvider", diff --git a/src/zep_cloud/core/client_wrapper.py b/src/zep_cloud/core/client_wrapper.py index 842f8ca9..d3deb3c2 100644 --- a/src/zep_cloud/core/client_wrapper.py +++ b/src/zep_cloud/core/client_wrapper.py @@ -33,12 +33,12 @@ def get_headers(self) -> typing.Dict[str, str]: import platform headers: typing.Dict[str, str] = { - "User-Agent": "zep-cloud/4.0.0rc2", + "User-Agent": "zep-cloud/4.0.0", "X-Fern-Language": "Python", "X-Fern-Runtime": f"python/{platform.python_version()}", "X-Fern-Platform": f"{platform.system().lower()}/{platform.release()}", "X-Fern-SDK-Name": "zep-cloud", - "X-Fern-SDK-Version": "4.0.0rc2", + "X-Fern-SDK-Version": "4.0.0", **(self.get_custom_headers() or {}), } headers["Authorization"] = f"Api-Key {self.api_key}" diff --git a/src/zep_cloud/graph/client.py b/src/zep_cloud/graph/client.py index a7ebcb53..1bd20aa4 100644 --- a/src/zep_cloud/graph/client.py +++ b/src/zep_cloud/graph/client.py @@ -21,6 +21,7 @@ from ..types.entity_type import EntityType from ..types.episode import Episode from ..types.episode_page import EpisodePage +from ..types.episode_search_filters import EpisodeSearchFilters from ..types.graph import Graph from ..types.graph_content_policy import GraphContentPolicy from ..types.graph_content_policy_request import GraphContentPolicyRequest @@ -33,6 +34,7 @@ from ..types.node_search_filters import NodeSearchFilters from ..types.observation import Observation from ..types.observation_page import ObservationPage +from ..types.observation_search_filters import ObservationSearchFilters from ..types.observation_steering import ObservationSteering from ..types.observation_type import ObservationType from ..types.ontology import Ontology @@ -40,6 +42,7 @@ from ..types.subgraph_response import SubgraphResponse from ..types.thread_summary import ThreadSummary from ..types.thread_summary_page import ThreadSummaryPage +from ..types.thread_summary_search_filters import ThreadSummarySearchFilters from .raw_client import AsyncRawGraphClient, RawGraphClient from .types.graph_context_request_recency_bias import GraphContextRequestRecencyBias from .types.graph_list_request_order import GraphListRequestOrder @@ -851,7 +854,7 @@ def search_edges( request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Edge, EdgePage]: """ - Edge search does not support node_labels or exclude_node_labels. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. + Edge search does not support node_labels, exclude_node_labels, or content_policy_violated. content_policy_violated is supported on episode search only. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. Parameters ---------- @@ -944,12 +947,14 @@ def search_episodes( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[EpisodeSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchEpisodesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Episode, EpisodePage]: """ + Episode search supports only the metadata_filters and content_policy_violated filters. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -982,7 +987,7 @@ def search_episodes( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[EpisodeSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -1047,7 +1052,7 @@ def search_nodes( request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Node, NodePage]: """ - Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, or target_node_uuids. These filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. + Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, target_node_uuids, date_filters, or content_policy_violated. content_policy_violated is supported on episode search only. The edge filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. To filter nodes by created_at, use graph.node.list. Parameters ---------- @@ -1140,12 +1145,14 @@ def search_observations( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ObservationSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchObservationsRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Observation, ObservationPage]: """ + Observation search supports no filters. Every filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -1178,7 +1185,7 @@ def search_observations( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ObservationSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -1237,12 +1244,14 @@ def search_thread_summaries( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ThreadSummarySearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchThreadSummariesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[ThreadSummary, ThreadSummaryPage]: """ + Thread-summary search supports only the metadata_filters filter, which matches the metadata of the thread episodes. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -1275,7 +1284,7 @@ def search_thread_summaries( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ThreadSummarySearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -2407,7 +2416,7 @@ async def search_edges( request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Edge, EdgePage]: """ - Edge search does not support node_labels or exclude_node_labels. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. + Edge search does not support node_labels, exclude_node_labels, or content_policy_violated. content_policy_violated is supported on episode search only. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. Parameters ---------- @@ -2509,12 +2518,14 @@ async def search_episodes( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[EpisodeSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchEpisodesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Episode, EpisodePage]: """ + Episode search supports only the metadata_filters and content_policy_violated filters. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -2547,7 +2558,7 @@ async def search_episodes( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[EpisodeSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -2621,7 +2632,7 @@ async def search_nodes( request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Node, NodePage]: """ - Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, or target_node_uuids. These filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. + Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, target_node_uuids, date_filters, or content_policy_violated. content_policy_violated is supported on episode search only. The edge filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. To filter nodes by created_at, use graph.node.list. Parameters ---------- @@ -2723,12 +2734,14 @@ async def search_observations( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ObservationSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchObservationsRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Observation, ObservationPage]: """ + Observation search supports no filters. Every filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -2761,7 +2774,7 @@ async def search_observations( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ObservationSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -2829,12 +2842,14 @@ async def search_thread_summaries( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ThreadSummarySearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchThreadSummariesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[ThreadSummary, ThreadSummaryPage]: """ + Thread-summary search supports only the metadata_filters filter, which matches the metadata of the thread episodes. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -2867,7 +2882,7 @@ async def search_thread_summaries( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ThreadSummarySearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] diff --git a/src/zep_cloud/graph/document_summary/client.py b/src/zep_cloud/graph/document_summary/client.py index c7ab7a1d..2a1a403b 100644 --- a/src/zep_cloud/graph/document_summary/client.py +++ b/src/zep_cloud/graph/document_summary/client.py @@ -45,7 +45,8 @@ def list( """ Lists the document summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters @@ -133,7 +134,8 @@ async def list( """ Lists the document summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters diff --git a/src/zep_cloud/graph/document_summary/raw_client.py b/src/zep_cloud/graph/document_summary/raw_client.py index 26566132..e90e7896 100644 --- a/src/zep_cloud/graph/document_summary/raw_client.py +++ b/src/zep_cloud/graph/document_summary/raw_client.py @@ -47,7 +47,8 @@ def list( """ Lists the document summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters @@ -209,7 +210,8 @@ async def list( """ Lists the document summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters diff --git a/src/zep_cloud/graph/observation/client.py b/src/zep_cloud/graph/observation/client.py index d34a09d9..137f7afe 100644 --- a/src/zep_cloud/graph/observation/client.py +++ b/src/zep_cloud/graph/observation/client.py @@ -45,7 +45,8 @@ def list( """ Lists the observations of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, `metadata_filters`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters @@ -168,7 +169,8 @@ async def list( """ Lists the observations of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, `metadata_filters`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters diff --git a/src/zep_cloud/graph/observation/raw_client.py b/src/zep_cloud/graph/observation/raw_client.py index a9eb75ef..5bb42e74 100644 --- a/src/zep_cloud/graph/observation/raw_client.py +++ b/src/zep_cloud/graph/observation/raw_client.py @@ -48,7 +48,8 @@ def list( """ Lists the observations of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, `metadata_filters`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters @@ -313,7 +314,8 @@ async def list( """ Lists the observations of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, `metadata_filters`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters diff --git a/src/zep_cloud/graph/raw_client.py b/src/zep_cloud/graph/raw_client.py index d7ac23ea..5c831c94 100644 --- a/src/zep_cloud/graph/raw_client.py +++ b/src/zep_cloud/graph/raw_client.py @@ -33,6 +33,7 @@ from ..types.entity_type import EntityType from ..types.episode import Episode from ..types.episode_page import EpisodePage +from ..types.episode_search_filters import EpisodeSearchFilters from ..types.graph import Graph from ..types.graph_content_policy import GraphContentPolicy from ..types.graph_content_policy_request import GraphContentPolicyRequest @@ -45,6 +46,7 @@ from ..types.node_search_filters import NodeSearchFilters from ..types.observation import Observation from ..types.observation_page import ObservationPage +from ..types.observation_search_filters import ObservationSearchFilters from ..types.observation_steering import ObservationSteering from ..types.observation_type import ObservationType from ..types.ontology import Ontology @@ -52,6 +54,7 @@ from ..types.subgraph_response import SubgraphResponse from ..types.thread_summary import ThreadSummary from ..types.thread_summary_page import ThreadSummaryPage +from ..types.thread_summary_search_filters import ThreadSummarySearchFilters from .types.graph_context_request_recency_bias import GraphContextRequestRecencyBias from .types.graph_list_request_order import GraphListRequestOrder from .types.graph_list_request_order_by import GraphListRequestOrderBy @@ -1825,7 +1828,7 @@ def search_edges( request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Edge, EdgePage]: """ - Edge search does not support node_labels or exclude_node_labels. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. + Edge search does not support node_labels, exclude_node_labels, or content_policy_violated. content_policy_violated is supported on episode search only. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. Parameters ---------- @@ -1995,12 +1998,14 @@ def search_episodes( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[EpisodeSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchEpisodesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Episode, EpisodePage]: """ + Episode search supports only the metadata_filters and content_policy_violated filters. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -2033,7 +2038,7 @@ def search_episodes( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[EpisodeSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -2064,7 +2069,7 @@ def search_episodes( "center_node_uuid": center_node_uuid, "filter_low_quality_results": filter_low_quality_results, "filters": convert_and_respect_annotation_metadata( - object_=filters, annotation=SearchFilters, direction="write" + object_=filters, annotation=EpisodeSearchFilters, direction="write" ), "mmr_lambda": mmr_lambda, "reranker": reranker, @@ -2175,7 +2180,7 @@ def search_nodes( request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Node, NodePage]: """ - Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, or target_node_uuids. These filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. + Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, target_node_uuids, date_filters, or content_policy_violated. content_policy_violated is supported on episode search only. The edge filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. To filter nodes by created_at, use graph.node.list. Parameters ---------- @@ -2345,12 +2350,14 @@ def search_observations( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ObservationSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchObservationsRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[Observation, ObservationPage]: """ + Observation search supports no filters. Every filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -2383,7 +2390,7 @@ def search_observations( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ObservationSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -2413,9 +2420,7 @@ def search_observations( "bfs_origin_node_uuids": bfs_origin_node_uuids, "center_node_uuid": center_node_uuid, "filter_low_quality_results": filter_low_quality_results, - "filters": convert_and_respect_annotation_metadata( - object_=filters, annotation=SearchFilters, direction="write" - ), + "filters": filters, "mmr_lambda": mmr_lambda, "reranker": reranker, }, @@ -2519,12 +2524,14 @@ def search_thread_summaries( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ThreadSummarySearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchThreadSummariesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[ThreadSummary, ThreadSummaryPage]: """ + Thread-summary search supports only the metadata_filters filter, which matches the metadata of the thread episodes. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -2557,7 +2564,7 @@ def search_thread_summaries( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ThreadSummarySearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -2588,7 +2595,7 @@ def search_thread_summaries( "center_node_uuid": center_node_uuid, "filter_low_quality_results": filter_low_quality_results, "filters": convert_and_respect_annotation_metadata( - object_=filters, annotation=SearchFilters, direction="write" + object_=filters, annotation=ThreadSummarySearchFilters, direction="write" ), "mmr_lambda": mmr_lambda, "reranker": reranker, @@ -4691,7 +4698,7 @@ async def search_edges( request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Edge, EdgePage]: """ - Edge search does not support node_labels or exclude_node_labels. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. + Edge search does not support node_labels, exclude_node_labels, or content_policy_violated. content_policy_violated is supported on episode search only. An edge has two nodes, so a node label filter is not defined for edge search. To filter edges by node label, use graph.edge.list, graph.node.list_neighbors, or graph.get_subgraph. To search the edges of nodes that have a label, do these two steps. First, call graph.search_nodes with node_labels. Then, call graph.search_edges with connected_node_uuids set to the UUIDs of the returned nodes. Parameters ---------- @@ -4864,12 +4871,14 @@ async def search_episodes( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[EpisodeSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchEpisodesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Episode, EpisodePage]: """ + Episode search supports only the metadata_filters and content_policy_violated filters. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -4902,7 +4911,7 @@ async def search_episodes( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[EpisodeSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -4933,7 +4942,7 @@ async def search_episodes( "center_node_uuid": center_node_uuid, "filter_low_quality_results": filter_low_quality_results, "filters": convert_and_respect_annotation_metadata( - object_=filters, annotation=SearchFilters, direction="write" + object_=filters, annotation=EpisodeSearchFilters, direction="write" ), "mmr_lambda": mmr_lambda, "reranker": reranker, @@ -5047,7 +5056,7 @@ async def search_nodes( request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Node, NodePage]: """ - Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, or target_node_uuids. These filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. + Node search does not support edge_types, exclude_edge_types, edge_uuids, connected_node_uuids, source_node_uuids, target_node_uuids, date_filters, or content_policy_violated. content_policy_violated is supported on episode search only. The edge filters select edges. To get the nodes that an edge connects, use graph.search_edges or graph.node.list_neighbors. To filter nodes by created_at, use graph.node.list. Parameters ---------- @@ -5220,12 +5229,14 @@ async def search_observations( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ObservationSearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchObservationsRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[Observation, ObservationPage]: """ + Observation search supports no filters. Every filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -5258,7 +5269,7 @@ async def search_observations( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ObservationSearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -5288,9 +5299,7 @@ async def search_observations( "bfs_origin_node_uuids": bfs_origin_node_uuids, "center_node_uuid": center_node_uuid, "filter_low_quality_results": filter_low_quality_results, - "filters": convert_and_respect_annotation_metadata( - object_=filters, annotation=SearchFilters, direction="write" - ), + "filters": filters, "mmr_lambda": mmr_lambda, "reranker": reranker, }, @@ -5397,12 +5406,14 @@ async def search_thread_summaries( bfs_origin_node_uuids: typing.Optional[typing.Sequence[str]] = OMIT, center_node_uuid: typing.Optional[str] = OMIT, filter_low_quality_results: typing.Optional[bool] = OMIT, - filters: typing.Optional[SearchFilters] = OMIT, + filters: typing.Optional[ThreadSummarySearchFilters] = OMIT, mmr_lambda: typing.Optional[float] = OMIT, reranker: typing.Optional[SearchThreadSummariesRequestReranker] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[ThreadSummary, ThreadSummaryPage]: """ + Thread-summary search supports only the metadata_filters filter, which matches the metadata of the thread episodes. Every other filter returns unsupported_filter. + Parameters ---------- graph_uuid : str @@ -5435,7 +5446,7 @@ async def search_thread_summaries( When the cross-encoder does not score the results, for example after a timeout, Zep returns the results without the filter. - filters : typing.Optional[SearchFilters] + filters : typing.Optional[ThreadSummarySearchFilters] Filters constraining which items are returned. mmr_lambda : typing.Optional[float] @@ -5466,7 +5477,7 @@ async def search_thread_summaries( "center_node_uuid": center_node_uuid, "filter_low_quality_results": filter_low_quality_results, "filters": convert_and_respect_annotation_metadata( - object_=filters, annotation=SearchFilters, direction="write" + object_=filters, annotation=ThreadSummarySearchFilters, direction="write" ), "mmr_lambda": mmr_lambda, "reranker": reranker, diff --git a/src/zep_cloud/graph/thread_summary/client.py b/src/zep_cloud/graph/thread_summary/client.py index 28a45f0f..257a6137 100644 --- a/src/zep_cloud/graph/thread_summary/client.py +++ b/src/zep_cloud/graph/thread_summary/client.py @@ -45,7 +45,8 @@ def list( """ Lists the thread summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters @@ -133,7 +134,8 @@ async def list( """ Lists the thread summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters diff --git a/src/zep_cloud/graph/thread_summary/raw_client.py b/src/zep_cloud/graph/thread_summary/raw_client.py index cee9588e..ddf823ff 100644 --- a/src/zep_cloud/graph/thread_summary/raw_client.py +++ b/src/zep_cloud/graph/thread_summary/raw_client.py @@ -47,7 +47,8 @@ def list( """ Lists the thread summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters @@ -209,7 +210,8 @@ async def list( """ Lists the thread summaries of a graph and returns one page of results. The default `page_size` is 50, and the maximum `page_size` is 100. You can sort by `uuid` or `created_at`. The default sort is `uuid` in descending order. - You cannot use these `filters` fields: `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + You cannot use these `filters` fields: `node_labels`, `exclude_node_labels`, `edge_types`, `exclude_edge_types`, `edge_uuids`, `episode_uuids`, `connected_node_uuids`, `source_node_uuids`, `target_node_uuids`, and `content_policy_violated`. + `date_filters` supports only the `created_at` field. If the request has an unsupported or unknown filter field, the API returns an `unsupported_filter` error. Parameters diff --git a/src/zep_cloud/types/__init__.py b/src/zep_cloud/types/__init__.py index 6569723d..e245364c 100644 --- a/src/zep_cloud/types/__init__.py +++ b/src/zep_cloud/types/__init__.py @@ -199,6 +199,7 @@ from .episode_debug_log import EpisodeDebugLog from .episode_list_filters import EpisodeListFilters from .episode_page import EpisodePage + from .episode_search_filters import EpisodeSearchFilters from .error_body import ErrorBody from .graph import Graph from .graph_content_policy import GraphContentPolicy @@ -255,6 +256,7 @@ from .observation import Observation from .observation_list_filters import ObservationListFilters from .observation_page import ObservationPage + from .observation_search_filters import ObservationSearchFilters from .observation_steering import ObservationSteering from .observation_type import ObservationType from .ontology import Ontology @@ -273,6 +275,7 @@ from .property_filter_operator import PropertyFilterOperator from .property_filter_value import PropertyFilterValue from .property_filter_value_three_item import PropertyFilterValueThreeItem + from .rejected_batch_item import RejectedBatchItem from .rename_agent_task_family_response import RenameAgentTaskFamilyResponse from .role_type import RoleType from .search_filters import SearchFilters @@ -308,6 +311,7 @@ from .thread_summary import ThreadSummary from .thread_summary_list_filters import ThreadSummaryListFilters from .thread_summary_page import ThreadSummaryPage + from .thread_summary_search_filters import ThreadSummarySearchFilters from .trace_connection import TraceConnection from .trace_connection_page import TraceConnectionPage from .trace_connection_provider import TraceConnectionProvider @@ -539,6 +543,7 @@ "EpisodeDebugLog": ".episode_debug_log", "EpisodeListFilters": ".episode_list_filters", "EpisodePage": ".episode_page", + "EpisodeSearchFilters": ".episode_search_filters", "ErrorBody": ".error_body", "Graph": ".graph", "GraphContentPolicy": ".graph_content_policy", @@ -595,6 +600,7 @@ "Observation": ".observation", "ObservationListFilters": ".observation_list_filters", "ObservationPage": ".observation_page", + "ObservationSearchFilters": ".observation_search_filters", "ObservationSteering": ".observation_steering", "ObservationType": ".observation_type", "Ontology": ".ontology", @@ -613,6 +619,7 @@ "PropertyFilterOperator": ".property_filter_operator", "PropertyFilterValue": ".property_filter_value", "PropertyFilterValueThreeItem": ".property_filter_value_three_item", + "RejectedBatchItem": ".rejected_batch_item", "RenameAgentTaskFamilyResponse": ".rename_agent_task_family_response", "RoleType": ".role_type", "SearchFilters": ".search_filters", @@ -648,6 +655,7 @@ "ThreadSummary": ".thread_summary", "ThreadSummaryListFilters": ".thread_summary_list_filters", "ThreadSummaryPage": ".thread_summary_page", + "ThreadSummarySearchFilters": ".thread_summary_search_filters", "TraceConnection": ".trace_connection", "TraceConnectionPage": ".trace_connection_page", "TraceConnectionProvider": ".trace_connection_provider", @@ -903,6 +911,7 @@ def __dir__(): "EpisodeDebugLog", "EpisodeListFilters", "EpisodePage", + "EpisodeSearchFilters", "ErrorBody", "Graph", "GraphContentPolicy", @@ -959,6 +968,7 @@ def __dir__(): "Observation", "ObservationListFilters", "ObservationPage", + "ObservationSearchFilters", "ObservationSteering", "ObservationType", "Ontology", @@ -977,6 +987,7 @@ def __dir__(): "PropertyFilterOperator", "PropertyFilterValue", "PropertyFilterValueThreeItem", + "RejectedBatchItem", "RenameAgentTaskFamilyResponse", "RoleType", "SearchFilters", @@ -1012,6 +1023,7 @@ def __dir__(): "ThreadSummary", "ThreadSummaryListFilters", "ThreadSummaryPage", + "ThreadSummarySearchFilters", "TraceConnection", "TraceConnectionPage", "TraceConnectionProvider", diff --git a/src/zep_cloud/types/batch_items_response.py b/src/zep_cloud/types/batch_items_response.py index 4be7199f..0f2ceeaf 100644 --- a/src/zep_cloud/types/batch_items_response.py +++ b/src/zep_cloud/types/batch_items_response.py @@ -5,6 +5,7 @@ import pydantic from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel from .batch_item import BatchItem +from .rejected_batch_item import RejectedBatchItem class BatchItemsResponse(UniversalBaseModel): @@ -13,6 +14,11 @@ class BatchItemsResponse(UniversalBaseModel): The batch items that were added, in the order they were appended. """ + rejected_items: typing.Optional[typing.List[RejectedBatchItem]] = pydantic.Field(default=None) + """ + The request items that were rejected because their graph was not found. + """ + if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: diff --git a/src/zep_cloud/types/document_summary_list_filters.py b/src/zep_cloud/types/document_summary_list_filters.py index 5d3cd9d5..e708bb6b 100644 --- a/src/zep_cloud/types/document_summary_list_filters.py +++ b/src/zep_cloud/types/document_summary_list_filters.py @@ -11,58 +11,14 @@ class DocumentSummaryListFilters(UniversalBaseModel): - connected_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges connected to any of these node UUIDs. Node search does not support this filter. - """ - - content_policy_violated: typing.Optional[bool] = pydantic.Field(default=None) - """ - Match episodes by their content-policy result. Supported only on episode search when the project setting include_policy_violating_episodes is true. - """ - date_filters: typing.Optional[DateFilters] = pydantic.Field(default=None) """ - Filter results by temporal values. - """ - - edge_types: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results with any of these edge types. Node search does not support this filter. - """ - - edge_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results with any of these edge UUIDs. Node search does not support this filter. - """ - - episode_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results derived from any of these episode UUIDs. - """ - - exclude_edge_types: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Exclude results with any of these edge types. Node search does not support this filter. - """ - - exclude_node_labels: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Exclude nodes that have any of these labels. On an edge list, the API - excludes an edge when its source node or its target node has one of - these labels. Edge search does not support this filter. + Filter results by created_at. """ metadata_filters: typing.Optional["MetadataFilterGroup"] = pydantic.Field(default=None) """ - Filter results by episode metadata. - """ - - node_labels: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include only nodes that have at least one of these labels. On an edge - list, the source node and the target node of each edge must each have - at least one of these labels. Edge search does not support this filter. + Filter results by the metadata of the document episodes. """ property_filters: typing.Optional[typing.List[PropertyFilter]] = pydantic.Field(default=None) @@ -70,16 +26,6 @@ class DocumentSummaryListFilters(UniversalBaseModel): Filter results by node or edge properties. """ - source_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges that start at any of these node UUIDs. Node search does not support this filter. - """ - - target_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges that end at any of these node UUIDs. Node search does not support this filter. - """ - if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: diff --git a/src/zep_cloud/types/edge_search_filters.py b/src/zep_cloud/types/edge_search_filters.py index 365eb5fa..2b4450a8 100644 --- a/src/zep_cloud/types/edge_search_filters.py +++ b/src/zep_cloud/types/edge_search_filters.py @@ -16,11 +16,6 @@ class EdgeSearchFilters(UniversalBaseModel): Include edges connected to any of these node UUIDs. """ - content_policy_violated: typing.Optional[bool] = pydantic.Field(default=None) - """ - Match episodes by their content-policy result. Supported only on episode search when the project setting include_policy_violating_episodes is true. - """ - date_filters: typing.Optional[DateFilters] = pydantic.Field(default=None) """ Filter results by temporal values. diff --git a/src/zep_cloud/types/episode_search_filters.py b/src/zep_cloud/types/episode_search_filters.py new file mode 100644 index 00000000..f75be981 --- /dev/null +++ b/src/zep_cloud/types/episode_search_filters.py @@ -0,0 +1,34 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs + + +class EpisodeSearchFilters(UniversalBaseModel): + content_policy_violated: typing.Optional[bool] = pydantic.Field(default=None) + """ + Match episodes by their content-policy result. Supported only on episode search when the project setting include_policy_violating_episodes is true. + """ + + metadata_filters: typing.Optional["MetadataFilterGroup"] = pydantic.Field(default=None) + """ + Filter results by the episode's own stored metadata. + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .metadata_filter_group import MetadataFilterGroup # noqa: E402, I001 + +update_forward_refs(EpisodeSearchFilters, MetadataFilterGroup=MetadataFilterGroup) diff --git a/src/zep_cloud/types/node_search_filters.py b/src/zep_cloud/types/node_search_filters.py index 76ea082d..b5243c36 100644 --- a/src/zep_cloud/types/node_search_filters.py +++ b/src/zep_cloud/types/node_search_filters.py @@ -6,21 +6,10 @@ import pydantic from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs -from .date_filters import DateFilters from .property_filter import PropertyFilter class NodeSearchFilters(UniversalBaseModel): - content_policy_violated: typing.Optional[bool] = pydantic.Field(default=None) - """ - Match episodes by their content-policy result. Supported only on episode search when the project setting include_policy_violating_episodes is true. - """ - - date_filters: typing.Optional[DateFilters] = pydantic.Field(default=None) - """ - Filter results by temporal values. - """ - episode_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) """ Include results derived from any of these episode UUIDs. diff --git a/src/zep_cloud/types/observation_list_filters.py b/src/zep_cloud/types/observation_list_filters.py index 150e0a78..2bcfcf00 100644 --- a/src/zep_cloud/types/observation_list_filters.py +++ b/src/zep_cloud/types/observation_list_filters.py @@ -1,68 +1,17 @@ # This file was auto-generated by Fern from our API Definition. -from __future__ import annotations - import typing import pydantic -from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel from .date_filters import DateFilters from .property_filter import PropertyFilter class ObservationListFilters(UniversalBaseModel): - connected_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges connected to any of these node UUIDs. Node search does not support this filter. - """ - - content_policy_violated: typing.Optional[bool] = pydantic.Field(default=None) - """ - Match episodes by their content-policy result. Supported only on episode search when the project setting include_policy_violating_episodes is true. - """ - date_filters: typing.Optional[DateFilters] = pydantic.Field(default=None) """ - Filter results by temporal values. - """ - - edge_types: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results with any of these edge types. Node search does not support this filter. - """ - - edge_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results with any of these edge UUIDs. Node search does not support this filter. - """ - - episode_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results derived from any of these episode UUIDs. - """ - - exclude_edge_types: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Exclude results with any of these edge types. Node search does not support this filter. - """ - - exclude_node_labels: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Exclude nodes that have any of these labels. On an edge list, the API - excludes an edge when its source node or its target node has one of - these labels. Edge search does not support this filter. - """ - - metadata_filters: typing.Optional["MetadataFilterGroup"] = pydantic.Field(default=None) - """ - Filter results by episode metadata. - """ - - node_labels: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include only nodes that have at least one of these labels. On an edge - list, the source node and the target node of each edge must each have - at least one of these labels. Edge search does not support this filter. + Filter results by created_at. """ property_filters: typing.Optional[typing.List[PropertyFilter]] = pydantic.Field(default=None) @@ -70,16 +19,6 @@ class ObservationListFilters(UniversalBaseModel): Filter results by node or edge properties. """ - source_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges that start at any of these node UUIDs. Node search does not support this filter. - """ - - target_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges that end at any of these node UUIDs. Node search does not support this filter. - """ - if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: @@ -88,8 +27,3 @@ class Config: frozen = True smart_union = True extra = pydantic.Extra.allow - - -from .metadata_filter_group import MetadataFilterGroup # noqa: E402, I001 - -update_forward_refs(ObservationListFilters, MetadataFilterGroup=MetadataFilterGroup) diff --git a/src/zep_cloud/types/observation_search_filters.py b/src/zep_cloud/types/observation_search_filters.py new file mode 100644 index 00000000..3c3121a2 --- /dev/null +++ b/src/zep_cloud/types/observation_search_filters.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ObservationSearchFilters = typing.Dict[str, typing.Any] diff --git a/src/zep_cloud/types/rejected_batch_item.py b/src/zep_cloud/types/rejected_batch_item.py new file mode 100644 index 00000000..0949d65b --- /dev/null +++ b/src/zep_cloud/types/rejected_batch_item.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class RejectedBatchItem(UniversalBaseModel): + index: typing.Optional[int] = pydantic.Field(default=None) + """ + The zero-based position of the item in the request. + """ + + reason: typing.Optional[str] = pydantic.Field(default=None) + """ + The reason that the item was rejected. + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/zep_cloud/types/thread_summary_list_filters.py b/src/zep_cloud/types/thread_summary_list_filters.py index 18a4aa4c..5f2cb8fb 100644 --- a/src/zep_cloud/types/thread_summary_list_filters.py +++ b/src/zep_cloud/types/thread_summary_list_filters.py @@ -11,58 +11,14 @@ class ThreadSummaryListFilters(UniversalBaseModel): - connected_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges connected to any of these node UUIDs. Node search does not support this filter. - """ - - content_policy_violated: typing.Optional[bool] = pydantic.Field(default=None) - """ - Match episodes by their content-policy result. Supported only on episode search when the project setting include_policy_violating_episodes is true. - """ - date_filters: typing.Optional[DateFilters] = pydantic.Field(default=None) """ - Filter results by temporal values. - """ - - edge_types: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results with any of these edge types. Node search does not support this filter. - """ - - edge_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results with any of these edge UUIDs. Node search does not support this filter. - """ - - episode_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include results derived from any of these episode UUIDs. - """ - - exclude_edge_types: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Exclude results with any of these edge types. Node search does not support this filter. - """ - - exclude_node_labels: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Exclude nodes that have any of these labels. On an edge list, the API - excludes an edge when its source node or its target node has one of - these labels. Edge search does not support this filter. + Filter results by created_at. """ metadata_filters: typing.Optional["MetadataFilterGroup"] = pydantic.Field(default=None) """ - Filter results by episode metadata. - """ - - node_labels: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include only nodes that have at least one of these labels. On an edge - list, the source node and the target node of each edge must each have - at least one of these labels. Edge search does not support this filter. + Filter results by the metadata of the thread episodes. """ property_filters: typing.Optional[typing.List[PropertyFilter]] = pydantic.Field(default=None) @@ -70,16 +26,6 @@ class ThreadSummaryListFilters(UniversalBaseModel): Filter results by node or edge properties. """ - source_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges that start at any of these node UUIDs. Node search does not support this filter. - """ - - target_node_uuids: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Include edges that end at any of these node UUIDs. Node search does not support this filter. - """ - if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: diff --git a/src/zep_cloud/types/thread_summary_search_filters.py b/src/zep_cloud/types/thread_summary_search_filters.py new file mode 100644 index 00000000..586f81bc --- /dev/null +++ b/src/zep_cloud/types/thread_summary_search_filters.py @@ -0,0 +1,29 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs + + +class ThreadSummarySearchFilters(UniversalBaseModel): + metadata_filters: typing.Optional["MetadataFilterGroup"] = pydantic.Field(default=None) + """ + Filter results by the metadata of the thread episodes. + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .metadata_filter_group import MetadataFilterGroup # noqa: E402, I001 + +update_forward_refs(ThreadSummarySearchFilters, MetadataFilterGroup=MetadataFilterGroup) From 90a14d18decc3def3bd1f39d82ca3de874e7716e Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Wed, 14 Oct 2026 01:00:43 +0000 Subject: [PATCH 2/3] [fern-replay] Applied customizations Patches applied (1): - patch-082f322d: Let an ontology field opt out, and fix the README (#348) --- .fern/replay.lock | 10 ++++++-- README.md | 60 ----------------------------------------------- 2 files changed, 8 insertions(+), 62 deletions(-) diff --git a/.fern/replay.lock b/.fern/replay.lock index 3f754355..53504c8f 100644 --- a/.fern/replay.lock +++ b/.fern/replay.lock @@ -54,14 +54,20 @@ generations: cli_version: unknown generator_versions: fernapi/fern-python-sdk: 5.39.2 -current_generation: 28ebe33b9302f169ff5a9569ee8f0d606c8fd251 + - commit_sha: 7247ff4caba2352760890211cfbc4f2ed84cb298 + tree_hash: afe30ccd47b76b0b6dff7b344eac68e63cedd873 + timestamp: 2026-10-14T01:00:40.661Z + cli_version: unknown + generator_versions: + fernapi/fern-python-sdk: 5.39.2 +current_generation: 7247ff4caba2352760890211cfbc4f2ed84cb298 patches: - id: patch-082f322d content_hash: sha256:80c233468a0236864659e748ffa647c6c6a89435d3fca6dec28965e48b901c46 original_commit: 082f322d1bd077cff00e3630500ac6187251a000 original_message: Let an ontology field opt out, and fix the README (#348) original_author: Pavlo Paliychuk - base_generation: 28ebe33b9302f169ff5a9569ee8f0d606c8fd251 + base_generation: 7247ff4caba2352760890211cfbc4f2ed84cb298 files: - README.md patch_content: | diff --git a/README.md b/README.md index c775b5f8..c861b306 100644 --- a/README.md +++ b/README.md @@ -33,78 +33,18 @@ pip install zep-cloud > [!NOTE] > Zep Cloud [overview](https://help.getzep.com/concepts) and [cloud sdk guide](https://help.getzep.com/sdks). -### Community Installation -```bash -pip install zep-python -``` -> [!NOTE] -> Zep Community Edition [quick start](https://help.getzep.com/ce/quickstart) and [sdk guide](https://help.getzep.com/ce/sdks). - -### Zep v0.x Compatible SDK -You can install Zep v0.x compatible sdk by running: -```bash -pip install "zep-python>=1.5.0,<2.0.0" -``` -> [!NOTE] -> Zep v0.x [quick start](https://help.getzep.com/ce/legacy/deployment/quickstart) and [sdk guide](https://help.getzep.com/ce/legacy/sdk). - ### How Zep works Zep persists and recalls chat histories, and automatically generates summaries and other artifacts from these chat histories. It also embeds messages and summaries, enabling you to search Zep for relevant context from past conversations. Zep does all of this asynchronously, ensuring these operations don't impact your user's chat experience. Data is persisted to database, allowing you to scale out when growth demands. -Zep also provides a simple, easy to use abstraction for document vector search called Document Collections. This is designed to complement Zep's core context features, but is not designed to be a general purpose vector database. - Zep allows you to be more intentional about constructing your prompt: 1. automatically adding a few recent messages, with the number customized for your app; 2. a summary of recent conversations prior to the messages above; 3. and/or contextually relevant summaries or messages surfaced from the entire chat session. -4. and/or relevant Business data from Zep Document Collections. - -Zep Cloud offers: -- **Fact Extraction:** Automatically build fact tables from conversations, without having to define a data schema upfront. -- **Dialog Classification:** Instantly and accurately classify chat dialog. Understand user intent and emotion, segment users, and more. Route chains based on semantic context, and trigger events. -- **Structured Data Extraction:** Quickly extract business data from chat conversations using a schema you define. Understand what your Assistant should ask for next in order to complete its task. You will also need to provide a Zep Project API key to your zep client. You can find out about zep projects in our [cloud docs](https://help.getzep.com/projects.html) -### Using LangChain Zep Classes with `zep-python` - -(Currently only available on release candidate versions) - -In the pre-release version `zep-python` sdk comes with `ZepChatMessageHistory` and `ZepVectorStore` -classes that are compatible with [LangChain's Python expression language](https://python.langchain.com/docs/expression_language/) - -In order to use these classes in your application, you need to make sure that you have -`langchain_core` package installed, please refer to [Langchain's docs installation section](https://python.langchain.com/docs/get_started/installation#langchain-core). - -We support `langchain_core@>=0.1.3<0.2.0` - -You can import these classes in the following way: - -```python -from zep_cloud.langchain import ZepChatMessageHistory, ZepVectorStore -``` - -### Running Examples -You will need to set the following environment variables to run examples in the `examples` directory: - -```dotenv -# Please use examples/.env.example as a template for .env file - -# Required -ZEP_API_KEY=# Your Zep Project API Key -ZEP_COLLECTION=# used in ingestion script and in vector store examples -OPENAI_API_KEY=# Your OpenAI API Key - -# Optional (If you want to use langsmith with LangServe Sample App) -LANGCHAIN_TRACING_V2=true -LANGCHAIN_API_KEY= -LANGCHAIN_PROJECT=# If not specified, defaults to "default" -``` - - - ## Installation ```sh From af832f8e6fd6b854649e729997b75bb2f364dbcb Mon Sep 17 00:00:00 2001 From: "zep-sdk-release-bot[bot]" Date: Wed, 14 Oct 2026 01:00:50 +0000 Subject: [PATCH 3/3] chore: bump SDK version to 4.0.0 --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index e4121b92..8d017284 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,7 @@ [project] name = "zep-cloud" dynamic = ["version"] +version = "4.0.0" [tool.poetry] name = "zep-cloud"