/semantic-analysis:extract-ontologiesfrom semantic-analysis
Authors and validates reviewed domain ontologies and source-backed glossaries from documents, schemas, or datasets. Use for ontology learning, vocabulary and definition authoring, competency questions, RDF/OWL modeling, SHACL design, and evidence-led entity or relation extraction as part of ontology authoring. For applying a fixed ontology to extract instances from supplied files, use an ontology-guided extraction workflow. Do not use for Semantic OKF snapshot operations or consulting an existing knowledge bundle.
Ships in semantic-analysis. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Turn source evidence into a reviewed semantic model before lifecycle materialization. Deliver approved mappings and constraints as ordinary output artifacts. For requests outside this authoring boundary, return an explicit diagnostic without importing or invoking another skill.
glossary.md with its evidence locators. Add glossary.csv when the user requests tabular output or needs a machine-readable glossary.SKILL.md, references/, scripts/, and declared Python requirements.owl:sameAs, disjointness, inverse properties, property characteristics, keys, or cardinalities without direct evidence and human review.rdfs:domain and rdfs:range as type-producing axioms, not input constraints. Put record-shape requirements in SHACL.owl:equivalentClass, owl:equivalentProperty, or owl:sameAs when equivalence is uncertain.Read extraction-workflow.md before extracting from sources or reviewing an axiom's source attribution. Read semantic-modeling.md before choosing OWL axioms, profiles, graph boundaries, or SHACL constraints. Read turtle-patterns.md when authoring RDF artifacts. Read standards-and-tools.md when exact standards status, validation scope, or tool limitations matter.
Read disjunctions.md for branch alternatives, qualified value counts, or tests that distinguish which values and records a choice governs.
Create or adapt this bundle unless the user specifies another contract:
scope.md # domain boundary, consumers, profile, assumptions
evidence.csv # exact source locator, interpretation, confidence, and review-state ledger
ontology.ttl # OWL 2 terminology and ontology metadata
data.ttl # accepted instance assertions
shapes.ttl # SHACL validation contract
competency-questions.rq # ASK/SELECT queries tied to numbered questions
validation-report.ttl # machine-readable SHACL report when shapes are run
Run the bundled scripts with uv and Python 3.11 or later. Replace
<skill-dir> below with this skill's actual directory; write OUTPUT_DIR in
the task workspace, outside the skill resource directory. uv run --script
prepares each script's environment from its declared dependency metadata.
Scaffold the first six files with:
uv run --script <skill-dir>/scripts/scaffold_ontology_bundle.py OUTPUT_DIR \
--ontology-iri https://example.org/ontology/domain \
--version-iri https://example.org/ontology/domain/1.0.0 \
--prefix ex \
--title "Domain ontology" \
--owl-profile rl
Do not publish the scaffold unchanged. Replace comments, fill the evidence ledger, and add positive and negative fixtures appropriate to the domain.
For a plan-only request, keep the response compact: use 6–10 ordered steps, name each core artifact once, state each applicable bundled command once, and surface no more than five unresolved review decisions. Name scaffold_ontology_bundle.py and validate_semantic_artifacts.py directly when they apply. Include only safety boundaries triggered by the request instead of restating the complete policy.
For offline or reproducible authoring, explicitly pin ontology sources, imports, and JSON-LD contexts to supplied local versions and forbid remote dereferencing during validation.
The validator's script metadata pins RDFLib, pySHACL, and OWL-RL; no separate virtual-environment or pip setup is needed for the commands shown here. The bundled references/requirements.txt records the fuller dependency set for separately provisioned environments. Optional external profile checkers or reasoners require their own explicitly selected, versioned setup; the bundled validator does not install or run them.
Validate local graph files with:
uv run --script <skill-dir>/scripts/validate_semantic_artifacts.py \
--data OUTPUT_DIR/data.ttl \
--ontology OUTPUT_DIR/ontology.ttl \
--shapes OUTPUT_DIR/shapes.ttl \
--inference none \
--report OUTPUT_DIR/validation-report.ttl
Use --inference rdfs, owlrl, or both only when that entailment regime is part of the declared validation contract. The bundled validator parses RDF graphs, meta-validates SHACL, and runs pySHACL; it deliberately does not certify OWL 2 DL/profile conformance or full logical consistency.
agents/openai.yaml (opens in a new tab)references/disjunctions.md (opens in a new tab)references/extraction-workflow.md (opens in a new tab)references/glossary.md (opens in a new tab)references/premise-reuse.md (opens in a new tab)references/requirements.in (opens in a new tab)references/requirements.txt (opens in a new tab)references/semantic-modeling.md (opens in a new tab)references/standards-and-tools.md (opens in a new tab)references/turtle-patterns.md (opens in a new tab)scripts/choose_owl_comparison_bundle.py (opens in a new tab)scripts/compile_glossary_batch.py (opens in a new tab)scripts/compile_glossary_proposals.py (opens in a new tab)scripts/normalize_owl_comparison.py (opens in a new tab)scripts/plan_owl_premise_reuse.py (opens in a new tab)scripts/scaffold_ontology_bundle.py (opens in a new tab)scripts/test_compile_glossary_batch.py (opens in a new tab)scripts/test_compile_glossary_proposals.py (opens in a new tab)scripts/validate_semantic_artifacts.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub gvillarroel/plugins --plugin semantic-analysis5 skills in this plugin
/book-semantic-analysisAnalyze supplied books or excerpts through evidence-linked themes, interpretive claims, alternative readings, and semantic relationships, then build interactive semantic graphs with inspectable passage evidence in ChatGPT or standalone HTML. Use for literary close reading and nonfiction argument analysis when the actual text is available./curate-semantic-modelCurate evidence-preserving semantic models, build reproducible taxonomy and ontology snapshots, and compare semantic changes between two versions of a document, repository, or pull request. Use for maintained typed knowledge, concept unification, and evidence-backed graph review./Other plugins' skills for the same job