Skip to content

feat: add Tavily MCP server to miroflow-tools library#144

Closed
ParakhJaggi wants to merge 2 commits intoMiroMindAI:mainfrom
tavily-ai:feat/tavily-migration/libs-tavily-mcp-server
Closed

feat: add Tavily MCP server to miroflow-tools library#144
ParakhJaggi wants to merge 2 commits intoMiroMindAI:mainfrom
tavily-ai:feat/tavily-migration/libs-tavily-mcp-server

Conversation

@ParakhJaggi
Copy link
Copy Markdown

Summary

  • Added a new tavily_mcp_server.py FastMCP server in the miroflow-tools library, providing a tavily_search tool as a parallel alternative to the existing Serper-based google_search tool.
  • The new server follows the same retry/error-handling patterns as serper_mcp_server.py (tenacity retries, JSON error responses, if __name__ == '__main__': mcp.run() entry point).
  • Added tavily-python>=0.5.0 dependency to pyproject.toml.

Files Changed

  • libs/miroflow-tools/src/miroflow_tools/mcp_servers/tavily_mcp_server.py (new file)
  • libs/miroflow-tools/pyproject.toml (added dependency)

Dependency Changes

  • Added tavily-python>=0.5.0 to libs/miroflow-tools/pyproject.toml

Environment Variable Changes

  • New: TAVILY_API_KEY — read by tavily_mcp_server.py to authenticate with the Tavily API

Notes for Reviewers

  • Existing Serper search server and its dependencies/env vars are unchanged.
  • The Tavily tool exposes parameters for search_depth, topic, include_domains, exclude_domains, and time_range to leverage Tavily's filtering capabilities.

🤖 Generated with Claude Code

Automated Review

  • Passed after 2 attempt(s)
  • Final review: The Tavily MCP server implementation is a clean additive migration. The core logic is sound, the dependency is properly added to pyproject.toml, and the code style is consistent with the existing serper_mcp_server.py. Attempt 2 correctly fixed the retry exception types to use httpx exceptions (httpx.ConnectError / httpx.TimeoutException) rather than Python built-ins. No regressions were introduced. Three minor issues remain: httpx and tenacity are used as direct imports but not declared as explicit dependencies in pyproject.toml (both are transitively available—httpx via tavily-python, and tenacity is a pre-existing undeclared dep already used in serper_mcp_server.py); the TavilyClient is instantiated on every call rather than being module-level; and there is no .env.example or README update documenting the new TAVILY_API_KEY variable (though an inline comment was added).

@tavily-ai tavily-ai closed this by deleting the head repository Mar 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants