This example demonstrates how to create and use an Upsonic Agent with DeepAgent architecture to conduct comprehensive business research and develop sales strategies. The example showcases how to leverage Upsonicβs coordination capabilities to manage multiple specialized agents working together on complex, multi-step research tasks.Documentation Index
Fetch the complete documentation index at: https://docs.upsonic.ai/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Upsonic framework provides seamless integration for multi-agent systems. This example showcases:- DeepAgent Integration β Using DeepAgent to coordinate specialized sub-agents
- Web Research β Using DuckDuckGo and Tavily for real-time company and industry data
- Financial Analysis β Using YFinance tools for stock and financial data
- Task Planning β Automatic task decomposition using planning tools
- Memory Persistence β SQLite-based session memory for continuity
- FastAPI Server β Running the agent as a production-ready API server
- Company Researcher β Gathers comprehensive company information
- Industry Analyst β Analyzes industry trends and market dynamics
- Financial Analyst β Performs financial analysis using YFinance
- Sales Strategist β Develops tailored sales strategies
Project Structure
Environment Variables
You can configure the model and search tools using environment variables:Installation
Managing Dependencies
api, streamlit, development
Usage
Option 1: Run Directly
Option 2: Run as API Server
http://localhost:8000. API documentation at /docs.
Example API call:
How It Works
| Component | Description |
|---|---|
| DeepAgent | Orchestrator that plans and delegates tasks to subagents |
| Planning Tool | Automatically breaks down complex research into manageable steps |
| Company Researcher | Uses web search to gather company information |
| Industry Analyst | Analyzes industry trends using Tavily/DuckDuckGo |
| Financial Analyst | Uses YFinance tools for financial data |
| Sales Strategist | Develops tailored sales strategies |
| Memory | SQLite-based persistence for session continuity |
Example Output
Query:Complete Implementation
main.py
orchestrator.py
subagents.py
upsonic_configs.json
Key Features
DeepAgent Orchestration
The orchestrator uses DeepAgentβs planning capabilities to automatically break down complex research tasks into manageable steps and delegate them to specialized subagents.Specialized Subagents
Each subagent is optimized for its specific domain:- Company Researcher: Web search tools for comprehensive company information
- Industry Analyst: Advanced search for industry trends and market analysis
- Financial Analyst: YFinance integration for real-time financial data
- Sales Strategist: Strategy development based on research synthesis
Memory Persistence
Uses SQLite database for session persistence, allowing the agent to:- Maintain conversation history
- Store research findings
- Build upon previous sessions
- Generate summaries for context

