Skip to main content

icon


better-moles-patent-finder

A tool designed to enhance patent discovery by leveraging MongoDB for efficient storage, querying, and analysis of patent data. This repository includes features to streamline patent searches, improve retrieval accuracy, and support advanced filtering and indexing capabilities.

Coverage
PyPI Latest Release
Unit Tests
Powered by Fabio
License

Overview

This project offers a powerful platform for patent research, combining advanced search features with a MongoDB backend to store, retrieve, and analyze patent-related data efficiently. It allows users to search for patents associated with chemical compounds, leveraging SMILES, InChI, and other molecular representations. The system also supports filtering by molecular structure, patent ID, and other criteria.


This project is based on the PatCID paper, which focuses on the identification and classification of patent data related to molecular structures. The techniques and methodologies from the PatCID framework are utilized to enhance patent search results by leveraging chemical informatics and advanced query techniques. The core concept of this project builds upon PatCID's ability to match molecular structures with relevant patent information, improving the overall efficiency and accuracy of patent searches. To check out their incredible work, visit the PatCID GitHub repository. scratches(1).png


Key Features:

  • Patent Search: Search patents by their ID or associated molecular properties.
  • Advanced Filtering: Filter patents based on molecular structure, chemical formula, and other relevant fields.
  • Efficient Querying: Use MongoDB's indexing and querying capabilities to retrieve patents quickly.
  • Data Model: The system stores patents and associated molecules in a structured format, making it easy to extend and scale.

Authors:


What is it?

This tool is designed to assist researchers and patent professionals in finding relevant patents related to chemical compounds using molecular representations like SMILES and InChI. By using MongoDB as the backend, it efficiently stores and indexes large volumes of patent and molecular data. Users can easily query patents, filter based on molecular structures, and retrieve precise results with high speed.

Key Features:

  • Patent Search: Search patents by their ID or associated molecular properties.
  • Advanced Filtering: Filter patents based on molecular structure, chemical formula, and other relevant fields.
  • Efficient Querying: Use MongoDB's indexing and querying capabilities to retrieve patents quickly.
  • Data Model: The system stores patents and associated molecules in a structured format, making it easy to extend and scale.

Mongo Documents Format

The MongoDB documents used by this project follow the structure below, which includes information about the molecule (using SMILES, InChI, etc.) and the associated patent IDs:

{
  "molecule": {
    "smiles": "Brc1cc(-c2ccccc2)nc(-c2ccc3c4ccccc4c4ccccc4c3c2)c1",
    "inchi": "InChI=1S/C29H18BrN/c30-21-17-28(19-8-2-1-3-9-19)31-29(18-21)20-14-15-26-24-12-5-4-10-22(24)23-11-6-7-13-25(23)27(26)16-20/h1-18H",
    "inchikey": "UPAWJZOAEGLCFP-UHFFFAOYSA-N",
    "sum_formula": "C29H18BrN",
    "conf": 0.57
  },
  "patents": [
    {"id": "US20200136057A1"},
    {"id": "US20200136057"}
  ]
}

Mongo Documents Format

  • molecule: Contains the molecular data (SMILES, InChI, InChIKey, sum formula).
  • patents: A list of patent IDs that are associated with the molecule.

Usage

Installation

You can install the better-moles-patent-finder package via pip from PyPI or clone the repository to run locally:

Install from PyPI:

pip install better-moles-patent-finder

Basic Usage

Once installed, you can start querying patents using the provided API or Running as a Script

You can run the project as a script by passing a configuration file path:

better-moles-patent-finder --config-path /path/to/config_file.yaml

Ensure MongoDB is running and accessible. The default connection string is configured in the project. You can modify it if necessary in the mongo_connector.py file.

from mongo.mongo_connector import MongoConnector
from mongo.mongo_configs import MongoConnectionConfig

config = MongoConnectionConfig()
config.load_from_dict({
    "host": "localhost",
    "port": 27017,
    "db_name": "patents",
    "collection": "patcid",
    "username": "root",
    "password": "example",
}) 
# Connect to the MongoDB database
mongo = MongoConnector(config)
mongo.connect()
import pandas as pd
from patent_finder.patent_finder_mongo_db import PatentFinderMongoDB

# Create a PatentFinder instance
pf = PatentFinderMongoDB(smiles_df=pd.DataFrame({'smiles':['<smiles>']}), mongo_connector=mongo)

# Search for patents by molecule structure (SMILES)
result = pf.search_by_smiles('Brc1cc(-c2ccccc2)nc(-c2ccc3c4ccccc4c4ccccc4c3c2)c1')

# Print the result
print(result)

License

This project is licensed under the terms of the GNU General Public License, Version 3.

Metadata

Release files for better-moles-patent-finder 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for better-moles-patent-finder 0.1.2
File Size Uploaded
better_moles_patent_finder-0.1.2.tar.gz 49.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for better-moles-patent-finder 0.1.2
File Interpreter ABI Platform
better_moles_patent_finder-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 84.4 kB

Release files / better_moles_patent_finder-0.1.2.tar.gz

Download URL better_moles_patent_finder-0.1.2.tar.gz
Size 49.5 kB
Tags Source
SHA-256 checksum
How to use checksums
4b9032dd0fb5836915504ca953578255de6e4b3fe621022692668c249b7bba99
BLAKE2b-256 checksum
How to use checksums
47b97995814542c088936ff63d33619a6276113082a07149e31e09781bbcfaff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release files / better_moles_patent_finder-0.1.2-py3-none-any.whl

Download URL better_moles_patent_finder-0.1.2-py3-none-any.whl
Size 34.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
820ccb8884f36eb3d61e97d4cfdcf7c2473fe3a3026cd1eb5d7085cddecd7e7e
BLAKE2b-256 checksum
How to use checksums
eca025a9373c7d50f8443260bcfd132785b2ea8d0dd03db1a51c933de16b3baa
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.21

Release history Release notifications | RSS feed

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page