Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
Signed-off-by: Kevin Su <[email protected]>
  • Loading branch information
pingsutw committed Mar 28, 2024
1 parent 30d6be0 commit aadcae3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
10 changes: 6 additions & 4 deletions docs/flyte_agents/developing_agents.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,11 @@ To create a new async agent, extend the [`AsyncAgentBase`](https://github.com/fl

```python
from typing import Optional
from flytekit.extend.backend.base_agent import AsyncAgentBase, AgentRegistry, Resource, ResourceMeta
from dataclasses import dataclass
from flytekit.models.literals import LiteralMap
from flytekit.models.task import TaskTemplate
from flytekit.extend.backend.base_agent import AsyncAgentBase, AgentRegistry, Resource, ResourceMeta


@dataclass
class BigQueryMetadata(ResourceMeta):
Expand Down Expand Up @@ -89,12 +90,13 @@ To create a new sync agent, extend the [`SyncAgentBase`](https://github.com/flyt

```python
from typing import Optional
from flytekit import FlyteContextManager
from flytekit.core.type_engine import TypeEngine
from flyteidl.core.execution_pb2 import TaskExecution
from flytekit.extend.backend.base_agent import SyncAgentBase, AgentRegistry, Resource
from flytekit.models.literals import LiteralMap
from flytekit.models.task import TaskTemplate
from flytekit import FlyteContextManager
from flytekit.core.type_engine import TypeEngine
from flytekit.extend.backend.base_agent import SyncAgentBase, AgentRegistry, Resource


class OpenAIAgent(SyncAgentBase):
def __init__(self):
Expand Down
2 changes: 1 addition & 1 deletion docs/flyte_agents/testing_agents_locally.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jupytext:
You can test agents locally without running the backend server, making agent development easier.

To test an agent locally, create a class for the agent task that inherits from `SyncAgentExecutorMixin` or `AsyncAgentExecutorMixin`.
These mixins can handle synchronous and asynchronous tasks respectively and allows flytekit to mimic FlytePropeller's behavior in calling the agent.
These mixins can handle synchronous and asynchronous tasks, respectively, and allow flytekit to mimic FlytePropeller's behavior in calling the agent.

## BigQuery example

Expand Down

0 comments on commit aadcae3

Please sign in to comment.