Skip to content

Commit 05118fc

Browse files
chore: add missing docstrings
1 parent f134f9b commit 05118fc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+152
-0
lines changed

src/parallel/types/auto_schema.py

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

1010

1111
class AutoSchema(BaseModel):
12+
"""Auto schema for a task input or output."""
13+
1214
type: Optional[Literal["auto"]] = None
1315
"""The type of schema being defined. Always `auto`."""

src/parallel/types/auto_schema_param.py

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

99

1010
class AutoSchemaParam(TypedDict, total=False):
11+
"""Auto schema for a task input or output."""
12+
1113
type: Literal["auto"]
1214
"""The type of schema being defined. Always `auto`."""

src/parallel/types/beta/beta_extract_params.py

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

4949

5050
class FullContentFullContentSettings(TypedDict, total=False):
51+
"""Optional settings for returning full content."""
52+
5153
max_chars_per_result: Optional[int]
5254
"""
5355
Optional limit on the number of characters to include in the full content for

src/parallel/types/beta/beta_run_input.py

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

1313

1414
class BetaRunInput(BaseModel):
15+
"""Task run input with additional beta fields."""
16+
1517
input: Union[str, Dict[str, object]]
1618
"""Input to the task, either text or a JSON object."""
1719

src/parallel/types/beta/beta_run_input_param.py

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

1515

1616
class BetaRunInputParam(TypedDict, total=False):
17+
"""Task run input with additional beta fields."""
18+
1719
input: Required[Union[str, Dict[str, object]]]
1820
"""Input to the task, either text or a JSON object."""
1921

src/parallel/types/beta/beta_task_run_result.py

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

1414

1515
class OutputBetaTaskRunTextOutput(BaseModel):
16+
"""Output from a task that returns text."""
17+
1618
basis: List[FieldBasis]
1719
"""Basis for the output.
1820
@@ -37,6 +39,8 @@ class OutputBetaTaskRunTextOutput(BaseModel):
3739

3840

3941
class OutputBetaTaskRunJsonOutput(BaseModel):
42+
"""Output from a task that returns JSON."""
43+
4044
basis: List[FieldBasis]
4145
"""Basis for the output.
4246
@@ -75,6 +79,8 @@ class OutputBetaTaskRunJsonOutput(BaseModel):
7579

7680

7781
class BetaTaskRunResult(BaseModel):
82+
"""Result of a beta task run. Available only if beta headers are specified."""
83+
7884
output: Output
7985
"""Output from the task conforming to the output schema."""
8086

src/parallel/types/beta/error_event.py

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

1010

1111
class ErrorEvent(BaseModel):
12+
"""Event indicating an error."""
13+
1214
error: ErrorObject
1315
"""Error."""
1416

src/parallel/types/beta/excerpt_settings_param.py

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

1010

1111
class ExcerptSettingsParam(TypedDict, total=False):
12+
"""Optional settings for returning relevant excerpts."""
13+
1214
max_chars_per_result: Optional[int]
1315
"""Optional upper bound on the total number of characters to include per url.
1416

src/parallel/types/beta/extract_error.py

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

99

1010
class ExtractError(BaseModel):
11+
"""Extract error details."""
12+
1113
content: Optional[str] = None
1214
"""Content returned for http client or server errors, if any."""
1315

src/parallel/types/beta/extract_response.py

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

1313

1414
class ExtractResponse(BaseModel):
15+
"""Fetch result."""
16+
1517
errors: List[ExtractError]
1618
"""Extract errors: requested URLs not in the results."""
1719

0 commit comments

Comments
 (0)