SuperAPIAI Directory

forage

github.com · AI developer platforms

Self-improving tool discovery: searches registries, installs MCP servers as subprocesses without restarts, and persists tool knowledge across sessions.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)
PlatformsLinux

About this tool

Forage is a self-improving tool discovery MCP server for AI agents, with the core goal of enabling agents to automatically discover, install, and learn to use new MCP tools, thereby breaking through the limitation of a fixed toolset at the start of a session.

Purpose AI coding agents can usually only use the tools already configured when the session starts. When they need to query a database, deploy to Vercel, or search Slack, agents often can only say they are unable to do so, and the user must manually install the corresponding MCP server. Forage aims to close this loop: when an agent encounters a capability boundary, it can "forage" for a suitable tool, install it, and teach itself how to use it, without restarting and without manual configuration, enabling the agent to continuously become more powerful.

Main capabilities Forage runs as a gateway/proxy MCP server and has the following capabilities:

  • Tool discovery: searches the official MCP Registry, Smithery, and npm in parallel to find suitable MCP tools.
  • Tool installation: launches tools as child processes via npx -y <package> and connects through StdioClientTransport (MCP client).
  • Capability wrapping: discovers the child server's tools via listTools and re-registers each tool on the Forage server under a namespaced name (foraged__<server>__<tool>).
  • Immediate effect: sends a tools/list_changed notification, so the agent can immediately see the new tools without restarting.
  • Call forwarding: when the agent calls a proxied tool, Forage forwards the call to the child server.
  • Knowledge persistence: forage_learn writes to the agent rules file, and the manifest automatically starts the tool in the next session. State is stored in the ~/.forage/ directory.
  • Startup recovery: at startup, Forage reads the manifest and automatically starts all previously installed servers, so the agent can continue from where it left off.
  • Human CLI: Forage also includes a command-line interface for humans.

How to use Users only need to manually install Forage once; it is the only MCP server that needs to be configured. After installation, start a new session, and Forage is ready. When the agent needs a new tool, it triggers the discovery and installation process through calls such as forage_install. When installing a tool, Forage will run npx -y <package> as a subprocess, connects to and discovers its tools, then re-registers and notifies the agent.

Security and Limitations

  • Installation requires explicit approval: Forage cannot install tools without explicit user approval; every forage_install call requires confirm: true.
  • Audit trail: Every install/uninstall is recorded with a timestamp to ~/.forage/install-log.json.
  • No remote backend: Everything runs locally; registry searches are read-only GET requests to public APIs.
  • No secrets stored: The child server's environment variables are passed in at install time and are not persisted.

Use Cases Suitable for developers who use AI coding agents (such as Claude Code) and want the agent to be able to autonomously extend its tool capabilities. Typical scenarios include: when the agent needs to query a database, deploy to Vercel, search Slack, etc., and the corresponding MCP server is not configured in the current session, Forage can automatically discover and install the required tools.

Other Information The repository lists future plans, including: forage update to check for new versions of installed tools; support for pip/cargo/brew packages (not limited to npm); smarter search ranking (weighted by download count, stars, and description relevance); automatic environment variable configuration from .env files; forage doctor to diagnose common setup issues; submission to the official MCP Registry, Smithery, mcp.so, and glama.ai; building a forage.dev landing page; adding a demo GIF/video to the README; writing a launch blog post; posting on r/ClaudeAI, r/LocalLLaMA, Hacker News (Show HN); sharing in MCP Discord/community channels; writing use case guides (e.g., "Add Postgres to Claude Code in 30 seconds"); adding GitHub Discussions for Q&A and feature requests.

Information about specific installation commands, detailed CLI usage, the range of supported platforms, fees and pricing, etc., is not yet available in the materials.

Up/Down to navigate · Enter to open · ESC to closeBrowse all tools