Skills for understanding and applying DOSDP (Dead Simple Ontology Design Patterns) to ensure consistent ontology term creation and maintenance...
This skill helps you understand, identify, and apply Dead Simple Ontology Design Patterns (DOSDP) when creating or editing ontology terms.
DOSDP patterns are templates that ensure consistent naming, definitions, and logical axioms across similar types of ontology terms. They encode best practices for term construction and help maintain consistency in:
DOSDP patterns are defined in YAML files with this structure:
pattern_name: pattern_name_here
description: 'Human-readable description with examples'
classes:
# Upper-level classes used in the pattern
disease: MONDO:0000001
relations:
# Relations used in logical definitions
disease has location: RO:0004026
vars:
# Variables that will be filled in
disease: "'disease'"
location: "'anatomical entity'"
name:
# Template for term name
text: '%s of %s'
vars: [disease, location]
def:
# Template for definition
text: 'A %s that involves the %s.'
vars: [disease, location]
equivalentTo:
# Logical definition template (OWL equivalence)
text: "%s and 'disease has location' some %s"
vars: [disease, location]
Pattern: location.yaml
Used when a disease/phenotype affects a specific anatomical location.
Structure:
{disease} of {location} or {location} {disease}A {disease} that involves the {location}.{disease} and 'disease has location' some {location}Examples:
When to use: Creating terms for diseases in specific anatomical locations
Pattern: disease_series_by_gene.yaml
Used for diseases caused by mutations in a specific gene.
Structure:
{disease} caused by variation in {gene} or {gene}-related {disease}Any {disease} in which the cause of the disease is a variation in the {gene} gene.{disease} and 'has material basis in germline mutation in' some {gene}has_material_basis_in_germline_mutation_in {gene_id}Examples:
When to use: Creating terms for monogenic diseases with gene-based names
Important notes:
Patterns: childhood.yaml, adult.yaml, infantile.yaml
Used for diseases characterized by onset at specific life stages.
Structure:
{age_stage} {disease}A {disease} that occurs during {age_stage}.{disease} and 'has characteristic' some {age_characteristic}Examples:
When to use: Creating age-specific variants of diseases
Patterns: autosomal_dominant.yaml, autosomal_recessive.yaml, x_linked.yaml, y_linked.yaml
Used for diseases with specific inheritance patterns.
Examples:
When to use: Creating terms that emphasize inheritance mode
Patterns: cancer.yaml, carcinoma.yaml, benign.yaml, malignant.yaml, sarcoma.yaml
Used for various types of neoplastic diseases.
Examples:
When to use: Creating cancer/tumor-related terms
Pattern: basis_in_disruption_of_process.yaml
Used for diseases characterized by disruption of a biological process.
Structure:
'has basis in disruption of' some {process}When to use: Diseases with clear mechanistic etiology
inflammatory_disease_by_site.yamlinfectious_disease_by_agent.yamlallergy.yaml, allergic_form_of_disease.yamlrare.yaml, rare_genetic.yamlisolated.yaml, syndromic.yaml, acute.yaml, chronic.yamlBefore creating a new term, ask:
What is the primary distinguishing characteristic?
Check pattern directory:
src/patterns/dosdp-patterns/*.yamlExamine similar existing terms:
Once you've identified a pattern, gather the required information:
Variable values: What will fill the pattern slots?
Parent class: What is the upper-level class?
References: What sources support this term?
Create the term following the pattern's template:
Name: Follow the pattern's naming convention exactly
Definition: Use the pattern's definition template
Logical definition: Create intersection_of axioms
intersection_of: {parent_class}
intersection_of: {relation} {filler}
Relationships: Add appropriate relationship statements
relationship: {relation} {target} {source="PMID:xxxxx"}
Synonyms: Follow pattern's synonym templates
Check that your term follows the pattern:
name: section?def: section?intersection_of axioms present?annotations: section?[Term]
id: MONDO:1060117
name: MYCBP2-related developmental delay with corpus callosum defects
def: "Any neurodevelopmental disorder in which the cause of the disease is a mutation in the MYCBP2 gene." [PMID:36200388]
synonym: "MDCD" EXACT ABBREVIATION [PMID:36200388]
synonym: "MYCBP2 neurodevelopmental disorder" EXACT []
is_a: MONDO:0700092 {source="PMID:36200388"} ! neurodevelopmental disorder
intersection_of: MONDO:0700092 ! neurodevelopmental disorder
intersection_of: has_material_basis_in_germline_mutation_in http://identifiers.org/hgnc/23386
relationship: has_material_basis_in_germline_mutation_in http://identifiers.org/hgnc/23386 {source="PMID:36200388"} ! MYCBP2
This follows the disease_series_by_gene pattern:
[Term]
id: MONDO:0000715
name: lymph node adenoid cystic carcinoma
def: "An adenoid cystic carcinoma that involves the lymph node." [PMID:12345678]
is_a: MONDO:0001082 ! lymph node cancer
is_a: MONDO:0004971 ! adenoid cystic carcinoma
intersection_of: MONDO:0004971 ! adenoid cystic carcinoma
intersection_of: disease_has_location UBERON:0000029 ! lymph node
This follows the location pattern:
Problem: Choosing too specific or too general a parent
Solution:
classes: sectionProblem: Missing intersection_of axioms or relationships
Solution: Every pattern requires:
intersection_of axioms from the equivalentTo: templateProblem: Deviating from pattern naming conventions
Solution:
name: templateProblem: Relationships without source tags
Solution: Add source attribution to all asserted axioms:
is_a: PARENT:123 {source="PMID:xxxxx"}
relationship: has_basis_in ENTITY:456 {source="PMID:yyyyy"}
Problem: Using wrong or guessed gene/anatomy identifiers
Solution: Always verify:
Sometimes a term could fit multiple patterns. Guidelines:
Primary characteristic wins: Choose the pattern that captures the most important distinguishing feature
Combine patterns when appropriate: Some terms can use multiple patterns
Avoid pattern conflicts: Don't mix incompatible patterns
Consult existing terms: Look for similar multi-pattern terms in the ontology
Patterns are typically stored in:
src/patterns/dosdp-patterns/*.yamlKey sections to understand:
Many pattern files include:
While this skill focuses on understanding patterns rather than using tools, be aware:
The overall philosophy is to: