How jayergood/multiagent-search works
MultiAgent-Search is a FastAPI-backed multi-agent assistant: a browser submits a task, the server starts an asynchronous orchestrator, and the agent combines optional search, SQL, and knowledge-base research with file reading and report-generation tools. The API also supports session uploads, output-file access, and WebSocket progress. The README documents these capabilities; sampled source confirms the server-to-agent dispatch, orchestration setup, database and RAG tool behavior, and context handling. Some tool and monitor wiring is documented but not sampled in full.
Main entry points: main_agent.py Main agent · server.py FastAPI server · monitor.py WebSocket monitor · network_search_agent.py Search subagent
Components 22
Web and sessions
- FastAPI server
api/server.py - WebSocket monitor
api/monitor.py - Session context
api/context.py
Agent orchestration
- Main agent
agent/main_agent.py - Chat model
agent/llm.py - Agent prompts
agent/prompts.py - Conversation checkpoints
agent/main_agent.py
Research integrations
- Search subagent
agent/subagents/network_search_agent.py - Database subagent
agent/subagents/database_query_agent.py - Knowledge subagent
agent/subagents/knowledge_base_agent.py - Web search tool
tools/tavily_tool.py - Tavily search
- SQL query tools
tools/db_tools.py - MySQL database
- RAGFlow tools
tools/ragflow_tools.py - RAGFlow service
Files and reports
- Session uploads
api/server.py - Uploaded file reader
tools/upload_file_read_tool.py - Markdown generator
tools/markdown_tools.py - PDF converter
tools/pdf_tools.py - Generated files
api/server.py
Other components
- Browser user
Connections 26
- Browser user → FastAPI server: submits task
- FastAPI server → Main agent: starts async task
- Browser user → FastAPI server: uploads files
- FastAPI server → Session uploads: saves files
- FastAPI server → WebSocket monitor: registers socket
- WebSocket monitor → Browser user: pushes progress
- Main agent → Session context: sets session context
- Main agent → WebSocket monitor: reports progress
- Main agent → Chat model: uses model
- Main agent → Agent prompts: loads prompts
- Main agent → Conversation checkpoints: persists conversation
- Main agent → Search subagent: dispatches task
- Main agent → Database subagent: dispatches task
- Main agent → Knowledge subagent: dispatches task
- Search subagent → Web search tool: uses search tool
- Web search tool → Tavily search: searches web
- Database subagent → SQL query tools: uses SQL tools
- SQL query tools → MySQL database: queries
- Knowledge subagent → RAGFlow tools: uses knowledge tools
- RAGFlow tools → RAGFlow service: queries knowledge
- Main agent → Session uploads: loads session files
- Main agent → Uploaded file reader: reads uploaded files
- Main agent → Markdown generator: generates report
- Main agent → PDF converter: converts to PDF
- Main agent → Generated files: writes session output
- FastAPI server → Generated files: lists and serves files