An AI-powered business intelligence and market research application that leverages Auto-GPT to conduct automated research missions. Personal CIA helps entrepreneurs and businesses gather competitive intelligence, market insights, and strategic analysis through autonomous AI agents.
- Automated Research Missions: Create custom research tasks that Auto-GPT executes autonomously
- Mission Dashboard: Track and manage multiple research missions with real-time status updates
- AI-Powered Summaries: Generate comprehensive summaries from multiple research outputs using OpenAI
- Flexible Research Parameters: Configure research scope, timeframe, business type, and focus areas
- Mission Management: View, filter, and delete completed or failed missions
- Status Tracking: Monitor missions with three states: Processing, Completed, and Failed
- Flask - Python web framework for REST API
- Flask-CORS - Cross-origin resource sharing
- OpenAI API - GPT-3 integration for summarization
- Auto-GPT - Autonomous AI agent for research execution
- React 18 - UI framework
- Material-UI (MUI) - Component library
- React Router - Navigation
- Create React App - Build tooling
Before you begin, ensure you have the following installed:
- Node.js (v14 or higher) and npm
- Python 3 (v3.8 or higher)
- Flask
- Auto-GPT (installation guide)
- OpenAI API Key
git clone https://github.com/CodeamonCat/Personal_CIA.git
cd Personal_CIApip install flask flask-cors openaiCreate a file at backend/openai.api_key and add your OpenAI API key:
echo "your-openai-api-key-here" > backend/openai.api_keyEdit backend/app.py and update the AUTO_GPT_PATH variable to point to your Auto-GPT installation:
AUTO_GPT_PATH = '/path/to/your/Auto-GPT'cd web
npm install
cd ..Or install from the root directory:
npm install --prefix ./web/You'll need two terminal windows to run both the backend and frontend.
sh flask_init.shThe backend server will start on http://localhost:5000
npm start --prefix ./web/The web application will open automatically at http://localhost:3000
- Access the Dashboard: Navigate to
http://localhost:3000and click "LOG IN" - Create a New Mission: Click "Add new session" to create a research mission
- Configure Research Parameters:
- Search timeframe (start and end dates)
- Number of attempts (0 = unlimited)
- Business type (B2B, B2C, P2P)
- Business description (1-2 sentences)
- Business focus (geo location, age group, income group, industry)
- Research type (market size, competitors, trends, etc.)
- Submit: Click "Start Search" to launch the mission
- Monitor Progress: Return to the dashboard to track mission status
- Generate Summaries: Select completed missions and click "Summarize" to generate an AI summary
All endpoints return JSON responses.
POST /api/new_mission
Request Body:
{
"businessDescription": "string - user's research prompt",
"numberOfAttempts": "int - number of attempts"
}Response:
{
"name": "string",
"date": "YYYY-MM-DD-HH:MM:SS",
"status": 0
}GET /api/missions
Response:
[
{
"id": 0,
"selected": false,
"name": "string",
"status": "Completed|Processing|Failed",
"createdAt": "YYYY-MM-DD-HH:MM:SS"
}
]GET /api/scan_process
Response:
{
"agent_status": [0, 1, -1, ...]
}Status codes: 1 = Completed, 0 = Processing, -1 = Failed
POST /api/delete_mission
Request Body:
{
"index": "int - mission index"
}POST /api/summary
Request Body:
{
"indices": [0, 1, 2]
}Response:
{
"summary": "string - AI-generated summary"
}GET /get_text
Response:
{
"text": "string - content from summary.txt"
}Personal_CIA/
โโโ backend/
โ โโโ app.py # Main Flask application
โ โโโ server.py # Alternative server (development)
โ โโโ summary.txt # Sample summary output
โ โโโ openai.api_key # OpenAI API key (not tracked)
โโโ web/
โ โโโ public/ # Static assets
โ โโโ src/
โ โ โโโ Containers/ # React page components
โ โ โ โโโ Landing.js # Landing page
โ โ โ โโโ Dashboard.js # Mission dashboard
โ โ โ โโโ Session.js # New mission form
โ โ โ โโโ ...
โ โ โโโ App.js # Main React component
โ โ โโโ index.js # React entry point
โ โโโ package.json # Frontend dependencies
โโโ flask_init.sh # Backend startup script
โโโ package.json # Root package.json
โโโ README.md # This file
Personal_CIA_demo.mp4
To enable debug mode in the backend, edit backend/app.py:
debug_mode = True # Set to True to skip Auto-GPT executionThe backend is configured to accept requests from http://localhost:3000. To change this, edit the CORS settings in backend/app.py:
app.config['CORS_RESOURCES'] = {r"/api/*": {"origins": "your-origin-here"}}Adjust OpenAI parameters in backend/app.py:
model = "text-davinci-003" # OpenAI model
temperature = 0.5 # Creativity level (0.0 - 1.0)
max_tokens = 4096 # Maximum response lengthContributions are welcome! Please feel free to submit a Pull Request.
This project is open source and available under the MIT License.
- Error: OpenAI API key not found: Ensure
backend/openai.api_keyexists and contains a valid API key - Error: Auto-GPT path invalid: Update
AUTO_GPT_PATHinbackend/app.pyto point to your Auto-GPT installation - CORS errors: Verify the frontend is running on
http://localhost:3000or update CORS settings
- Cannot connect to backend: Ensure the Flask server is running on port 5000
- Dependencies missing: Run
npm installin thewebdirectory - Port 3000 already in use: Stop other applications using port 3000 or specify a different port
For issues and questions, please open an issue on the GitHub repository.