mirror of
https://github.com/hwchase17/langchain.git
synced 2026-03-18 19:18:48 +00:00
should be no functional changes also keep __init__ exposing a lot for backwards compat --------- Co-authored-by: Dev 2049 <dev.dev2049@gmail.com> Co-authored-by: Bagatur <baskaryan@gmail.com>
26 lines
643 B
Python
26 lines
643 B
Python
from __future__ import annotations
|
|
|
|
from dataclasses import dataclass
|
|
from typing import NamedTuple, Union
|
|
|
|
|
|
@dataclass
|
|
class AgentAction:
|
|
"""A full description of an action for an ActionAgent to execute."""
|
|
|
|
tool: str
|
|
"""The name of the Tool to execute."""
|
|
tool_input: Union[str, dict]
|
|
"""The input to pass in to the Tool."""
|
|
log: str
|
|
"""Additional information to log about the action."""
|
|
|
|
|
|
class AgentFinish(NamedTuple):
|
|
"""The final return value of an ActionAgent."""
|
|
|
|
return_values: dict
|
|
"""Dictionary of return values."""
|
|
log: str
|
|
"""Additional information to log about the return value"""
|