1---2name: ddgs-search3description: Use the Python-based ddgs CLI (via `uvx ddgs`) for ad-hoc, unlimited web searches across multiple search engines. Trigger this skill when the user asks you to look something up online, compare sources, or gather search-based research.4---56# DDGS Search78## Workflow91. Clarify the user’s intent and translate it into a concise ddgs query (e.g., “OpenClaw agent capabilities”, “台北市立大學 markeTech 2026”, “AI-generated music licensing summary”).102. Choose the appropriate ddgs subcommand (`text`, `news`, `images`, `videos`, `books`) and supply the query via `-q/--query` plus any filters you need.113. Run the CLI with the desired flags. Example:12 ```bash13 uvx ddgs text \14 -q "OpenClaw agent" \15 -b google \16 -p 1 \17 --output json \18 --verify False19 ```204. Pull the most relevant titles, snippets, and URLs (or file paths) from the generated output, summarize key findings, cite the sources/engines, and ask if the user wants deeper digging.2122## Command reference23- `uvx ddgs text` → General web search. Supports `-b/--backend` (e.g., `duckduckgo`, `bing`, `google`, `auto`), `-p/--page`, `-m/--max_results`, `-r/--region`, and `-t/--timelimit`.24- `uvx ddgs news` → News sources only; pair with `-r/--region` or `-t/--timelimit` to narrow to breaking stories.25- `uvx ddgs images`, `uvx ddgs videos`, `uvx ddgs books` → Media-specific metasearches; capture `title`, `href`, and any metadata exposed in JSON output (e.g., `ext`, `download` paths).2627## Available backends28| Function | Backends |29| --- | --- |30| `text()` | bing, brave, duckduckgo, google, grokipedia, mojeek, yandex, yahoo, wikipedia |31| `images()` | duckduckgo |32| `videos()` | duckduckgo |33| `news()` | bing, duckduckgo, yahoo |34| `books()` | annasarchive |3536## Mode-specific options37### text (general web searches)38- Pass the search phrase with `-q/--query` (text only); `-k/--keywords` is deprecated.39- `-r/--region` (e.g., `us-en`, `uk-en`, `ru-ru`) and `-s/--safesearch` (`on`, `moderate`, `off`) control localization and content sensitivity.40- `-t/--timelimit` accepts `d`, `w`, `m`, or `y` for day/week/month/year windows; omit for all-time.41- `-m/--max_results` limits how many entries ddgs returns (default 10) and `-p/--page` picks the page number (default 1).42- `-b/--backend` lets you pin engines (comma-delimited names or `auto` to pick automatically). Works with the backend list above.4344### news (news-focused search)45- Same core flags as `text` (`-q`, `-r`, `-s`, `-t`, `-m`, `-p`, `-b`), but ddgs only queries news outlets.46- Use `-t` to keep results fresh (day/week/month), and prefer `bing`, `duckduckgo`, or `yahoo` backends for broader coverage.4748### images49- Inherits the general `-q`, `-r`, `-s`, `-t`, `-m`, `-p`, `-b` flags with backend locked to `duckduckgo`.50- Extra filters include `--size` (`Small`, `Medium`, `Large`, `Wallpaper`), `--color` (`Red`, `Orange`, `Yellow`, `Green`, `Blue`, `Purple`, `Pink`, `Brown`, `Black`, `Gray`, `Teal`, `White`, `Monochrome`, `color`), `--type` (`photo`, `clipart`, `gif`, `transparent`, `line`), `--layout` (`Square`, `Tall`, `Wide`), and `--license` (e.g., `any`, `Public`, `Share`, `ShareCommercially`, `Modify`, `ModifyCommercially`).5152### videos53- Core flags work the same (`-q`, `-r`, `-s`, `-t`, `-m`, `-p`, `-b`) with `duckduckgo` as the backend.54- Additional filters: `--resolution` (`high`, `standard`), `--duration` (`short`, `medium`, `long`), `--license` (`creativeCommon`, `youtube`).5556### books57- Only supports `-q`, `-m`, `-p`, and `-b` (backend defaults to `annasarchive`). Use this mode to find e-books or archived copies.5859## Flags & options60- `-q/--query`, `-r/--region`, `-s/--safesearch`, `-t/--timelimit`, `-m/--max_results`, `-p/--page`, and `-b/--backend` cover the shared behaviors across modes (text/news/images/videos/books).61- `-o/--output` writes structured CSV/JSON (or `filename.json`) for easy parsing.62- `--verify False` is often necessary here to bypass TLS certificate issues; `True` performs strict verification.63- `--download`/`--download-directory` fetch results locally—useful for images or videos that need inspection.6465## Result files66- When you use `--output json`, ddgs saves the results to a timestamped file (`text_<query>_<YYYYMMDD>_<HHMMSS>.json`). Open that file to read titles, snippets, and URLs, then delete or archive it once the insight is shared.67- If `--download` runs, note the download directories (default `./downloads/` or the one you provided) and mention them to the user.6869## Environmental notes70- Ensure `uvx` is on PATH before running anything (`which uvx`). On this system it now lives in `/usr/local/bin`, so the command is available globally.71- Re-run `uvx ddgs --help` occasionally to confirm the CLI has not changed.72- Record the exact command arguments you used so future agents can reproduce the search.7374## Notes75- Always mention which search engine/backends you queried when it matters (some users trust DuckDuckGo’s privacy, others expect Google/Bing coverage).76- If ddgs returns sparse context, rerun with `--output json` and focus on the `body`/`snippet` fields before synthesizing your response.