biogrounder 0.2.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,3 @@
1
+ """BioGrounder: describe biology in, grounded function + ontology terms out."""
2
+
3
+ __version__ = "0.2.0"
@@ -0,0 +1,169 @@
1
+ # Which ontologies are searched for each kind of concept, in order of preference.
2
+ # Any ontology id served by EBI OLS works here (see https://www.ebi.ac.uk/ols4/ontologies).
3
+ # "ncbigene" is special: genes are looked up through MyGene.info.
4
+ # Outside helpers (MyDisease, Monarch, MyChem, Reactome, NCBI Taxonomy, PubTator, BioPortal, ...) are
5
+ # configured separately in sources.yaml; they add candidates but only from the ontologies listed here
6
+ # (or IDs they are the authority for, such as Reactome pathways).
7
+ kind_ontologies:
8
+ disease: [mondo, doid]
9
+ phenotype: [hp, mp]
10
+ biological_process: [go]
11
+ molecular_function: [go]
12
+ cellular_component: [go]
13
+ pathway: [go]
14
+ anatomy: [uberon]
15
+ cell_type: [cl]
16
+ chemical: [chebi]
17
+ gene: [ncbigene]
18
+ organism: [ncbitaxon]
19
+ assay: [bao, obi] # the test method itself: BioAssay Ontology, Ontology for Biomedical Investigations
20
+ medical_action: [maxo] # treatments, procedures, therapies, diagnostic tests: Medical Action Ontology
21
+ genotype: [geno] # zygosity and genotype parts (homozygous, compound heterozygous, wild-type allele): GENO
22
+ chromosome: [chr] # chromosomes, arms and cytogenetic bands (22q11.2): CHR from Monarch's monochrom
23
+ other: [mondo, go, hp, uberon, chebi]
24
+
25
+ # After a term is chosen, also report equivalent IDs in these ontologies
26
+ # (keyed by the chosen term's ontology). Equivalents are read from the ontologies' own xrefs.
27
+ crosswalk:
28
+ mondo: [DOID]
29
+ doid: [MONDO]
30
+
31
+ # Annotations below this confidence put a run in the review queue.
32
+ review_threshold: 0.6
33
+ # How many similar worked examples are shown to the brain per request.
34
+ examples_per_request: 3
35
+ # How many ontology candidates per concept are shown to the brain.
36
+ candidates_per_mention: 8
37
+ # Species searched for genes (MyGene.info names or taxon ids).
38
+ gene_species: human,mouse
39
+
40
+ # The "plus": the learning dictionary (knowledge/dictionary.yaml).
41
+ # auto_learn: add confident, exact, verified mappings of new phrasings from every saved analysis,
42
+ # and allow the learn_term tool. Set false on a server where you only want people to teach it.
43
+ # min_confidence: how sure the brain must be before a mapping is learned.
44
+ learning:
45
+ auto_learn: true
46
+ min_confidence: 0.85
47
+
48
+ # Medical codes and other identifiers reported for every chosen term ("codes" in each annotation).
49
+ # They are read from the chosen term's own cross-references (MONDO alone carries OMIM, Orphanet,
50
+ # ICD-10/11, MeSH, UMLS, SNOMED CT, ...). Display name -> the xref prefixes that mean that system
51
+ # (case-insensitive; a prefix also matches versioned forms such as SNOMEDCT_US_2025_09_01).
52
+ code_systems:
53
+ MONDO: [MONDO]
54
+ Disease Ontology: [DOID]
55
+ Human Phenotype Ontology: [HP]
56
+ Mammalian Phenotype Ontology: [MP]
57
+ OMIM: [OMIM, MIM]
58
+ Orphanet: [Orphanet, ORPHA, ORDO]
59
+ ICD-10-CM: [ICD10CM]
60
+ ICD-10 (WHO): [ICD10WHO, ICD10]
61
+ ICD-11: [icd11.foundation, ICD11]
62
+ ICD-9: [ICD9, ICD9CM]
63
+ MeSH: [MESH, MSH]
64
+ UMLS: [UMLS, UMLS_CUI]
65
+ SNOMED CT: [SCTID, SNOMEDCT_US, SNOMEDCT]
66
+ NCI Thesaurus: [NCIT, NCI]
67
+ MedDRA: [MedDRA]
68
+ MedGen: [MEDGEN]
69
+ GARD: [GARD]
70
+ NANDO: [NANDO]
71
+ NCBI Gene: [NCBIGene]
72
+ HGNC: [HGNC]
73
+ MGI: [MGI]
74
+ Ensembl: [ENSEMBL]
75
+ UniProt: [UniProtKB]
76
+ ChEBI: [CHEBI]
77
+ CAS: [cas]
78
+ DrugBank: [drugbank]
79
+ PubChem: [PUBCHEM.COMPOUND]
80
+ KEGG: [kegg.compound, kegg.drug]
81
+ HMDB: [hmdb]
82
+ FMA: [FMA]
83
+ Reactome: [Reactome]
84
+ MAxO: [MAXO]
85
+ GENO: [GENO]
86
+
87
+ # Identifiers that may already be written in a description (an OMIM number, an rsID, an ICD code,
88
+ # a CAS number, an ontology ID ...). Each is found by `regex` ({1}, {2} = capture groups) and resolved
89
+ # by the first `resolve` step that succeeds:
90
+ # curie look the ID up directly (OLS, MyGene, or the source that owns the prefix)
91
+ # disease_xref find the MONDO disease that cross-references it (MyDisease); ICD codes fall back
92
+ # to their parent code (E84.0 -> E84)
93
+ # gene_query a MyGene.info query, e.g. 'ensembl.gene:{1}'
94
+ # chemical_query a MyChem.info query, e.g. 'chebi.xrefs.cas:{1}'
95
+ # source ask one source from sources.yaml (e.g. myvariant for rsIDs)
96
+ # none just report it (e.g. a PubMed ID)
97
+ identifier_patterns:
98
+ - system: ontology term
99
+ regex: '\b(MONDO|DOID|HP|MP|GO|UBERON|CL|CHEBI|NCBITaxon|BAO|OBI|EFO|PATO|SO|PR|ZP)[:_](\d{4,})\b'
100
+ curie: '{1}:{2}'
101
+ resolve: [{via: curie}]
102
+ - system: OMIM
103
+ regex: '\b(?:OMIM|MIM)\s*(?:#|no\.?|number)?\s*:?\s*\*?(\d{6})\b'
104
+ curie: 'OMIM:{1}'
105
+ resolve: [{via: disease_xref, db: omim}, {via: gene_query, q: 'MIM:{1}'}]
106
+ - system: Orphanet
107
+ regex: '\bORPHA(?:NET)?\s*[:#]?\s*(\d{1,7})\b'
108
+ curie: 'Orphanet:{1}'
109
+ resolve: [{via: disease_xref, db: orphanet}]
110
+ - system: ICD-10
111
+ regex: '\bICD-?10(?:-?CM)?\s*(?:code)?\s*:?\s*([A-TV-Z]\d{2}(?:\.\d{1,4}[A-Z]?)?)\b'
112
+ curie: 'ICD10CM:{1}'
113
+ resolve: [{via: disease_xref, db: icd10cm}, {via: disease_xref, db: icd10who}]
114
+ - system: MeSH
115
+ regex: '\bMe?SH\s*(?:ID)?\s*:?\s*(D\d{6})\b'
116
+ curie: 'MESH:{1}'
117
+ resolve: [{via: disease_xref, db: mesh}]
118
+ - system: UMLS CUI
119
+ regex: '\b(C\d{7})\b'
120
+ curie: 'UMLS:{1}'
121
+ resolve: [{via: disease_xref, db: umls}]
122
+ - system: dbSNP
123
+ regex: '\b(rs\d{3,})\b'
124
+ curie: 'dbSNP:{1}'
125
+ resolve: [{via: source, source: myvariant, kind: other}]
126
+ - system: NCBI Gene
127
+ regex: '\b(?:NCBIGene|Entrez\s*Gene(?:\s*ID)?|GeneID)\s*:?\s*(\d+)\b'
128
+ curie: 'NCBIGene:{1}'
129
+ resolve: [{via: curie}]
130
+ - system: HGNC
131
+ regex: '\bHGNC\s*:\s*(\d+)\b'
132
+ curie: 'HGNC:{1}'
133
+ resolve: [{via: gene_query, q: 'HGNC:{1}'}]
134
+ - system: Ensembl gene
135
+ regex: '\b(ENS[A-Z]*G\d{11})\b'
136
+ curie: 'ENSEMBL:{1}'
137
+ resolve: [{via: gene_query, q: 'ensembl.gene:{1}'}]
138
+ - system: UniProt
139
+ regex: '\bUniProt(?:KB)?\s*:?\s*([OPQ]\d[A-Z0-9]{3}\d|[A-NR-Z]\d(?:[A-Z][A-Z0-9]{2}\d){1,2})\b'
140
+ curie: 'UniProtKB:{1}'
141
+ resolve: [{via: gene_query, q: 'uniprot.Swiss-Prot:{1}'}]
142
+ - system: CAS
143
+ regex: '\b(\d{2,7}-\d{2}-\d)\b'
144
+ check: cas
145
+ curie: 'CAS:{1}'
146
+ resolve: [{via: chemical_query, q: 'chebi.xrefs.cas:{1}'}]
147
+ - system: Reactome
148
+ regex: '\b(R-[A-Z]{3}-\d+)\b'
149
+ curie: 'Reactome:{1}'
150
+ resolve: [{via: curie}]
151
+ - system: PubMed
152
+ regex: '\bPMID\s*:?\s*(\d{4,9})\b'
153
+ curie: 'PMID:{1}'
154
+ resolve: [{via: none}]
155
+
156
+ # Connections in the literature (PubTator3 relations mined from PubMed) between the grounded genes,
157
+ # diseases and chemicals: treat, cause, associate, inhibit, stimulate, interact, ...
158
+ literature:
159
+ connections_in_analysis: true # add them to every server-side analysis
160
+ max_entities: 8 # pairs grow fast; PubTator asks for at most 3 requests/second
161
+ papers_for_top: 5 # fetch example papers for the strongest connections
162
+ min_publications: 3 # leave out relations seen in fewer papers (often mining noise)
163
+ parallel_requests: 4 # PubTator calls in flight at once (their starts are still paced)
164
+ papers_per_connection: 3
165
+ scan_wait_seconds: 120 # how long an analysis waits for slow text annotators (PubTator)
166
+
167
+ # Where proposals made with propose_change are sent for review (GitHub owner/name). Change it in a fork.
168
+ contribute:
169
+ repository: djportUCD/biogrounder
@@ -0,0 +1,7 @@
1
+ # The learning dictionary: phrase -> ontology ID, grown by using the MCP.
2
+ # confirmed = a person said so (strong prior)
3
+ # learned = picked up automatically from confident analyses or added by an AI
4
+ # (weak prior that grows with `count`, until a person confirms or rejects it)
5
+ # rejected = a person said this phrase does NOT mean this ID
6
+ # Edit, confirm, reject or delete entries freely. Terms themselves always come live from OLS.
7
+ entries: []
@@ -0,0 +1,29 @@
1
+ id: cftr-f508del
2
+ title: CFTR F508del and cystic fibrosis
3
+ text: >-
4
+ CFTR is an ATP-gated anion channel in the apical membrane of epithelial cells that conducts chloride
5
+ and bicarbonate. The common F508del variant misfolds and is degraded by ER-associated degradation
6
+ before reaching the membrane, so airway surface liquid becomes dehydrated, mucus thickens, and
7
+ recurrent bacterial lung infections follow, as seen in cystic fibrosis.
8
+ summary: CFTR is an epithelial anion channel; the F508del variant causes cystic fibrosis.
9
+ function: Moves chloride and bicarbonate out of epithelial cells to keep secretions hydrated.
10
+ mechanism: >-
11
+ ATP binding opens the channel in the apical membrane. F508del misfolds, is caught by ER quality
12
+ control and degraded, so little channel reaches the cell surface.
13
+ why: >-
14
+ Ion flow drives water onto the airway surface; without it mucus is thick and cannot be cleared,
15
+ so bacteria persist and cause chronic infection.
16
+ annotations:
17
+ - {mention: cystic fibrosis, curie: MONDO:0009061, label: cystic fibrosis, kind: disease}
18
+ - {mention: CFTR, curie: NCBIGene:1080, label: 'CFTR (human): CF transmembrane conductance regulator', kind: gene}
19
+ - {mention: ATP-gated anion channel ... conducts chloride, curie: GO:0005260, label: intracellularly ATP-gated chloride channel activity, kind: molecular_function}
20
+ - {mention: bicarbonate, curie: GO:0015701, label: bicarbonate transport, kind: biological_process}
21
+ - {mention: apical membrane, curie: GO:0016324, label: apical plasma membrane, kind: cellular_component}
22
+ - {mention: ER-associated degradation, curie: GO:0036503, label: ERAD pathway, kind: biological_process}
23
+ - {mention: recurrent bacterial lung infections, curie: HP:0002205, label: Recurrent respiratory infections, kind: phenotype}
24
+ forbidden:
25
+ - {curie: NCBIGene:12638, reason: the mouse Cftr gene; the text is about the human gene}
26
+ notes: >-
27
+ Prefer the most specific GO function the text supports: it says ATP-gated, so the ATP-gated chloride
28
+ channel term beats the generic 'chloride channel activity'.
29
+ tags: [human, ion-channel, variant]
@@ -0,0 +1,32 @@
1
+ # A worked example. Edit any field. `annotations` lists the key terms a good answer should
2
+ # contain (not necessarily every possible term). IDs were checked against OLS.
3
+ id: duchenne-dystrophin
4
+ title: Dystrophin loss in Duchenne muscular dystrophy
5
+ text: >-
6
+ Dystrophin (DMD) is a large cytoskeletal protein that links the actin cytoskeleton of muscle fibers
7
+ to the extracellular matrix through the dystrophin-associated glycoprotein complex at the
8
+ sarcolemma. This link stabilizes the membrane during contraction. Loss-of-function mutations in DMD
9
+ leave the sarcolemma fragile, so fibers tear, degenerate and are replaced by fat and fibrous tissue,
10
+ producing progressive muscle weakness in boys with Duchenne muscular dystrophy.
11
+ summary: Dystrophin is a structural muscle protein whose loss causes Duchenne muscular dystrophy.
12
+ function: Mechanically anchors the muscle-fiber cytoskeleton to the extracellular matrix.
13
+ mechanism: >-
14
+ Binds actin inside the fiber and the dystrophin-associated glycoprotein complex in the sarcolemma,
15
+ which in turn binds the extracellular matrix, forming a load-bearing bridge across the membrane.
16
+ why: >-
17
+ Spreads the force of contraction so the sarcolemma does not tear; without it fibers are damaged
18
+ with every contraction and progressively lost.
19
+ annotations:
20
+ - {mention: Duchenne muscular dystrophy, curie: MONDO:0010679, label: Duchenne muscular dystrophy, kind: disease}
21
+ - {mention: DMD, curie: NCBIGene:1756, label: 'DMD (human): dystrophin', kind: gene}
22
+ - {mention: sarcolemma, curie: GO:0042383, label: sarcolemma, kind: cellular_component}
23
+ - {mention: dystrophin-associated glycoprotein complex, curie: GO:0016010, label: dystrophin-associated glycoprotein complex, kind: cellular_component}
24
+ - {mention: links the actin cytoskeleton, curie: GO:0003779, label: actin binding, kind: molecular_function}
25
+ - {mention: progressive muscle weakness, curie: HP:0001324, label: Muscle weakness, kind: phenotype}
26
+ forbidden:
27
+ - {curie: MONDO:1010199, reason: the non-human animal form of the disease; this text is about people}
28
+ - {curie: NCBIGene:13405, reason: the mouse Dmd gene; the text is about the human gene}
29
+ notes: >-
30
+ 'links the actin cytoskeleton' is grounded as an implied molecular function (actin binding).
31
+ The disease is a human disease, so MONDO is preferred; DOID:11723 is added automatically as an equivalent.
32
+ tags: [human, muscle, structural-protein]
@@ -0,0 +1,32 @@
1
+ id: lep-ob-mouse
2
+ title: Lep ob/ob mouse model of monogenic obesity
3
+ text: >-
4
+ Lep ob/ob mice carry a nonsense mutation in the leptin gene and make no functional leptin, the
5
+ adipocyte hormone that signals energy stores to the hypothalamus. Without this satiety signal the
6
+ mice overeat from weaning, become severely obese, and develop hyperglycemia and insulin resistance,
7
+ making them a model of congenital leptin deficiency and type 2 diabetes-like metabolic disease.
8
+ summary: A mouse strain lacking leptin that models monogenic obesity and insulin resistance.
9
+ function: Leptin is a hormone that reports fat stores to the brain and suppresses appetite.
10
+ mechanism: >-
11
+ Adipocytes secrete leptin in proportion to fat mass; it acts on hypothalamic neurons to reduce food
12
+ intake. A nonsense mutation abolishes the protein, so the brain senses starvation regardless of fat mass.
13
+ why: >-
14
+ Matches food intake to energy stores; without it the animal overeats continuously, causing obesity
15
+ and secondary metabolic disease.
16
+ annotations:
17
+ - {mention: leptin gene, curie: NCBIGene:16846, label: 'Lep (mouse): leptin', kind: gene}
18
+ - {mention: adipocyte hormone, curie: GO:0005179, label: hormone activity, kind: molecular_function}
19
+ - {mention: satiety signal, curie: GO:0032099, label: negative regulation of appetite, kind: biological_process}
20
+ - {mention: hypothalamus, curie: UBERON:0001898, label: hypothalamus, kind: anatomy}
21
+ - {mention: overeat, curie: MP:0001433, label: polyphagia, kind: phenotype}
22
+ - {mention: severely obese, curie: MP:0001261, label: obese, kind: phenotype}
23
+ - {mention: hyperglycemia, curie: MP:0001559, label: hyperglycemia, kind: phenotype}
24
+ - {mention: insulin resistance, curie: MP:0005331, label: insulin resistance, kind: phenotype}
25
+ - {mention: congenital leptin deficiency, curie: MONDO:0013991, label: obesity due to congenital leptin deficiency, kind: disease}
26
+ forbidden:
27
+ - {curie: HP:0001513, reason: the human phenotype term; phenotypes of mice go to MP}
28
+ - {curie: NCBIGene:3952, reason: 'the human LEP gene; these are mice, so the mouse ortholog'}
29
+ notes: >-
30
+ Mouse model: phenotypes go to MP, not HP, and the gene is the mouse ortholog. The human disease the
31
+ model represents is still grounded in MONDO.
32
+ tags: [mouse, model-organism, metabolism, mmrrc]
@@ -0,0 +1,35 @@
1
+ # Plain-language curation rules. Edit freely; the brain reads all of them.
2
+ guidelines:
3
+ - id: most-specific-supported
4
+ text: Choose the most specific term the text actually supports, and no more specific than that.
5
+ kinds: []
6
+ - id: mouse-phenotypes-mp
7
+ text: When the text describes a mouse or other model organism, ground its phenotypes to MP (Mammalian
8
+ Phenotype), and ground human patient phenotypes to HP.
9
+ kinds: [phenotype]
10
+ - id: prefer-mondo
11
+ text: Ground diseases to MONDO first; Disease Ontology equivalents are added automatically from cross-references.
12
+ kinds: [disease]
13
+ - id: model-represents-disease
14
+ text: For an animal model, also ground the human disease the model is said to represent, marked as implied
15
+ if the text names it only indirectly.
16
+ kinds: [disease]
17
+ - id: function-vs-process
18
+ text: An activity of a single gene product (binds, transports, catalyses) is a molecular_function; what
19
+ the cell or organism achieves with it is a biological_process. Ground both when the text supports both.
20
+ kinds: [molecular_function, biological_process]
21
+ - id: gene-species
22
+ text: Ground a gene to the species the text is about (mouse symbol and mouse gene for mouse studies).
23
+ kinds: [gene]
24
+ - id: test-methods
25
+ text: For a test method or assay description (including new approach methodologies, NAMs), ground the method
26
+ itself as an assay (BAO / OBI), what it measures as a biological_process or phenotype, the test system as
27
+ a cell_type, anatomy or organism, and the test substance as a chemical. Say in the summary which type of
28
+ method it is - in vitro, ex vivo, in chemico (reactivity of a chemical, e.g. DPRA), in silico (computer
29
+ models such as (Q)SAR) or in vivo with a lower organism - and what it is used for (e.g. skin sensitisation
30
+ hazard, regulatory screening).
31
+ kinds: []
32
+ - id: pathways-go-and-reactome
33
+ text: When the text describes a named signalling or metabolic pathway, ground it in GO and, where a Reactome
34
+ pathway is offered, prefer the Reactome pathway for the pathway itself and GO for the process it achieves.
35
+ kinds: [pathway]
@@ -0,0 +1,341 @@
1
+ # The catalogue of outside services this MCP can ask for help.
2
+ #
3
+ # It is written for two readers: the code (adapter, kinds, params) and the AI using the MCP
4
+ # (helps_with, good_for, not_for, returns). The list_sources tool shows it to the AI, so the AI
5
+ # knows which helper to ask for what. Edit freely: turn sources on or off, tune what they are
6
+ # searched for, or add notes about what you've seen them get right or wrong.
7
+ #
8
+ # Fields
9
+ # adapter how the code talks to it: ols, mygene, mychem, mydisease, monarch, reactome,
10
+ # ncbi_taxonomy, pubtator, bioportal, or rest_json (a generic JSON API you
11
+ # describe entirely in params; see the uniprot entry below for a template)
12
+ # enabled used automatically during grounding for the kinds listed
13
+ # kinds which concept kinds it is asked about (see kind_ontologies in config.yaml)
14
+ # own_ids ID prefixes this source is the authority for (verified against it, not OLS)
15
+ # key if the service needs a key: the env var, whether it is required, how to get one.
16
+ # People store keys with: biogrounder keys set <id>
17
+ # (never paste a key into an AI chat)
18
+ # rate_limit requests per second this client allows itself
19
+ # terms licence / terms of use, in short; check the link before heavy use
20
+
21
+ sources:
22
+ - id: ols
23
+ name: EMBL-EBI Ontology Lookup Service (OLS4)
24
+ adapter: ols
25
+ enabled: true
26
+ url: https://www.ebi.ac.uk/ols4
27
+ docs: https://www.ebi.ac.uk/ols4/help
28
+ helps_with: >-
29
+ The main source. Searches ~270 OBO ontologies (MONDO, DOID, HP, MP, GO, UBERON, CL, ChEBI,
30
+ NCBITaxon, BAO, OBI, ...) by label and synonym, and returns definitions, synonyms and
31
+ cross-references. Every non-gene ID is verified here.
32
+ good_for: [any ontology term, checking an ID exists, finding MONDO <-> DOID equivalents]
33
+ not_for: [genes (use mygene), Reactome pathway IDs]
34
+ kinds: [all]
35
+ returns: [any OBO CURIE]
36
+ rate_limit: 4
37
+ terms: Free, no key. Each ontology keeps its own licence.
38
+
39
+ - id: mygene
40
+ name: MyGene.info (BioThings)
41
+ adapter: mygene
42
+ enabled: true
43
+ url: https://mygene.info/v3
44
+ docs: https://docs.mygene.info
45
+ helps_with: >-
46
+ Genes by symbol, alias or name for the species in config.yaml (gene_species). Returns
47
+ NCBI Gene IDs with HGNC / MGI cross-references and a summary.
48
+ good_for: [gene symbols, old gene names and aliases (Nrf2 -> NFE2L2), mouse vs human genes]
49
+ not_for: [proteins described only by function with no gene name]
50
+ kinds: [gene]
51
+ returns: [NCBIGene]
52
+ own_ids: [NCBIGene]
53
+ rate_limit: 5
54
+ terms: Free, no key. BioThings (Scripps) terms of use; gene data keep their sources' licences.
55
+
56
+ - id: mydisease
57
+ name: MyDisease.info (BioThings)
58
+ adapter: mydisease
59
+ enabled: true
60
+ url: https://mydisease.info/v1
61
+ docs: https://docs.mydisease.info
62
+ helps_with: >-
63
+ Diseases. Returns MONDO IDs together with their DOID, OMIM and MeSH cross-references, so it
64
+ also bridges MeSH disease IDs (e.g. from PubTator) to MONDO.
65
+ good_for: [disease names, rare diseases, MeSH or OMIM -> MONDO]
66
+ not_for: [phenotypes / symptoms (use ols or monarch)]
67
+ kinds: [disease]
68
+ returns: [MONDO]
69
+ rate_limit: 5
70
+ terms: Free, no key. BioThings (Scripps) terms of use; aggregated data keep each source's licence.
71
+
72
+ - id: monarch
73
+ name: Monarch Initiative knowledge graph
74
+ adapter: monarch
75
+ enabled: true
76
+ url: https://api-v3.monarchinitiative.org/v3/api
77
+ docs: https://api-v3.monarchinitiative.org/v3/docs
78
+ helps_with: >-
79
+ A second opinion for diseases and phenotypes. Searches MONDO and the phenotype ontologies
80
+ (HP, MP, ZP, ...) with synonyms and cross-references in one call. Also used after grounding to
81
+ add codes to diseases and genes, and the curated gene–disease causal links (MONDO). Its
82
+ semantic similarity service (semsimian over PHENIO) scores how close two terms are, even
83
+ across species (MP against HP), and which diseases best fit a set of phenotypes: used by
84
+ check_consistency and to tell near misses from wrong answers when scoring.
85
+ good_for: [phenotypes, diseases, cross-species phenotypes]
86
+ not_for: [chemicals, pathways]
87
+ kinds: [disease, phenotype]
88
+ returns: [MONDO, HP, MP, ZP, ...]
89
+ rate_limit: 4
90
+ terms: Free, no key. Software BSD-3-Clause; data keep each upstream source's licence.
91
+ params:
92
+ categories:
93
+ disease: biolink:Disease
94
+ phenotype: biolink:PhenotypicFeature
95
+ gene: biolink:Gene
96
+
97
+ - id: quickgo
98
+ name: QuickGO (EBI) Gene Ontology annotations
99
+ adapter: quickgo
100
+ enabled: true
101
+ url: https://www.ebi.ac.uk/QuickGO/services
102
+ docs: https://www.ebi.ac.uk/QuickGO/api/index.html
103
+ helps_with: >-
104
+ Checks statements that a gene does something: is the gene's product annotated to a GO
105
+ function, process or location (or a more specific one), with which evidence code and
106
+ reference? Used by check_consistency, not for searching terms. "Not annotated" means nobody
107
+ has curated it, not that it is false; a NOT annotation means curators say it does not.
108
+ good_for: [checking gene-function statements, evidence codes and references for GO claims]
109
+ not_for: [finding terms]
110
+ kinds: []
111
+ returns: [GO annotations]
112
+ rate_limit: 5
113
+ terms: Free, no key. GO annotations are CC BY 4.0 (Gene Ontology Consortium).
114
+
115
+ - id: maxo_annotations
116
+ name: MAxO annotations (Monarch Initiative)
117
+ adapter: maxo_annotations
118
+ enabled: true
119
+ url: https://github.com/monarch-initiative/maxo-annotations/releases/latest/download/maxo-annotations.tsv
120
+ docs: https://github.com/monarch-initiative/maxo-annotations
121
+ helps_with: >-
122
+ Curated medical actions for a disease: which treatments, procedures and diagnostics (MAxO
123
+ terms) treat or prevent which of its phenotypes (HP), with an evidence code and a PMID.
124
+ Added to grounded MONDO diseases as related terms. A small, hand-curated set (a few hundred
125
+ diseases), so absence means "not curated yet".
126
+ good_for: [treatments of rare diseases, which phenotype a treatment targets]
127
+ not_for: [drugs as chemicals (use ChEBI), common diseases]
128
+ kinds: []
129
+ returns: [MAXO, HP]
130
+ rate_limit: 1
131
+ terms: CC BY 4.0. Downloaded once a day from the latest GitHub release.
132
+
133
+ - id: namo
134
+ name: NAMO (Monarch New Approach Methodology Ontology)
135
+ adapter: namo
136
+ enabled: true
137
+ url: https://raw.githubusercontent.com/monarch-initiative/namo/main/src/namo/schema/namo.yaml
138
+ docs: https://github.com/monarch-initiative/namo
139
+ helps_with: Model systems that replace animal testing - organoids, organ-on-chip, cell-free assays, in-silico models.
140
+ good_for:
141
+ - organoid, spheroid and 3D culture models
142
+ - organ-on-chip, tissue-on-chip and other microphysiological systems
143
+ - in-silico models (QSAR, PBPK, digital twins, machine learning) and cell-free assays
144
+ not_for:
145
+ - specific assays or protocols (use OBI/BAO through OLS)
146
+ - the cells, tissues or chemicals a model uses (CL, UBERON, ChEBI)
147
+ kinds: [assay, other]
148
+ returns: [namo]
149
+ own_ids: [namo]
150
+ rate_limit: 1
151
+ terms: BSD-3-Clause
152
+ notes: A LinkML schema, not in OLS; the file is downloaded once a day and searched locally. IDs are namo:ClassName.
153
+ - id: dismech
154
+ name: DisMech disease mechanisms (Monarch Initiative)
155
+ adapter: dismech
156
+ enabled: true
157
+ url: https://github.com/monarch-initiative/dismech/releases/latest/download/mondo_emc.tsv
158
+ docs: https://dismech.monarchinitiative.org
159
+ helps_with: >-
160
+ Links a grounded MONDO disease to its DisMech page: a curated description of the disease
161
+ mechanism (genes, processes, cell types, phenotypes), with the papers it cites. DisMech
162
+ entries are drafted by AI agents and reviewed by people; the project says it is not medical advice.
163
+ good_for: [how a disease works, mechanism summaries with citations]
164
+ not_for: [grounding terms]
165
+ kinds: []
166
+ returns: [links to mechanism pages, PMIDs]
167
+ rate_limit: 1
168
+ terms: >-
169
+ Repository licensed BSD-3-Clause (its LICENSE file still carries a template copyright line);
170
+ parts of its knowledge base contain LOINC content under LOINC's own terms. Only links,
171
+ summaries and PMIDs are shown here. Downloaded once a day from the latest GitHub release (about 6 MB).
172
+
173
+ - id: mychem
174
+ name: MyChem.info (BioThings)
175
+ adapter: mychem
176
+ enabled: true
177
+ url: https://mychem.info/v1
178
+ docs: https://docs.mychem.info
179
+ helps_with: >-
180
+ Chemicals and drugs. Aggregates ChEBI, PubChem, DrugBank, ChEMBL and UNII and returns ChEBI
181
+ IDs with PubChem / DrugBank cross-references. Handles drug and trade names that ChEBI's own
182
+ labels miss.
183
+ good_for: [drug names, common chemical names, test substances]
184
+ not_for: [chemical classes described only in words]
185
+ kinds: [chemical]
186
+ returns: [CHEBI]
187
+ rate_limit: 5
188
+ terms: Free, no key. BioThings (Scripps) terms of use; data keep each source's licence (DrugBank is restricted).
189
+
190
+ - id: reactome
191
+ name: Reactome Content Service
192
+ adapter: reactome
193
+ enabled: true
194
+ url: https://reactome.org/ContentService
195
+ docs: https://reactome.org/dev/content-service
196
+ helps_with: >-
197
+ Curated human pathways and reactions (R-HSA-... IDs), e.g. "KEAP1-NFE2L2 pathway" or
198
+ "thyroid hormone synthesis". Use alongside GO when the text describes a signalling or
199
+ metabolic pathway.
200
+ good_for: [signalling pathways, metabolic pathways, named cascades]
201
+ not_for: [diseases, single genes]
202
+ kinds: [pathway, biological_process]
203
+ returns: [Reactome (Reactome:R-HSA-...)]
204
+ own_ids: [Reactome]
205
+ rate_limit: 4
206
+ terms: Free, no key. Reactome data are CC0.
207
+ params:
208
+ species: Homo sapiens
209
+
210
+ - id: ncbi_taxonomy
211
+ name: NCBI Taxonomy (E-utilities)
212
+ adapter: ncbi_taxonomy
213
+ enabled: true
214
+ url: https://eutils.ncbi.nlm.nih.gov/entrez/eutils
215
+ docs: https://www.ncbi.nlm.nih.gov/books/NBK25501/
216
+ helps_with: >-
217
+ Organisms by scientific or common name ("bovine", "zebrafish", "rhesus monkey") to NCBI
218
+ Taxonomy IDs. Better than label search for common names.
219
+ good_for: [common organism names, adjectives like bovine / porcine / murine]
220
+ not_for: [cell lines, strains]
221
+ kinds: [organism]
222
+ returns: [NCBITaxon]
223
+ rate_limit: 3
224
+ key:
225
+ env: NCBI_API_KEY
226
+ required: false
227
+ how_to_get: Optional. A free NCBI account key (https://www.ncbi.nlm.nih.gov/account/settings/) raises the limit from 3 to 10 requests/second.
228
+ terms: Free. NCBI usage policy applies; taxonomy data are public domain.
229
+
230
+ - id: pubtator
231
+ name: NCBI PubTator3 entity lookup
232
+ adapter: pubtator
233
+ enabled: true
234
+ url: https://www.ncbi.nlm.nih.gov/research/pubtator3-api
235
+ docs: https://www.ncbi.nlm.nih.gov/research/pubtator3/api
236
+ helps_with: >-
237
+ How the biomedical literature normalises a name: genes to NCBI Gene, diseases to MeSH
238
+ (bridged to MONDO through MyDisease). Strong on gene aliases and on how diseases are
239
+ named in papers. Also the source of literature connections: relations mined from PubMed
240
+ (treat, cause, associate, inhibit, stimulate, interact, ...) between two entities, with
241
+ paper counts and example papers (find_literature_connections).
242
+ good_for: [gene aliases as used in papers, disease names as used in papers]
243
+ not_for: [organisms, cell types, assays]
244
+ kinds: [gene, disease]
245
+ returns: [NCBIGene, MONDO]
246
+ rate_limit: 3
247
+ terms: Free, no key. NCBI usage policy applies (max 3 requests/second).
248
+ params:
249
+ concepts:
250
+ gene: GENE
251
+ disease: DISEASE
252
+ chemical: CHEMICAL
253
+
254
+ - id: bioportal
255
+ name: NCBO BioPortal (search + text annotator)
256
+ adapter: bioportal
257
+ enabled: true # stays inactive until someone stores a key
258
+ url: https://data.bioontology.org
259
+ docs: https://data.bioontology.org/documentation
260
+ helps_with: >-
261
+ Over 1,000 ontologies, including ones not in OLS. Its text annotator finds ontology terms
262
+ directly in a whole paragraph, which is a useful cross-check on what the reading step found.
263
+ good_for: [scanning a whole description for terms, ontologies missing from OLS]
264
+ not_for: [genes]
265
+ kinds: [disease, phenotype, anatomy, cell_type, assay]
266
+ returns: [OBO CURIEs from the listed ontologies]
267
+ rate_limit: 5
268
+ key:
269
+ env: BIOPORTAL_API_KEY
270
+ required: true
271
+ how_to_get: Free. Create an account at https://bioportal.bioontology.org/accounts/new, then copy the key from your account page.
272
+ terms: Free with an account. Each ontology keeps its own licence.
273
+ params:
274
+ ontologies: [MONDO, DOID, HP, MP, GO, UBERON, CL, CHEBI, BAO, OBI]
275
+
276
+ # A template for adding any JSON REST API without writing code. Disabled by default.
277
+ - id: uniprot
278
+ name: UniProtKB
279
+ adapter: rest_json
280
+ enabled: false
281
+ url: https://rest.uniprot.org
282
+ docs: https://www.uniprot.org/help/api
283
+ helps_with: >-
284
+ Proteins by name or function, with their gene names. Useful when a text names a protein
285
+ ("thyroid peroxidase") rather than a gene. Off by default because the main pipeline grounds
286
+ genes, not proteins; turn it on if you want UniProt accessions too.
287
+ good_for: [protein names, protein function text]
288
+ not_for: [diseases, phenotypes]
289
+ kinds: [gene]
290
+ returns: [UniProtKB]
291
+ own_ids: [UniProtKB]
292
+ rate_limit: 5
293
+ terms: Free, no key. CC BY 4.0.
294
+ params:
295
+ search_path: /uniprotkb/search
296
+ search_params: {query: "{query} AND reviewed:true", format: json, size: "{limit}", fields: "accession,protein_name,gene_names,organism_name"}
297
+ results: results
298
+ id: primaryAccession
299
+ id_prefix: UniProtKB
300
+ label: proteinDescription.recommendedName.fullName.value
301
+ synonyms: genes.0.geneName.value
302
+ get_path: /uniprotkb/{id}.json
303
+
304
+ - id: pubtator_text
305
+ name: NCBI PubTator3 text annotation (AIONER, GNorm2, tmVar3, NLM-Chem, TaggerOne)
306
+ adapter: pubtator_text
307
+ enabled: true
308
+ url: https://www.ncbi.nlm.nih.gov/CBBresearch/Lu/Demo/RESTful
309
+ docs: https://www.ncbi.nlm.nih.gov/research/pubtator3/api
310
+ helps_with: >-
311
+ Runs NCBI's literature taggers over your own text and returns the genes, species, diseases,
312
+ chemicals, variants and cell lines it finds, already normalised to NCBI Gene, NCBI Taxonomy,
313
+ MeSH (bridged to MONDO) and dbSNP. Free, no key. It is a queued service: results take about
314
+ 1-2 minutes, so it runs in the background (scan_text_with_sources, get_scan_result).
315
+ good_for: [catching genes, variants and species the reading step missed, species-aware gene IDs]
316
+ not_for: [phenotypes, processes, anatomy, assays; anything needing an answer in seconds]
317
+ kinds: []
318
+ returns: [NCBIGene, NCBITaxon, MONDO (via MeSH), dbSNP, HGVS, Cellosaurus]
319
+ rate_limit: 2
320
+ terms: Free, no key. NCBI usage policy; at most 3 requests/second; not for clinical decisions.
321
+ params:
322
+ bioconcept: All
323
+ poll_seconds: 5
324
+ max_wait_seconds: 240
325
+
326
+ - id: myvariant
327
+ name: MyVariant.info (BioThings)
328
+ adapter: myvariant
329
+ enabled: true
330
+ url: https://myvariant.info/v1
331
+ docs: https://docs.myvariant.info
332
+ helps_with: >-
333
+ Variants. An rsID (or an HGVS ID) to the gene it sits in and ClinVar conditions and
334
+ significance, aggregating dbSNP, ClinVar, gnomAD and more. Used to resolve rsIDs written in a
335
+ text; ask it directly with ask_source('myvariant', 'rs113993960').
336
+ good_for: [rsIDs, HGVS genomic IDs, ClinVar conditions for a variant]
337
+ not_for: [protein-level names like F508del without a gene/ID]
338
+ kinds: []
339
+ returns: [dbSNP, HGVS]
340
+ rate_limit: 5
341
+ terms: Free, no key. BioThings (Scripps) terms of use; ClinVar and dbSNP data are public domain.