{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/tool-planner-dynamic-solution-tree-planning","title":"Tool-Planner: Task Planning with Clusters across Multiple Tools","arxiv_id":"2406.03807","date":"2024-06-06","proceeding":null,"authors":["Yanming Liu","Xinyue Peng","Jiannan Cao","Shi Bo","Yuwei Zhang","Xuhong Zhang","Sheng Cheng","Xun Wang","Jianwei Yin","Tianyu Du"],"abstract":"Large language models (LLMs) have demonstrated exceptional reasoning capabilities, enabling them to solve various complex problems. Recently, this ability has been applied to the paradigm of tool learning. Tool learning involves providing examples of tool usage and their corresponding functions, allowing LLMs to formulate plans and demonstrate the process of invoking and executing each tool. LLMs can address tasks that they cannot complete independently, thereby enhancing their potential across different tasks. However, this approach faces two key challenges. First, redundant error correction leads to unstable planning and long execution time. Additionally, designing a correct plan among multiple tools is also a challenge in tool learning. To address these issues, we propose Tool-Planner, a task-processing framework based on toolkits. Tool-Planner groups tools based on the API functions with the same function into a toolkit and allows LLMs to implement planning across the various toolkits. When a tool error occurs, the language model can reselect and adjust tools based on the toolkit. Experiments show that our approach demonstrates a high pass and win rate across different datasets and optimizes the planning scheme for tool learning in models such as GPT-4 and Claude 3, showcasing the potential of our method. Our code is public at https://github.com/OceannTwT/Tool-Planner","url_abs":"https://arxiv.org/abs/2406.03807v3","url_pdf":"https://arxiv.org/pdf/2406.03807v3.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"tool-planner-dynamic-solution-tree-planning","repo_url":"https://github.com/OceannTwT/Tool-Planner","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"language-modelling","task_name":"Language Modelling"},{"task_slug":"large-language-model","task_name":"Large Language Model"},{"task_slug":"task-planning","task_name":"Task Planning"}],"methods":[{"method_slug":"absolute-position-encodings","method_name":"Absolute Position Encodings"},{"method_slug":"adam","method_name":"Adam"},{"method_slug":"attention","method_name":"Attention"},{"method_slug":"bpe","method_name":"BPE"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"dropout","method_name":"Dropout"},{"method_slug":"gpt-4","method_name":"GPT-4"},{"method_slug":"label-smoothing","method_name":"Label Smoothing"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"position-wise-feed-forward-layer","method_name":"Position-Wise Feed-Forward Layer"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"transformer","method_name":"Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":null,"atlas_url":"https://app.syntology.ai/?focus=2406.03807","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2406.03807"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"deterministic:regex_extraction","url":"https://github.com/OceannTwT/Tool-Planner","reach":null}],"summary":{"ran":1,"ran_draft_wrong":6,"unverified":2},"by_repo_kind":{"official":{"samples":9,"ran":7,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":9,"samples":[{"code_sha256_prefix":"bc6b848d2561696b","entry":"GPTFactory","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"bc6b848d2561696b"}},{"code_sha256_prefix":"8f703b078a43ac66","entry":"api_json_to_openai_json","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"8f703b078a43ac66"}},{"code_sha256_prefix":"54a81f9e2f2a53e7","entry":"call_toolbench","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"54a81f9e2f2a53e7"}},{"code_sha256_prefix":"7b6b723a33f5ea2a","entry":"change_name","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"7b6b723a33f5ea2a"}},{"code_sha256_prefix":"d736a3eedbd124d9","entry":"chat_completion_request","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"d736a3eedbd124d9"}},{"code_sha256_prefix":"1fef96553cdda752","entry":"fetch_api_json","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1fef96553cdda752"}},{"code_sha256_prefix":"e6d1b09cb3624d3f","entry":"standardize","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"e6d1b09cb3624d3f"}},{"code_sha256_prefix":"cd04f70a6a050a52","entry":"PlannerProcessor","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"cd04f70a6a050a52"}},{"code_sha256_prefix":"5d7af7ec7a3dc062","entry":"parse_arguments","repo":"OceannTwT/Tool-Planner","repo_kind":"official","path":"src/planner/plan.py","file_url":"https://github.com/OceannTwT/Tool-Planner/blob/HEAD/src/planner/plan.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"5d7af7ec7a3dc062"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}