Skip to content

Commit ca75227

Browse files
feat(api): manual updates
1 parent 538719d commit ca75227

File tree

15 files changed

+110
-93
lines changed

15 files changed

+110
-93
lines changed

.stats.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 24
22
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-3856961a8959b60dbf0b6912d69c23390fbbca1c5e31028dd0decc85234dd285.yml
33
openapi_spec_hash: 988a7d6d7cef81ceb4acda3ef9f8c21e
4-
config_hash: 7dd9730225e87663fd62814dcfe62ba7
4+
config_hash: 293588cb2728a4e82aba52073e15ebc1

api.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# Shared Types
2+
3+
```python
4+
from supermemory.types import And, Or
5+
```
6+
17
# Supermemory
28

39
Types:

src/supermemory/types/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
from __future__ import annotations
44

5+
from .shared import Or as Or, And as And
56
from .add_response import AddResponse as AddResponse
67
from .search_response import SearchResponse as SearchResponse
78
from .profile_response import ProfileResponse as ProfileResponse

src/supermemory/types/client_search_params.py

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,14 @@
22

33
from __future__ import annotations
44

5-
from typing import Union, Iterable
5+
from typing import Union
66
from typing_extensions import Required, Annotated, TypeAlias, TypedDict
77

88
from .._utils import PropertyInfo
9+
from .shared_params.or_ import Or
10+
from .shared_params.and_ import And
911

10-
__all__ = ["ClientSearchParams", "Filters", "FiltersOr", "FiltersAnd", "Include"]
12+
__all__ = ["ClientSearchParams", "Filters", "Include"]
1113

1214

1315
class ClientSearchParams(TypedDict, total=False):
@@ -49,19 +51,7 @@ class ClientSearchParams(TypedDict, total=False):
4951
"""
5052

5153

52-
class FiltersOr(TypedDict, total=False):
53-
"""OR"""
54-
55-
or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]]
56-
57-
58-
class FiltersAnd(TypedDict, total=False):
59-
"""AND"""
60-
61-
and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]]
62-
63-
64-
Filters: TypeAlias = Union[FiltersOr, FiltersAnd]
54+
Filters: TypeAlias = Union[Or, And]
6555

6656

6757
class Include(TypedDict, total=False):

src/supermemory/types/document_list_params.py

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,15 @@
22

33
from __future__ import annotations
44

5-
from typing import Union, Iterable
6-
from typing_extensions import Literal, Required, Annotated, TypeAlias, TypedDict
5+
from typing import Union
6+
from typing_extensions import Literal, Annotated, TypeAlias, TypedDict
77

88
from .._types import SequenceNotStr
99
from .._utils import PropertyInfo
10+
from .shared_params.or_ import Or
11+
from .shared_params.and_ import And
1012

11-
__all__ = ["DocumentListParams", "Filters", "FiltersOr", "FiltersAnd"]
13+
__all__ = ["DocumentListParams", "Filters"]
1214

1315

1416
class DocumentListParams(TypedDict, total=False):
@@ -41,16 +43,4 @@ class DocumentListParams(TypedDict, total=False):
4143
"""Field to sort by"""
4244

4345

44-
class FiltersOr(TypedDict, total=False):
45-
"""OR"""
46-
47-
or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]]
48-
49-
50-
class FiltersAnd(TypedDict, total=False):
51-
"""AND"""
52-
53-
and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]]
54-
55-
56-
Filters: TypeAlias = Union[FiltersOr, FiltersAnd]
46+
Filters: TypeAlias = Union[Or, And]

src/supermemory/types/memory_list_params.py

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,15 @@
22

33
from __future__ import annotations
44

5-
from typing import Union, Iterable
6-
from typing_extensions import Literal, Required, Annotated, TypeAlias, TypedDict
5+
from typing import Union
6+
from typing_extensions import Literal, Annotated, TypeAlias, TypedDict
77

88
from .._types import SequenceNotStr
99
from .._utils import PropertyInfo
10+
from .shared_params.or_ import Or
11+
from .shared_params.and_ import And
1012

11-
__all__ = ["MemoryListParams", "Filters", "FiltersOr", "FiltersAnd"]
13+
__all__ = ["MemoryListParams", "Filters"]
1214

1315

1416
class MemoryListParams(TypedDict, total=False):
@@ -41,16 +43,4 @@ class MemoryListParams(TypedDict, total=False):
4143
"""Field to sort by"""
4244

4345

44-
class FiltersOr(TypedDict, total=False):
45-
"""OR"""
46-
47-
or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]]
48-
49-
50-
class FiltersAnd(TypedDict, total=False):
51-
"""AND"""
52-
53-
and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]]
54-
55-
56-
Filters: TypeAlias = Union[FiltersOr, FiltersAnd]
46+
Filters: TypeAlias = Union[Or, And]

src/supermemory/types/search_documents_params.py

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,15 @@
22

33
from __future__ import annotations
44

5-
from typing import Union, Iterable
5+
from typing import Union
66
from typing_extensions import Required, Annotated, TypeAlias, TypedDict
77

88
from .._types import SequenceNotStr
99
from .._utils import PropertyInfo
10+
from .shared_params.or_ import Or
11+
from .shared_params.and_ import And
1012

11-
__all__ = ["SearchDocumentsParams", "Filters", "FiltersOr", "FiltersAnd"]
13+
__all__ = ["SearchDocumentsParams", "Filters"]
1214

1315

1416
class SearchDocumentsParams(TypedDict, total=False):
@@ -82,16 +84,4 @@ class SearchDocumentsParams(TypedDict, total=False):
8284
"""
8385

8486

85-
class FiltersOr(TypedDict, total=False):
86-
"""OR"""
87-
88-
or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]]
89-
90-
91-
class FiltersAnd(TypedDict, total=False):
92-
"""AND"""
93-
94-
and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]]
95-
96-
97-
Filters: TypeAlias = Union[FiltersOr, FiltersAnd]
87+
Filters: TypeAlias = Union[Or, And]

src/supermemory/types/search_execute_params.py

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,15 @@
22

33
from __future__ import annotations
44

5-
from typing import Union, Iterable
5+
from typing import Union
66
from typing_extensions import Required, Annotated, TypeAlias, TypedDict
77

88
from .._types import SequenceNotStr
99
from .._utils import PropertyInfo
10+
from .shared_params.or_ import Or
11+
from .shared_params.and_ import And
1012

11-
__all__ = ["SearchExecuteParams", "Filters", "FiltersOr", "FiltersAnd"]
13+
__all__ = ["SearchExecuteParams", "Filters"]
1214

1315

1416
class SearchExecuteParams(TypedDict, total=False):
@@ -82,16 +84,4 @@ class SearchExecuteParams(TypedDict, total=False):
8284
"""
8385

8486

85-
class FiltersOr(TypedDict, total=False):
86-
"""OR"""
87-
88-
or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]]
89-
90-
91-
class FiltersAnd(TypedDict, total=False):
92-
"""AND"""
93-
94-
and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]]
95-
96-
97-
Filters: TypeAlias = Union[FiltersOr, FiltersAnd]
87+
Filters: TypeAlias = Union[Or, And]

src/supermemory/types/search_memories_params.py

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,14 @@
22

33
from __future__ import annotations
44

5-
from typing import Union, Iterable
5+
from typing import Union
66
from typing_extensions import Required, Annotated, TypeAlias, TypedDict
77

88
from .._utils import PropertyInfo
9+
from .shared_params.or_ import Or
10+
from .shared_params.and_ import And
911

10-
__all__ = ["SearchMemoriesParams", "Filters", "FiltersOr", "FiltersAnd", "Include"]
12+
__all__ = ["SearchMemoriesParams", "Filters", "Include"]
1113

1214

1315
class SearchMemoriesParams(TypedDict, total=False):
@@ -49,19 +51,7 @@ class SearchMemoriesParams(TypedDict, total=False):
4951
"""
5052

5153

52-
class FiltersOr(TypedDict, total=False):
53-
"""OR"""
54-
55-
or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]]
56-
57-
58-
class FiltersAnd(TypedDict, total=False):
59-
"""AND"""
60-
61-
and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]]
62-
63-
64-
Filters: TypeAlias = Union[FiltersOr, FiltersAnd]
54+
Filters: TypeAlias = Union[Or, And]
6555

6656

6757
class Include(TypedDict, total=False):
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
from .or_ import Or as Or
4+
from .and_ import And as And

0 commit comments

Comments
 (0)