Skip to content

Commit 1f04083

Browse files
chore: add missing docstrings
1 parent 2c2a4bc commit 1f04083

26 files changed

+65
-0
lines changed

src/turbopuffer/types/attribute_schema_config.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212

1313

1414
class AnnAnnConfig(BaseModel):
15+
"""Configuration options for ANN (Approximate Nearest Neighbor) indexing."""
16+
1517
distance_metric: Optional[DistanceMetric] = None
1618
"""A function used to calculate vector similarity."""
1719

@@ -20,6 +22,8 @@ class AnnAnnConfig(BaseModel):
2022

2123

2224
class AttributeSchemaConfig(BaseModel):
25+
"""Detailed configuration for an attribute attached to a document."""
26+
2327
type: AttributeType
2428
"""The data type of the attribute.
2529

src/turbopuffer/types/attribute_schema_config_param.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313

1414

1515
class AnnAnnConfig(TypedDict, total=False):
16+
"""Configuration options for ANN (Approximate Nearest Neighbor) indexing."""
17+
1618
distance_metric: DistanceMetric
1719
"""A function used to calculate vector similarity."""
1820

@@ -21,6 +23,8 @@ class AnnAnnConfig(TypedDict, total=False):
2123

2224

2325
class AttributeSchemaConfigParam(TypedDict, total=False):
26+
"""Detailed configuration for an attribute attached to a document."""
27+
2428
type: Required[AttributeType]
2529
"""The data type of the attribute.
2630

src/turbopuffer/types/bm25_clause_params.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,7 @@
88

99

1010
class Bm25ClauseParams(TypedDict, total=False):
11+
"""Additional (optional) parameters for a single BM25 query clause."""
12+
1113
last_as_prefix: bool
1214
"""Whether to treat the last token in the query input as a literal prefix."""

src/turbopuffer/types/columns_param.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313

1414

1515
class ColumnsParamTyped(TypedDict, total=False):
16+
"""A list of documents in columnar format.
17+
18+
Each key is a column name, mapped to an array of values for that column.
19+
"""
20+
1621
id: Required[SequenceNotStr[IDParam]]
1722
"""The IDs of the documents."""
1823

src/turbopuffer/types/contains_all_tokens_filter_params.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,7 @@
88

99

1010
class ContainsAllTokensFilterParams(TypedDict, total=False):
11+
"""Additional (optional) parameters for the ContainsAllTokens filter."""
12+
1113
last_as_prefix: bool
1214
"""Whether to treat the last token in the query input as a literal prefix."""

src/turbopuffer/types/full_text_search_config.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010

1111

1212
class FullTextSearchConfig(BaseModel):
13+
"""Configuration options for full-text search."""
14+
1315
ascii_folding: Optional[bool] = None
1416
"""
1517
Whether to convert each non-ASCII character in a token to its ASCII equivalent,

src/turbopuffer/types/full_text_search_config_param.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111

1212

1313
class FullTextSearchConfigParam(TypedDict, total=False):
14+
"""Configuration options for full-text search."""
15+
1416
ascii_folding: bool
1517
"""
1618
Whether to convert each non-ASCII character in a token to its ASCII equivalent,

src/turbopuffer/types/namespace_delete_all_response.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,7 @@
88

99

1010
class NamespaceDeleteAllResponse(BaseModel):
11+
"""The response to a successful namespace deletion request."""
12+
1113
status: Literal["OK"]
1214
"""The status of the request."""

src/turbopuffer/types/namespace_explain_query_params.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ class NamespaceExplainQueryParams(TypedDict, total=False):
6060

6161

6262
class Consistency(TypedDict, total=False):
63+
"""The consistency level for a query."""
64+
6365
level: Literal["strong", "eventual"]
6466
"""The query's consistency level.
6567

src/turbopuffer/types/namespace_explain_query_response.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,7 @@
88

99

1010
class NamespaceExplainQueryResponse(BaseModel):
11+
"""The response to a successful query explain."""
12+
1113
plan_text: Optional[str] = None
1214
"""The textual representation of the query plan."""

0 commit comments

Comments
 (0)