Skip to content

Commit c8ddfe2

Browse files
Unshuredbschmigelski
authored andcommitted
fix: Move AgentInput to types submodule (strands-agents#746)
1 parent f286fc7 commit c8ddfe2

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

src/strands/agent/agent.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
Mapping,
2323
Optional,
2424
Type,
25-
TypeAlias,
2625
TypeVar,
2726
Union,
2827
cast,
@@ -51,6 +50,7 @@
5150
from ..tools.executors._executor import ToolExecutor
5251
from ..tools.registry import ToolRegistry
5352
from ..tools.watcher import ToolWatcher
53+
from ..types.agent import AgentInput
5454
from ..types.content import ContentBlock, Message, Messages
5555
from ..types.exceptions import ContextWindowOverflowException
5656
from ..types.tools import ToolResult, ToolUse
@@ -67,8 +67,6 @@
6767
# TypeVar for generic structured output
6868
T = TypeVar("T", bound=BaseModel)
6969

70-
AgentInput: TypeAlias = str | list[ContentBlock] | Messages | None
71-
7270

7371
# Sentinel class and object to distinguish between explicit None and default parameter value
7472
class _DefaultCallbackHandlerSentinel:

src/strands/types/agent.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
"""Agent-related type definitions for the SDK.
2+
3+
This module defines the types used for an Agent.
4+
"""
5+
6+
from typing import TypeAlias
7+
8+
from .content import ContentBlock, Messages
9+
10+
AgentInput: TypeAlias = str | list[ContentBlock] | Messages | None

0 commit comments

Comments
 (0)