Files
openclaw-skill/openclaw-knowhow-skill/patches/README.md
Selig 4c966a3ad2 Initial commit: OpenClaw Skill Collection
6 custom skills (assign-task, dispatch-webhook, daily-briefing,
task-capture, qmd-brain, tts-voice) with technical documentation.
Compatible with Claude Code, OpenClaw, Codex CLI, and OpenCode.
2026-03-13 10:58:30 +08:00

66 lines
1.8 KiB
Markdown
Executable File
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Skill Seeker Patches
## fetch_and_save 工具
這個 patch 為 Skill Seeker MCP 新增 `fetch_and_save` 工具,可以直接抓取網頁並存檔,**不經過 Claude API**,節省 97%+ 的 token 成本。
### 安裝步驟
```bash
# 1. 確保已安裝 skill-seekers
pip install skill-seekers
# 2. 執行 patch 腳本
python add_fetch_and_save.py
# 3. 重啟 Claude Code
```
### 使用方式
#### 單檔模式
```
mcp__skill-seeker__fetch_and_save(
url="https://docs.example.com/guide.md",
output="docs/guide.md"
)
```
#### 批次模式
```
mcp__skill-seeker__fetch_and_save(urls=[
{"url": "https://docs.example.com/intro.md", "output": "docs/intro.md"},
{"url": "https://docs.example.com/api.md", "output": "docs/api.md"}
])
```
### 參數說明
| 參數 | 類型 | 預設值 | 說明 |
|------|------|--------|------|
| `url` | str | - | 單一 URL需搭配 output |
| `output` | str | - | 輸出檔案路徑 |
| `urls` | list | - | 批次模式:`[{"url": str, "output": str}, ...]` |
| `extract_markdown` | bool | true | 自動從 HTML 提取 markdown |
| `timeout` | int | 30 | 請求超時(秒) |
| `rate_limit` | float | 0.5 | 請求間隔(秒) |
### Token 效率比較
| 方法 | Token 消耗 | 說明 |
|------|-----------|------|
| WebFetch + Write | ~2000/頁 | 內容經過 API 兩次 |
| **fetch_and_save** | **~50/頁** | 只有呼叫和狀態回傳 |
### 如何提示 LLM 使用這個工具
> "請用 `fetch_and_save` 工具抓取網頁並存檔,這樣比較省 token"
或者在 system prompt 中加入:
> "當需要抓取網頁存檔時,優先使用 `mcp__skill-seeker__fetch_and_save` 而非 WebFetch以節省 token"
### 注意事項
- 每次 `pip upgrade skill-seekers` 後需要重新執行 patch
- Patch 腳本會檢查是否已 patch不會重複修改