
Web Search
- 32 installs
- 902 repo stars
- Updated June 22, 2026
- bear2u/my-skills
web-search is a Claude skill that runs DuckDuckGo text, news, and image searches with region and time filters via a bundled Python script.
About
This skill runs a bundled Python script to search DuckDuckGo for text, news, or images. It supports region codes, SafeSearch levels, and time-range filters, and returns results as JSON. A developer uses it when the built-in web search is unavailable outside the US or when news, image, or region-scoped results are needed.
- Searches DuckDuckGo for text, news, or images via a bundled script
- Supports region codes, SafeSearch, and day/week/month/year time filters
- Returns JSON that can be saved or processed programmatically
Web Search by the numbers
- 32 all-time installs (skills.sh)
- Ranked #1,205 of 2,715 Automation & Workflows skills by installs in the Skillselion catalog
- Data as of Aug 4, 2026 (Skillselion catalog sync)
web-search capabilities & compatibility
- Capabilities
- web search · news search · image search
- Use cases
- web search · research
- Pricing
- Free
What web-search says it does
python3 ~/.claude/skills/web-search/scripts/search.py -q "검색어" -t text -n 5
빌트인 WebSearch를 사용할 수 없을 때 (US 외 지역)
npx skills add https://github.com/bear2u/my-skills --skill web-searchAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 32 |
|---|---|
| repo stars | ★ 902 |
| Last updated | June 22, 2026 |
| Repository | bear2u/my-skills ↗ |
What it does
Run DuckDuckGo text, news, or image searches with region and time filters when the built-in web search is limited.
Who is it for?
News, image, or region-scoped web search outside the US when built-in search is limited
Skip if: Simple US-region text search where the built-in WebSearch already works
When should I use this skill?
You need DuckDuckGo news, image, region, or time-filtered search results
What you get
JSON search results for text, news, or images with region, SafeSearch, and time-range control.
- JSON search results
By the numbers
- 3 search types (text/news/images)
- 6 documented CLI parameters
Files
DuckDuckGo Web Search
DuckDuckGo 검색 엔진을 활용한 텍스트, 뉴스, 이미지 검색 스킬.
When to Use
다음 상황에서 사용:
- 빌트인 WebSearch를 사용할 수 없을 때 (US 외 지역)
- 뉴스 전용 검색이 필요할 때
- 이미지 URL을 검색해야 할 때
- 검색 결과를 JSON으로 저장하거나 프로그래밍적으로 처리해야 할 때
- 시간 범위(일/주/월/년)를 세밀하게 지정해야 할 때
- 특정 지역(한국, 일본 등) 기준 검색 결과가 필요할 때
빌트인 WebSearch를 우선 사용하는 경우:
- US 지역의 단순 텍스트 검색
- 빠른 사실 확인
Core Workflow
Step 1: 검색 유형 판별
사용자 요청에서 검색 유형 파악:
- 텍스트 검색 (기본): 일반적인 웹 검색
- 뉴스 검색: "뉴스", "최근 소식", "news" 키워드 포함
- 이미지 검색: "이미지", "사진", "image", "picture" 키워드 포함
Step 2: 스크립트 실행
python3 ~/.claude/skills/web-search/scripts/search.py -q "검색어" -t text -n 5Step 3: 결과 정리
JSON 출력을 사용자에게 읽기 좋은 형태로 정리하여 전달.
Parameters
| 파라미터 | 필수 | 기본값 | 설명 |
|---|---|---|---|
-q | Yes | - | 검색 키워드 |
-t | No | text | text, news, images |
-n | No | 5 | 최대 결과 수 |
-r | No | wt-wt | 지역 코드 |
-s | No | moderate | SafeSearch: on, moderate, off |
-p | No | None | 기간: d(일), w(주), m(월), y(년) |
주요 지역 코드
- 전세계:
wt-wt| 한국:kr-kr| 미국:us-en| 일본:jp-jp| 영국:uk-en
Examples
텍스트 검색
python3 ~/.claude/skills/web-search/scripts/search.py -q "Claude Code Anthropic" -t text -n 5한국 뉴스 검색 (최근 1주)
python3 ~/.claude/skills/web-search/scripts/search.py -q "AI 인공지능" -t news -n 10 -r kr-kr -p w이미지 검색
python3 ~/.claude/skills/web-search/scripts/search.py -q "modern web design" -t images -n 5결과를 파일로 저장
python3 ~/.claude/skills/web-search/scripts/search.py -q "React 19" -t text -n 20 > results.json검색 연산자
query에 포함하여 사용:
site:example.com- 특정 사이트 내 검색filetype:pdf- 특정 파일 유형"exact phrase"- 정확한 구문-exclude- 특정 단어 제외
Error Handling
- Rate Limit: 잠시 후 재시도하거나 결과 수를 줄임
- Timeout: 네트워크 확인 후 재시도
- 패키지 미설치: 스크립트가 자동 설치 시도. 실패 시
pip install -U ddgs수동 실행
#!/usr/bin/env python3
"""DuckDuckGo Search CLI for Claude Code Skill."""
import argparse
import json
import subprocess
import sys
import time
def ensure_dependency():
try:
import ddgs # noqa: F401
except ImportError:
try:
import duckduckgo_search # noqa: F401
except ImportError:
print("Installing ddgs...", file=sys.stderr)
cmd = [sys.executable, "-m", "pip", "install", "-U", "ddgs"]
try:
subprocess.check_call(
cmd, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL,
)
except subprocess.CalledProcessError:
subprocess.check_call(
cmd + ["--break-system-packages"],
stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL,
)
def _get_ddgs():
try:
from ddgs import DDGS
except ImportError:
from duckduckgo_search import DDGS
return DDGS()
def search_text(query, region, safesearch, timelimit, max_results):
return list(_get_ddgs().text(
keywords=query,
region=region,
safesearch=safesearch,
timelimit=timelimit,
max_results=max_results,
))
def search_news(query, region, safesearch, timelimit, max_results):
return list(_get_ddgs().news(
keywords=query,
region=region,
safesearch=safesearch,
timelimit=timelimit,
max_results=max_results,
))
def search_images(query, region, safesearch, max_results):
return list(_get_ddgs().images(
keywords=query,
region=region,
safesearch=safesearch,
max_results=max_results,
))
def main():
parser = argparse.ArgumentParser(description="DuckDuckGo Search CLI")
parser.add_argument("-q", "--query", required=True, help="검색 키워드")
parser.add_argument(
"-t", "--type", default="text",
choices=["text", "news", "images"],
help="검색 유형 (기본: text)",
)
parser.add_argument(
"-n", "--max-results", type=int, default=5,
help="최대 결과 수 (기본: 5)",
)
parser.add_argument(
"-r", "--region", default="wt-wt",
help="검색 지역 (기본: wt-wt)",
)
parser.add_argument(
"-s", "--safesearch", default="moderate",
choices=["on", "moderate", "off"],
help="SafeSearch (기본: moderate)",
)
parser.add_argument(
"-p", "--period", default=None,
choices=["d", "w", "m", "y"],
help="기간: d(일), w(주), m(월), y(년)",
)
args = parser.parse_args()
ensure_dependency()
max_retries = 3
for attempt in range(max_retries):
try:
if args.type == "text":
results = search_text(
args.query, args.region, args.safesearch,
args.period, args.max_results,
)
elif args.type == "news":
results = search_news(
args.query, args.region, args.safesearch,
args.period, args.max_results,
)
elif args.type == "images":
results = search_images(
args.query, args.region, args.safesearch,
args.max_results,
)
output = {
"query": args.query,
"type": args.type,
"region": args.region,
"result_count": len(results),
"results": results,
}
print(json.dumps(output, ensure_ascii=False, indent=2))
return
except Exception as e:
if "Ratelimit" in str(e) and attempt < max_retries - 1:
wait = (attempt + 1) * 2
print(f"Rate limit hit, retrying in {wait}s... ({attempt + 1}/{max_retries})", file=sys.stderr)
time.sleep(wait)
continue
error_output = {
"error": True,
"error_type": type(e).__name__,
"message": str(e),
}
print(json.dumps(error_output, ensure_ascii=False, indent=2), file=sys.stderr)
sys.exit(1)
if __name__ == "__main__":
main()
Related skills
FAQ
What search types are supported?
Text, news, and image search, selectable with the -t flag.
When should I use it over the built-in search?
When you need news or image results, region or time filters, or search outside the US where built-in WebSearch is limited.