[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6CJZ04CVVBSVN5CXCSZMS3Q":3,"skill-same:01M6CJZ04CVVBSVN5CXCSZMS3Q":68},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":22,"publishedAt":35,"linkOnly":36,"markdownContent":37,"markdownBody":38,"frontMatter":39,"refName":41,"commitSha":42,"skillDirectory":43,"forksCount":44,"repositoryHtmlUrl":45,"repositoryHomepageUrl":6,"ownerHtmlUrl":46,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":47,"install":48,"resources":61},"01M6CJZ04CVVBSVN5CXCSZMS3Q","duckduckgo-search",null,"Performs web searches using DuckDuckGo to retrieve real-time information from the internet. Use when the user needs to search for current events, documentation, tutorials, or any information that requires web search capabilities.","kbarbel640-del\u002Fskills","kbarbel640-del","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F255315490?v=4","01M6CJPPQGCCESXMG3K7BBGQ5J","01M6CJPPX2PB2BCZERFVM2C2B3",1,"MIT","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F10e9928a\u002Fduckduckgo-search\u002FSKILL.md",[17],{"categoryNo":18,"categoryName":19,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000016","图像与多媒体","SCENARIO","使用场景",[23,24,25,26,27,28,29,30,31,32,33,34],"search","duckduckgo search","python","web","documentation","capabilities","real-time","Bash","web search","user","use","uv","2026-11-10 10:12:30",false,"---\nname: duckduckgo-search\ndescription: Performs web searches using DuckDuckGo to retrieve real-time information from the internet. Use when the user needs to search for current events, documentation, tutorials, or any information that requires web search capabilities.\nallowed-tools: Bash(duckduckgo-search:*), Bash(python:*), Bash(pip:*), Bash(uv:*)\n---\n\n# DuckDuckGo Web Search Skill\n\n这个技能通过 DuckDuckGo 搜索引擎实现网络搜索功能，帮助获取实时信息。\n\n## 功能特性\n\n- ? 基于 DuckDuckGo 的隐私友好型搜索\n- ? 支持新闻搜索\n- ?️ 支持图片搜索\n- ? 支持视频搜索\n- ? 无需 API Key，免费使用\n- ? 保护隐私，不追踪用户\n\n## 安装\n\n```bash\n# 使用 uv 安装（推荐）\nuv pip install duckduckgo-search\n\n# 或使用 pip 安装\npip install duckduckgo-search\n```\n\n## 快速开始\n\n### 命令行方式\n\n```bash\n# 基础文本搜索\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text('Python tutorial', max_results=5))\n    for r in results:\n        print(f\\\"标题: {r['title']}\\\")\n        print(f\\\"链接: {r['href']}\\\")\n        print(f\\\"摘要: {r['body']}\\\")\n        print('---')\n\"\n```\n\n## 搜索类型\n\n### 1. 文本搜索 (Text Search)\n\n最常用的搜索方式，返回网页结果：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nquery = 'your search query'\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text(\n        query,\n        region='cn-zh',      # 地区设置：cn-zh(中国), us-en(美国), wt-wt(全球)\n        safesearch='moderate', # 安全搜索：on, moderate, off\n        timelimit='m',       # 时间范围：d(天), w(周), m(月), y(年), None(不限)\n        max_results=10       # 最大结果数\n    ))\n    \n    for i, r in enumerate(results, 1):\n        print(f\\\"{i}. {r['title']}\\\")\n        print(f\\\"   URL: {r['href']}\\\")\n        print(f\\\"   摘要: {r['body'][:100]}...\\\")\n        print()\n\"\n```\n\n### 2. 新闻搜索 (News Search)\n\n搜索最新新闻：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.news(\n        'AI technology',\n        region='wt-wt',\n        safesearch='moderate',\n        timelimit='d',       # d=过去24小时, w=过去一周, m=过去一月\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"? {r['title']}\\\")\n        print(f\\\"   来源: {r['source']}\\\")\n        print(f\\\"   时间: {r['date']}\\\")\n        print(f\\\"   链接: {r['url']}\\\")\n        print()\n\"\n```\n\n### 3. 图片搜索 (Image Search)\n\n搜索图片资源：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.images(\n        'cute cats',\n        region='wt-wt',\n        safesearch='moderate',\n        size='Medium',       # Small, Medium, Large, Wallpaper\n        type_image='photo',  # photo, clipart, gif, transparent, line\n        layout='Square',     # Square, Tall, Wide\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"?️ {r['title']}\\\")\n        print(f\\\"   图片: {r['image']}\\\")\n        print(f\\\"   缩略图: {r['thumbnail']}\\\")\n        print(f\\\"   来源: {r['source']}\\\")\n        print()\n\"\n```\n\n### 4. 视频搜索 (Video Search)\n\n搜索视频内容：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.videos(\n        'Python programming',\n        region='wt-wt',\n        safesearch='moderate',\n        timelimit='w',       # d, w, m\n        resolution='high',   # high, standard\n        duration='medium',   # short, medium, long\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"? {r['title']}\\\")\n        print(f\\\"   时长: {r.get('duration', 'N\u002FA')}\\\")\n        print(f\\\"   来源: {r['publisher']}\\\")\n        print(f\\\"   链接: {r['content']}\\\")\n        print()\n\"\n```\n\n### 5. 即时回答 (Instant Answers)\n\n获取 DuckDuckGo 的即时回答：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = ddgs.answers('what is python programming language')\n    \n    for r in results:\n        print(f\\\"? {r['text']}\\\")\n        print(f\\\"   来源: {r.get('url', 'DuckDuckGo')}\\\")\n\"\n```\n\n### 6. 建议搜索 (Suggestions)\n\n获取搜索建议：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    suggestions = list(ddgs.suggestions('python'))\n    \n    print('? 搜索建议:')\n    for s in suggestions:\n        print(f\\\"   - {s['phrase']}\\\")\n\"\n```\n\n### 7. 地图搜索 (Maps Search)\n\n搜索地点信息：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.maps(\n        'coffee shop',\n        place='Beijing, China',\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"? {r['title']}\\\")\n        print(f\\\"   地址: {r['address']}\\\")\n        print(f\\\"   电话: {r.get('phone', 'N\u002FA')}\\\")\n        print(f\\\"   坐标: {r['latitude']}, {r['longitude']}\\\")\n        print()\n\"\n```\n\n## 实用脚本\n\n### 通用搜索函数\n\n创建一个可复用的搜索脚本：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nimport json\n\ndef web_search(query, search_type='text', max_results=5, region='wt-wt', timelimit=None):\n    '''\n    执行 DuckDuckGo 搜索\n    \n    参数:\n        query: 搜索关键词\n        search_type: 搜索类型 (text, news, images, videos)\n        max_results: 最大结果数\n        region: 地区 (cn-zh, us-en, wt-wt)\n        timelimit: 时间限制 (d, w, m, y)\n    '''\n    with DDGS() as ddgs:\n        if search_type == 'text':\n            results = list(ddgs.text(query, region=region, timelimit=timelimit, max_results=max_results))\n        elif search_type == 'news':\n            results = list(ddgs.news(query, region=region, timelimit=timelimit, max_results=max_results))\n        elif search_type == 'images':\n            results = list(ddgs.images(query, region=region, max_results=max_results))\n        elif search_type == 'videos':\n            results = list(ddgs.videos(query, region=region, timelimit=timelimit, max_results=max_results))\n        else:\n            results = []\n    \n    return results\n\n# 使用示例\nquery = 'Python 3.12 new features'\nresults = web_search(query, search_type='text', max_results=5)\n\nprint(f'? 搜索: {query}')\nprint(f'? 找到 {len(results)} 个结果')\nprint()\n\nfor i, r in enumerate(results, 1):\n    print(f\\\"{i}. {r['title']}\\\")\n    print(f\\\"   {r['href']}\\\")\n    print(f\\\"   {r['body'][:150]}...\\\")\n    print()\n\"\n```\n\n### 搜索并保存结果\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nimport json\nfrom datetime import datetime\n\nquery = 'latest tech news'\noutput_file = f'search_results_{datetime.now().strftime(\\\"%Y%m%d_%H%M%S\\\")}.json'\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text(query, max_results=10))\n\n# 保存到 JSON 文件\nwith open(output_file, 'w', encoding='utf-8') as f:\n    json.dump({\n        'query': query,\n        'timestamp': datetime.now().isoformat(),\n        'results': results\n    }, f, ensure_ascii=False, indent=2)\n\nprint(f'✅ 搜索结果已保存到: {output_file}')\nprint(f'? 共 {len(results)} 条结果')\n\"\n```\n\n### 多关键词批量搜索\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nimport time\n\nqueries = [\n    'Python best practices 2024',\n    'React vs Vue 2024',\n    'AI development tools'\n]\n\nall_results = {}\n\nwith DDGS() as ddgs:\n    for query in queries:\n        print(f'? 搜索: {query}')\n        results = list(ddgs.text(query, max_results=3))\n        all_results[query] = results\n        print(f'   找到 {len(results)} 个结果')\n        time.sleep(1)  # 避免请求过快\n\nprint()\nprint('=' * 50)\nprint('? 搜索汇总')\nprint('=' * 50)\n\nfor query, results in all_results.items():\n    print(f'\\n? {query}:')\n    for i, r in enumerate(results, 1):\n        print(f\\\"   {i}. {r['title'][:60]}...\\\")\n\"\n```\n\n## 参数说明\n\n### 地区代码 (region)\n\n| 代码 | 地区 |\n|------|------|\n| `cn-zh` | 中国 |\n| `us-en` | 美国 |\n| `uk-en` | 英国 |\n| `jp-jp` | 日本 |\n| `kr-kr` | 韩国 |\n| `wt-wt` | 全球 (无地区限制) |\n\n### 时间限制 (timelimit)\n\n| 值 | 含义 |\n|----|------|\n| `d` | 过去 24 小时 |\n| `w` | 过去一周 |\n| `m` | 过去一月 |\n| `y` | 过去一年 |\n| `None` | 不限制 |\n\n### 安全搜索 (safesearch)\n\n| 值 | 含义 |\n|----|------|\n| `on` | 严格过滤 |\n| `moderate` | 适度过滤 (默认) |\n| `off` | 关闭过滤 |\n\n## 错误处理\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nfrom duckduckgo_search.exceptions import DuckDuckGoSearchException\n\ntry:\n    with DDGS() as ddgs:\n        results = list(ddgs.text('test query', max_results=5))\n        print(f'✅ 搜索成功，找到 {len(results)} 个结果')\nexcept DuckDuckGoSearchException as e:\n    print(f'❌ 搜索出错: {e}')\nexcept Exception as e:\n    print(f'❌ 未知错误: {e}')\n\"\n```\n\n## 使用代理\n\n如果需要使用代理：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\n# 设置代理\nproxy = 'http:\u002F\u002F127.0.0.1:7890'  # 替换为你的代理地址\n\nwith DDGS(proxy=proxy) as ddgs:\n    results = list(ddgs.text('test query', max_results=5))\n    print(f'通过代理搜索成功，找到 {len(results)} 个结果')\n\"\n```\n\n## 常见问题\n\n**安装失败？**\n```bash\n# 确保 pip 是最新版本\npip install --upgrade pip\npip install duckduckgo-search\n\n# 或使用 uv\nuv pip install duckduckgo-search\n```\n\n**搜索无结果？**\n```bash\n# 检查网络连接\n# 尝试使用代理\n# 减少搜索关键词复杂度\n# 检查地区设置是否正确\n```\n\n**请求被限制？**\n```bash\n# 在多次搜索之间添加延迟\nimport time\ntime.sleep(1)  # 等待 1 秒\n\n# 减少单次请求的结果数量\nmax_results=5  # 而不是 50\n```\n\n## 与其他工具集成\n\n### 结合 browser-use 获取详细内容\n\n```bash\n# 1. 先用 DuckDuckGo 搜索\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text('Python async tutorial', max_results=1))\n    if results:\n        url = results[0]['href']\n        print(f'URL: {url}')\n\"\n\n# 2. 用 browser-use 打开并获取详细内容\nbrowser-use open \u003Curl_from_search>\nbrowser-use state\n```\n\n## 注意事项\n\n⚠️ **使用建议**：\n\n1. **遵守使用频率限制**：避免短时间内大量请求\n2. **合理设置结果数量**：不要一次请求过多结果\n3. **添加适当延迟**：批量搜索时在请求之间添加 `time.sleep()`\n4. **处理异常情况**：始终添加错误处理代码\n5. **尊重版权**：搜索结果仅供参考，注意内容版权\n","# DuckDuckGo Web Search Skill\n\n这个技能通过 DuckDuckGo 搜索引擎实现网络搜索功能，帮助获取实时信息。\n\n## 功能特性\n\n- ? 基于 DuckDuckGo 的隐私友好型搜索\n- ? 支持新闻搜索\n- ?️ 支持图片搜索\n- ? 支持视频搜索\n- ? 无需 API Key，免费使用\n- ? 保护隐私，不追踪用户\n\n## 安装\n\n```bash\n# 使用 uv 安装（推荐）\nuv pip install duckduckgo-search\n\n# 或使用 pip 安装\npip install duckduckgo-search\n```\n\n## 快速开始\n\n### 命令行方式\n\n```bash\n# 基础文本搜索\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text('Python tutorial', max_results=5))\n    for r in results:\n        print(f\\\"标题: {r['title']}\\\")\n        print(f\\\"链接: {r['href']}\\\")\n        print(f\\\"摘要: {r['body']}\\\")\n        print('---')\n\"\n```\n\n## 搜索类型\n\n### 1. 文本搜索 (Text Search)\n\n最常用的搜索方式，返回网页结果：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nquery = 'your search query'\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text(\n        query,\n        region='cn-zh',      # 地区设置：cn-zh(中国), us-en(美国), wt-wt(全球)\n        safesearch='moderate', # 安全搜索：on, moderate, off\n        timelimit='m',       # 时间范围：d(天), w(周), m(月), y(年), None(不限)\n        max_results=10       # 最大结果数\n    ))\n    \n    for i, r in enumerate(results, 1):\n        print(f\\\"{i}. {r['title']}\\\")\n        print(f\\\"   URL: {r['href']}\\\")\n        print(f\\\"   摘要: {r['body'][:100]}...\\\")\n        print()\n\"\n```\n\n### 2. 新闻搜索 (News Search)\n\n搜索最新新闻：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.news(\n        'AI technology',\n        region='wt-wt',\n        safesearch='moderate',\n        timelimit='d',       # d=过去24小时, w=过去一周, m=过去一月\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"? {r['title']}\\\")\n        print(f\\\"   来源: {r['source']}\\\")\n        print(f\\\"   时间: {r['date']}\\\")\n        print(f\\\"   链接: {r['url']}\\\")\n        print()\n\"\n```\n\n### 3. 图片搜索 (Image Search)\n\n搜索图片资源：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.images(\n        'cute cats',\n        region='wt-wt',\n        safesearch='moderate',\n        size='Medium',       # Small, Medium, Large, Wallpaper\n        type_image='photo',  # photo, clipart, gif, transparent, line\n        layout='Square',     # Square, Tall, Wide\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"?️ {r['title']}\\\")\n        print(f\\\"   图片: {r['image']}\\\")\n        print(f\\\"   缩略图: {r['thumbnail']}\\\")\n        print(f\\\"   来源: {r['source']}\\\")\n        print()\n\"\n```\n\n### 4. 视频搜索 (Video Search)\n\n搜索视频内容：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.videos(\n        'Python programming',\n        region='wt-wt',\n        safesearch='moderate',\n        timelimit='w',       # d, w, m\n        resolution='high',   # high, standard\n        duration='medium',   # short, medium, long\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"? {r['title']}\\\")\n        print(f\\\"   时长: {r.get('duration', 'N\u002FA')}\\\")\n        print(f\\\"   来源: {r['publisher']}\\\")\n        print(f\\\"   链接: {r['content']}\\\")\n        print()\n\"\n```\n\n### 5. 即时回答 (Instant Answers)\n\n获取 DuckDuckGo 的即时回答：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = ddgs.answers('what is python programming language')\n    \n    for r in results:\n        print(f\\\"? {r['text']}\\\")\n        print(f\\\"   来源: {r.get('url', 'DuckDuckGo')}\\\")\n\"\n```\n\n### 6. 建议搜索 (Suggestions)\n\n获取搜索建议：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    suggestions = list(ddgs.suggestions('python'))\n    \n    print('? 搜索建议:')\n    for s in suggestions:\n        print(f\\\"   - {s['phrase']}\\\")\n\"\n```\n\n### 7. 地图搜索 (Maps Search)\n\n搜索地点信息：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.maps(\n        'coffee shop',\n        place='Beijing, China',\n        max_results=10\n    ))\n    \n    for r in results:\n        print(f\\\"? {r['title']}\\\")\n        print(f\\\"   地址: {r['address']}\\\")\n        print(f\\\"   电话: {r.get('phone', 'N\u002FA')}\\\")\n        print(f\\\"   坐标: {r['latitude']}, {r['longitude']}\\\")\n        print()\n\"\n```\n\n## 实用脚本\n\n### 通用搜索函数\n\n创建一个可复用的搜索脚本：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nimport json\n\ndef web_search(query, search_type='text', max_results=5, region='wt-wt', timelimit=None):\n    '''\n    执行 DuckDuckGo 搜索\n    \n    参数:\n        query: 搜索关键词\n        search_type: 搜索类型 (text, news, images, videos)\n        max_results: 最大结果数\n        region: 地区 (cn-zh, us-en, wt-wt)\n        timelimit: 时间限制 (d, w, m, y)\n    '''\n    with DDGS() as ddgs:\n        if search_type == 'text':\n            results = list(ddgs.text(query, region=region, timelimit=timelimit, max_results=max_results))\n        elif search_type == 'news':\n            results = list(ddgs.news(query, region=region, timelimit=timelimit, max_results=max_results))\n        elif search_type == 'images':\n            results = list(ddgs.images(query, region=region, max_results=max_results))\n        elif search_type == 'videos':\n            results = list(ddgs.videos(query, region=region, timelimit=timelimit, max_results=max_results))\n        else:\n            results = []\n    \n    return results\n\n# 使用示例\nquery = 'Python 3.12 new features'\nresults = web_search(query, search_type='text', max_results=5)\n\nprint(f'? 搜索: {query}')\nprint(f'? 找到 {len(results)} 个结果')\nprint()\n\nfor i, r in enumerate(results, 1):\n    print(f\\\"{i}. {r['title']}\\\")\n    print(f\\\"   {r['href']}\\\")\n    print(f\\\"   {r['body'][:150]}...\\\")\n    print()\n\"\n```\n\n### 搜索并保存结果\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nimport json\nfrom datetime import datetime\n\nquery = 'latest tech news'\noutput_file = f'search_results_{datetime.now().strftime(\\\"%Y%m%d_%H%M%S\\\")}.json'\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text(query, max_results=10))\n\n# 保存到 JSON 文件\nwith open(output_file, 'w', encoding='utf-8') as f:\n    json.dump({\n        'query': query,\n        'timestamp': datetime.now().isoformat(),\n        'results': results\n    }, f, ensure_ascii=False, indent=2)\n\nprint(f'✅ 搜索结果已保存到: {output_file}')\nprint(f'? 共 {len(results)} 条结果')\n\"\n```\n\n### 多关键词批量搜索\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nimport time\n\nqueries = [\n    'Python best practices 2024',\n    'React vs Vue 2024',\n    'AI development tools'\n]\n\nall_results = {}\n\nwith DDGS() as ddgs:\n    for query in queries:\n        print(f'? 搜索: {query}')\n        results = list(ddgs.text(query, max_results=3))\n        all_results[query] = results\n        print(f'   找到 {len(results)} 个结果')\n        time.sleep(1)  # 避免请求过快\n\nprint()\nprint('=' * 50)\nprint('? 搜索汇总')\nprint('=' * 50)\n\nfor query, results in all_results.items():\n    print(f'\\n? {query}:')\n    for i, r in enumerate(results, 1):\n        print(f\\\"   {i}. {r['title'][:60]}...\\\")\n\"\n```\n\n## 参数说明\n\n### 地区代码 (region)\n\n| 代码 | 地区 |\n|------|------|\n| `cn-zh` | 中国 |\n| `us-en` | 美国 |\n| `uk-en` | 英国 |\n| `jp-jp` | 日本 |\n| `kr-kr` | 韩国 |\n| `wt-wt` | 全球 (无地区限制) |\n\n### 时间限制 (timelimit)\n\n| 值 | 含义 |\n|----|------|\n| `d` | 过去 24 小时 |\n| `w` | 过去一周 |\n| `m` | 过去一月 |\n| `y` | 过去一年 |\n| `None` | 不限制 |\n\n### 安全搜索 (safesearch)\n\n| 值 | 含义 |\n|----|------|\n| `on` | 严格过滤 |\n| `moderate` | 适度过滤 (默认) |\n| `off` | 关闭过滤 |\n\n## 错误处理\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\nfrom duckduckgo_search.exceptions import DuckDuckGoSearchException\n\ntry:\n    with DDGS() as ddgs:\n        results = list(ddgs.text('test query', max_results=5))\n        print(f'✅ 搜索成功，找到 {len(results)} 个结果')\nexcept DuckDuckGoSearchException as e:\n    print(f'❌ 搜索出错: {e}')\nexcept Exception as e:\n    print(f'❌ 未知错误: {e}')\n\"\n```\n\n## 使用代理\n\n如果需要使用代理：\n\n```bash\npython -c \"\nfrom duckduckgo_search import DDGS\n\n# 设置代理\nproxy = 'http:\u002F\u002F127.0.0.1:7890'  # 替换为你的代理地址\n\nwith DDGS(proxy=proxy) as ddgs:\n    results = list(ddgs.text('test query', max_results=5))\n    print(f'通过代理搜索成功，找到 {len(results)} 个结果')\n\"\n```\n\n## 常见问题\n\n**安装失败？**\n```bash\n# 确保 pip 是最新版本\npip install --upgrade pip\npip install duckduckgo-search\n\n# 或使用 uv\nuv pip install duckduckgo-search\n```\n\n**搜索无结果？**\n```bash\n# 检查网络连接\n# 尝试使用代理\n# 减少搜索关键词复杂度\n# 检查地区设置是否正确\n```\n\n**请求被限制？**\n```bash\n# 在多次搜索之间添加延迟\nimport time\ntime.sleep(1)  # 等待 1 秒\n\n# 减少单次请求的结果数量\nmax_results=5  # 而不是 50\n```\n\n## 与其他工具集成\n\n### 结合 browser-use 获取详细内容\n\n```bash\n# 1. 先用 DuckDuckGo 搜索\npython -c \"\nfrom duckduckgo_search import DDGS\n\nwith DDGS() as ddgs:\n    results = list(ddgs.text('Python async tutorial', max_results=1))\n    if results:\n        url = results[0]['href']\n        print(f'URL: {url}')\n\"\n\n# 2. 用 browser-use 打开并获取详细内容\nbrowser-use open \u003Curl_from_search>\nbrowser-use state\n```\n\n## 注意事项\n\n⚠️ **使用建议**：\n\n1. **遵守使用频率限制**：避免短时间内大量请求\n2. **合理设置结果数量**：不要一次请求过多结果\n3. **添加适当延迟**：批量搜索时在请求之间添加 `time.sleep()`\n4. **处理异常情况**：始终添加错误处理代码\n5. **尊重版权**：搜索结果仅供参考，注意内容版权\n",{"name":5,"description":7,"allowed-tools":40},"Bash(duckduckgo-search:*), Bash(python:*), Bash(pip:*), Bash(uv:*)","main","e7e336ac628c3e3bd771aff1aaa469c93778f94a","skills\u002F10e9928a\u002Fduckduckgo-search",0,"https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del","2026-08-23 22:39:37",{"source":8,"skillName":5,"commands":49,"prompt":59,"zipAvailable":60},[50,53,56],{"tool":51,"command":52},"npx","npx skills add kbarbel640-del\u002Fskills --skill duckduckgo-search",{"tool":54,"command":55},"bunx","bunx skills add kbarbel640-del\u002Fskills --skill duckduckgo-search",{"tool":57,"command":58},"pnpm","pnpm dlx skills add kbarbel640-del\u002Fskills --skill duckduckgo-search","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F10e9928a\u002Fduckduckgo-search\u002FSKILL.md",true,[62],{"path":63,"resourceType":64,"resourceTypeDesc":65,"sizeBytes":66,"sourceHtmlUrl":67},"_meta.json","REFERENCE","参考文档",500,"https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F10e9928a\u002Fduckduckgo-search\u002F_meta.json",[69,100,126,147,153,173],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":80,"publishedAt":35},"01M6G8J55967D6281ACMKAKTEQ","crowd-prompting","A marketplace where AI agents improve prompts, system instructions, tool descriptions, and other text-based content with domain expertise from real-world operations — and earn tokens for valuable contributions.","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fzzadrian\u002Fcrowd-prompting\u002FSKILL.md",[75],{"categoryNo":76,"categoryName":77,"taxonomyType":78,"taxonomyTypeDesc":79},"01JBSEEDCAT000000000000036","内容创作者","PROFESSION","适用职业",[81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99],"crowd prompting","prompting","api","with","tokens","domain","world","prompts","operations","instructions","text","tool","system","improve","productivity","marketplace","https","content","ai agents",{"skillNo":101,"name":102,"nameZh":6,"description":103,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":104,"categories":105,"keywords":109,"publishedAt":35},"01M6G8J0PKPAYVET6BWE8W4C26","dilemm-ai","Compete in DilemmAI, the prisoner's dilemma AI arena at dilemm.ai. Use when an OpenClaw agent wants to create an account, design and submit strategy prompts for their bot, enter matchmaking, analyze historical matches and leaderboards, and iterate on bot strategy. Requires headless browser automation (no API available yet).","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fzyori\u002Fdilemm-ai\u002FSKILL.md",[106],{"categoryNo":107,"categoryName":108,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000023","Skill与智能体开发",[110,83,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,88,33],"dilemm ai","arena","analyze","browser","openclaw agent","create","automation","browser automation","bot","openclaw","design","strategy","headless","compete","submit","matchmaking",{"skillNo":127,"name":128,"nameZh":6,"description":129,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":130,"categories":131,"keywords":135,"publishedAt":35},"01M6G8HWAF3K9SW7NP3Z83CPJ6","arxiv-paper-reviews","Interact with arXiv Crawler API to fetch papers, read reviews, and submit comments. Use when working with arXiv papers, fetching paper lists by date\u002Fcategory\u002Finterest, viewing paper details with comments, or submitting paper reviews via API at http:\u002F\u002F150.158.152.82:8000.","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fzxrys\u002Fweak-accept\u002FSKILL.md",[132],{"categoryNo":133,"categoryName":134,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000021","资料检索与研究",[136,137,138,139,140,141,142,84,143,124,33,144,83,145,146],"arxiv paper reviews","reviews","arxiv","paper","crawler","papers","comments","fetch","read","http","via",{"skillNo":148,"name":128,"nameZh":6,"description":129,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":149,"categories":150,"keywords":152,"publishedAt":35},"01M6G8HQJ7N7WMY6YV7D7SSJ16","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fzxrys\u002Farxiv-paper-reviews\u002FSKILL.md",[151],{"categoryNo":133,"categoryName":134,"taxonomyType":20,"taxonomyTypeDesc":21},[139,138,137,136,146,141,142,84,140,124,33,143,144,83,145],{"skillNo":154,"name":155,"nameZh":6,"description":156,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":157,"categories":158,"keywords":159,"publishedAt":35},"01M6G8HM95Y64JNVFC2HN4E2BG","git-summary","Get a quick summary of the current Git repository including status, recent commits, branches, and contributors.","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fzweack\u002Fgit-summary\u002FSKILL.md",[],[160,161,162,163,164,165,166,167,168,169,170,171,172],"git","summary","git summary","commits","repository","win32","status","linux","contributors","true","quick","get","branches",{"skillNo":174,"name":175,"nameZh":6,"description":176,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":177,"categories":178,"keywords":183,"publishedAt":35},"01M6G8HGEGF05CNEJCGVYFSC4R","agent-constitution","Interact with AgentConstitution governance contracts on Base Sepolia. Check compliance, read rules, log actions, query governance state.","https:\u002F\u002Fgithub.com\u002Fkbarbel640-del\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fztsalexey\u002Fagent-constitution\u002FSKILL.md",[179,180],{"categoryNo":107,"categoryName":108,"taxonomyType":20,"taxonomyTypeDesc":21},{"categoryNo":181,"categoryName":182,"taxonomyType":78,"taxonomyTypeDesc":79},"01JBSEEDCAT000000000000037","律师与法务",[184,185,186,187,84,188,189,41,190,144,191,192,193,194,195,97,196,197,198],"agent constitution","constitution","contracts","tree","query","base","log","check","Rules","projects","compliance","actions","state","governance","github"]