goose-py 0.1.2__tar.gz → 0.1.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {goose_py-0.1.2 → goose_py-0.1.4}/PKG-INFO +1 -1
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/agent.py +3 -2
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/core.py +2 -1
- {goose_py-0.1.2 → goose_py-0.1.4}/pyproject.toml +1 -1
- {goose_py-0.1.2 → goose_py-0.1.4}/README.md +0 -0
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/__init__.py +0 -0
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/conversation.py +0 -0
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/errors.py +0 -0
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/py.typed +0 -0
- {goose_py-0.1.2 → goose_py-0.1.4}/goose/types.py +0 -0
@@ -1,5 +1,4 @@
|
|
1
1
|
import logging
|
2
|
-
import uuid
|
3
2
|
from datetime import datetime
|
4
3
|
from typing import Any, Callable
|
5
4
|
|
@@ -20,9 +19,11 @@ class Agent:
|
|
20
19
|
self,
|
21
20
|
*,
|
22
21
|
flow_name: str,
|
22
|
+
run_id: str,
|
23
23
|
logger: Callable[[AgentResponse[Any]], None] | None = None,
|
24
24
|
) -> None:
|
25
25
|
self.flow_name = flow_name
|
26
|
+
self.run_id = run_id
|
26
27
|
self.logger = logger or logging.info
|
27
28
|
|
28
29
|
async def __call__[R: BaseModel](
|
@@ -58,7 +59,7 @@ class Agent:
|
|
58
59
|
end_time = datetime.now()
|
59
60
|
agent_response = AgentResponse(
|
60
61
|
response=parsed_response,
|
61
|
-
id=
|
62
|
+
id=self.run_id,
|
62
63
|
flow_name=self.flow_name,
|
63
64
|
task_name=task_name,
|
64
65
|
model=model,
|
@@ -177,11 +177,12 @@ class Flow:
|
|
177
177
|
self,
|
178
178
|
*,
|
179
179
|
name: str,
|
180
|
+
run_id: str,
|
180
181
|
agent_logger: Callable[[AgentResponse[Any]], None] | None = None,
|
181
182
|
) -> None:
|
182
183
|
self.name = name
|
183
184
|
self._nodes: list[Node[BaseModel]] = []
|
184
|
-
self._agent = Agent(flow_name=self.name, logger=agent_logger)
|
185
|
+
self._agent = Agent(flow_name=self.name, run_id=run_id, logger=agent_logger)
|
185
186
|
|
186
187
|
@property
|
187
188
|
def agent(self) -> Agent:
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|