Skip to content

Commit

Permalink
file_creation
Browse files Browse the repository at this point in the history
  • Loading branch information
femto committed Oct 17, 2024
1 parent d1541a4 commit 8ae4c8b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
3 changes: 2 additions & 1 deletion examples/smart_minion/gsm8k/evalute_gsm8k_re2.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,8 @@ async def load_data_sample(file_path: str, samples=1) -> List[dict]:


async def main():
file_name = "gsm8k_test.json"
current_dir = os.path.dirname(os.path.abspath(__file__))
file_name = os.path.join(current_dir, "gsm8k_test.jsonl")
data = load_jsonl(file_name)
# data = await load_data_sample(file_name, samples=1055)

Expand Down
7 changes: 0 additions & 7 deletions metagpt/minion/worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -641,13 +641,6 @@ def save_files(self, file_structure):
f.write(content)


# 在其他地方使用PythonMinion时,根据需要设置query_type
self.input.query_type = "calculate" # 对于数学问题
self.input.query_type = "code_solution" # 对于代码生成问题
self.input.query_type = "file_creation" # 对于文件创建问题
python_minion = PythonMinion(input=self.input, brain=self.brain)


@register_route_downstream
class MathMinion(PythonMinion):
"This is a problem involve math, you need to use math tool to solve it"
Expand Down

0 comments on commit 8ae4c8b

Please sign in to comment.