← 返回 Skills 市场
jiafar

Google Patents

作者 jiafar · GitHub ↗ · v1.2.0
cross-platform ⚠ suspicious
506
总下载
1
收藏
4
当前安装
3
版本数
在 OpenClaw 中安装
/install google-patents
功能描述
Search Google Patents database for patent research, infringement risk checks, and competitive IP analysis. Use when user mentions: 专利, patent, 侵权, infringeme...
使用说明 (SKILL.md)

Google Patents

Search and retrieve patent data via SerpApi. Requires SERPAPI_API_KEY env var (free: 100/month at serpapi.com).

5 Commands

bash scripts/patents.sh search "keywords" [options]     # Search patents
bash scripts/patents.sh detail "US11734097B1"            # Basic info + claims
bash scripts/patents.sh fulltext "US11734097B1"          # Description full text
bash scripts/patents.sh full "US11734097B1"              # ALL data in one call
bash scripts/patents.sh pdf "US11734097B1" output.pdf    # Download PDF

Patent ID: short US11734097B1 or full patent/US11734097B1/en. Supports all countries: CN, US, EP, JP, KR, WO, DE, etc.

Search Options

--country US,CN,JP,WO,EP,KR    --status GRANT|APPLICATION
--type PATENT|DESIGN            --assignee "Company"
--inventor "Name"               --sort relevance|new|old
--after publication:20230101    --before publication:20251231
--num 10-100                    --page N
--language ENGLISH|CHINESE      --litigation YES|NO
--scholar                       --clustered

Boolean: "(massage) AND (glove OR mitt)" | Multi-term + CPC: "(pet grooming);(A01K13)"

What Each Command Returns

search: patent_id, title, snippet, assignee, inventor, dates, pdf, country_status detail: title, abstract, claims[], inventors[], assignees[], classifications[], legal_events[], citations, similar_documents[], images[], pdf, family_id, worldwide_applications fulltext: description full text (FIELD OF INVENTION, BACKGROUND, SUMMARY, DETAILED DESCRIPTION) full: Everything from detail + description_full combined pdf: Downloads PDF file to specified path

E-commerce Scenarios

# Infringement risk check (pre-listing must-do)
bash scripts/patents.sh search "product" --type DESIGN --country US --status GRANT

# Competitor patents
bash scripts/patents.sh search "category" --assignee "Company" --num 50

# Read claims to assess real risk
bash scripts/patents.sh full "USD975937S1"

# Download patent PDF for reference
bash scripts/patents.sh pdf "USD975937S1" ./patent.pdf

# Expired patents (free to use)
bash scripts/patents.sh search "tech" --before "filing:20040101"

# Latest trends
bash scripts/patents.sh search "tech" --sort new --after "publication:20240101"

# Litigation-prone patents
bash scripts/patents.sh search "product" --litigation YES --country US

Error Handling

All errors return JSON with error and code fields. No exceptions thrown.

Code Meaning
PATENT_NOT_FOUND Patent ID doesn't exist (404)
AUTH_ERROR Invalid/expired API key (401/403)
MAX_RETRIES_EXCEEDED Network failure after 3 retries
NO_DESCRIPTION Patent has no description text
PARSE_ERROR HTML parsing failed
NO_PDF No PDF available
DOWNLOAD_ERROR PDF download failed
MISSING_QUERY No search query provided
MISSING_ID No patent ID provided

Auto-retry: 3 attempts with exponential backoff (2s, 4s, 8s) on 429/5xx errors. Rate limit: 1 second between requests to avoid triggering anti-scraping. Timeouts: 10s connect, 30s max per request, 60s for PDF downloads.

FAQ

Q: Why are some fields empty? A: Different countries have different patent page formats. Some patents may have incomplete data, or the description may not be digitized.

Q: Can I batch-fetch patents? A: Yes, loop through IDs. Respect the 1s rate limit. Free tier = 100 calls/month. Cached results (same query within 1h) are free.

Q: How to get PDF? A: bash scripts/patents.sh pdf "US11734097B1" output.pdf

Q: Chinese vs English patents? A: Chinese pages (patent/CNxxxxxx/zh) have native Chinese content. English pages have machine-translated content. Use --language CHINESE for search.

Q: Patent ID formats? A: Country code + number + type suffix. Examples: CN106484775A, US20180232442A1, EP2264377A2, USD975937S1 (design), JP2020123456A.

安全使用建议
Do not assume this is safe just because it calls a legitimate API. The script contains a hardcoded SerpApi API key (embedded in scripts/patents.sh) while the registry metadata does not declare required credentials — this is a red flag. Before installing: (1) ask the publisher to remove the embedded key and require users to supply their own SERPAPI_API_KEY (confirm the key in the repo is revoked/rotated), (2) ensure the skill manifest (registry metadata) is updated to declare the required env var, (3) if you must run it, run in a sandboxed environment and do not expose other credentials, and (4) consider creating and using your own SerpApi account to avoid routing requests/billing through an unknown key. If the owner cannot or will not remove the embedded key, treat the skill as untrustworthy.
功能分析
Type: OpenClaw Skill Name: google-patents Version: 1.2.0 The skill bundle is classified as suspicious due to several vulnerabilities in `scripts/patents.sh`. A hardcoded SerpApi key is exposed, which is a security risk for the skill owner. More critically, the `search` command is vulnerable to parameter injection against the SerpApi endpoint, as several user-provided options are not URL-encoded. Most significantly, the `pdf` command allows arbitrary file write via path traversal, as the output filename is used directly without sanitization, enabling an attacker to write downloaded PDF content to arbitrary locations on the filesystem.
能力评估
Purpose & Capability
The script implements Google Patents queries via SerpApi which matches the skill's stated purpose, but the registry metadata declares no required env vars while the SKILL.md says SERPAPI_API_KEY is required and the script embeds a default API key; this mismatch is unexpected and concerning.
Instruction Scope
SKILL.md and the script restrict behavior to calling SerpApi and downloading PDFs (expected). However the runtime instructions expect an API key but the script will silently use a hardcoded default key if SERPAPI_API_KEY is not set, which is scope creep (uses a credential not declared in registry and may route requests through the author's account).
Install Mechanism
Instruction-only skill with a small bash script; there is no install spec and nothing is written to disk beyond user-requested PDF downloads. No risky download/install behavior.
Credentials
Registry lists no required env vars but SKILL.md requires SERPAPI_API_KEY; the script reads SERPAPI_API_KEY but provides a hardcoded default API key value in the source. Embedding an API key in the script is disproportionate and risky (leaks credentials, routes requests/billing to that key).
Persistence & Privilege
always:false and the skill does not modify other skills or system-wide settings. It only writes files when downloading PDFs (user-specified).
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install google-patents
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /google-patents 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.2.0
v1.2: Added PDF download, structured error handling (9 error codes), auto-retry with exponential backoff, rate limiting (1s/req), request timeouts, FAQ section
v1.1.0
v1.1: Added fulltext and full(all-in-one) commands, auto-retry with exponential backoff, description full text extraction, auto patent ID normalization
v1.0.0
Initial release: Google Patents search and detail via SerpApi. Supports infringement checks, competitor IP analysis, patent trends, litigation filtering.
元数据
Slug google-patents
版本 1.2.0
许可证
累计安装 4
当前安装数 4
历史版本数 3
常见问题

Google Patents 是什么?

Search Google Patents database for patent research, infringement risk checks, and competitive IP analysis. Use when user mentions: 专利, patent, 侵权, infringeme... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 506 次。

如何安装 Google Patents?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install google-patents」即可一键安装,无需额外配置。

Google Patents 是免费的吗?

是的,Google Patents 完全免费(开源免费),可自由下载、安装和使用。

Google Patents 支持哪些平台?

Google Patents 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Google Patents?

由 jiafar(@jiafar)开发并维护,当前版本 v1.2.0。

💬 留言讨论