[論文レビュー] ToolWeaver: Weaving Collaborative Semantics for Scalable Tool Use in Large Language Models
ToolWeaver は協調意識を取り入れたトークン化により階層的な構成ツールコードを学習し、LLMでのツール利用を拡張可能かつ一般化可能にする。ToolBenchで最先端を上回る。
Prevalent retrieval-based tool-use pipelines struggle with a dual semantic challenge: their retrievers often employ encoders that fail to capture complex semantics, while the Large Language Model (LLM) itself lacks intrinsic tool knowledge from its natural language pretraining. Generative methods offer a powerful alternative by unifying selection and execution, tasking the LLM to directly learn and generate tool identifiers. However, the common practice of mapping each tool to a unique new token introduces substantial limitations: it creates a scalability and generalization crisis, as the vocabulary size explodes and each tool is assigned a semantically isolated token. This approach also creates a semantic bottleneck that hinders the learning of collaborative tool relationships, as the model must infer them from sparse co-occurrences of monolithic tool IDs within a vast library. To address these limitations, we propose ToolWeaver, a novel generative tool learning framework that encodes tools into hierarchical sequences. This approach makes vocabulary expansion logarithmic to the number of tools. Crucially, it enables the model to learn collaborative patterns from the dense co-occurrence of shared codes, rather than the sparse co-occurrence of monolithic tool IDs. We generate these structured codes through a novel tokenization process designed to weave together a tool's intrinsic semantics with its extrinsic co-usage patterns. These structured codes are then integrated into the LLM through a generative alignment stage, where the model is fine-tuned to produce the hierarchical code sequences. Evaluation results with nearly 47,000 tools show that ToolWeaver significantly outperforms state-of-the-art methods, establishing a more scalable, generalizable, and semantically-aware foundation for advanced tool-augmented agents.
研究の動機と目的
- exploding tool catalogsの中でLLMにおけるスケーラブルなツール利用を動機づける。
- 1ツールにつき1トークンの方式を置換する、階層的で構成的なツール表現を提案する。
- 構造化されたトークン化プロセスを通じてツールの意味と協調関係を学習する。
- マルチステージの生成整列を介してLLMへ構造化ツールコードを組み込む。
- 大規模ツールベンチマークでの検索性能とエンドツーエンド性能を、言語能力を保持したまま向上させることを示す。
提案手法
- 各ツールをLコードブックのLコードの系列として表現し、語彙の成長を対数的に可能にする(K^L ツールで L*K 新しいトークン)。
- 協調意識を取り入れた残差量子化(RQ-VAE)を用いて、ツールとツールの類似度行列に導かれた階層コードへ意味的ツール記述を写像する。
- 共出現に基づく近接コードを促すグラフラプラシアン正則化を導入する。
- 最終コードブックレベルで衝突を避けるための一様マッピング制約を、Sinkhorn-Knoppによって解かれる最適輸送形式で適用する。
- 2段階でLLMを微調整する:検索整列(クエリからツールコード系列を予測)と軌道整列(ツール呼び出し、パラメータ、回答を学習)。
- 推論時には有効なコード系列のプレフィックスツリーを用いた制約付きビーム探索を使用して、ツール識別子の妥当性を保証する。
実験結果
リサーチクエスチョン
- RQ1ツール表現を1ツールにつき1トークン以上にスケールさせても語彙が爆発しないようにするには?
- RQ2協調的なツール使用パターンをツール表現に統合して、一般化と推論を改善できるか?
- RQ3階層的なコード表現は、従来法と比較してエンドツーエンドのタスク性能とツールオーケストレーションを改善するか?
- RQ4協調正則化はモデル性能と言語能力にどのような影響を与えるか?
主な発見
| Model | I1 NDCG@1 | I1 NDCG@3 | I1 NDCG@5 | I2 NDCG@1 | I2 NDCG@3 | I2 NDCG@5 | I3 NDCG@1 | I3 NDCG@3 | I3 NDCG@5 |
|---|---|---|---|---|---|---|---|---|---|
| BM25* | 22.77 | 22.64 | 25.61 | 18.29 | 20.74 | 22.18 | 10.00 | 10.08 | 12.33 |
| EmbSim* | 54.00 | 50.82 | 55.86 | 40.84 | 36.67 | 39.55 | 18.00 | 17.77 | 20.70 |
| ToolRetriever* | 72.31 | 70.30 | 74.99 | 64.54 | 57.91 | 63.61 | 52.00 | 39.89 | 42.92 |
| ToolGen* | 87.67 | 88.84 | 91.54 | 83.46 | 86.24 | 88.84 | 79.00 | 79.80 | 84.79 |
| ToolWeaver | 91.16 | 91.14 | 93.48 | 89.76 | 89.70 | 91.80 | 88.00 | 85.80 | 90.12 |
- ToolWeaver は単純および複雑なシナリオでの検索NDCG@kをより高く達成し、最難易度のI3設定でNDCG@1が88.00に達する。
- エンドツーエンド評価では、見たことのないツールやカテゴリを含む複数の設定でSoPR/SoWRの最高値を達成。
- アブレーションにより、意味的初期化が最も重要なステップであり、協調的ガイダンスは特に複雑なタスクで追加の利得を提供することを示す。
- 協調正規化の最適重量はλ=1付近で、λが大きすぎるとツール固有の意味論に悪影響。
- ToolWeaver は ToolGen よりも一般的な言語能力をはるかに良好に保持し、困惑度が低く要約品質が安定している。
より良い研究を、今すぐ始めましょう
論文設計から論文執筆まで、研究時間を劇的に削減しましょう。
クレジットカード登録不要
このレビューはAIが作成し、人間の編集者が確認しました。