Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "3.26.0"
".": "3.27.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 26
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-8773015c1da0dcb9dfeec7ff946b71ed9b75b854d0f0de6dc1545d218d181715.yml
openapi_spec_hash: 1af583bba4ee00275021c440cf38ee13
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-062b5e0b84ca5acf4b18f1a9650e023e1908ee6f2b88465e55ba5213ee9257bf.yml
openapi_spec_hash: c465d5d777712bec4bdd8e6aa81a0da9
config_hash: f3eb5ca71172780678106f6d46f15dda
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# Changelog

## 3.27.0 (2026-02-24)

Full Changelog: [v3.26.0...v3.27.0](https://github.com/supermemoryai/python-sdk/compare/v3.26.0...v3.27.0)

### Features

* **api:** api update ([04a5168](https://github.com/supermemoryai/python-sdk/commit/04a51688c214687dc622500c934d053e046b38c1))


### Chores

* **internal:** add request options to SSE classes ([2d6cdd8](https://github.com/supermemoryai/python-sdk/commit/2d6cdd83fb5f6097f940cdea43eafe2f73a510ca))
* **internal:** make `test_proxy_environment_variables` more resilient ([1539616](https://github.com/supermemoryai/python-sdk/commit/1539616c58f9f72e63c560d6c08e6bf8b04a0740))

## 3.26.0 (2026-02-20)

Full Changelog: [v3.25.0...v3.26.0](https://github.com/supermemoryai/python-sdk/compare/v3.25.0...v3.26.0)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "supermemory"
version = "3.26.0"
version = "3.27.0"
description = "The official Python library for the supermemory API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
10 changes: 10 additions & 0 deletions src/supermemory/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ def profile(
self,
*,
container_tag: str,
filters: client_profile_params.Filters | Omit = omit,
q: str | Omit = omit,
threshold: float | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -315,6 +316,9 @@ def profile(
container_tag: Tag to filter the profile by. This can be an ID for your user, a project ID, or
any other identifier you wish to use to filter memories.

filters: Optional metadata filters to apply to profile results and search results.
Supports complex AND/OR queries with multiple conditions.

q: Optional search query to include search results in the response

threshold: Threshold for search results. Only results with a score above this threshold
Expand All @@ -333,6 +337,7 @@ def profile(
body=maybe_transform(
{
"container_tag": container_tag,
"filters": filters,
"q": q,
"threshold": threshold,
},
Expand Down Expand Up @@ -607,6 +612,7 @@ async def profile(
self,
*,
container_tag: str,
filters: client_profile_params.Filters | Omit = omit,
q: str | Omit = omit,
threshold: float | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -623,6 +629,9 @@ async def profile(
container_tag: Tag to filter the profile by. This can be an ID for your user, a project ID, or
any other identifier you wish to use to filter memories.

filters: Optional metadata filters to apply to profile results and search results.
Supports complex AND/OR queries with multiple conditions.

q: Optional search query to include search results in the response

threshold: Threshold for search results. Only results with a score above this threshold
Expand All @@ -641,6 +650,7 @@ async def profile(
body=await async_maybe_transform(
{
"container_tag": container_tag,
"filters": filters,
"q": q,
"threshold": threshold,
},
Expand Down
3 changes: 3 additions & 0 deletions src/supermemory/_response.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T:
),
response=self.http_response,
client=cast(Any, self._client),
options=self._options,
),
)

Expand All @@ -162,6 +163,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T:
cast_to=extract_stream_chunk_type(self._stream_cls),
response=self.http_response,
client=cast(Any, self._client),
options=self._options,
),
)

Expand All @@ -175,6 +177,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T:
cast_to=cast_to,
response=self.http_response,
client=cast(Any, self._client),
options=self._options,
),
)

Expand Down
11 changes: 8 additions & 3 deletions src/supermemory/_streaming.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import json
import inspect
from types import TracebackType
from typing import TYPE_CHECKING, Any, Generic, TypeVar, Iterator, AsyncIterator, cast
from typing import TYPE_CHECKING, Any, Generic, TypeVar, Iterator, Optional, AsyncIterator, cast
from typing_extensions import Self, Protocol, TypeGuard, override, get_origin, runtime_checkable

import httpx
Expand All @@ -13,6 +13,7 @@

if TYPE_CHECKING:
from ._client import Supermemory, AsyncSupermemory
from ._models import FinalRequestOptions


_T = TypeVar("_T")
Expand All @@ -22,7 +23,7 @@ class Stream(Generic[_T]):
"""Provides the core interface to iterate over a synchronous stream response."""

response: httpx.Response

_options: Optional[FinalRequestOptions] = None
_decoder: SSEBytesDecoder

def __init__(
Expand All @@ -31,10 +32,12 @@ def __init__(
cast_to: type[_T],
response: httpx.Response,
client: Supermemory,
options: Optional[FinalRequestOptions] = None,
) -> None:
self.response = response
self._cast_to = cast_to
self._client = client
self._options = options
self._decoder = client._make_sse_decoder()
self._iterator = self.__stream__()

Expand Down Expand Up @@ -85,7 +88,7 @@ class AsyncStream(Generic[_T]):
"""Provides the core interface to iterate over an asynchronous stream response."""

response: httpx.Response

_options: Optional[FinalRequestOptions] = None
_decoder: SSEDecoder | SSEBytesDecoder

def __init__(
Expand All @@ -94,10 +97,12 @@ def __init__(
cast_to: type[_T],
response: httpx.Response,
client: AsyncSupermemory,
options: Optional[FinalRequestOptions] = None,
) -> None:
self.response = response
self._cast_to = cast_to
self._client = client
self._options = options
self._decoder = client._make_sse_decoder()
self._iterator = self.__stream__()

Expand Down
2 changes: 1 addition & 1 deletion src/supermemory/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "supermemory"
__version__ = "3.26.0" # x-release-please-version
__version__ = "3.27.0" # x-release-please-version
Loading