Every LLM tool call is structurally an RPC -- a function name, JSON arguments, and a serialized result -- yet each protocol (native Python, MCP, OpenAPI, LangChain) is integrated from scratch. We present ToolRegistry, a system that makes this RPC nature explicit: a single Tool object acts as a universal stub regardless of transport, while the registry serves as the RPC client runtime for dispatch, schema generation, and execution. The system ships as three packages -- a core registry, a server exposing tools over MCP and OpenAPI, and a hub of production-ready implementations -- and invokes tools through pluggable thread or process backends. The system now also provides tag-based permission policies, BM25F-powered progressive tool disclosure for large registries, think-augmented function calling, multi-provider schema support (OpenAI, Anthropic, Gemini), declarative JSONC/YAML configuration, and a near-zero-dependency core built on stdlib-only vendored modules. In our benchmarks the library cuts integration code by 60-80%, and choosing the right concurrency mode (thread vs. process) yields up to 3.1x throughput over the alternative for a given workload. ToolRegistry is open-source at https://github.com/Oaklight/ToolRegistry; documentation lives at https://toolregistry.readthedocs.io/.


翻译:[translated abstract in Chinese] 每个大语言模型工具调用在结构上都是一个RPC——包含函数名、JSON参数与序列化结果——然而每种协议(原生Python、MCP、OpenAPI、LangChain)都需要从头进行集成。我们提出ToolRegistry系统,该框架将这种RPC本质显式化:单个Tool对象作为独立于传输层的通用存根,而注册表则充当RPC客户端运行时,负责调度、模式生成与执行。系统以三个软件包形式发布——核心注册表、通过MCP和OpenAPI暴露工具的服务器、以及生产级实现的中心枢纽——并通过可插拔的线程或进程后端调用工具。该系统现还提供基于标签的权限策略、面向大型注册表的BM25F渐进式工具披露、增强思考的函数调用、多供应商模式支持(OpenAI、Anthropic、Gemini)、声明式JSONC/YAML配置,以及基于仅标准库封装模块的近零依赖核心。在基准测试中,该库减少了60-80%的集成代码,且针对特定工作负载选用正确的并发模式(线程vs.进程)可带来最高达3.1倍的吞吐量提升。ToolRegistry以开源形式发布在https://github.com/Oaklight/ToolRegistry,文档位于https://toolregistry.readthedocs.io/。

0
下载
关闭预览

相关内容

大语言模型在规划与调度问题上的应用
专知会员服务
53+阅读 · 2025年1月12日
掌握使用Python的大型语言模型
专知会员服务
63+阅读 · 2024年5月22日
使用 OpenLLM 构建和部署大模型应用
专知会员服务
55+阅读 · 2024年1月4日
下载 | 最全中文文本分类模型库,上手即用
机器学习算法与Python学习
31+阅读 · 2019年10月17日
吐血整理!140种Python标准库、第三方库和外部工具都有了
炼数成金订阅号
16+阅读 · 2019年7月30日
最全中文自然语言处理数据集、平台和工具整理
深度学习与NLP
34+阅读 · 2019年6月22日
中文自然语言处理数据集:ChineseNLPCorpus
AINLP
35+阅读 · 2019年6月21日
一个牛逼的 Python 调试工具
机器学习算法与Python学习
15+阅读 · 2019年4月30日
Jiagu:中文深度学习自然语言处理工具
AINLP
90+阅读 · 2019年2月20日
干货 | Python 爬虫的工具列表大全
机器学习算法与Python学习
11+阅读 · 2018年4月13日
深度文本匹配开源工具(MatchZoo)
机器学习研究会
10+阅读 · 2017年12月5日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
8+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
11+阅读 · 2015年12月31日
国家自然科学基金
7+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
9+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2014年12月31日
VIP会员
最新内容
学习数据的几何:形状空间分析数学综述
专知会员服务
7+阅读 · 6月17日
定向能反无人机系统最新发展动态
专知会员服务
8+阅读 · 6月17日
从燃煤战舰到算法战争:水面指挥的永恒要求
专知会员服务
6+阅读 · 6月17日
相关资讯
下载 | 最全中文文本分类模型库,上手即用
机器学习算法与Python学习
31+阅读 · 2019年10月17日
吐血整理!140种Python标准库、第三方库和外部工具都有了
炼数成金订阅号
16+阅读 · 2019年7月30日
最全中文自然语言处理数据集、平台和工具整理
深度学习与NLP
34+阅读 · 2019年6月22日
中文自然语言处理数据集:ChineseNLPCorpus
AINLP
35+阅读 · 2019年6月21日
一个牛逼的 Python 调试工具
机器学习算法与Python学习
15+阅读 · 2019年4月30日
Jiagu:中文深度学习自然语言处理工具
AINLP
90+阅读 · 2019年2月20日
干货 | Python 爬虫的工具列表大全
机器学习算法与Python学习
11+阅读 · 2018年4月13日
深度文本匹配开源工具(MatchZoo)
机器学习研究会
10+阅读 · 2017年12月5日
相关基金
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
8+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
11+阅读 · 2015年12月31日
国家自然科学基金
7+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
9+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员