Skip to main content

Universal tool platform for AI agents โ€” 14+ toolsets, MCP, YAML workflows, provider adapters (OpenAI/Anthropic/LangChain)

Project description


title: AgentToolStore Registry emoji: ๐Ÿ› ๏ธ colorFrom: blue colorTo: purple sdk: docker app_port: 7860 pinned: false

14 toolsets 46 functions MIT toolstore live

AgentToolStore

A package index for agent tools. PyPI for Python packages, npm for JavaScript โ€” ToolStore does the same for agent-callable toolsets. Agents discover tools through a single tool_store function instead of wiring up dozens of tools by hand.

โ†’ Client SDK docs โ€” installing, integrating into agents, CLI, MCP bridge, skills โ†’ Registry server docs โ€” API endpoints, running locally, deploying on HF Spaces

Live registry: mrw33554432-agenttoolstore.hf.space


How it works

toolstore update                     โ† downloads index.json from registry
       โ”‚
       โ–ผ
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  Local index cache       โ”‚  โ† search and info read from here (no network)
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
       โ”‚
       โ–ผ
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  tool_store(execute)     โ”‚  โ† fetches code from registry on demand
โ”‚  โ†’ temp dir โ†’ import     โ”‚     runs in-process, no Docker
โ”‚  โ†’ call function โ†’ JSON  โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
  1. toolstore update pulls the registry index and caches it locally
  2. search / info read from the local cache โ€” instant, no network
  3. execute fetches code from the registry, installs deps explicitly, runs in-process, returns JSON

Installation

pip install toolstore

Or from source:

git clone https://github.com/Mrw33554432/AgentToolStore.git
cd AgentToolStore/client
pip install -e .

Requirements: Python โ‰ฅ3.10, httpx, pydantic, rich, typer.


Adding to Your Agent

Add one tool definition and one handler. The agent discovers every published toolset through a single tool_store call.

How it fits into an agent loop

System prompt                         Tool call loop
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€     โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
"Tool store includes but not          1. Agent calls tool_store(search)
 limited to: Echo Service,                โ†’ discovers xlsx-toolkit
 calculator, weather, ..."
                                      2. Agent calls tool_store(info)
                                         โ†’ gets xlsx_read params + docs

                                      3. Agent calls tool_store(execute)
                                         โ†’ runs xlsx_read, gets result

                                      4. Agent calls tool_store(close)
                                         โ†’ frees context space

1. Tool definition

Register this in your agent's function-calling tool list:

TOOL_STORE_SCHEMA = {
    "type": "function",
    "function": {
        "name": "tool_store",
        "description": (
            "A universal tool manager that lets you search, inspect, "
            "and execute thousands of tools and local utilities."
        ),
        "parameters": {
            "type": "object",
            "properties": {
                "action": {
                    "type": "string",
                    "enum": ["search", "execute", "info", "close"],
                    "description": (
                        "The action to perform: 'search' finds tools "
                        "matching a query; 'execute' runs a tool; "
                        "'info' adds a tool to your context so you can "
                        "see its parameters; 'close' removes it."
                    ),
                },
                "query": {
                    "type": "string",
                    "description": "Search query string (for action='search')",
                },
                "tool_name": {
                    "type": "string",
                    "description": (
                        "Name of the tool to inspect, execute, or close "
                        "(required for action='info', 'execute', or 'close')"
                    ),
                },
                "arguments": {
                    "type": "object",
                    "description": (
                        "Arguments for the tool execution "
                        "(required for action='execute')"
                    ),
                },
            },
            "required": ["action"],
        },
    },
}

2. Handler

Wire the native function into your tool-call router. The native function handles search, info, and execute โ€” add a small shim for close:

from toolstore.native_tool import tool_store_tool

def handle_tool_store(action: str, **kwargs) -> str:
    if action == "close":
        return f"Closed tool '{kwargs.get('tool_name', '')}'."
    return tool_store_tool(action=action, **kwargs)

3. Secondary tools prompt

Most tools are exposure: secondary โ€” too many to list in every system message. Inject a compact listing into the system prompt instead. Call get_secondary_tool_names() then info with format="secondary":

from toolstore.native_tool import get_secondary_tool_names, tool_store_tool

names = get_secondary_tool_names()
listing = tool_store_tool(action="info", tool_names=names, format="secondary")
system_prompt += f"\n\n{listing}"

Produces:

Tool store includes but is not limited to the following tools:
- Echo Service
- calculator
- weather
- skill:algorithmic-art
...

The agent sees names; when it needs a tool it calls info again (without format="secondary") for the full schema, then execute.

4. Agent conversation example

Agent: tool_store(action="search", query="read Excel files")
  โ†’ Found: xlsx-toolkit โ€” Read, create, and manipulate Excel files

Agent: tool_store(action="info", tool_name="xlsx-toolkit")
  โ†’ Returns bindings for xlsx_read, xlsx_sheets, xlsx_to_csv, xlsx_create
    with parameter types and docstrings for each

Agent: tool_store(action="execute", tool_name="xlsx-toolkit",
                  arguments={"function": "xlsx_read",
                             "filepath": "/workspace/report.xlsx"})
  โ†’ {"sheets": ["Sheet1"], "data": {"Sheet1": [[...], ...]}}

Agent: tool_store(action="close", tool_name="xlsx-toolkit")
  โ†’ Closed tool 'xlsx-toolkit'.

5. Execution model

Property Behaviour
Runtime In-process โ€” no Docker, no sandbox
Code origin Fetched from registry, cached after first download
Dependencies Never auto-installed; agent gets a clear error listing what's needed
Isolation Each toolset runs in its own temp directory
Safety All code is visible in the registry; deps are explicit; agent decides what to install

6. Local execution (no registry)

Skip the registry entirely and call toolsets from a local directory:

from toolstore.exec_tools import _execute_toolset_local

result = _execute_toolset_local(
    toolset_path="./toolsets/xlsx-toolkit",
    function_name="xlsx_read",
    filepath="/workspace/data.xlsx",
)

CLI Usage

# Pull the latest index from the registry
toolstore update

# Search for tools
toolstore search "spreadsheet"

# Inspect a toolset
toolstore info xlsx-toolkit

# Execute a function
toolstore use text-transform --function text_stats text="Hello world."

# Publish your own toolset
toolstore login --username <user> --password <pass>
toolstore toolset publish ./toolsets/my-toolkit

# Delete a toolset
toolstore delete my-toolkit

# Run ToolStore as an MCP server (stdio or SSE)
toolstore serve

# Export the tool_store schema for use with OpenAI / vLLM
toolstore export

# Manage skills
toolstore skill discover /path/to/skills
toolstore skill list-dirs

Full command reference:

Command Description
update Pull the latest registry index and scan local MCP servers
search Search for tools by name, description, or tags
use Execute a tool function immediately
info Show detailed schema and documentation for a tool
login Authenticate with the registry to publish
publish Publish a new tool or update an existing one
delete Remove a tool from the registry
export Export the meta-tool schema (OpenAI / vLLM formats)
serve Run ToolStore as an MCP server (stdio or SSE)
skill Manage Agent Skills (scan, discover, publish, โ€ฆ)
toolset Manage toolsets (scan, list, publish, โ€ฆ)
mcp-server Register and manage MCP servers
docker Configure Docker execution permissions

Writing a Toolset

A toolset is a directory with two files:

my-toolkit/
โ”œโ”€โ”€ toolset.py    # @tool functions (code bindings)
โ””โ”€โ”€ doc.md        # human + agent guidance

toolset.py

Every function decorated with @tool becomes a callable binding. The decorator auto-generates an OpenAI function-calling schema from type hints and docstrings:

from toolstore.toolset import tool

@tool
def my_function(*, input: str, count: int = 1) -> dict:
    """Do something useful.

    Args:
        input: The input text.
        count: How many times to repeat.
    """
    return {"result": input * count}

Rules:

  • Use keyword-only arguments (*,)
  • Annotate every parameter with a type hint
  • Write a Google-style docstring with an Args: section
  • Return a JSON-serializable dict

Two kinds of toolsets

Type toolset.py doc.md Example
Code Real @tool functions Full docs xlsx-toolkit, file-verify
Doc-only Minimal empty module Full guidance stuck-toolkit

Doc-only toolsets are valid โ€” they carry skill content without code bindings. No placeholder functions allowed. Code or nothing.


Registry API

The registry is a FastAPI server backed by SQLite, hosted on Hugging Face Spaces. All endpoints are public except auth and publish.

Endpoint Method Auth Description
/ GET No Browse page (HTML) โ€” dark-themed cards showing all published toolsets
/api GET No API root
/health GET No Health check โ€” database connectivity status
/index.json GET No Full index โ€” every toolset with metadata, bindings, and full source code
/auth/register POST No Register a new user account
/auth/token POST No Login โ€” returns JWT access token (OAuth2 password flow)
/publish POST JWT Publish a new toolset or update an existing one
/tools/{name} DELETE JWT Delete a toolset

Running your own registry

cd server
pip install -r requirements.txt
python init_db.py          # create SQLite database
uvicorn app.main:app --port 8000

Set TOOLSTORE_REGISTRY_URL=http://localhost:8000/index.json to point the CLI at a local registry. The default is:

https://mrw33554432-agenttoolstore.hf.space/index.json

Toolsets Catalog

All 14 toolsets published on the live registry.

Document processing

Toolset Functions Dependencies
xlsx-toolkit xlsx_read ยท xlsx_sheets ยท xlsx_to_csv ยท xlsx_create openpyxl
pdf-toolkit pdf_extract ยท pdf_meta ยท pdf_merge ยท pdf_form_fields pdfplumber, PyPDF2
docx-toolkit docx_read ยท docx_info ยท docx_extract_tables ยท docx_create python-docx
pptx-toolkit pptx_read ยท pptx_info ยท pptx_create python-pptx

Utility

Toolset Functions Dependencies
text-transform text_diff ยท regex_extract ยท markdown_table ยท text_stats stdlib
file-verify check_json ยท check_yaml ยท check_csv ยท file_hash ยท detect_encoding PyYAML, chardet (optional)
calc-toolkit eval_expression ยท convert_unit ยท basic_stats stdlib
text-gen lorem_words ยท lorem_paragraphs ยท generate_sentences ยท generate_data stdlib
batch-ops batch_rename ยท batch_find_replace ยท batch_stats ยท batch_copy stdlib

Guidance & diagnostics

Toolset Functions Dependencies
debug-toolkit analyze_error ยท extract_log_patterns stdlib
webapp-testing-toolkit check_url ยท extract_urls stdlib
doc-coauthoring-toolkit document_outline ยท markdown_template stdlib
internal-comms-toolkit comms_template ยท format_bullets stdlib
stuck-toolkit doc-only โ€” no code bindings โ€”

Project Structure

AgentToolStore/
โ”œโ”€โ”€ client/                          # Python SDK (pip install toolstore)
โ”‚   โ”œโ”€โ”€ pyproject.toml
โ”‚   โ””โ”€โ”€ src/toolstore/
โ”‚       โ”œโ”€โ”€ cli.py                   # Typer CLI (update, search, use, publish, โ€ฆ)
โ”‚       โ”œโ”€โ”€ native_tool.py           # tool_store_tool() โ€” the agent-facing entry point
โ”‚       โ”œโ”€โ”€ toolset.py               # @tool decorator + schema generation
โ”‚       โ”œโ”€โ”€ toolset_manager.py       # AST-based toolset discovery & publishing
โ”‚       โ”œโ”€โ”€ exec_tools.py            # Local + remote toolset execution
โ”‚       โ”œโ”€โ”€ config_manager.py        # Settings, registry URL, env-var overrides
โ”‚       โ”œโ”€โ”€ mcp_client.py            # MCP client (stdio / SSE transport)
โ”‚       โ”œโ”€โ”€ mcp_server.py            # MCP server โ€” expose ToolStore via MCP
โ”‚       โ”œโ”€โ”€ index_manager.py         # Local index cache
โ”‚       โ”œโ”€โ”€ transport.py             # stdio / SSE / streamable-http transports
โ”‚       โ”œโ”€โ”€ skill_manager.py         # Agent Skills loader + discovery
โ”‚       โ”œโ”€โ”€ skill_discovery.py       # Skill directory scanner
โ”‚       โ”œโ”€โ”€ schema_converter.py      # Convert ToolStore schemas to OpenAI format
โ”‚       โ”œโ”€โ”€ management/              # Management server + SPA (custom HTTP server)
โ”‚       โ”‚   โ”œโ”€โ”€ server.py
โ”‚       โ”‚   โ”œโ”€โ”€ api_helpers.py
โ”‚       โ”‚   โ”œโ”€โ”€ api_mcp.py
โ”‚       โ”‚   โ”œโ”€โ”€ api_skills.py
โ”‚       โ”‚   โ””โ”€โ”€ static/
โ”‚       โ”‚       โ””โ”€โ”€ app.js
โ”‚       โ””โ”€โ”€ docker_pool.py           # Docker container pool (optional)
โ”‚
โ”œโ”€โ”€ server/                          # Registry server (FastAPI + SQLite)
โ”‚   โ”œโ”€โ”€ Dockerfile                   # HF Spaces deployment
โ”‚   โ”œโ”€โ”€ requirements.txt
โ”‚   โ”œโ”€โ”€ init_db.py
โ”‚   โ””โ”€โ”€ app/
โ”‚       โ”œโ”€โ”€ main.py                  # FastAPI app โ€” browse page, API, auth
โ”‚       โ”œโ”€โ”€ models.py                # Pydantic models (ToolSet, Binding, โ€ฆ)
โ”‚       โ”œโ”€โ”€ database.py              # SQLite with HF Storage Bucket
โ”‚       โ”œโ”€โ”€ db.py                    # Connection helper
โ”‚       โ””โ”€โ”€ auth.py                  # JWT auth + user management
โ”‚
โ”œโ”€โ”€ toolsets/                        # All 14 published toolsets
โ”‚   โ”œโ”€โ”€ xlsx-toolkit/
โ”‚   โ”œโ”€โ”€ pdf-toolkit/
โ”‚   โ”œโ”€โ”€ docx-toolkit/
โ”‚   โ”œโ”€โ”€ pptx-toolkit/
โ”‚   โ”œโ”€โ”€ text-transform/
โ”‚   โ”œโ”€โ”€ file-verify/
โ”‚   โ”œโ”€โ”€ calc-toolkit/
โ”‚   โ”œโ”€โ”€ text-gen/
โ”‚   โ”œโ”€โ”€ batch-ops/
โ”‚   โ”œโ”€โ”€ debug-toolkit/
โ”‚   โ”œโ”€โ”€ webapp-testing-toolkit/
โ”‚   โ”œโ”€โ”€ doc-coauthoring-toolkit/
โ”‚   โ”œโ”€โ”€ internal-comms-toolkit/
โ”‚   โ””โ”€โ”€ stuck-toolkit/
โ”‚
โ”œโ”€โ”€ Dockerfile                       # Root Dockerfile (HF Spaces entry point)
โ”œโ”€โ”€ _publish_toolsets.py             # Utility: batch-publish all toolsets
โ”œโ”€โ”€ LICENSE                          # MIT
โ””โ”€โ”€ README.md

Development

git clone https://github.com/Mrw33554432/AgentToolStore.git
cd AgentToolStore
pip install -e client/

# Run a local registry for testing
cd server && pip install -r requirements.txt && python init_db.py
uvicorn app.main:app --port 8000 &

# Point the CLI at your local registry
export TOOLSTORE_REGISTRY_URL=http://localhost:8000/index.json

# Test a toolset
toolstore use text-transform --function text_stats text="Hello world."

Contributing

  1. Write a toolset (toolsets/<name>/toolset.py + doc.md)
  2. Decorate every callable function with @tool
  3. Use keyword-only arguments with type hints and Google-style docstrings
  4. Keep imports inside each function so they fail cleanly at call time
  5. Test with toolstore use <name> --function <fn> <args>
  6. Open a PR against main

Remaining Work

  • xlsx / pdf / docx / pptx testing โ€” these toolsets need openpyxl, pdfplumber, python-docx, and python-pptx installed in the test environment for full integration tests
  • Rate limiting โ€” the registry server has no rate limiting on public endpoints
  • Large payload handling โ€” docx/pptx toolset bindings can be large; better error handling for oversized publishes

License

MIT โ€” see LICENSE

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agent_tool_store-2.0.1.tar.gz (102.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agent_tool_store-2.0.1-py3-none-any.whl (113.6 kB view details)

Uploaded Python 3

File details

Details for the file agent_tool_store-2.0.1.tar.gz.

File metadata

  • Download URL: agent_tool_store-2.0.1.tar.gz
  • Upload date:
  • Size: 102.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for agent_tool_store-2.0.1.tar.gz
Algorithm Hash digest
SHA256 361d1ee66d14e0628af3169c44bafcf0dfe746cfe5c85dbd75e65ed74fb18248
MD5 477c3ef356fe09d3144bc5240ead22cd
BLAKE2b-256 61411a01a682cde1b5b94f3348b7c4512d3c024b45ea6b2efda1a3bebfa2571f

See more details on using hashes here.

File details

Details for the file agent_tool_store-2.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for agent_tool_store-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8b8f0f2c7d9b28e3eed523ed18a34bae9c906ca675c760f2c217cb6f7733158a
MD5 16dce694108e7b0fe3970f43ada5c1b8
BLAKE2b-256 94f08aaffb4063eee263b6a5110f6dfcbb40dafc97d83d0d916bb59e0d3d0741

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page