Spaces:
Sleeping
Sleeping
Update app.py
Browse files10 unmodified lines11121314151617181920212232 unmodified lines5556575859606110 unmodified lines@tooldef my_custom_tool(arg1:str, arg2:int)-> str: #it's import to specify the return type#Keep this format for the description / args / args description but feel free to modify the tool"""A tool that does nothing yetArgs:arg1: the first argumentarg2: the second argument"""return "What magic will you build ?"@tooldef get_current_time_in_timezone(timezone: str) -> str:32 unmodified linesagent = CodeAgent(model=model,tools=[final_answer], ## add your tools here (don't remove final answer)max_steps=6,verbosity_level=1,grammar=None,10 unmodified lines111213141516171819202122232425262732 unmodified lines6061626364656610 unmodified lines@tooldef my_custom_tool(arg1:str, arg2:int)-> str: #it's import to specify the return type#Keep this format for the description / args / args description but feel free to modify the tool"""A tool that outputs arg1 N times joined with '-', where N is arg2.Args:arg1: the string to outputarg2: the number of times"""result = ""for range(arg2):if len(result) > 0:result += "-"result += arg1return result@tooldef get_current_time_in_timezone(timezone: str) -> str:32 unmodified linesagent = CodeAgent(model=model,tools=[final_answer, get_current_time_in_timezone, image_generation_tool, my_custom_tool], ## add your tools here (don't remove final answer)max_steps=6,verbosity_level=1,grammar=None,
app.py+10-5