npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@caikiji/mcp-search

v1.4.8

Published

MCP server for web search powered by SearXNG — privacy-respecting self-hosted metasearch

Readme

✨ 特性

  • 🌐 网页搜索 — 聚合多引擎结果(Brave、DuckDuckGo、Bing News 等)
  • 📄 内容抓取 — 搜索结果中直接点开链接,转 Markdown
  • 🔍 引擎发现info 查看引擎数量;info scope: "engines" 查看完整列表
  • 🎯 Token 高效 — compact 模式、智能截断、去重
  • 🔒 自建 — 配合自己的 SearXNG 实例,完全隐私可控

安装

npm install -g @caikiji/mcp-search

配置

环境变量

| 变量 | 默认值 | 说明 | |----------|---------|------| | SEARCH_URL | — | SearXNG 实例地址(必填) | | SEARCH_AUTH | — | Basic 认证凭据(user:pass)。如果实例是公开的,留空即可。 | | SEARCH_TIMEOUT | 15000 | SearXNG API 超时(毫秒) | | SEARCH_FETCH_TIMEOUT | 15000 | 页面抓取超时(毫秒) | | SEARCH_DEFAULT_COUNT | 10 | 默认返回结果数(1–50) | | SEARCH_MAX_LENGTH | 8000 | 页面抓取最大字符数(500–50000) | | SEARCH_SNIPPET_LENGTH | 300 | 搜索结果片段截断长度 | | SEARCH_FETCH_UA | Chrome UA | 页面抓取的 User-Agent | | SEARCH_RECOMMENDED_ENGINES | — | 分号分隔的推荐引擎,可附带 引擎名|说明。显示在 info 输出。完整示例见下方配置。 |

MCP 客户端配置

{
  "mcpServers": {
    "search": {
      "command": "npx",
      "args": ["-y", "@caikiji/mcp-search"],
      "env": {
        "SEARCH_URL": "https://search.example.com",
        "SEARCH_AUTH": "user:password",
        "SEARCH_RECOMMENDED_ENGINES": "duckduckgo|通用搜索、隐私优先;bing|图片、新闻;sogou|中文网页;sogou wechat|微信公众号文章;stackoverflow|编程问答;github|代码仓库"
      }
    }
  }
}

工具

搜索

| 工具 | 参数 | 说明 | |------|------|------| | query | query, [language], [categories], [time_range], [engines], [pageno], [count], [format] | 网页搜索,自动去重 + 智能截断。format: "compact" 最小 token 消耗。 | | result | url, [max_length] | 打开搜索结果中的链接,返回 Markdown 正文。 | | info | [scope] | 实例信息。默认:数量、分类、设置。scope: "engines" 显示完整引擎列表。 |

query 参数

| 参数 | 说明 | |------|------| | query | 搜索关键词(必填) | | site | 限定域名,如 github.com。会在查询前追加 site:。 | | language | 语言代码(zh-CNen-USauto)。默认:auto | | categories | 逗号分隔:general, news, images, video, music, it, science, files, social media | | time_range | day, week, month, year | | engines | 逗号分隔引擎名。用 info 查看可用项 | | pageno | 页码。默认:1 | | count | 返回结果数(1–50)。默认:10 | | format | full(标题+URL+摘要)或 compact(仅标题+URL,最少 token)。默认:full | | depth | true 时强制 count=1,自动抓取首条结果的 reader 正文。省掉搜索→挑选→打开的往返。默认:false |

输出格式

Full 模式:

5 results | Sources: duckduckgo,brave
[1] Title
URL: https://...
Src: duckduckgo

Snippet text here (truncated to 300 chars)...

[2] Next Title
URL: https://...
Src: google +2

Compact 模式:

5 results | Sources: duckduckgo
[1] Title — https://...
[2] Next Title — https://...