Sem descrição

Lukas Goldschmidt a4096b9dfb news-mcp: cleanup feed naming, improve ingestion logs, add mcporter README examples há 1 mês atrás
news_mcp a4096b9dfb news-mcp: cleanup feed naming, improve ingestion logs, add mcporter README examples há 1 mês atrás
.gitignore 13f8f1d5ab Initialize news-mcp scaffold há 1 mês atrás
OUTLOOK.md 13f8f1d5ab Initialize news-mcp scaffold há 1 mês atrás
PROJECT.md 600fcdbd55 Polish news-mcp docs + add emerging topics and tests há 1 mês atrás
README.md a4096b9dfb news-mcp: cleanup feed naming, improve ingestion logs, add mcporter README examples há 1 mês atrás
killserver.sh a4096b9dfb news-mcp: cleanup feed naming, improve ingestion logs, add mcporter README examples há 1 mês atrás
requirements.txt 600fcdbd55 Polish news-mcp docs + add emerging topics and tests há 1 mês atrás
restart.sh 13f8f1d5ab Initialize news-mcp scaffold há 1 mês atrás
run.sh 13f8f1d5ab Initialize news-mcp scaffold há 1 mês atrás
test_news_mcp.py 9c337fea91 news-mcp: add get_news_sentiment + LLM-derived importance há 1 mês atrás
tests.sh 600fcdbd55 Polish news-mcp docs + add emerging topics and tests há 1 mês atrás

README.md

📰 News MCP Server

FastMCP-based MCP server that turns news feeds into deduplicated, enriched clusters.

Quick start

cd news-mcp
source .venv/bin/activate
pip install -r requirements.txt
./run.sh

Default SSE mount (FastMCP):

  • http://127.0.0.1:8506/mcp/sse

Health:

  • http://127.0.0.1:8506/health

What this server provides

  • Fetches from one or more configured news feeds (NEWS_FEED_URL / NEWS_FEED_URLS)
  • Deduplicates articles into clusters (v1 fuzzy title similarity)
  • Enriches clusters with Groq (topic/entities/sentiment/keywords)
  • Caches clusters + Groq fields in SQLite

Tools (MCP)

1) get_latest_events(topic, limit)

  • topic is a coarse category: crypto | macro | regulation | ai | other

2) get_events_for_entity(entity, limit)

  • substring, case-insensitive match over extracted entities

3) get_event_summary(event_id)

  • Groq-written compressed narrative for a given cluster_id

4) detect_emerging_topics(limit)

  • derives “emerging” signals from recent cached clusters

5) get_news_sentiment(entity, timeframe)

  • aggregates sentiment around an entity from cached enriched clusters

Configuration

See news-mcp/.env. Key variables:

  • GROQ_API_KEY, GROQ_MODEL, GROQ_DEBUG
  • NEWS_FEED_URL (single feed fallback)
  • NEWS_FEED_URLS (comma-separated feed URLs; overrides NEWS_FEED_URL)
  • NEWS_REFRESH_INTERVAL_SECONDS (default 900)
  • NEWS_BACKGROUND_REFRESH_ON_START (default true)
  • NEWS_BACKGROUND_REFRESH_ENABLED (default true)
  • NEWS_CLUSTERS_TTL_HOURS
  • GROQ_ENRICH_OTHER_ONLY (default false; set true for cost control)

mcporter examples (all news-mcp calls)

Use your existing config path:

CONFIG=/home/lucky/.openclaw/workspace/config/mcporter.json

Inspect server + tools:

mcporter --config "$CONFIG" list news --schema

1) Latest events

mcporter --config "$CONFIG" call news.get_latest_events topic=crypto limit=10
mcporter --config "$CONFIG" call news.get_latest_events topic=macro limit=5

2) Events for an entity

mcporter --config "$CONFIG" call news.get_events_for_entity entity=Bitcoin limit=10
mcporter --config "$CONFIG" call news.get_events_for_entity entity=ETH limit=10
mcporter --config "$CONFIG" call news.get_events_for_entity entity=ETF limit=10

3) Event summary (by cluster_id)

# First fetch an event id
mcporter --config "$CONFIG" call news.get_latest_events topic=crypto limit=1

# Then summarize it
mcporter --config "$CONFIG" call news.get_event_summary event_id=<cluster_id>

4) Emerging topics

mcporter --config "$CONFIG" call news.detect_emerging_topics limit=10

5) Sentiment for an entity

mcporter --config "$CONFIG" call news.get_news_sentiment entity=Bitcoin timeframe=24h
mcporter --config "$CONFIG" call news.get_news_sentiment entity=Ethereum timeframe=72h