### Start Web Server Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Start the web server for accessing generated reports. ```bash docker exec -it trendradar python manage.py start_webserver ``` -------------------------------- ### Combined Configuration Example Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md An example showing how to set both sorting priority and global display count limits in the configuration file. ```yaml # config.yaml report: sort_by_position_first: true # Config order priority max_news_per_keyword: 10 # Global default max 10 per keyword ``` -------------------------------- ### Install Project Dependencies Source: https://github.com/sansan0/trendradar/blob/master/README.md Run the appropriate script to install project dependencies based on your operating system. ```bash # Windows: setup-windows.bat or setup-windows-en.bat # Mac/Linux: ./setup-mac.sh ``` -------------------------------- ### Build and Start All Services Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Build all TrendRadar services and start them in detached mode. ```bash docker compose build docker compose up -d ``` -------------------------------- ### Regex Start of String Matching Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Example of using regex to match titles that start with a specific pattern (`^pattern`). ```txt /^breaking/ ``` -------------------------------- ### Build and Start News Push Service Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Build and start only the news push service (trendradar). ```bash docker compose build trendradar docker compose up -d trendradar ``` -------------------------------- ### Clone Project and Start Services Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Clone the project repository and use docker compose to start both the news push and MCP services. Ensure you are in the 'docker' directory after cloning. ```bash # Clone project (Recommended) git clone https://github.com/sansan0/TrendRadar.git cd TrendRadar/docker docker compose up -d # Check running status docker ps | grep trendradar ``` -------------------------------- ### Clone Project and Navigate Directory Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Clone the TrendRadar repository and change into the project directory to begin setup. ```bash git clone https://github.com/sansan0/TrendRadar.git cd TrendRadar ``` -------------------------------- ### Start MCP Inspector Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Run this command to start the MCP Inspector, a debug tool for testing MCP connections. It is recommended to run this after starting the TrendRadar HTTP service. ```bash npx @modelcontextprotocol/inspector ``` -------------------------------- ### LiteLLM Model Format Examples Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Examples of how to specify AI models using the 'provider/model_name' format with LiteLLM integration. This replaces the older 'provider' field and simplifies configuration. ```text model: "openai/gpt-4o" # DeepSeek: model: "deepseek/deepseek-chat" # Gemini: model: "gemini/gemini-2.5-flash" # Anthropic: model: "anthropic/claude-3-5-sonnet" ``` -------------------------------- ### Keyword Grouping Example Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Demonstrates how to define groups of keywords with required and filter words. Empty lines separate distinct groups. ```txt iPhone Huawei OPPO +launch A-shares Shanghai Index Shenzhen Index +fluctuation !prediction World Cup Euro Cup Asian Cup +match ``` -------------------------------- ### Start TrendRadar HTTP Service Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Use these commands to start the TrendRadar HTTP service for MCP integration. Ensure you are in the project directory. ```bash # Windows start-http.bat ``` ```bash # Mac/Linux ./start-http.sh ``` -------------------------------- ### Global Filter Example Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Example demonstrating the effect of global filters on news content. Global filter words are excluded regardless of other matches. ```txt [GLOBAL_FILTER] advertisement [WORD_GROUPS] technology AI ``` -------------------------------- ### Run HTTP Server with Custom Port Source: https://github.com/sansan0/trendradar/blob/master/README.md Start the MCP server using HTTP transport on a custom port, useful for troubleshooting port conflicts. ```bash uv run python -m mcp_server.server --transport http --port 33333 ``` -------------------------------- ### Run HTTP Server Source: https://github.com/sansan0/trendradar/blob/master/README.md Start the MCP server using HTTP transport on the default port 3333. This is used for viewing detailed error logs. ```bash uv run python -m mcp_server.server --transport http --port 3333 ``` -------------------------------- ### Start MCP Service Separately (Linux/Mac) Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Deploy the MCP service as a standalone container on Linux or macOS. Mounts the local 'config' and 'output' directories as read-only volumes and sets the timezone. ```bash # Linux/Mac docker run -d --name trendradar-mcp \ -p 127.0.0.1:3333:3333 \ -v $(pwd)/config:/app/config:ro \ -v $(pwd)/output:/app/output:ro \ -e TZ=Asia/Shanghai \ wantcat/trendradar-mcp:latest ``` -------------------------------- ### Start Trendradar MCP Service Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Use this command to pull the latest image and start only the `trendradar-mcp` service for AI dialogue analysis. ```bash docker compose pull trendradar-mcp docker compose up -d trendradar-mcp ``` -------------------------------- ### Build and Start MCP AI Analysis Service Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Build and start only the MCP AI analysis service (trendradar-mcp). ```bash docker compose build trendradar-mcp docker compose up -d trendradar-mcp ``` -------------------------------- ### Required Word Syntax Example Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Demonstrates the syntax for specifying required words in the frequency_words.txt file. Both 'Tang Monk' and 'Pig' must appear in the title for the news to be included. ```text +Tang Monk +Pig ``` -------------------------------- ### Start All TrendRadar Services with Docker Compose Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Pull the latest Docker images and start all TrendRadar services, including push and AI analysis, in detached mode. ```bash docker compose pull docker compose up -d ``` -------------------------------- ### Regex Multiple Options Matching Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Example of using regex to match any one of several options using the pipe symbol (`|`). Note the escaped pipe `\|`. ```txt /apple\|huawei\|xiaomi/ ``` -------------------------------- ### Start MCP Service Separately (Windows PowerShell) Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Deploy the MCP service as a standalone container on Windows using PowerShell. Mounts the current directory's 'config' and 'output' folders as read-only volumes and sets the timezone. ```powershell # Windows PowerShell docker run -d --name trendradar-mcp ` -p 127.0.0.1:3333:3333 ` -v ${PWD}/config:/app/config:ro ` -v ${PWD}/output:/app/output:ro ` -e TZ=Asia/Shanghai ` wantcat/trendradar-mcp:latest ``` -------------------------------- ### Start Only TrendRadar News Push Service with Docker Compose Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Pull the latest image for the TrendRadar service and start only the news push functionality in detached mode. ```bash docker compose pull trendradar docker compose up -d trendradar ``` -------------------------------- ### Configure Timezone Settings Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Set the application's timezone to ensure correct push times. Examples for Los Angeles and London are provided. ```yaml app: timezone: "Asia/Shanghai" # Default is China Standard Time ``` -------------------------------- ### Slack Message Format Preview Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md This is an example of the message format sent to Slack. It includes batch information and trending topic details. ```text *[Batch 1/2]* 📊 *Trending Topics Statistics* 🔥 *[1/3] AI ChatGPT* : 2 articles 1. [Baidu Hot] 🆕 ChatGPT-5 Official Release *[1]* - 09:15 (1 time) 2. [Toutiao] AI Chip Stocks Surge *[3]* - [08:30 ~ 10:45] (3 times) ``` -------------------------------- ### Custom Message Template Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md An example of a custom JSON template that includes a 'text' field for content and a 'username' field. ```json {"text": "{content}", "username": "TrendRadar"} ``` -------------------------------- ### ntfy Push Notification - Free Usage Test Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Test your ntfy free usage setup by sending a message to your subscribed topic. Ensure the topic name is hard-to-guess. ```bash curl -d "Test message" ntfy.sh/your-topic-name ``` -------------------------------- ### Configure Region Display Order Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Adjust the order of sections in push messages by modifying the `display.region_order` list. This example places 'AI Analysis' at the top. ```yaml display: region_order: - ai_analysis # Move to first line - new_items - hotlist - rss - standalone ``` -------------------------------- ### Configuration Strategy: Broad to Strict Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Illustrates a step-by-step approach to refining keyword configurations from broad terms to more specific ones using required and filter words. ```txt # Step 1: Start with broad keywords for testing Artificial Intelligence AI ChatGPT # Step 2: After finding mismatches, add required words Artificial Intelligence AI ChatGPT +technology # Step 3: After finding noise, add filter words Artificial Intelligence AI ChatGPT +technology !advertisement !training ``` -------------------------------- ### Configuration Strategy: Avoid Over-Complexity Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Shows a recommended approach to split complex keyword groups into smaller, more precise groups for better management. ```txt Huawei OPPO Apple Samsung vivo OnePlus Meizu +phone +launch +sales !fake !repair !second-hand ``` ```txt Huawei OPPO +new product Apple Samsung +launch phone sales +market ``` -------------------------------- ### Enable and Configure Monitoring Platforms Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Enable trending platform crawling and specify sources in the `config/config.yaml` file. Suggest choosing 10-15 core platforms to avoid information overload. ```yaml platforms: enabled: true # Enable trending platform crawling sources: - id: "toutiao" name: "Toutiao" - id: "baidu" name: "Baidu Hot Search" - id: "wallstreetcn-hot" name: "Wallstreetcn" # Add more platforms... ``` -------------------------------- ### Keyword vs. Platform Display Mode Comparison Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Illustrates the difference in output formatting between 'keyword' mode and 'platform' mode for push messages. 'Keyword' mode groups by topic, while 'platform' mode groups by source. ```text # keyword mode (group by keyword) 📊 Trending Keywords Stats 🔥 [1/3] AI : 12 items 1. [Weibo] OpenAI releases GPT-5 #1-#3 - 08:30 (5 times) 2. [Zhihu] How to view AI replacing programmers #2 - 09:15 (3 times) # platform mode (group by platform) 📊 Trending News Stats 🔥 [1/4] Weibo : 12 items 1. [AI] OpenAI releases GPT-5 #1-#3 - 08:30 (5 times) 2. [Trump] Trump announces major policy #2 - 09:15 (3 times) ``` -------------------------------- ### Clone Project and Configure Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Clone the TrendRadar repository and modify configuration files before building the Docker image. ```bash git clone https://github.com/sansan0/TrendRadar.git cd TrendRadar # Modify config files vim config/config.yaml vim config/frequency_words.txt # Use build version docker compose cd docker cp docker-compose-build.yml docker-compose.yml ``` -------------------------------- ### Regex End of String Matching Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Example of using regex to match titles that end with a specific pattern (`pattern$`). ```txt /release$/ ``` -------------------------------- ### Regex Word Boundary Matching Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Example of using regex with word boundaries (`\bword\b`) to match standalone words. ```txt /\bword\b/ ``` -------------------------------- ### Manually Update Images and Restart Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Manually pull the latest Crawler and MCP images, then restart the services. ```bash docker pull wantcat/trendradar:latest docker pull wantcat/trendradar-mcp:latest docker compose down docker compose up -d ``` -------------------------------- ### Docker Deployment for Bark Server Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Use this Docker command to deploy a self-hosted Bark server. Ensure ports are correctly mapped. ```bash docker run -d \ --name bark-server \ -p 8080:8080 \ finab/bark-server ``` -------------------------------- ### View Help Information Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Display help information for TrendRadar management commands. ```bash docker exec -it trendradar python manage.py help ``` -------------------------------- ### Regex Non-Letter Boundary Matching Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Example of using regex with non-letter boundaries (`(? alias` syntax. ```txt deepseek => DeepSeek News ``` -------------------------------- ### TrendRadar STDIO Mode Client Configuration Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md A basic configuration template for connecting a STDIO client to the TrendRadar MCP service. Replace `/path/to/TrendRadar` with the actual project path. This mode is recommended. ```json { "name": "trendradar", "command": "uv", "args": [ "--directory", "/path/to/TrendRadar", "run", "python", "-m", "mcp_server.server" ], "type": "stdio" } ``` -------------------------------- ### Configure Push Content and Style Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Customize push message display and content by modifying the `report` and `display` sections in `config/config.yaml`. This includes setting display modes, ranking thresholds, and regional order. ```yaml report: mode: "daily" # Push mode display_mode: "keyword" # Display mode (v4.6.0 new) rank_threshold: 5 # Ranking highlight threshold sort_by_position_first: false # Sorting priority max_news_per_keyword: 0 # Maximum display count per keyword display: region_order: - new_items # New trending section - hotlist # Hotlist section - rss # RSS subscription section - standalone # Independent display section - ai_analysis # AI analysis section ``` -------------------------------- ### Global Display Count Limit Configuration Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Sets a maximum number of news items to display per keyword globally. A value of 0 means unlimited. ```yaml report: max_news_per_keyword: 10 # Max 10 per keyword (0=unlimited) ``` -------------------------------- ### Global Filter Configuration Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Globally exclude content by listing keywords under the [GLOBAL_FILTER] region. This filter has the highest priority. ```txt [GLOBAL_FILTER] advertisement promotion marketing shocking clickbait [WORD_GROUPS] technology AI Huawei HarmonyOS !car ``` -------------------------------- ### AI Analysis Mode and Time Window Configuration Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Configure AI analysis behavior with independent control over the mode and time window. Supports custom execution periods and daily frequency limits. ```yaml ai_analysis: mode: "follow_report" # Options: follow_report | daily | current | incremental time_window: execution_period: "08:00-18:00" daily_frequency_limit: 3 ``` -------------------------------- ### Configure Cursor with TrendRadar STDIO Mode Source: https://github.com/sansan0/trendradar/blob/master/README-EN.md Configure Cursor to use TrendRadar's MCP service via STDIO. This is the recommended method and requires specifying the command to run the MCP server. ```json { "mcpServers": { "trendradar": { "command": "uv", "args": [ "--directory", "/path/to/TrendRadar", "run", "python", "-m", "mcp_server.server" ] } } } ```