mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-06-08 15:05:17 +02:00
can change timeout through data.yaml
This commit is contained in:
parent
f80ebc4d67
commit
2fc8f20de6
2 changed files with 3 additions and 2 deletions
|
|
@ -1,3 +1,4 @@
|
|||
datasets_dir: "D:/work/automl/datasets" # path to the datasets directory
|
||||
work_dir: ../workspace # path to the workspace directory
|
||||
role_dir: storage/SELA # path to the role directory
|
||||
role_timeout: 1000 # timeout for each node/role in seconds
|
||||
|
|
@ -6,7 +6,7 @@ import os
|
|||
|
||||
from pydantic import model_validator
|
||||
|
||||
from expo.utils import mcts_logger, save_notebook
|
||||
from expo.utils import DATA_CONFIG, mcts_logger, save_notebook
|
||||
from metagpt.actions.di.write_analysis_code import WriteAnalysisCode
|
||||
from metagpt.const import SERDESER_PATH
|
||||
from metagpt.roles.di.data_interpreter import DataInterpreter
|
||||
|
|
@ -163,7 +163,7 @@ class ResearchAssistant(DataInterpreter):
|
|||
self.planner.plan.task_map[task_id] for task_id in sorted(self.planner.plan.task_map.keys())
|
||||
]
|
||||
|
||||
@async_timeout(1000)
|
||||
@async_timeout(DATA_CONFIG["role_timeout"])
|
||||
@role_raise_decorator
|
||||
async def run(self, with_message=None) -> Message | None:
|
||||
"""Observe, and think and act based on the results of the observation"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue