modsearch

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

ModSearch - Search Bridge Skill

ModSearch - 搜索桥接技能

Use this skill when:
  • User asks for web search, latest updates, or source-backed answers
  • Current model/toolchain cannot perform direct search reliably
  • You need structured search results before downstream summarization/fetch
使用该技能的场景:
  • 用户需要网页搜索、最新更新或有来源支撑的回答
  • 当前模型/工具链无法可靠执行直接搜索
  • 你需要在下游总结/内容抓取前获取结构化搜索结果

Prerequisites

前置依赖

bash
modsearch --version
If using the default provider (
gemini-cli
), ensure Gemini CLI is installed and authenticated:
bash
gemini --version
If missing:
bash
npm install -g @google/gemini-cli
gemini
Or run directly with
npx
(no global install required):
bash
npx @google/gemini-cli          # launch interactive auth
bash
modsearch --version
如果使用默认提供商(
gemini-cli
),请确保已安装Gemini CLI并完成身份验证:
bash
gemini --version
如果缺失可执行文件:
bash
npm install -g @google/gemini-cli
gemini
或者直接使用
npx
运行(无需全局安装):
bash
npx @google/gemini-cli          # 启动交互式身份验证

Command

命令

bash
modsearch -q "<query>"
bash
modsearch -q "<query>"

or via npx

或通过npx运行

npx @liustack/modsearch -q "<query>"

Optional:

```bash
modsearch -q "<query>" -o <output-json-path> -p <provider> -m <model> --max-results <n> --prompt "<extra constraints>"
npx @liustack/modsearch -q "<query>"

可选参数:

```bash
modsearch -q "<query>" -o <output-json-path> -p <provider> -m <model> --max-results <n> --prompt "<extra constraints>"

Workflow

工作流

  1. Run
    modsearch
    with the user query.
  2. Parse JSON output.
  3. Use
    summary
    and
    items
    as evidence for reasoning or for selecting URLs to fetch.
  4. If
    uncertainty
    is non-empty, explicitly communicate ambiguity to the user.
  1. 携带用户查询运行
    modsearch
  2. 解析JSON输出
  3. 使用
    summary
    items
    作为推理证据,或用于选择要抓取的URL
  4. 如果
    uncertainty
    不为空,明确向用户告知存在歧义

Output Contract

输出约定

  • summary
    : high-level synthesis of search findings
  • items
    : normalized list (
    title
    ,
    url
    ,
    snippet
    ,
    source
    ,
    published_at
    ,
    relevance
    )
  • uncertainty
    : caveats, missing data, or confidence risks
Detailed schema:
references/output-schema.md
  • summary
    :搜索结果的高层级汇总
  • items
    :标准化列表(包含
    title
    url
    snippet
    source
    published_at
    relevance
    字段)
  • uncertainty
    :注意事项、缺失数据或置信度风险
详细schema见:
references/output-schema.md

Failure Handling

故障处理

  • If provider command fails (missing auth, quota, network, binary not found), report exact error and suggest provider setup checks.
  • If JSON is partially malformed, keep
    rawText
    and continue with best-effort extraction.
  • 如果提供商命令运行失败(身份验证缺失、配额不足、网络问题、二进制文件未找到),上报准确错误并建议检查提供商配置
  • 如果JSON部分损坏,保留
    rawText
    并继续尽最大努力提取内容

Implementation Note

实现说明

v1 uses Gemini CLI as the default provider (
gemini -p
with JSON output mode).
The architecture is provider-extensible and can support any search-capable model or service provider in future versions.
v1版本使用Gemini CLI作为默认提供商(
gemini -p
配合JSON输出模式)。 该架构支持扩展提供商,未来版本可对接任何具备搜索能力的模型或服务提供商。