web-search-and-fetch/SKILL.md
Run Google searches and fetch JS-rendered web pages as Markdown via `google-search-cli`, a Patchright-based CLI invoked through `uvx` from its GitHub repo (no local install needed). Use when the agent needs (1) fresh Google search results from a query, (2) the Markdown of a URL that plain HTTP fetch (curl/WebFetch) cannot render because it requires JavaScript or evades bots, or (3) inspection of the raw HTML of a Google results page. Trigger phrases include "google for ...", "search the web for ...", "fetch this page as markdown", "this page needs JS to render". Do not use for static doc URLs that WebFetch handles cleanly, or when Chromium cannot be installed on the machine.
npx skillsauth add ceshine/ceshine-agent-skills web-search-and-fetchInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
A thin wrapper around the google-search-cli tool from github.com/ceshine/python-playwright-google-search. Invoke it via uvx so the user does not need a local checkout of the repo. The CLI uses patchright (a Playwright fork with anti-bot patches) under the hood.
The first time the CLI runs on a machine, Chromium must be downloaded.
Do not auto-run this — it downloads ~150 MB and may need sudo for --with-deps. Instead, when the CLI errors with a message like Executable doesn't exist at ..., tell the user to run:
uvx --from git+https://github.com/ceshine/python-playwright-google-search.git patchright install chromium
On Linux, add --with-deps if the system is missing shared libraries (needs sudo). Routing the install through the same --from URL ensures the patchright version used to install the browser matches the version that will later run it. Chromium lands in ~/.cache/ms-playwright/, so subsequent uvx invocations reuse it.
./browser-state.json is read/written in the CWD; reusing it across calls keeps cookies/session alive and lowers rate-limit risk.
Do NOT modify the uvx command templates — do not add anything before or after the command, including the &&, ;, | operators (e.g., DO NOT use a cd command before the uvx command`). Altering the template breaks sandbox whitelist pattern detection. Use the exact forms shown below.
Both commands output their results to stdout. You can use the redirect operator (>) to write the results to a temporary file.
uvx --from git+https://github.com/ceshine/python-playwright-google-search.git google-search-cli search "<query>" [-l 10]
uvx --from git+https://github.com/ceshine/python-playwright-google-search.git google-search-cli fetch-markdown "<url>" [--max-n-chars 250000] [-w 0]
-w / --wait: seconds to wait after the page loads before capturing content. Increase this (e.g. -w 5 or -w 10) if the Markdown looks incomplete or anomalous (lazy-loaded scripts, late-rendered content).uvx --from git+https://github.com/ceshine/python-playwright-google-search.git google-search-cli search "<query>" --get-html
search: JSON array of {title, link, snippet} objects on stdout. With --get-html, JSON metadata including originalHtmlLength, cleanedHtmlLength, and a 500-char htmlPreview.fetch-markdown: plain Markdown text on stdout. When content exceeds --max-n-chars, the literal suffix \n\n... (truncated) is appended. Detect this string to decide whether to re-invoke with a larger limit.Error: ..., exit code 1.The two subcommands have asymmetric headless defaults. This is intentional; do not flip them without a specific reason.
search defaults to headless=True — mimics human browsing for anti-bot evasion. Override with --no-headless only when debugging.fetch-markdown defaults to headless=False — some pages render incorrectly headless. Pass --headless only in no-display environments (containers/CI without X)../browser-state.json by default. Keeping it preserves cookies/session across invocations.--no-save-state and --state-file <unique-path>.search (for a query) or fetch-markdown (for a specific URL).Bash using the uvx --from git+... form above. The bash command should start with uvx --from git+. Use the given command template exactly. DO NOT use any other commands (e.g., cd).search, Markdown text for fetch-markdown.fetch-markdown output ends with ... (truncated) and the user needs more, re-invoke once with a larger --max-n-chars. Do not loop.fetch-markdown output looks anomalous (e.g. empty, missing expected sections, or clearly incomplete), re-invoke once with a higher -w value (e.g. -w 10) to allow late-rendered content to settle. Do not loop.Stop and report to the user when:
search calls in a row return empty results — likely rate-limited. Back off and surface the issue rather than retrying in a tight loop.search "recent papers on retrieval-augmented generation" -l 5fetch-markdown "<url>"--max-n-chars 500000.tools
Fetch transcripts and create structured watching guides / summaries for YouTube videos. Use when the user asks to (1) get, fetch, extract, or download a transcript or captions from a YouTube video URL, or (2) summarize, create a watching guide, or produce a structured summary of a YouTube video. Trigger on youtube.com/watch, youtu.be, or youtube.com/shorts links.
tools
Always use this skill at the beginning of a session. It establishes how to find and use skills, and requires relevant Skill tool invocation before ANY response including clarifying questions
tools
Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends the agent's capabilities with specialized knowledge, workflows, or tool integrations.
development
Retrieve the Markdown version of a public web page from a URL using the agent's built-in URL fetch capability and markdown.new. Use when a user asks for page content in Markdown, cleaner extracted page content for LLM use, or URL-to-Markdown conversion.