Skip to main content

A set of ORM-style clients for publicly available intellectual property data

Project description

patent_client_logo

Build codecov Documentation

PyPI PyPI - Python Versions Downloads Pydantic v2

Summary

A powerful library for accessing intellectual property, featuring:

  • 🍰 Ease of use: All sources use a simple unified API inspired by Django-ORM.
  • 🐼 Pandas Integration: Results are easily castable to Pandas Dataframes and Series.
  • 🚀 Performance: Fetched data is retrieved using the httpx library with native HTTP/2 and asyncio support, and cached using the hishel library for super-fast queries, and yankee for data extraction.
  • 🌐 Async/Await Support: All API's (optionally!) support the async/await syntax.
  • 🔮 Pydantic v2 Support: All models retrieved are Pydantic v2 models with all the goodness that comes with them!

Docs, including a fulsome Getting Started and User Guide are available on Read the Docs. The Examples folder includes examples of using patent_client for many common IP tasks

⭐ New in v5 ⭐

Version 5 brings a new and more reliable way to provide synchronous and asynchronous access to the various APIs. In version 5, like in version 3, you can just from patent_client import [Model] and get a synchronous version of the model. No asynchronous methods or functionality at all. Or you can do from patent_client._async import [Model] and get an asynchronous version of the model.

Version 5 also brings support for the USPTO's new Open Data Portal, a system currently in beta that is scheduled to replace the current Patent Examination Data System in late 2024.

Coverage

  • Free software: Apache Software License 2.0

Installation

pip install patent_client

If you only want access to USPTO resources, you're done! However, additional setup is necessary to access EPO Inpadoc and EPO Register resources. See the Docs.

Quick Start

To use the project:

# Import the model classes you need
>>> from patent_client import Inpadoc, Assignment, USApplication

# Fetch US Applications
>>> app = USApplication.objects.get('15710770')
>>> app.patent_title
'Camera Assembly with Concave-Shaped Front Face'

# Fetch from USPTO Assignments
>>> assignments = Assignment.objects.filter(assignee='Google')
>>> len(assignments) > 23000
True
>>> assignment = Assignment.objects.get('47086-788')
>>> assignment.conveyance_text
'ASSIGNMENT OF ASSIGNORS INTEREST'

# Fetch from INPADOC
>>> pub = Inpadoc.objects.get('EP3082535A1')
>>> pub.biblio.title
'AUTOMATIC FLUID DISPENSER'

Async Quick Start

To use async with Patent Client, just import the classes you need from the async module. All methods and iterators that access data or create a network request are asynchronous.

from patent_client._async import USApplication

apps = list()
async for app in USApplication.objects.filter(first_named_applicant="Google"):
  apps.append(app)

app = await USApplication.objects.aget("16123456")

Documentation

Docs, including a fulsome Getting Started are available on Read the Docs.

Development

To run the all tests run:

pytest

A developer guide is provided in the Documentation. Pull requests welcome!

Related projects

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

patent_client-5.0.19.tar.gz (4.6 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

patent_client-5.0.19-py3-none-any.whl (4.8 MB view details)

Uploaded Python 3

File details

Details for the file patent_client-5.0.19.tar.gz.

File metadata

  • Download URL: patent_client-5.0.19.tar.gz
  • Upload date:
  • Size: 4.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.11.4 Darwin/24.3.0

File hashes

Hashes for patent_client-5.0.19.tar.gz
Algorithm Hash digest
SHA256 fa0b70d3d7d41108c3bb27f77f5d92f0c6a148f01bbe1deb6b0e20060f73fb8e
MD5 86e892d190ba29c3a594478f763deed4
BLAKE2b-256 83f3709edac0eccd4c05ce97b5fdcb71e4fa4c4fb60491dac8c518f8deb53c9e

See more details on using hashes here.

File details

Details for the file patent_client-5.0.19-py3-none-any.whl.

File metadata

  • Download URL: patent_client-5.0.19-py3-none-any.whl
  • Upload date:
  • Size: 4.8 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.11.4 Darwin/24.3.0

File hashes

Hashes for patent_client-5.0.19-py3-none-any.whl
Algorithm Hash digest
SHA256 502f45abf89d2b86eae5c64ed654b6699f97ea3d749df97fee56834df63ee9a4
MD5 4d861e9529031f0b76d3184088ec26c3
BLAKE2b-256 54a4f2e057cb91d080b43a711fe4d7aad7b1e6c5864964a0fd82c324bf3b58f1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page