Z User commited on
Commit
da88712
·
1 Parent(s): 51bc0d6

add Firecrawl as primary web scraper for anti-crawl sites

Browse files

- Add FIRECRAWL_API_KEY to .env
- Update SOUL.md: Firecrawl as step 1 (headless browser + stealth)
- Jina Reader demoted to step 2 fallback
- 5-level fallback chain for WeChat articles

Files changed (1) hide show
  1. SOUL.md +1 -1
SOUL.md CHANGED
@@ -97,7 +97,7 @@ browser_navigate(URL) → browser_snapshot(获取内容) → 分析/提取/截
97
  |---------|---------|
98
  | web_search 无结果 | 换关键词(英文/同义词/更具体)→ 换搜索引擎 → 告知用户 |
99
  | web_extract 失败 | 改用 browser_navigate + snapshot → 告知用户手动查看 |
100
- | 微信公众号文章 | 飞书转发公众号文章会自带标题+摘要+链接,**优先基于已有信息快速回应**。如需全文:① **Jina Reader 代理**:web_extract("https://r.jina.ai/" + 原始URL),Jina 服务端抓取返回 Markdown 正文,免费无需 Key; 搜狗搜索兜底:web_search "site:weixin.sogou.com + 关键词"; 搜文章标题找转载或 Google 缓存; 全部失败则让用户截图或粘贴正文。**禁止直接 curl mp.weixin.qq.com**(会被验证码拦截) |
101
  | terminal 超时 | 缩小任务范围 → 后台运行 → 建议用户本地执行 |
102
  | 文件不存在 | search_files 模糊搜索 → 列出相似文件让用户确认 |
103
  | API 报错 401/403 | 告知用户需要更新凭证/Key |
 
97
  |---------|---------|
98
  | web_search 无结果 | 换关键词(英文/同义词/更具体)→ 换搜索引擎 → 告知用户 |
99
  | web_extract 失败 | 改用 browser_navigate + snapshot → 告知用户手动查看 |
100
+ | 微信公众号文章 | 飞书转发公众号文章会自带标题+摘要+链接,**优先基于已有信息快速回应**。如需全文:① **Firecrawl**(首选):通过 terminal 调用 Firecrawl API 抓取完整正文(headless 浏览器+stealth,反爬能力强),命令:`curl -s -X POST https://api.firecrawl.dev/v1/scrape -H "Content-Type: application/json" -H "Authorization: Bearer $FIRECRAWL_API_KEY" -d '{"url":"目标URL","formats":["markdown"]}'`,返回 JSON 中 `data.markdown` 即为正文;② **Jina Reader 代理**:web_extract("https://r.jina.ai/" + 原始URL),免费无需 Key; 搜狗搜索兜底:web_search "site:weixin.sogou.com + 关键词"; 搜文章标题找转载或 Google 缓存; 全部失败则让用户截图或粘贴正文。**禁止直接 curl 目标网页**(会被验证码拦截) |
101
  | terminal 超时 | 缩小任务范围 → 后台运行 → 建议用户本地执行 |
102
  | 文件不存在 | search_files 模糊搜索 → 列出相似文件让用户确认 |
103
  | API 报错 401/403 | 告知用户需要更新凭证/Key |