modelscope.cn

kimi-tools

通过 Python 脚本调用 kimi search 和 kimi fetch,用于网页搜索与页面抓取任务,返回结构化数据与 Markdown ?

Installation

$ npx skills add https://modelscope.cn

Also in this package

Other skills from modelscope.cn · top by installs.

npx skills add https://modelscope.cn

Browse all from modelscope.cn

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Skill metadata

Parsed from SKILL.md frontmatter.

Compatibility"需要 Kimi Code 订??

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 1,599 B

History

  1. First recorded snapshot · 0 installs

SKILL.md

Kimi API Tools

前置条件

  • 需要可用的 Kimi Code 订阅,并设置为环境变量:KIMIAPIKEY
  • 需要 Python 3.9 或更高版本,视环境采用 python3python 命令
  • 需要网络可访问权限

快速开始

  1. 设置 API Key:export KIMIAPIKEY=...
  2. 先用 kimi_search.py 做关键词检索。
  3. 再用 kimi_fetch.py 按 URL 抓取正文。

脚本说明

scripts/kimi_search.py

调用 POST /search

python ./scripts/kimi_search.py \
  --query "短剧创作指南" \
  --limit 5 \
  --timeout-seconds 30

参数:

  • --query -> 搜索关键词(必填)
  • --limit -> 返回结果数量(1-20,默认 5)
  • --include-content -> 是否启用页面抓取(默认 false)
  • --timeout-seconds -> 超时时间(默认 30 秒)

scripts/kimi_fetch.py

调用 POST /fetch

python ./scripts/kimi_fetch.py \
  --url "https://example.com" \
  --timeout-seconds 30

参数:

  • --url -> 目标 URL(必填)
  • --timeout-seconds -> 超时时间(默认 30 秒)

逃生通道

若环境中没有 KIMIAPIKEY,可通过 --api-key 参数传入,但非常不建议在命令行中暴露敏感信息。

Agent 使用约定

  • 按需开启 --include-content--limit,以控制 token 成本。