From d15b31e5c77d4a15d43456da964c7ee71a2a68e9 Mon Sep 17 00:00:00 2001 From: Robert Gambee Date: Thu, 12 Feb 2026 13:12:25 -0500 Subject: [PATCH 1/2] Regenerate code from OpenAPI spec --- src/everyrow/generated/api/health/__init__.py | 1 + .../generated/api/health/health_health_get.py | 123 ++++++++++++++++++ .../agent_map_operations_agent_map_post.py | 17 ++- .../dedupe_operations_dedupe_post.py | 17 ++- .../operations/merge_operations_merge_post.py | 17 ++- .../operations/rank_operations_rank_post.py | 17 ++- .../screen_operations_screen_post.py | 17 ++- ...ngle_agent_operations_single_agent_post.py | 17 ++- src/everyrow/generated/models/__init__.py | 16 +-- .../generated/models/health_response.py | 61 +++++++++ .../generated/models/merge_operation.py | 11 +- .../generated/models/task_progress_info.py | 93 +++++++++++++ .../generated/models/task_status_response.py | 35 ++++- 13 files changed, 422 insertions(+), 20 deletions(-) create mode 100644 src/everyrow/generated/api/health/__init__.py create mode 100644 src/everyrow/generated/api/health/health_health_get.py create mode 100644 src/everyrow/generated/models/health_response.py create mode 100644 src/everyrow/generated/models/task_progress_info.py diff --git a/src/everyrow/generated/api/health/__init__.py b/src/everyrow/generated/api/health/__init__.py new file mode 100644 index 00000000..2d7c0b23 --- /dev/null +++ b/src/everyrow/generated/api/health/__init__.py @@ -0,0 +1 @@ +"""Contains endpoint functions for accessing the API""" diff --git a/src/everyrow/generated/api/health/health_health_get.py b/src/everyrow/generated/api/health/health_health_get.py new file mode 100644 index 00000000..51ce241b --- /dev/null +++ b/src/everyrow/generated/api/health/health_health_get.py @@ -0,0 +1,123 @@ +from http import HTTPStatus +from typing import Any + +import httpx + +from ... import errors +from ...client import AuthenticatedClient, Client +from ...models.health_response import HealthResponse +from ...types import Response + + +def _get_kwargs() -> dict[str, Any]: + _kwargs: dict[str, Any] = { + "method": "get", + "url": "/health", + } + + return _kwargs + + +def _parse_response(*, client: AuthenticatedClient | Client, response: httpx.Response) -> HealthResponse | None: + if response.status_code == 200: + response_200 = HealthResponse.from_dict(response.json()) + + return response_200 + + if client.raise_on_unexpected_status: + raise errors.UnexpectedStatus(response.status_code, response.content) + else: + return None + + +def _build_response(*, client: AuthenticatedClient | Client, response: httpx.Response) -> Response[HealthResponse]: + return Response( + status_code=HTTPStatus(response.status_code), + content=response.content, + headers=response.headers, + parsed=_parse_response(client=client, response=response), + ) + + +def sync_detailed( + *, + client: AuthenticatedClient | Client, +) -> Response[HealthResponse]: + """Health + + Raises: + errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. + httpx.TimeoutException: If the request takes longer than Client.timeout. + + Returns: + Response[HealthResponse] + """ + + kwargs = _get_kwargs() + + response = client.get_httpx_client().request( + **kwargs, + ) + + return _build_response(client=client, response=response) + + +def sync( + *, + client: AuthenticatedClient | Client, +) -> HealthResponse | None: + """Health + + Raises: + errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. + httpx.TimeoutException: If the request takes longer than Client.timeout. + + Returns: + HealthResponse + """ + + return sync_detailed( + client=client, + ).parsed + + +async def asyncio_detailed( + *, + client: AuthenticatedClient | Client, +) -> Response[HealthResponse]: + """Health + + Raises: + errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. + httpx.TimeoutException: If the request takes longer than Client.timeout. + + Returns: + Response[HealthResponse] + """ + + kwargs = _get_kwargs() + + response = await client.get_async_httpx_client().request(**kwargs) + + return _build_response(client=client, response=response) + + +async def asyncio( + *, + client: AuthenticatedClient | Client, +) -> HealthResponse | None: + """Health + + Raises: + errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. + httpx.TimeoutException: If the request takes longer than Client.timeout. + + Returns: + HealthResponse + """ + + return ( + await asyncio_detailed( + client=client, + ) + ).parsed diff --git a/src/everyrow/generated/api/operations/agent_map_operations_agent_map_post.py b/src/everyrow/generated/api/operations/agent_map_operations_agent_map_post.py index 81758fd1..806429e4 100644 --- a/src/everyrow/generated/api/operations/agent_map_operations_agent_map_post.py +++ b/src/everyrow/generated/api/operations/agent_map_operations_agent_map_post.py @@ -9,14 +9,17 @@ from ...models.error_response import ErrorResponse from ...models.insufficient_balance_error import InsufficientBalanceError from ...models.operation_response import OperationResponse -from ...types import Response +from ...types import UNSET, Response, Unset def _get_kwargs( *, body: AgentMapOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> dict[str, Any]: headers: dict[str, Any] = {} + if not isinstance(x_cohort_source, Unset): + headers["X-Cohort-Source"] = x_cohort_source _kwargs: dict[str, Any] = { "method": "post", @@ -70,6 +73,7 @@ def sync_detailed( *, client: AuthenticatedClient, body: AgentMapOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Parallel AI research agents @@ -82,6 +86,7 @@ def sync_detailed( `include_research` Args: + x_cohort_source (None | str | Unset): body (AgentMapOperation): Raises: @@ -94,6 +99,7 @@ def sync_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = client.get_httpx_client().request( @@ -107,6 +113,7 @@ def sync( *, client: AuthenticatedClient, body: AgentMapOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Parallel AI research agents @@ -119,6 +126,7 @@ def sync( `include_research` Args: + x_cohort_source (None | str | Unset): body (AgentMapOperation): Raises: @@ -132,6 +140,7 @@ def sync( return sync_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ).parsed @@ -139,6 +148,7 @@ async def asyncio_detailed( *, client: AuthenticatedClient, body: AgentMapOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Parallel AI research agents @@ -151,6 +161,7 @@ async def asyncio_detailed( `include_research` Args: + x_cohort_source (None | str | Unset): body (AgentMapOperation): Raises: @@ -163,6 +174,7 @@ async def asyncio_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = await client.get_async_httpx_client().request(**kwargs) @@ -174,6 +186,7 @@ async def asyncio( *, client: AuthenticatedClient, body: AgentMapOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Parallel AI research agents @@ -186,6 +199,7 @@ async def asyncio( `include_research` Args: + x_cohort_source (None | str | Unset): body (AgentMapOperation): Raises: @@ -200,5 +214,6 @@ async def asyncio( await asyncio_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ) ).parsed diff --git a/src/everyrow/generated/api/operations/dedupe_operations_dedupe_post.py b/src/everyrow/generated/api/operations/dedupe_operations_dedupe_post.py index 6037895d..a420cb21 100644 --- a/src/everyrow/generated/api/operations/dedupe_operations_dedupe_post.py +++ b/src/everyrow/generated/api/operations/dedupe_operations_dedupe_post.py @@ -9,14 +9,17 @@ from ...models.error_response import ErrorResponse from ...models.insufficient_balance_error import InsufficientBalanceError from ...models.operation_response import OperationResponse -from ...types import Response +from ...types import UNSET, Response, Unset def _get_kwargs( *, body: DedupeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> dict[str, Any]: headers: dict[str, Any] = {} + if not isinstance(x_cohort_source, Unset): + headers["X-Cohort-Source"] = x_cohort_source _kwargs: dict[str, Any] = { "method": "post", @@ -70,12 +73,14 @@ def sync_detailed( *, client: AuthenticatedClient, body: DedupeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """AI-powered deduplication Use AI to identify and remove duplicate rows based on the equivalence relation. Args: + x_cohort_source (None | str | Unset): body (DedupeOperation): Raises: @@ -88,6 +93,7 @@ def sync_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = client.get_httpx_client().request( @@ -101,12 +107,14 @@ def sync( *, client: AuthenticatedClient, body: DedupeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """AI-powered deduplication Use AI to identify and remove duplicate rows based on the equivalence relation. Args: + x_cohort_source (None | str | Unset): body (DedupeOperation): Raises: @@ -120,6 +128,7 @@ def sync( return sync_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ).parsed @@ -127,12 +136,14 @@ async def asyncio_detailed( *, client: AuthenticatedClient, body: DedupeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """AI-powered deduplication Use AI to identify and remove duplicate rows based on the equivalence relation. Args: + x_cohort_source (None | str | Unset): body (DedupeOperation): Raises: @@ -145,6 +156,7 @@ async def asyncio_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = await client.get_async_httpx_client().request(**kwargs) @@ -156,12 +168,14 @@ async def asyncio( *, client: AuthenticatedClient, body: DedupeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """AI-powered deduplication Use AI to identify and remove duplicate rows based on the equivalence relation. Args: + x_cohort_source (None | str | Unset): body (DedupeOperation): Raises: @@ -176,5 +190,6 @@ async def asyncio( await asyncio_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ) ).parsed diff --git a/src/everyrow/generated/api/operations/merge_operations_merge_post.py b/src/everyrow/generated/api/operations/merge_operations_merge_post.py index 189f8753..cf090b4f 100644 --- a/src/everyrow/generated/api/operations/merge_operations_merge_post.py +++ b/src/everyrow/generated/api/operations/merge_operations_merge_post.py @@ -9,14 +9,17 @@ from ...models.insufficient_balance_error import InsufficientBalanceError from ...models.merge_operation import MergeOperation from ...models.operation_response import OperationResponse -from ...types import Response +from ...types import UNSET, Response, Unset def _get_kwargs( *, body: MergeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> dict[str, Any]: headers: dict[str, Any] = {} + if not isinstance(x_cohort_source, Unset): + headers["X-Cohort-Source"] = x_cohort_source _kwargs: dict[str, Any] = { "method": "post", @@ -70,12 +73,14 @@ def sync_detailed( *, client: AuthenticatedClient, body: MergeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Semantic table join Use AI to semantically merge two tables based on task instructions. Args: + x_cohort_source (None | str | Unset): body (MergeOperation): Raises: @@ -88,6 +93,7 @@ def sync_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = client.get_httpx_client().request( @@ -101,12 +107,14 @@ def sync( *, client: AuthenticatedClient, body: MergeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Semantic table join Use AI to semantically merge two tables based on task instructions. Args: + x_cohort_source (None | str | Unset): body (MergeOperation): Raises: @@ -120,6 +128,7 @@ def sync( return sync_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ).parsed @@ -127,12 +136,14 @@ async def asyncio_detailed( *, client: AuthenticatedClient, body: MergeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Semantic table join Use AI to semantically merge two tables based on task instructions. Args: + x_cohort_source (None | str | Unset): body (MergeOperation): Raises: @@ -145,6 +156,7 @@ async def asyncio_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = await client.get_async_httpx_client().request(**kwargs) @@ -156,12 +168,14 @@ async def asyncio( *, client: AuthenticatedClient, body: MergeOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Semantic table join Use AI to semantically merge two tables based on task instructions. Args: + x_cohort_source (None | str | Unset): body (MergeOperation): Raises: @@ -176,5 +190,6 @@ async def asyncio( await asyncio_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ) ).parsed diff --git a/src/everyrow/generated/api/operations/rank_operations_rank_post.py b/src/everyrow/generated/api/operations/rank_operations_rank_post.py index 7bcfed5b..22a8626a 100644 --- a/src/everyrow/generated/api/operations/rank_operations_rank_post.py +++ b/src/everyrow/generated/api/operations/rank_operations_rank_post.py @@ -9,14 +9,17 @@ from ...models.insufficient_balance_error import InsufficientBalanceError from ...models.operation_response import OperationResponse from ...models.rank_operation import RankOperation -from ...types import Response +from ...types import UNSET, Response, Unset def _get_kwargs( *, body: RankOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> dict[str, Any]: headers: dict[str, Any] = {} + if not isinstance(x_cohort_source, Unset): + headers["X-Cohort-Source"] = x_cohort_source _kwargs: dict[str, Any] = { "method": "post", @@ -70,12 +73,14 @@ def sync_detailed( *, client: AuthenticatedClient, body: RankOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Score and sort rows with AI Use AI to score each row and sort results by the specified field. Args: + x_cohort_source (None | str | Unset): body (RankOperation): Raises: @@ -88,6 +93,7 @@ def sync_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = client.get_httpx_client().request( @@ -101,12 +107,14 @@ def sync( *, client: AuthenticatedClient, body: RankOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Score and sort rows with AI Use AI to score each row and sort results by the specified field. Args: + x_cohort_source (None | str | Unset): body (RankOperation): Raises: @@ -120,6 +128,7 @@ def sync( return sync_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ).parsed @@ -127,12 +136,14 @@ async def asyncio_detailed( *, client: AuthenticatedClient, body: RankOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Score and sort rows with AI Use AI to score each row and sort results by the specified field. Args: + x_cohort_source (None | str | Unset): body (RankOperation): Raises: @@ -145,6 +156,7 @@ async def asyncio_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = await client.get_async_httpx_client().request(**kwargs) @@ -156,12 +168,14 @@ async def asyncio( *, client: AuthenticatedClient, body: RankOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Score and sort rows with AI Use AI to score each row and sort results by the specified field. Args: + x_cohort_source (None | str | Unset): body (RankOperation): Raises: @@ -176,5 +190,6 @@ async def asyncio( await asyncio_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ) ).parsed diff --git a/src/everyrow/generated/api/operations/screen_operations_screen_post.py b/src/everyrow/generated/api/operations/screen_operations_screen_post.py index faa20806..3b8c6773 100644 --- a/src/everyrow/generated/api/operations/screen_operations_screen_post.py +++ b/src/everyrow/generated/api/operations/screen_operations_screen_post.py @@ -9,14 +9,17 @@ from ...models.insufficient_balance_error import InsufficientBalanceError from ...models.operation_response import OperationResponse from ...models.screen_operation import ScreenOperation -from ...types import Response +from ...types import UNSET, Response, Unset def _get_kwargs( *, body: ScreenOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> dict[str, Any]: headers: dict[str, Any] = {} + if not isinstance(x_cohort_source, Unset): + headers["X-Cohort-Source"] = x_cohort_source _kwargs: dict[str, Any] = { "method": "post", @@ -70,12 +73,14 @@ def sync_detailed( *, client: AuthenticatedClient, body: ScreenOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Filter rows with AI research Use AI to screen/filter each row based on the provided task instructions. Args: + x_cohort_source (None | str | Unset): body (ScreenOperation): Raises: @@ -88,6 +93,7 @@ def sync_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = client.get_httpx_client().request( @@ -101,12 +107,14 @@ def sync( *, client: AuthenticatedClient, body: ScreenOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Filter rows with AI research Use AI to screen/filter each row based on the provided task instructions. Args: + x_cohort_source (None | str | Unset): body (ScreenOperation): Raises: @@ -120,6 +128,7 @@ def sync( return sync_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ).parsed @@ -127,12 +136,14 @@ async def asyncio_detailed( *, client: AuthenticatedClient, body: ScreenOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Filter rows with AI research Use AI to screen/filter each row based on the provided task instructions. Args: + x_cohort_source (None | str | Unset): body (ScreenOperation): Raises: @@ -145,6 +156,7 @@ async def asyncio_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = await client.get_async_httpx_client().request(**kwargs) @@ -156,12 +168,14 @@ async def asyncio( *, client: AuthenticatedClient, body: ScreenOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Filter rows with AI research Use AI to screen/filter each row based on the provided task instructions. Args: + x_cohort_source (None | str | Unset): body (ScreenOperation): Raises: @@ -176,5 +190,6 @@ async def asyncio( await asyncio_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ) ).parsed diff --git a/src/everyrow/generated/api/operations/single_agent_operations_single_agent_post.py b/src/everyrow/generated/api/operations/single_agent_operations_single_agent_post.py index 492c98e5..18fcaf7c 100644 --- a/src/everyrow/generated/api/operations/single_agent_operations_single_agent_post.py +++ b/src/everyrow/generated/api/operations/single_agent_operations_single_agent_post.py @@ -9,14 +9,17 @@ from ...models.insufficient_balance_error import InsufficientBalanceError from ...models.operation_response import OperationResponse from ...models.single_agent_operation import SingleAgentOperation -from ...types import Response +from ...types import UNSET, Response, Unset def _get_kwargs( *, body: SingleAgentOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> dict[str, Any]: headers: dict[str, Any] = {} + if not isinstance(x_cohort_source, Unset): + headers["X-Cohort-Source"] = x_cohort_source _kwargs: dict[str, Any] = { "method": "post", @@ -70,6 +73,7 @@ def sync_detailed( *, client: AuthenticatedClient, body: SingleAgentOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Single AI research agent @@ -90,6 +94,7 @@ def sync_detailed( You cannot mix these approaches - either use a preset OR specify all custom parameters. Args: + x_cohort_source (None | str | Unset): body (SingleAgentOperation): Raises: @@ -102,6 +107,7 @@ def sync_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = client.get_httpx_client().request( @@ -115,6 +121,7 @@ def sync( *, client: AuthenticatedClient, body: SingleAgentOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Single AI research agent @@ -135,6 +142,7 @@ def sync( You cannot mix these approaches - either use a preset OR specify all custom parameters. Args: + x_cohort_source (None | str | Unset): body (SingleAgentOperation): Raises: @@ -148,6 +156,7 @@ def sync( return sync_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ).parsed @@ -155,6 +164,7 @@ async def asyncio_detailed( *, client: AuthenticatedClient, body: SingleAgentOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> Response[ErrorResponse | InsufficientBalanceError | OperationResponse]: """Single AI research agent @@ -175,6 +185,7 @@ async def asyncio_detailed( You cannot mix these approaches - either use a preset OR specify all custom parameters. Args: + x_cohort_source (None | str | Unset): body (SingleAgentOperation): Raises: @@ -187,6 +198,7 @@ async def asyncio_detailed( kwargs = _get_kwargs( body=body, + x_cohort_source=x_cohort_source, ) response = await client.get_async_httpx_client().request(**kwargs) @@ -198,6 +210,7 @@ async def asyncio( *, client: AuthenticatedClient, body: SingleAgentOperation, + x_cohort_source: None | str | Unset = UNSET, ) -> ErrorResponse | InsufficientBalanceError | OperationResponse | None: """Single AI research agent @@ -218,6 +231,7 @@ async def asyncio( You cannot mix these approaches - either use a preset OR specify all custom parameters. Args: + x_cohort_source (None | str | Unset): body (SingleAgentOperation): Raises: @@ -232,5 +246,6 @@ async def asyncio( await asyncio_detailed( client=client, body=body, + x_cohort_source=x_cohort_source, ) ).parsed diff --git a/src/everyrow/generated/models/__init__.py b/src/everyrow/generated/models/__init__.py index 051f4c6e..311717c4 100644 --- a/src/everyrow/generated/models/__init__.py +++ b/src/everyrow/generated/models/__init__.py @@ -3,9 +3,7 @@ from .agent_map_operation import AgentMapOperation from .agent_map_operation_input_type_1_item import AgentMapOperationInputType1Item from .agent_map_operation_input_type_2 import AgentMapOperationInputType2 -from .agent_map_operation_response_schema_type_0 import ( - AgentMapOperationResponseSchemaType0, -) +from .agent_map_operation_response_schema_type_0 import AgentMapOperationResponseSchemaType0 from .billing_response import BillingResponse from .create_artifact_request import CreateArtifactRequest from .create_artifact_request_data_type_0_item import CreateArtifactRequestDataType0Item @@ -18,6 +16,7 @@ from .dedupe_operation_strategy import DedupeOperationStrategy from .error_response import ErrorResponse from .error_response_details_type_0 import ErrorResponseDetailsType0 +from .health_response import HealthResponse from .http_validation_error import HTTPValidationError from .insufficient_balance_error import InsufficientBalanceError from .llm_enum_public import LLMEnumPublic @@ -25,8 +24,8 @@ from .merge_operation import MergeOperation from .merge_operation_left_input_type_1_item import MergeOperationLeftInputType1Item from .merge_operation_left_input_type_2 import MergeOperationLeftInputType2 -from .merge_operation_right_input_type_1_item import MergeOperationRightInputType1Item from .merge_operation_relationship_type_type_0 import MergeOperationRelationshipTypeType0 +from .merge_operation_right_input_type_1_item import MergeOperationRightInputType1Item from .merge_operation_right_input_type_2 import MergeOperationRightInputType2 from .merge_operation_use_web_search_type_0 import MergeOperationUseWebSearchType0 from .operation_response import OperationResponse @@ -44,9 +43,8 @@ from .single_agent_operation import SingleAgentOperation from .single_agent_operation_input_type_1_item import SingleAgentOperationInputType1Item from .single_agent_operation_input_type_2 import SingleAgentOperationInputType2 -from .single_agent_operation_response_schema_type_0 import ( - SingleAgentOperationResponseSchemaType0, -) +from .single_agent_operation_response_schema_type_0 import SingleAgentOperationResponseSchemaType0 +from .task_progress_info import TaskProgressInfo from .task_result_response import TaskResultResponse from .task_result_response_data_type_0_item import TaskResultResponseDataType0Item from .task_result_response_data_type_1 import TaskResultResponseDataType1 @@ -72,6 +70,7 @@ "DedupeOperationStrategy", "ErrorResponse", "ErrorResponseDetailsType0", + "HealthResponse", "HTTPValidationError", "InsufficientBalanceError", "LLMEnumPublic", @@ -79,8 +78,8 @@ "MergeOperation", "MergeOperationLeftInputType1Item", "MergeOperationLeftInputType2", - "MergeOperationRightInputType1Item", "MergeOperationRelationshipTypeType0", + "MergeOperationRightInputType1Item", "MergeOperationRightInputType2", "MergeOperationUseWebSearchType0", "OperationResponse", @@ -99,6 +98,7 @@ "SingleAgentOperationInputType1Item", "SingleAgentOperationInputType2", "SingleAgentOperationResponseSchemaType0", + "TaskProgressInfo", "TaskResultResponse", "TaskResultResponseDataType0Item", "TaskResultResponseDataType1", diff --git a/src/everyrow/generated/models/health_response.py b/src/everyrow/generated/models/health_response.py new file mode 100644 index 00000000..38d7f790 --- /dev/null +++ b/src/everyrow/generated/models/health_response.py @@ -0,0 +1,61 @@ +from __future__ import annotations + +from collections.abc import Mapping +from typing import Any, TypeVar + +from attrs import define as _attrs_define +from attrs import field as _attrs_field + +from ..types import UNSET, Unset + +T = TypeVar("T", bound="HealthResponse") + + +@_attrs_define +class HealthResponse: + """ + Attributes: + status (str | Unset): Default: 'ok'. + """ + + status: str | Unset = "ok" + additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict) + + def to_dict(self) -> dict[str, Any]: + status = self.status + + field_dict: dict[str, Any] = {} + field_dict.update(self.additional_properties) + field_dict.update({}) + if status is not UNSET: + field_dict["status"] = status + + return field_dict + + @classmethod + def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T: + d = dict(src_dict) + status = d.pop("status", UNSET) + + health_response = cls( + status=status, + ) + + health_response.additional_properties = d + return health_response + + @property + def additional_keys(self) -> list[str]: + return list(self.additional_properties.keys()) + + def __getitem__(self, key: str) -> Any: + return self.additional_properties[key] + + def __setitem__(self, key: str, value: Any) -> None: + self.additional_properties[key] = value + + def __delitem__(self, key: str) -> None: + del self.additional_properties[key] + + def __contains__(self, key: str) -> bool: + return key in self.additional_properties diff --git a/src/everyrow/generated/models/merge_operation.py b/src/everyrow/generated/models/merge_operation.py index f80e1e6b..01fca9df 100644 --- a/src/everyrow/generated/models/merge_operation.py +++ b/src/everyrow/generated/models/merge_operation.py @@ -1,7 +1,6 @@ from __future__ import annotations from collections.abc import Mapping -from everyrow.generated.types import Unset from typing import TYPE_CHECKING, Any, TypeVar, cast from uuid import UUID @@ -36,9 +35,9 @@ class MergeOperation: use_web_search (MergeOperationUseWebSearchType0 | None | Unset): Control web search behavior: 'auto' (default) tries LLM merge first then conditionally searches, 'no' skips web search entirely, 'yes' forces web search without initial LLM merge Default: MergeOperationUseWebSearchType0.AUTO. - relationship_type (MergeOperationRelationshipTypeType0 | None | Unset): Control relationship type: - 'many_to_one' (default) allows multiple left rows to match one right row, - 'one_to_one' enforces unique matching between left and right rows. + relationship_type (MergeOperationRelationshipTypeType0 | None | Unset): Control merge relationship behavior: + 'many_to_one' (default) allows multiple left rows to match the same right row, 'one_to_one' enforces unique + matches and resolves clashes Default: MergeOperationRelationshipTypeType0.MANY_TO_ONE. session_id (None | Unset | UUID): Session ID. If not provided, a new session is auto-created for this task. """ @@ -48,7 +47,9 @@ class MergeOperation: left_key: None | str | Unset = UNSET right_key: None | str | Unset = UNSET use_web_search: MergeOperationUseWebSearchType0 | None | Unset = MergeOperationUseWebSearchType0.AUTO - relationship_type: MergeOperationRelationshipTypeType0 | None | Unset = UNSET + relationship_type: MergeOperationRelationshipTypeType0 | None | Unset = ( + MergeOperationRelationshipTypeType0.MANY_TO_ONE + ) session_id: None | Unset | UUID = UNSET additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict) diff --git a/src/everyrow/generated/models/task_progress_info.py b/src/everyrow/generated/models/task_progress_info.py new file mode 100644 index 00000000..e3f7c39c --- /dev/null +++ b/src/everyrow/generated/models/task_progress_info.py @@ -0,0 +1,93 @@ +from __future__ import annotations + +from collections.abc import Mapping +from typing import Any, TypeVar + +from attrs import define as _attrs_define +from attrs import field as _attrs_field + +T = TypeVar("T", bound="TaskProgressInfo") + + +@_attrs_define +class TaskProgressInfo: + """ + Attributes: + pending (int): Number of subtasks pending + running (int): Number of subtasks currently running + completed (int): Number of subtasks completed + failed (int): Number of subtasks failed + total (int): Total number of subtasks + """ + + pending: int + running: int + completed: int + failed: int + total: int + additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict) + + def to_dict(self) -> dict[str, Any]: + pending = self.pending + + running = self.running + + completed = self.completed + + failed = self.failed + + total = self.total + + field_dict: dict[str, Any] = {} + field_dict.update(self.additional_properties) + field_dict.update( + { + "pending": pending, + "running": running, + "completed": completed, + "failed": failed, + "total": total, + } + ) + + return field_dict + + @classmethod + def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T: + d = dict(src_dict) + pending = d.pop("pending") + + running = d.pop("running") + + completed = d.pop("completed") + + failed = d.pop("failed") + + total = d.pop("total") + + task_progress_info = cls( + pending=pending, + running=running, + completed=completed, + failed=failed, + total=total, + ) + + task_progress_info.additional_properties = d + return task_progress_info + + @property + def additional_keys(self) -> list[str]: + return list(self.additional_properties.keys()) + + def __getitem__(self, key: str) -> Any: + return self.additional_properties[key] + + def __setitem__(self, key: str, value: Any) -> None: + self.additional_properties[key] = value + + def __delitem__(self, key: str) -> None: + del self.additional_properties[key] + + def __contains__(self, key: str) -> bool: + return key in self.additional_properties diff --git a/src/everyrow/generated/models/task_status_response.py b/src/everyrow/generated/models/task_status_response.py index 5358534e..81a9adbb 100644 --- a/src/everyrow/generated/models/task_status_response.py +++ b/src/everyrow/generated/models/task_status_response.py @@ -2,7 +2,7 @@ import datetime from collections.abc import Mapping -from typing import Any, TypeVar, cast +from typing import TYPE_CHECKING, Any, TypeVar, cast from uuid import UUID from attrs import define as _attrs_define @@ -13,6 +13,10 @@ from ..models.task_status import TaskStatus from ..types import UNSET, Unset +if TYPE_CHECKING: + from ..models.task_progress_info import TaskProgressInfo + + T = TypeVar("T", bound="TaskStatusResponse") @@ -26,6 +30,7 @@ class TaskStatusResponse: task_type (PublicTaskType): created_at (datetime.datetime | None): When the task was created updated_at (datetime.datetime | None): When the task was last updated + progress (None | TaskProgressInfo): Subtask progress counts (available while task is running) artifact_id (None | Unset | UUID): Result artifact ID (if the task completed) error (None | str | Unset): Error message (if the task failed) """ @@ -36,11 +41,14 @@ class TaskStatusResponse: task_type: PublicTaskType created_at: datetime.datetime | None updated_at: datetime.datetime | None + progress: None | TaskProgressInfo artifact_id: None | Unset | UUID = UNSET error: None | str | Unset = UNSET additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict) def to_dict(self) -> dict[str, Any]: + from ..models.task_progress_info import TaskProgressInfo + task_id = str(self.task_id) session_id = str(self.session_id) @@ -61,6 +69,12 @@ def to_dict(self) -> dict[str, Any]: else: updated_at = self.updated_at + progress: dict[str, Any] | None + if isinstance(self.progress, TaskProgressInfo): + progress = self.progress.to_dict() + else: + progress = self.progress + artifact_id: None | str | Unset if isinstance(self.artifact_id, Unset): artifact_id = UNSET @@ -85,6 +99,7 @@ def to_dict(self) -> dict[str, Any]: "task_type": task_type, "created_at": created_at, "updated_at": updated_at, + "progress": progress, } ) if artifact_id is not UNSET: @@ -96,6 +111,8 @@ def to_dict(self) -> dict[str, Any]: @classmethod def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T: + from ..models.task_progress_info import TaskProgressInfo + d = dict(src_dict) task_id = UUID(d.pop("task_id")) @@ -135,6 +152,21 @@ def _parse_updated_at(data: object) -> datetime.datetime | None: updated_at = _parse_updated_at(d.pop("updated_at")) + def _parse_progress(data: object) -> None | TaskProgressInfo: + if data is None: + return data + try: + if not isinstance(data, dict): + raise TypeError() + progress_type_0 = TaskProgressInfo.from_dict(data) + + return progress_type_0 + except (TypeError, ValueError, AttributeError, KeyError): + pass + return cast(None | TaskProgressInfo, data) + + progress = _parse_progress(d.pop("progress")) + def _parse_artifact_id(data: object) -> None | Unset | UUID: if data is None: return data @@ -168,6 +200,7 @@ def _parse_error(data: object) -> None | str | Unset: task_type=task_type, created_at=created_at, updated_at=updated_at, + progress=progress, artifact_id=artifact_id, error=error, ) From dfe0c56d77bf1c3ff009cb168d57d6e87bee254c Mon Sep 17 00:00:00 2001 From: Robert Gambee Date: Thu, 12 Feb 2026 13:14:55 -0500 Subject: [PATCH 2/2] Update tests --- tests/test_ops.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/test_ops.py b/tests/test_ops.py index 9a00eabe..2f3c6ac2 100644 --- a/tests/test_ops.py +++ b/tests/test_ops.py @@ -56,6 +56,7 @@ def _make_status_response( created_at=datetime.now(), updated_at=datetime.now(), artifact_id=artifact_id, + progress=None, )