Skip to content

Commit c80c78c

Browse files
committed
SDK regeneration
1 parent e2adc9f commit c80c78c

8 files changed

+99
-3
lines changed

reference.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1185,6 +1185,14 @@ client.graph.set_entity_types_internal()
11851185
<dl>
11861186
<dd>
11871187

1188+
**edge_types:** `typing.Optional[typing.Sequence[EdgeType]]`
1189+
1190+
</dd>
1191+
</dl>
1192+
1193+
<dl>
1194+
<dd>
1195+
11881196
**entity_types:** `typing.Optional[typing.Sequence[EntityType]]`
11891197

11901198
</dd>

src/zep_cloud/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@
88
ApidataDocumentCollection,
99
ApidataDocumentSearchResponse,
1010
ApidataDocumentWithScore,
11+
ApidataEntityEdgeSourceTarget,
1112
ClassifySessionRequest,
1213
CreateDocumentRequest,
14+
EdgeType,
1315
EndSessionResponse,
1416
EndSessionsResponse,
1517
EntityEdge,
@@ -70,10 +72,12 @@
7072
"ApidataDocumentCollection",
7173
"ApidataDocumentSearchResponse",
7274
"ApidataDocumentWithScore",
75+
"ApidataEntityEdgeSourceTarget",
7376
"BadRequestError",
7477
"ClassifySessionRequest",
7578
"ConflictError",
7679
"CreateDocumentRequest",
80+
"EdgeType",
7781
"EndSessionResponse",
7882
"EndSessionsResponse",
7983
"EntityEdge",

src/zep_cloud/core/client_wrapper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def get_headers(self) -> typing.Dict[str, str]:
1717
headers: typing.Dict[str, str] = {
1818
"X-Fern-Language": "Python",
1919
"X-Fern-SDK-Name": "zep-cloud",
20-
"X-Fern-SDK-Version": "2.12.3",
20+
"X-Fern-SDK-Version": "2.13.0",
2121
}
2222
headers["Authorization"] = f"Api-Key {self.api_key}"
2323
return headers

src/zep_cloud/graph/client.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
from ..errors.not_found_error import NotFoundError
1313
from ..types.add_triple_response import AddTripleResponse
1414
from ..types.api_error import ApiError as types_api_error_ApiError
15+
from ..types.edge_type import EdgeType
1516
from ..types.entity_type import EntityType
1617
from ..types.entity_type_response import EntityTypeResponse
1718
from ..types.episode import Episode
@@ -82,6 +83,7 @@ def list_entity_types(self, *, request_options: typing.Optional[RequestOptions]
8283
def set_entity_types_internal(
8384
self,
8485
*,
86+
edge_types: typing.Optional[typing.Sequence[EdgeType]] = OMIT,
8587
entity_types: typing.Optional[typing.Sequence[EntityType]] = OMIT,
8688
request_options: typing.Optional[RequestOptions] = None
8789
) -> SuccessResponse:
@@ -90,6 +92,8 @@ def set_entity_types_internal(
9092
9193
Parameters
9294
----------
95+
edge_types : typing.Optional[typing.Sequence[EdgeType]]
96+
9397
entity_types : typing.Optional[typing.Sequence[EntityType]]
9498
9599
request_options : typing.Optional[RequestOptions]
@@ -112,7 +116,7 @@ def set_entity_types_internal(
112116
_response = self._client_wrapper.httpx_client.request(
113117
"entity-types",
114118
method="PUT",
115-
json={"entity_types": entity_types},
119+
json={"edge_types": edge_types, "entity_types": entity_types},
116120
request_options=request_options,
117121
omit=OMIT,
118122
)
@@ -574,6 +578,7 @@ async def main() -> None:
574578
async def set_entity_types_internal(
575579
self,
576580
*,
581+
edge_types: typing.Optional[typing.Sequence[EdgeType]] = OMIT,
577582
entity_types: typing.Optional[typing.Sequence[EntityType]] = OMIT,
578583
request_options: typing.Optional[RequestOptions] = None
579584
) -> SuccessResponse:
@@ -582,6 +587,8 @@ async def set_entity_types_internal(
582587
583588
Parameters
584589
----------
590+
edge_types : typing.Optional[typing.Sequence[EdgeType]]
591+
585592
entity_types : typing.Optional[typing.Sequence[EntityType]]
586593
587594
request_options : typing.Optional[RequestOptions]
@@ -612,7 +619,7 @@ async def main() -> None:
612619
_response = await self._client_wrapper.httpx_client.request(
613620
"entity-types",
614621
method="PUT",
615-
json={"entity_types": entity_types},
622+
json={"edge_types": edge_types, "entity_types": entity_types},
616623
request_options=request_options,
617624
omit=OMIT,
618625
)

src/zep_cloud/types/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,10 @@
77
from .apidata_document_collection import ApidataDocumentCollection
88
from .apidata_document_search_response import ApidataDocumentSearchResponse
99
from .apidata_document_with_score import ApidataDocumentWithScore
10+
from .apidata_entity_edge_source_target import ApidataEntityEdgeSourceTarget
1011
from .classify_session_request import ClassifySessionRequest
1112
from .create_document_request import CreateDocumentRequest
13+
from .edge_type import EdgeType
1214
from .end_session_response import EndSessionResponse
1315
from .end_sessions_response import EndSessionsResponse
1416
from .entity_edge import EntityEdge
@@ -64,8 +66,10 @@
6466
"ApidataDocumentCollection",
6567
"ApidataDocumentSearchResponse",
6668
"ApidataDocumentWithScore",
69+
"ApidataEntityEdgeSourceTarget",
6770
"ClassifySessionRequest",
6871
"CreateDocumentRequest",
72+
"EdgeType",
6973
"EndSessionResponse",
7074
"EndSessionsResponse",
7175
"EntityEdge",
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# This file was auto-generated by Fern from our API Definition.
2+
3+
import datetime as dt
4+
import typing
5+
6+
from ..core.datetime_utils import serialize_datetime
7+
from ..core.pydantic_utilities import deep_union_pydantic_dicts, pydantic_v1
8+
9+
10+
class ApidataEntityEdgeSourceTarget(pydantic_v1.BaseModel):
11+
source: typing.Optional[str] = pydantic_v1.Field(default=None)
12+
"""
13+
Source represents the originating node identifier in the edge type relationship. (optional)
14+
"""
15+
16+
target: typing.Optional[str] = pydantic_v1.Field(default=None)
17+
"""
18+
Target represents the target node identifier in the edge type relationship. (optional)
19+
"""
20+
21+
def json(self, **kwargs: typing.Any) -> str:
22+
kwargs_with_defaults: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
23+
return super().json(**kwargs_with_defaults)
24+
25+
def dict(self, **kwargs: typing.Any) -> typing.Dict[str, typing.Any]:
26+
kwargs_with_defaults_exclude_unset: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
27+
kwargs_with_defaults_exclude_none: typing.Any = {"by_alias": True, "exclude_none": True, **kwargs}
28+
29+
return deep_union_pydantic_dicts(
30+
super().dict(**kwargs_with_defaults_exclude_unset), super().dict(**kwargs_with_defaults_exclude_none)
31+
)
32+
33+
class Config:
34+
frozen = True
35+
smart_union = True
36+
extra = pydantic_v1.Extra.allow
37+
json_encoders = {dt.datetime: serialize_datetime}

src/zep_cloud/types/edge_type.py

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# This file was auto-generated by Fern from our API Definition.
2+
3+
import datetime as dt
4+
import typing
5+
6+
from ..core.datetime_utils import serialize_datetime
7+
from ..core.pydantic_utilities import deep_union_pydantic_dicts, pydantic_v1
8+
from .apidata_entity_edge_source_target import ApidataEntityEdgeSourceTarget
9+
from .entity_property import EntityProperty
10+
11+
12+
class EdgeType(pydantic_v1.BaseModel):
13+
description: str
14+
name: str
15+
properties: typing.Optional[typing.List[EntityProperty]] = None
16+
source_targets: typing.Optional[typing.List[ApidataEntityEdgeSourceTarget]] = None
17+
18+
def json(self, **kwargs: typing.Any) -> str:
19+
kwargs_with_defaults: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
20+
return super().json(**kwargs_with_defaults)
21+
22+
def dict(self, **kwargs: typing.Any) -> typing.Dict[str, typing.Any]:
23+
kwargs_with_defaults_exclude_unset: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
24+
kwargs_with_defaults_exclude_none: typing.Any = {"by_alias": True, "exclude_none": True, **kwargs}
25+
26+
return deep_union_pydantic_dicts(
27+
super().dict(**kwargs_with_defaults_exclude_unset), super().dict(**kwargs_with_defaults_exclude_none)
28+
)
29+
30+
class Config:
31+
frozen = True
32+
smart_union = True
33+
extra = pydantic_v1.Extra.allow
34+
json_encoders = {dt.datetime: serialize_datetime}

src/zep_cloud/types/entity_type_response.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,12 @@
55

66
from ..core.datetime_utils import serialize_datetime
77
from ..core.pydantic_utilities import deep_union_pydantic_dicts, pydantic_v1
8+
from .edge_type import EdgeType
89
from .entity_type import EntityType
910

1011

1112
class EntityTypeResponse(pydantic_v1.BaseModel):
13+
edge_types: typing.Optional[typing.List[EdgeType]] = None
1214
entity_types: typing.Optional[typing.List[EntityType]] = None
1315

1416
def json(self, **kwargs: typing.Any) -> str:

0 commit comments

Comments
 (0)