Skip to content
Merged
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
38 changes: 19 additions & 19 deletions fasta2a/fasta2a/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from typing_extensions import NotRequired, TypeAlias, TypedDict


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class AgentCard(TypedDict):
"""The card that describes an agent."""

Expand Down Expand Up @@ -66,7 +66,7 @@ class Provider(TypedDict):
url: str


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class Capabilities(TypedDict):
"""The capabilities of the agent."""

Expand All @@ -80,7 +80,7 @@ class Capabilities(TypedDict):
"""Whether the agent exposes status change history for tasks."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class Authentication(TypedDict):
"""The authentication schemes supported by the agent."""

Expand All @@ -91,7 +91,7 @@ class Authentication(TypedDict):
"""The credentials a client should use for private cards."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class Skill(TypedDict):
"""Skills are a unit of capability that an agent can perform."""

Expand Down Expand Up @@ -126,7 +126,7 @@ class Skill(TypedDict):
"""Supported mime types for output data."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class Artifact(TypedDict):
"""Agents generate Artifacts as an end result of a Task.

Expand Down Expand Up @@ -159,7 +159,7 @@ class Artifact(TypedDict):
"""Whether this is the last chunk of the artifact."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class PushNotificationConfig(TypedDict):
"""Configuration for push notifications.

Expand Down Expand Up @@ -193,7 +193,7 @@ class PushNotificationConfig(TypedDict):
"""Authentication details for push notifications."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskPushNotificationConfig(TypedDict):
"""Configuration for task push notifications."""

Expand Down Expand Up @@ -242,7 +242,7 @@ class TextPart(_BasePart):
"""The text of the part."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class FilePart(_BasePart):
"""A part that contains a file."""

Expand All @@ -253,7 +253,7 @@ class FilePart(_BasePart):
"""The file of the part."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class _BaseFile(_BasePart):
"""A base class for all file types."""

Expand All @@ -264,15 +264,15 @@ class _BaseFile(_BasePart):
"""The mime type of the file."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class _BinaryFile(_BaseFile):
"""A binary file."""

data: str
"""The base64 encoded bytes of the file."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class _URLFile(_BaseFile):
"""A file that is hosted on a remote URL."""

Expand All @@ -284,7 +284,7 @@ class _URLFile(_BaseFile):
"""A file is a binary file or a URL file."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class DataPart(_BasePart):
"""A part that contains data."""

Expand All @@ -305,7 +305,7 @@ class DataPart(_BasePart):
"""The possible states of a task."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskStatus(TypedDict):
"""Status and accompanying message for a task."""

Expand All @@ -319,7 +319,7 @@ class TaskStatus(TypedDict):
"""ISO datetime value of when the status was updated."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class Task(TypedDict):
"""A Task is a stateful entity that allows Clients and Remote Agents to achieve a specific outcome.

Expand All @@ -346,7 +346,7 @@ class Task(TypedDict):
"""Extension metadata."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskStatusUpdateEvent(TypedDict):
"""Sent by server during sendSubscribe or subscribe requests."""

Expand All @@ -363,7 +363,7 @@ class TaskStatusUpdateEvent(TypedDict):
"""Extension metadata."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskArtifactUpdateEvent(TypedDict):
"""Sent by server during sendSubscribe or subscribe requests."""

Expand All @@ -377,23 +377,23 @@ class TaskArtifactUpdateEvent(TypedDict):
"""Extension metadata."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskIdParams(TypedDict):
"""Parameters for a task id."""

id: str
metadata: NotRequired[dict[str, Any]]


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskQueryParams(TaskIdParams):
"""Query parameters for a task."""

history_length: NotRequired[int]
"""Number of recent messages to be retrieved."""


@pydantic.with_config(config={'alias_generator': to_camel})
@pydantic.with_config({'alias_generator': to_camel})
class TaskSendParams(TypedDict):
"""Sent by the client to the agent to create, continue, or restart a task."""

Expand Down