$npx -y skills add ai4protein/VenusFactory2 --skill kegg_databaseDirect REST API access to KEGG (academic use only). Pathway analysis, gene-pathway mapping, metabolic pathways, drug interactions, ID conversion. Use this for direct HTTP/REST work or KEGG-specific control.
| 1 | # KEGG Database |
| 2 | |
| 3 | ## Overview |
| 4 | |
| 5 | KEGG (Kyoto Encyclopedia of Genes and Genomes) is a comprehensive bioinformatics resource for biological pathway analysis and molecular interaction networks. **In this project the agent exposes only download tools**: save database info, entry lists, search results, entry data, ID conversions, cross-references, and drug-drug interactions to files; each returns rich JSON `{status, file_info, content_preview, biological_metadata, execution_context}`. For programmatic use, the package also provides query-style APIs (see Project Modules). |
| 6 | |
| 7 | **Important**: KEGG API is made available only for academic use by academic users. |
| 8 | |
| 9 | ## When to Use This Skill |
| 10 | |
| 11 | This skill should be used when querying pathways, genes, compounds, enzymes, diseases, and drugs across multiple organisms using KEGG's REST API. |
| 12 | |
| 13 | ## Quick Start |
| 14 | |
| 15 | The skill provides: |
| 16 | 1. **Project modules** in `src/tools/database/kegg/`: `kegg_rest.py` (base HTTP client), `kegg_operations.py` (query/download operations), `kegg_api.py` (backward-compat re-exports); all download functions re-exported via package. For programmatic use, import e.g. `from src.tools.database.kegg import download_kegg_entry_by_id, ...`. |
| 17 | 2. Reference: `references/kegg_reference.md` |
| 18 | |
| 19 | ### Agent Tools (Download Only) |
| 20 | |
| 21 | | Tool name | Arguments | Purpose | |
| 22 | |-----------|-----------|---------| |
| 23 | | `download_kegg_info_by_database` | `database`, `out_path` | Download KEGG database info/statistics to file | |
| 24 | | `download_kegg_list_by_database` | `database`, `out_path`, `org_or_ids` (optional) | Download KEGG entry list by database to file | |
| 25 | | `download_kegg_find_by_database` | `database`, `query`, `out_path`, `option` (optional) | Download KEGG search results to file | |
| 26 | | `download_kegg_entry_by_id` | `entry_id`, `out_path`, `format` (optional) | Download KEGG entry data by entry ID to file | |
| 27 | | `download_kegg_conv_by_id` | `target_db`, `source_id`, `out_path` | Download KEGG ID conversion result to file | |
| 28 | | `download_kegg_link_by_id` | `target_db`, `source_id`, `out_path` | Download KEGG cross-reference links to file | |
| 29 | | `download_kegg_ddi_by_id` | `drug_id`, `out_path` | Download KEGG drug-drug interaction data to file | |
| 30 | |
| 31 | All return rich JSON: `{status, file_info, content_preview, biological_metadata, execution_context}`. Academic use only. |
| 32 | |
| 33 | ### Project Modules (Programmatic Use) |
| 34 | |
| 35 | | Capability | Function | Module | Purpose | |
| 36 | |------------|----------|--------|---------| |
| 37 | | HTTP client | `kegg_request(operation, *path_parts)` | kegg_rest.py | Base REST GET request, returns text | |
| 38 | | ID helper | `_join_ids(entry_id)` | kegg_rest.py | Format one or multiple IDs for URL (max 10) | |
| 39 | | Query: info | `query_kegg_info_by_database(database)` | kegg_operations.py | Returns rich JSON in memory | |
| 40 | | Query: list | `query_kegg_list_by_database(database, org_or_ids)` | kegg_operations.py | Returns rich JSON in memory | |
| 41 | | Query: find | `query_kegg_find_by_database(database, query, option)` | kegg_operations.py | Returns rich JSON in memory | |
| 42 | | Query: entry | `query_kegg_entry_by_id(entry_id, format)` | kegg_operations.py | Returns rich JSON in memory | |
| 43 | | Query: conv | `query_kegg_conv_by_id(target_db, source_id)` | kegg_operations.py | Returns rich JSON in memory | |
| 44 | | Query: link | `query_kegg_link_by_id(target_db, source_id)` | kegg_operations.py | Returns rich JSON in memory | |
| 45 | | Query: ddi | `query_kegg_ddi_by_id(drug_id)` | kegg_operations.py | Returns rich JSON in memory | |
| 46 | | Download: info | `download_kegg_info_by_database(database, out_path)` | kegg_operations.py | Save to file, return rich JSON | |
| 47 | | Download: list | `download_kegg_list_by_database(database, out_path, org_or_ids)` | kegg_operations.py | Save to file, return rich JSON | |
| 48 | | Download: find | `download_kegg_find_by_database(database, query, out_path, option)` | kegg_operations.py | Save to file, return rich JSON | |
| 49 | | Download: entry | `download_kegg_entry_by_id(entry_id, out_path, format)` | kegg_operations.py | Save to file, return rich JSON | |
| 50 | | Download: conv | `download_kegg_conv_by_id(target_db, source_id, out_path)` | kegg_operations.py | Save to file, return rich JSON | |
| 51 | | Download: link | `download_kegg_link_by_id(target_db, source_id, out_path)` | kegg_operations.py | Save to file, return rich JSON | |
| 52 | | Download: ddi | `download_kegg_ddi_by_id(drug_id, out_path)` | kegg_operations.py | Save to file, return rich JSON | |
| 53 | | Compat alias | `kegg_info`, `kegg_list`, `kegg_find`, `kegg_get`, `kegg_conv`, `kegg_link`, `kegg_ddi` | kegg_operations.py | Backward-compat aliases for query functions | |
| 54 | |
| 55 | ## Core Capabilities |
| 56 | |
| 57 | ### 1. Database Information |
| 58 | |
| 59 | **Download database info:** |
| 60 | ```python |
| 61 | fro |