FinnewsHunter: Multi-agent financial intelligence platform powered by AgenticX. Real-time news analysis, sentiment fusion, and alpha factor mining.
FinnewsHunter: Multi-agent financial intelligence platform powered by AgenticX. Real-time news analysis, sentiment fusion, and alpha factor mining.
An enterprise-grade financial news analysis system built on the AgenticX framework, integrating real-time news streams, deep quantitative analysis, and multi-agent debate mechanisms.
FinnewsHunter goes beyond traditional text classification by deploying multi-agent teams (NewsAnalyst, Researcher, etc.) to monitor multiple financial news sources in real-time, including Sina Finance, National Business Daily, Financial World, Securities Times, and more. It leverages large language models for deep interpretation, sentiment analysis, and market impact assessment, combined with knowledge graphs to mine potential investment opportunities and risks, providing decision-level alpha signals for quantitative trading.
BailianEmbeddingProvider and MilvusStorage, avoiding reinventing the wheelThe system adopts a layered architecture design:
cd /Users/damon/myWork/AgenticX
pip install -e .cd FinnewsHunter/backend
pip install -r requirements.txtcd FinnewsHunter/backend
cp env.example .env
# Edit .env file and fill in LLM API Key and other configurationsMulti-Provider LLM Configuration:
The system supports 5 LLM providers, at least one needs to be configured:
| Provider | Environment Variable | Registration URL |
|---|---|---|
| Bailian (Alibaba Cloud) | DASHSCOPE_API_KEY |
https://dashscope.console.aliyun.com/ |
| OpenAI | OPENAI_API_KEY |
https://platform.openai.com/api-keys |
| DeepSeek | DEEPSEEK_API_KEY |
https://platform.deepseek.com/ |
| Kimi (Moonshot) | MOONSHOT_API_KEY |
https://platform.moonshot.cn/ |
| Zhipu | ZHIPU_API_KEY |
https://open.bigmodel.cn/ |
Example Configuration (Recommended: Bailian):
# Bailian (Alibaba Cloud) - Recommended, fast access in China
DASHSCOPE_API_KEY=sk-your-dashscope-key
DASHSCOPE_BASE_URL=https://dashscope.aliyuncs.com/compatible-mode/v1
BAILIAN_MODELS=qwen-plus,qwen-max,qwen-turbo
# Optional: Other providers
OPENAI_API_KEY=sk-your-openai-key
DEEPSEEK_API_KEY=sk-your-deepseek-keycd FinnewsHunter
docker compose -f deploy/docker-compose.dev.yml up -d postgres redis milvus-etcd milvus-minio milvus-standalonecd FinnewsHunter/backend
python init_db.pycd FinnewsHunter/backend
python -m app.scripts.init_stocks
# Will fetch all A-share data (approximately 5000+ stocks) from akshare and save to databasecd FinnewsHunter/backend
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000# Open a new terminal
cd FinnewsHunter
docker compose -f deploy/docker-compose.dev.yml up -d celery-worker celery-beat# Open a new terminal
cd FinnewsHunter/frontend
npm install # First time requires dependency installation
npm run devcd FinnewsHunter
docker compose -f deploy/docker-compose.dev.yml pscd FinnewsHunter
# Restart Docker services (infrastructure + Celery)
docker compose -f deploy/docker-compose.dev.yml restart
# If backend API is started independently, manually restart it
# Press Ctrl+C to stop backend process, then rerun:
cd backend
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000cd FinnewsHunter
# Restart only Celery (after code changes)
docker compose -f deploy/docker-compose.dev.yml restart celery-worker celery-beat
# Restart only database
docker compose -f deploy/docker-compose.dev.yml restart postgres
# Restart only Redis
docker compose -f deploy/docker-compose.dev.yml restart rediscd FinnewsHunter
docker compose -f deploy/docker-compose.dev.yml downcd FinnewsHunter
# View Celery Worker logs
docker compose -f deploy/docker-compose.dev.yml logs -f celery-worker
# View Celery Beat logs (scheduled task dispatch)
docker compose -f deploy/docker-compose.dev.yml logs -f celery-beat
# View PostgreSQL logs
docker compose -f deploy/docker-compose.dev.yml logs -f postgres
# View all service logs
docker compose -f deploy/docker-compose.dev.yml logs -fcd FinnewsHunter
# Execute reset script
./reset_all_data.sh
# Enter yes to confirmThe script will automatically complete:
After execution, wait:
# Enter PostgreSQL container
docker exec -it finnews_postgres psql -U finnews -d finnews_dbExecute in PostgreSQL command line:
-- Clear news table
DELETE FROM news;
-- Clear task table
DELETE FROM crawl_tasks;
-- Clear analysis table
DELETE FROM analyses;
-- Reset auto-increment IDs
ALTER SEQUENCE news_id_seq RESTART WITH 1;
ALTER SEQUENCE crawl_tasks_id_seq RESTART WITH 1;
ALTER SEQUENCE analyses_id_seq RESTART WITH 1;
-- Verify results (should all be 0)
SELECT 'news table', COUNT(*) FROM news;
SELECT 'crawl_tasks table', COUNT(*) FROM crawl_tasks;
SELECT 'analyses table', COUNT(*) FROM analyses;
-- Exit
\qcd FinnewsHunter
docker exec finnews_redis redis-cli FLUSHDBcd FinnewsHunter/backend
rm -f celerybeat-schedule*cd FinnewsHunter
docker compose -f deploy/docker-compose.dev.yml restart celery-worker celery-beat# Check news count (should be 0)
docker exec finnews_postgres psql -U finnews -d finnews_db -c "SELECT COUNT(*) FROM news;"
# Check Redis (should be 0 or very small)
docker exec finnews_redis redis-cli DBSIZE
# Check if Celery has started crawling
docker compose -f deploy/docker-compose.dev.yml logs -f celery-beat
# Should see 10 crawl tasks triggered per minutecd FinnewsHunter/backend
python reset_database.py
# Enter yes to confirmUse Case: When reset script doesn't work, this is the fastest method
…Immediately refresh browser after execution:
Command + Shift + RCtrl + Shift + RAfter data is cleared, frontend may still display old data due to browser cache.
Mac System:
Press Command + Shift + R
or Command + Option + RWindows/Linux System:
Press Ctrl + Shift + R
or Ctrl + F5F12 to open developer toolsChrome/Edge:
Command + Shift + Delete (Mac) or Ctrl + Shift + Delete (Windows)After refreshing page, hard refresh again
# Press Ctrl+C in frontend terminal to stop service
# Then restart
cd FinnewsHunter/frontend
npm run dev| Time | Event | Expected Result |
|---|---|---|
| 0 min | Execute reset script | Database cleared, Redis cleared |
| 1 min | Celery Beat starts scheduling | 10 crawl tasks triggered |
| 2-5 min | First batch of news saved | Database starts having data |
| 5-10 min | All sources have data | Frontend can see 100+ news |
| 30 min | Data continues growing | 500+ news |
| 1 hour | Stable operation | 1000-2000 news |
Notes:
Steps to immediately hard refresh frontend after reset:
Command + Shift + R (Mac) or Ctrl + Shift + R (Windows) in browsercd FinnewsHunter
# View news count by source
docker exec finnews_postgres psql -U finnews -d finnews_db -c "
SELECT source, COUNT(*) as count
FROM news
WHERE created_at > NOW() - INTERVAL '1 hour'
GROUP BY source
ORDER BY count DESC;
"
# View recent crawl task status
docker exec finnews_postgres psql -U finnews -d finnews_db -c "
SELECT source,
crawled_count,
saved_count,
status,
error_message
FROM crawl_tasks
WHERE created_at > NOW() - INTERVAL '10 minutes'
ORDER BY created_at DESC
LIMIT 20;
"cd FinnewsHunter
# View ERROR logs
docker compose -f deploy/docker-compose.dev.yml logs celery-worker | grep ERROR
# View specific source issues
docker compose -f deploy/docker-compose.dev.yml logs celery-worker | grep "jwview"**System is configured with automatic c
No open issues yet, or sync has not completed.