SkillAgentSearch skills...

Claude Patent Creator

USPTO patent creation system with MCP server + Claude Code plugin. Hybrid RAG search over MPEP/USC/CFR, BigQuery access to 76M+ patents, automated 35 USC 112 compliance checks, prior art search, diagram generation. GPU-accelerated with skills and autonomous agents.

Install / Use

/learn @RobThePCGuy/Claude Patent Creator
About this skill

Quality Score

0/100

Supported Platforms

Claude Code
Claude Desktop
Cursor

README

Claude Patent Creator

MIT License Python 3.9+ MCP Server PyTorch

USPTO patent creation and analysis system with dual-mode architecture: MCP server for programmatic access + Claude Code plugin with skills, autonomous agents, and slash commands. Features hybrid RAG search (FAISS+BM25+reranking) over MPEP/USC/CFR, BigQuery access to 76M+ patents, automated compliance checking, prior art search, and diagram generation.

Project Status

This project is a work in progress and is not fully functional.

Contributions, issues, and pull requests are welcome. Feel free to explore, experiment, or build upon the code. No guarantees of stability or completeness are provided.


Features

Dual-Mode Architecture

| Mode | Use Case | Components | Access Method | |------|----------|------------|---------------| | MCP Server | Programmatic API access | 20 MCP tools | Any MCP client (Claude Code, Claude Desktop, etc.) | | Claude Code Plugin | Interactive workflows | 15 skills + 10 agents + slash commands + hooks | Claude Code IDE |

Core Capabilities

Search & Retrieval (20 MCP Tools)

  • MPEP/USC/CFR Search - Hybrid RAG (FAISS vector + BM25 lexical + cross-encoder reranking) across 500MB of USPTO regulations
  • Patent Search - BigQuery access to 76M+ worldwide patents with full-text search and CPC classification
  • USPTO API Integration - Real-time patent data retrieval and recent filings
  • Prior Art Discovery - Automated novelty and freedom-to-operate analysis

Automated Analysis

  • Claims Review - 35 USC 112(b) compliance: definiteness, antecedent basis, indefinite terms, claim structure
  • Specification Review - 35 USC 112(a) adequacy: written description, enablement, best mode
  • Formalities Check - MPEP 608 compliance: abstract length, title format, drawings, required sections

Content Generation

  • Diagram Generator - Patent-style technical diagrams using Graphviz (block diagrams, flowcharts, system architectures)
  • Patent Creation - Guided workflow for drafting complete USPTO-ready applications

Claude Code Plugin Features

  • 15 Skills - Specialized expertise modules (setup, development, index management, troubleshooting, testing, patent review, search, diagrams, prior art)
  • 10 Autonomous Agents - Long-running workflows (patent-creator, prior-art-searcher, mpep-expert, patent-drafter, etc.)
  • Slash Commands - Quick-access workflows (/create-patent, /search-prior-art, /review-claims, /full-review, etc.)
  • Hooks System - Custom event-driven automation

Technology Stack

Architecture:
  FastMCP (MCP Server Framework)
  +-- 20 MCP Tools (search, analysis, generation)
  +-- Claude Code Plugin (skills, agents, commands, hooks)

RAG Pipeline:
  FAISS Vector Search (BGE-base-en-v1.5, 768-dim embeddings)
  + BM25 Lexical Search (rank-bm25)
  + Cross-Encoder Reranking (MS-MARCO MiniLM-L-6-v2)
  + HyDE Query Expansion (optional, API-based)

Data Sources:
  - MPEP (Manual of Patent Examining Procedure)
  - 35 USC (Patent Statutes)
  - 37 CFR (Patent Regulations)
  - Subsequent Publications (USPTO updates)
  - BigQuery patents-public-data (76M+ patents)

ML Stack:
  PyTorch 2.9+ (CUDA 12.8 for GPU acceleration)
  Sentence Transformers 5.1+
  HuggingFace Transformers 4.57+
  FAISS 1.12+ (CPU/GPU)

Validation & Monitoring:
  Pydantic v2 (type safety + input validation)
  Structured logging (JSON/human formats)
  Performance tracking (@track_performance)
  Health check system

Installation

Option 1: One-Line Install (Recommended)

# Installs package, detects GPU, downloads MPEP, builds index, registers MCP server
pip install git+https://github.com/RobThePCGuy/Claude-Patent-Creator.git && patent-creator setup

# Restart Claude Code after completion

What happens automatically:

  1. Installs Python package dependencies
  2. Detects hardware (NVIDIA GPU/Apple Silicon/CPU)
  3. Uninstalls CPU-only PyTorch if GPU detected
  4. Installs correct PyTorch (CUDA 12.8/MPS/CPU)
  5. Restarts setup with GPU-enabled PyTorch
  6. Downloads MPEP PDFs (500MB) from USPTO
  7. Builds hybrid index with GPU acceleration
  8. Registers MCP server with Claude Code

Option 2: Manual Installation

# Clone repository
git clone https://github.com/RobThePCGuy/Claude-Patent-Creator.git
cd Claude-Patent-Creator

# Optional: Create virtual environment
python -m venv venv
source venv/bin/activate  # Linux/macOS
venv\Scripts\activate     # Windows

# Install package
pip install -e .

# Run setup wizard
patent-creator setup

Option 3: Claude Code Plugin (Standalone Mode)

# In Claude Code
/plugin marketplace add C:\Users\<YOUR_USER>\Desktop\Projects
/plugin install claude-patent-creator-standalone

# Run setup command
/setup-patent-system

Quick Start

Using MCP Tools

# Search MPEP for claim definiteness requirements
search_mpep("claim definiteness 35 USC 112(b)", top_k=5)

# Search 76M+ patents for prior art
search_patents_bigquery("neural network training", limit=10)

# Analyze claims for compliance
review_patent_claims(claims_text)

# Generate patent diagram
render_diagram("block", components, connections)

Using Claude Code Skills

Skills activate automatically based on your task:

  • "Install the system"setup-assistant skill
  • "Search for patents about AI"patent-search skill
  • "Review my claims for compliance"patent-reviewer skill
  • "Find MPEP section on enablement"mpep-search skill
  • "Build the index"index-manager skill
  • "Something is broken"troubleshooting-assistant skill

Using Slash Commands

/create-patent          # Complete patent creation workflow (55-80 min)
/search-prior-art       # Prior art search with novelty analysis
/review-claims          # Claims-only 35 USC 112(b) analysis
/review-specification   # Specification-only 35 USC 112(a) analysis
/review-formalities     # MPEP 608 formalities check
/full-review            # Parallel review (claims + spec + formalities)

Using Autonomous Agents

# Long-running workflows that work independently
"Create a patent for my invention, use the patent-creator agent"
"Conduct prior art search for my invention, use the prior-art-searcher agent"

CLI Commands

# System health check
patent-creator health

# Rebuild MPEP index
patent-creator rebuild-index

# Verify MCP configuration
patent-creator verify-config

# Check BigQuery authentication
patent-creator check-bigquery

# Download MPEP PDFs only
patent-creator download-mpep

# Download all sources (MPEP + 35 USC + 37 CFR)
patent-creator download-all

Requirements

Minimum

  • Python: 3.9 - 3.13 (3.14 experimental)
  • RAM: 8GB
  • Disk: 2GB (MPEP PDFs + index)

Optional (Recommended)

  • GPU: NVIDIA GPU with CUDA 12.8 (5-10x faster indexing and search)
  • Google Cloud: Project with BigQuery enabled (for patent search)
  • Graphviz: System package (for diagram generation)

Python Dependencies

  • mcp>=1.21.0 - MCP server framework
  • sentence-transformers>=5.1.2 - Embeddings
  • faiss-cpu>=1.12.0 - Vector search
  • numpy>=1.26.0,<2.0.0 - Array operations (CRITICAL: <2.0 for FAISS compatibility)
  • rank-bm25>=0.2.2 - Lexical search
  • google-cloud-bigquery>=3.38.0 - Patent search
  • pydantic>=2.10.0 - Validation
  • graphviz>=0.21 - Diagram generation
  • PyMuPDF>=1.26.0 - PDF processing

See pyproject.toml for complete dependency list.


MCP Tools Reference

MPEP Search Tools (2)

  • search_mpep - Hybrid RAG search with filters
  • get_mpep_section - Retrieve full section content

Patent Search Tools (7)

  • check_bigquery_status - Verify BigQuery configuration
  • search_patents_bigquery - Search 76M+ patents
  • get_patent_bigquery - Get full patent details
  • search_patents_by_cpc_bigquery - Search by CPC classification
  • search_uspto_api - USPTO API search
  • get_uspto_patent - Get USPTO patent details
  • get_recent_uspto_patents - Recent filings

Analysis Tools (3)

  • review_patent_claims - 35 USC 112(b) compliance
  • review_specification - 35 USC 112(a) adequacy
  • check_formalities - MPEP 608 compliance

Diagram Tools (2)

  • render_diagram - Generate patent diagrams
  • get_diagram_templates - List available templates

Prior Art Tools (1)

  • search_prior_art - Automated prior art discovery

System Tools (5)

  • get_index_stats - Index statistics
  • check_diagram_tools_status - Graphviz status
  • check_patent_corpus_status - Corpus availability
  • check_uspto_api_status - API connectivity
  • get_patent_details - Combined patent retrieval

Configuration

Environment Variables

Create .env file in the project root:

# Required for BigQuery patent search
GOOGLE_CLOUD_PROJECT=your-project-id

# Optional API keys (for HyDE query expansion)
ANTHROPIC_API_KEY=sk-ant-...
OPENAI_API_KEY=sk-...

# Optional settings
PATENT_LOG_LEVEL=INFO              # Logging verbosity
PATENT_LOG_FORMAT=human            # Log format (json/human)
PATENT_ENABLE_METRICS=true         # Performance tracking
PATENT_MPEP_USE_HYDE=false         # HyDE query expansion
PATENT_MPEP_DEVICE=gpu             # Device (gpu/cpu)
PATENT_OPERATION_TIMEOUT=300       # Timeout (seconds)

# Windows only (for Git Bash)
CLAUDE_CODE_GIT_BASH_PATH=C:\dev\Git\bin\bash.exe

BigQuery Setup (Optional)

# Install Google Cloud SDK
# https://cloud.google.com/sdk/docs/install

# Authenticate
gcloud auth application-default login

# Set project
export GOOGLE_CLOUD_PROJECT=your-project-id

# Te
View on GitHub
GitHub Stars41
CategoryDevelopment
Updated4h ago
Forks4

Languages

Python

Security Score

95/100

Audited on Mar 19, 2026

No findings