Hmdb database

From aipoch/medical-research-skills · View interactive version

Hmdb database is an AI agent skill from the GitHub repository aipoch/medical-research-skills. Access the Human Metabolome Database (HMDB) to search metabolites by name/structure/ID and extract chemical/biological/clinical fields when you need metabolomics research data or automated HMDB XML mining.

How to use this skill

Skill file

Source: https://github.com/aipoch/medical-research-skills

When to Use

Key Features

Dependencies

Example Usage

1) Download HMDB XML

Download the HMDB metabolite XML dataset from:

Assume you saved it as:

data/hmdb_metabolites.xml

2) Search and Extract Fields (Runnable Example)

from scripts.hmdb_parser import HMDBParser

def main():
    # Path to the HMDB XML dump downloaded from hmdb.ca/downloads
    xml_path = "data/hmdb_metabolites.xml"

    parser = HMDBParser(xml_path)

    # Search by metabolite name (text query)
    results = parser.search("Caffeine")

    # Print basic information from the first match (structure depends on implementation)
    if not results:
        print("No results found.")
        return

    first = results[0]
    print("Top match:")
    print(first)

if __name__ == "__main__":
    main()

3) Field Reference

For a curated list of extractable fields and how they map to HMDB XML elements, see:

Implementation Details

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.