Skip to main content
Glama
Jarvis News MCP

Jarvis News MCP

by soothill

Jarvis News MCP

一个本地 Model Context Protocol 服务器,用于从 BBC News 和 Sky News 的官方 RSS feed 向 Jarvis 提供最新且注明出处的新闻简报。

该服务器不需要 API 密钥。它只在 Jarvis 调用工具时才获取发布商的 RSS 数据,移除重复的 feed 条目,将 BBC/Sky 的相似报道归组,并依据时效性、feed 中的突出程度、公共影响相关词以及跨发布商的报道覆盖情况对新闻进行排序。

Jarvis 可以调用什么

工具

用途

get_news_summary

返回一个或多个发布商的排序简报。

search_news

查找有关人物、地点、组织或事件的最新新闻。

list_news_feeds

显示所有已配置的官方 feed 和类别。

结果包含结构化 JSON 以及可读的 Markdown。每条新闻都保留其发布商、时间戳和直接链接。如果某个 feed 不可用,其他 feed 仍会正常返回,并且响应中会包含一条警告。

Related MCP server: MCP News Server

安装

要求:Node.js 20 或更高版本。

git clone https://github.com/soothill/news-mcp.git
cd news-mcp
npm ci
npm run build

构建后的服务器入口点是 dist/index.js。请将项目文件夹放在固定位置,以便 Jarvis 能够持续启动它。

连接到 Jarvis

如果 Jarvis 支持常见的 mcpServers 配置格式,请将此条目添加到其 MCP 配置中:

{
  "mcpServers": {
    "news": {
      "command": "node",
      "args": ["/absolute/path/to/News Feed/dist/index.js"]
    }
  }
}

请将路径替换为此项目构建后的 dist/index.js 的绝对路径。在 macOS 或 Linux 上,在项目目录中运行 pwd 即可找到该路径中的项目部分。可在 jarvis.mcp.example.json 中找到可直接编辑的版本。更改配置后请重启 Jarvis。

此服务器通过标准输入/输出使用 MCP,这适用于将服务器作为子进程启动的本地助手。它刻意不向标准输出写入任何普通输出,因为该通道保留给 MCP 消息使用。

给 Jarvis 的示例请求:

  • “给我过去 12 小时内 BBC 和 Sky 最重要的五条新闻。”

  • “今天英国政坛发生了什么?请检查两个来源。”

  • “搜索 BBC 和 Sky 过去三天科技新闻中关于量子计算的内容。”

  • “刷新 feed,并给我一份附有来源链接的简明晨间简报。”

为获得最佳的综合简报,Jarvis 应使用两个来源和 top 类别调用 get_news_summary。若要进行更广泛的研究,它可以在一次调用中请求多个类别。

更新现有安装

在项目目录中:

git pull --ff-only
npm ci
npm run build

之后重启 Jarvis,以便它启动新构建。

工具输入

get_news_summary 接受:

  • sources:bbc、sky 或两者;默认为两者。

  • categories:top、uk、world、us、business、politics、technology、science、health 和 entertainment 中的一个或多个;默认为 top。

  • lookbackHours:1–168;默认为 24。

  • maxStories:1–30;默认为 10。

  • refresh:绕过短暂的内存缓存;默认为 false。

search_news 接受相同的输入,外加一个必填的 query。

Sky 目前不提供已配置的 science 或 health RSS feed。针对这些组合的请求将返回 BBC 的结果,并附带一条明确的警告。

运行时设置

可选的环境变量:

变量

默认值

允许范围

含义

NEWS_CACHE_TTL_SECONDS

180

0–3600

每个 feed 的内存缓存生存时间。

NEWS_HTTP_TIMEOUT_MS

10000

1000–30000

每个发布商请求的超时时间。

NEWS_USER_AGENT

JarvisNewsMCP/1.0...

—

发送给 feed 的 HTTP User-Agent。

开发与检查

npm run check
npm test
npm run test:live

test:live 会连接真实的 BBC 和 Sky 头条新闻 feed,并打印五条当前新闻。所有其他测试都是确定性的,不需要互联网。

故障排除

  • 如果 Jarvis 无法启动服务器,请确认 node --version 显示为 20 或更高版本,并且其 MCP 配置中的路径是绝对路径。

  • 如果缺少 dist/index.js,请依次运行 npm ci 和 npm run build。

  • 如果简报中包含 feed 警告,请使用 refresh: true 重试。服务器即使在某个 feed 不可用时,也会返回其他正常的 feed。

  • 运行 npm run test:live,检查这台机器是否可以访问两家发布商。

  • MCP 传输使用标准输入/输出。直接运行 node dist/index.js 似乎没有任何反应,因为它正在等待 MCP 客户端;这是预期行为。

“重要性”如何评估

服务器对其排序方式保持透明。当一条新闻更新、更接近发布商 feed 的顶部、出现在头条新闻 feed 中、包含与重大公共影响相关的词,或得到两家发布商的独立报道时,它就会排得更靠前。这是一种自动化的相关性评估,而非编辑或事实性判定。

返回的摘要文本是发布商提供的 RSS 元数据的简短清理版本。Jarvis 可以将这些注明出处的结果转化为更具对话感的简报,但不应捏造返回新闻中不存在的细节。feed 文本被视为不可信数据,服务器绝不会将其解释为指令。

数据与发布商条款

本项目使用发布商的官方 RSS 端点,并保留署名和链接。在个人使用之外重新分发或发布生成的简报之前,请查阅 BBC 和 Sky 当前的 feed 条款。本项目不会抓取或存储任何文章页面、图片、cookie 或用户数据。

Available Tools

3 tools
get_news_summaryGet BBC and Sky news summaryA
Read-onlyIdempotent

Fetch and rank important recent events from official BBC News and Sky News RSS feeds. Returns short publisher-supplied summaries, links, timestamps, source corroboration, and partial-feed warnings.

Inputs: refresh, sources, categories, maxStories, +1 more. Returns: stories, warnings, storyCount, generatedAt, +4 more

list_news_feedsList configured news feedsA
Read-onlyIdempotent

List the official BBC News and Sky News RSS endpoints and categories this server can query.

Inputs: no named parameters. Returns: feeds

search_newsSearch BBC and Sky newsA
Read-onlyIdempotent

Search recent BBC News and Sky News RSS stories for a specific person, place, organisation, or event, then return ranked and attributed matches.

Inputs: query (required), refresh, sources, categories, +2 more. Returns: stories, warnings, storyCount, generatedAt, +4 more

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.4/5.0

    Scored across 3 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: fetching top stories, searching by query, and listing available feeds/categories. There is no realistic confusion between broad summaries, targeted search, or feed metadata.

    Naming Consistency5/5

    All tool names follow a consistent lowercase snake_case verb_noun pattern: get_news_summary, search_news, and list_news_feeds. The naming is predictable and easy to pattern-match.

    Tool Count5/5

    Three tools is well-scoped for a focused news RSS server. Each tool covers a distinct user need without redundancy or wasted surface area.

    Completeness4/5

    The core news workflows—listing available sources, getting a ranked summary, and searching stories—are covered. The main minor gap is that list_news_feeds advertises categories/endpoints but there is no explicit tool to fetch news from a specific category directly.

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables searching news, fetching top headlines, listing sources, and generating tech briefings via NewsAPI, with an optional browser frontend.
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      Fetches news from trusted global sources using NewsAPI and RSS feeds, enabling search, headline retrieval, and source listing.
      -
    • A
      license
      A
      quality
      B
      maintenance
      Enables news search and headline retrieval using NewsAPI. Supports getting top headlines by country and category, and searching articles across thousands of sources.
      2
      MIT