@base <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic> .
@prefix : <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic#> .
@prefix schema: <http://schema.org/> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix prov: <http://www.w3.org/ns/prov#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix ex: <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic#> .

: a owl:Ontology ;
  rdfs:label "Metadata Weekly AI Knowledge Architecture Ontology" ;
  rdfs:comment "Lightweight ontology generated from the Metadata Weekly article about semantic layers, ontologies, knowledge graphs, and context graphs." ;
  schema:name "Metadata Weekly AI Knowledge Architecture Ontology" ;
  schema:description "A small RDF model for semantic layers, ontologies, knowledge graphs, context graphs, claims, FAQ entries, and glossary terms." ;
  schema:identifier "https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic" ;
  rdfs:isDefinedBy : .

:article a schema:Article ;
  schema:headline "Ontologies, Context Graphs, and Semantic Layers: What AI Actually Needs in 2026" ;
  schema:abstract "Semantic layers govern metrics, while ontologies, knowledge graphs, and context graphs represent meaning, context, and inference for AI systems."@en ;
  schema:url <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic> ;
  schema:datePublished "2026-01-22"^^xsd:date ;
  schema:author :jessica-talisman ;
  schema:publisher :metadata-weekly ;
  schema:about :semantic-layer, :ontology, :knowledge-graph, :context-graph, :knowledge-architecture ;
  schema:hasPart :, :concept-section, :claim-section, :faq, :glossary, :howto, :sparql-section ;
  prov:wasGeneratedBy :kg-generator-skill, :rdf-infographic-skill .

:jessica-talisman a schema:Person ;
  schema:name "Jessica Talisman" ;
  schema:url <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic> ;
  schema:identifier "https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic#jessica-talisman" .

:metadata-weekly a schema:Organization ;
  schema:name "Metadata Weekly" ;
  schema:url <https://metadataweekly.substack.com/> .

:concept-section a schema:ArticleSection ;
  schema:name "Core architecture concepts" ;
  schema:isPartOf :article ;
  schema:hasPart :semantic-layer, :ontology, :knowledge-graph, :context-graph, :knowledge-architecture .

:claim-section a schema:ArticleSection ;
  schema:name "Claims encoded in RDF" ;
  schema:isPartOf :article ;
  schema:hasPart :claim-metric-consistency, :claim-ai-needs-context .

:semantic-layer a schema:DefinedTerm, skos:Concept ;
  schema:name "Semantic layer" ;
  skos:prefLabel "Semantic layer"@en ;
  schema:description "A governed abstraction layer for metric definitions, dimensional models, SQL generation, and reporting consistency."@en ;
  skos:definition "A governed abstraction layer for metric definitions, dimensional models, SQL generation, and reporting consistency."@en ;
  ex:optimizesFor :measurement ;
  ex:answersQuestionType "What is X?" ;
  ex:limitation "Does not fully model domain reality, causal context, authority, tacit knowledge, or inference rules."@en ;
  rdfs:isDefinedBy : .

:ontology a schema:DefinedTerm, skos:Concept ;
  schema:name "Ontology" ;
  skos:prefLabel "Ontology"@en ;
  schema:description "A formal specification of domain concepts, properties, constraints, and relationships."@en ;
  skos:definition "A formal specification of domain concepts, properties, constraints, and relationships."@en ;
  owl:sameAs <http://dbpedia.org/resource/Ontology_(information_science)> ;
  ex:optimizesFor :meaning ;
  ex:supports :logical-inference, :disambiguation, :domain-understanding ;
  rdfs:isDefinedBy : .

:knowledge-graph a schema:DefinedTerm, skos:Concept ;
  schema:name "Knowledge graph" ;
  skos:prefLabel "Knowledge graph"@en ;
  schema:description "A graph-based representation of entities, relationships, and facts that provides structured domain context."@en ;
  owl:sameAs <http://dbpedia.org/resource/Knowledge_graph> ;
  ex:providesContextFor :ai-systems ;
  rdfs:isDefinedBy : .

:context-graph a schema:DefinedTerm, skos:Concept ;
  schema:name "Context graph" ;
  skos:prefLabel "Context graph"@en ;
  schema:description "A knowledge graph focused on operational context, decision traces, authority, precedents, procedures, justifications, and execution histories."@en ;
  ex:captures :decision-trace, :tacit-knowledge, :procedure-execution, :authority, :precedent ;
  rdfs:isDefinedBy : .

:knowledge-architecture a schema:DefinedTerm, skos:Concept ;
  schema:name "Knowledge architecture" ;
  skos:prefLabel "Knowledge architecture"@en ;
  schema:description "The discipline of designing semantic systems that represent concepts, relationships, constraints, context, and inference rules."@en ;
  ex:uses :semantic-layer, :ontology, :knowledge-graph, :context-graph ;
  rdfs:isDefinedBy : .

:measurement a skos:Concept ; skos:prefLabel "Measurement"@en ; rdfs:isDefinedBy : .
:meaning a skos:Concept ; skos:prefLabel "Meaning"@en ; rdfs:isDefinedBy : .
:ai-systems a skos:Concept ; skos:prefLabel "AI systems"@en ; rdfs:isDefinedBy : .
:logical-inference a skos:Concept ; skos:prefLabel "Logical inference"@en ; rdfs:isDefinedBy : .
:disambiguation a skos:Concept ; skos:prefLabel "Disambiguation"@en ; rdfs:isDefinedBy : .
:domain-understanding a skos:Concept ; skos:prefLabel "Domain understanding"@en ; rdfs:isDefinedBy : .
:decision-trace a skos:Concept ; skos:prefLabel "Decision trace"@en ; rdfs:isDefinedBy : .
:tacit-knowledge a skos:Concept ; skos:prefLabel "Tacit knowledge"@en ; rdfs:isDefinedBy : .
:procedure-execution a skos:Concept ; skos:prefLabel "Procedure execution"@en ; rdfs:isDefinedBy : .
:authority a skos:Concept ; skos:prefLabel "Authority"@en ; rdfs:isDefinedBy : .
:precedent a skos:Concept ; skos:prefLabel "Precedent"@en ; rdfs:isDefinedBy : .

:claim-metric-consistency a schema:Claim ;
  schema:name "Metric consistency is not domain understanding" ;
  schema:text "Semantic layers solve governed calculation, but they do not by themselves represent organizational reality."@en ;
  schema:about :semantic-layer ;
  schema:isPartOf :claim-section .

:claim-ai-needs-context a schema:Claim ;
  schema:name "AI needs context and inference" ;
  schema:text "AI systems need concepts, relationships, constraints, decision context, and inference-ready representations."@en ;
  schema:about :ontology, :knowledge-graph, :context-graph ;
  schema:isPartOf :claim-section .

:glossary a schema:DefinedTermSet ;
  schema:name "Glossary" ;
  schema:hasDefinedTerm :semantic-layer, :ontology, :knowledge-graph, :context-graph, :knowledge-architecture ;
  schema:isPartOf :article .

:faq a schema:FAQPage ;
  schema:name "FAQ" ;
  schema:isPartOf :article ;
  schema:mainEntity :q1, :q2, :q3, :q4 .

:q1 a schema:Question ;
  schema:name "Is a semantic layer enough for AI?" ;
  schema:acceptedAnswer :a1 .
:a1 a schema:Answer ;
  schema:text "It is enough for governed metric lookup and calculation consistency, but not for reasoning that requires domain concepts, constraints, causal context, or procedural meaning."@en .

:q2 a schema:Question ;
  schema:name "What does an ontology add?" ;
  schema:acceptedAnswer :a2 .
:a2 a schema:Answer ;
  schema:text "An ontology makes concepts, relationships, properties, and constraints explicit so machines can interpret and reason over domain meaning."@en .

:q3 a schema:Question ;
  schema:name "What does a context graph add beyond a knowledge graph?" ;
  schema:acceptedAnswer :a3 .
:a3 a schema:Answer ;
  schema:text "A context graph captures the operational why: decisions, authority, precedent, procedures, execution history, and supporting evidence."@en .

:q4 a schema:Question ;
  schema:name "What should organizations build now?" ;
  schema:acceptedAnswer :a4 .
:a4 a schema:Answer ;
  schema:text "They should keep governed metrics where those work, then add formal knowledge representation where AI systems must reason about concepts, procedures, constraints, and decisions."@en .

:howto a schema:HowTo ;
  schema:name "How to choose the right semantic architecture" ;
  schema:isPartOf :article ;
  schema:step :step1, :step2, :step3 .
:step1 a schema:HowToStep ; schema:name "Use a semantic layer for governed metrics" ; schema:text "Choose a semantic layer when the task is consistent calculation, dimensions, joins, and BI-facing answers."@en .
:step2 a schema:HowToStep ; schema:name "Use an ontology for domain meaning" ; schema:text "Choose an ontology when the task requires explicit classes, relationships, constraints, and inference."@en .
:step3 a schema:HowToStep ; schema:name "Use a context graph for operational reasoning" ; schema:text "Choose a context graph when the task requires decision traces, authority, procedures, precedents, or auditability."@en .

:sparql-section a schema:ArticleSection ;
  schema:name "SPARQL exploration templates" ;
  schema:isPartOf :article ;
  schema:hasPart :query-entity-type-summary, :query-describe-article, :query-construct-compact-graph .

:uriburner-sparql a schema:WebAPI ;
  schema:name "URIBurner SPARQL endpoint" ;
  schema:url <https://linkeddata.uriburner.com/sparql> ;
  schema:description "SPARQL endpoint used by the generated HTML workbench for live query exploration."@en .

:query-entity-type-summary a schema:SoftwareSourceCode ;
  schema:name "Entity type summary" ;
  schema:programmingLanguage "SPARQL" ;
  schema:codeSampleType "SELECT" ;
  schema:target :uriburner-sparql ;
  schema:about :article ;
  schema:text """PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>

SELECT ?type (SAMPLE(?s) AS ?sampleEntity) (SAMPLE(?label) AS ?sampleLabel) (COUNT(?s) AS ?entityCount)
WHERE {
  GRAPH <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic> {
    ?s rdf:type ?type .
    OPTIONAL { ?s rdfs:label ?label }
  }
}
GROUP BY ?type
ORDER BY DESC(?entityCount)""" .

:query-describe-article a schema:SoftwareSourceCode ;
  schema:name "Describe source article" ;
  schema:programmingLanguage "SPARQL" ;
  schema:codeSampleType "DESCRIBE" ;
  schema:target :uriburner-sparql ;
  schema:about :article ;
  schema:text """DESCRIBE <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic#article>
FROM <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic>""" .

:query-construct-compact-graph a schema:SoftwareSourceCode ;
  schema:name "Construct compact graph" ;
  schema:programmingLanguage "SPARQL" ;
  schema:codeSampleType "CONSTRUCT" ;
  schema:target :uriburner-sparql ;
  schema:about :article ;
  schema:text """CONSTRUCT { ?s ?p ?o }
WHERE {
  GRAPH <https://metadataweekly.substack.com/p/ontologies-context-graphs-and-semantic> {
    ?s ?p ?o .
    FILTER(?p IN (<http://schema.org/about>, <http://schema.org/hasPart>, <http://schema.org/mentions>, <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>))
  }
}
LIMIT 100""" .

:kg-generator-skill a schema:SoftwareApplication ;
  schema:name "kg-generator skill" ;
  schema:url <https://github.com/OpenLinkSoftware/ai-agent-skills/tree/main/kg-generator> ;
  schema:description "Codex skill used to generate standards-oriented RDF knowledge graphs from source documents."@en .

:rdf-infographic-skill a schema:SoftwareApplication ;
  schema:name "rdf-infographic-skill" ;
  schema:url <https://github.com/OpenLinkSoftware/ai-agent-skills/tree/main/rdf-infographic-skill> ;
  schema:description "Codex skill used to generate RDF-backed HTML and Markdown companion artifacts."@en .

<https://virtuoso.openlinksw.com/#this> a schema:SoftwareApplication ;
  schema:name "OpenLink Virtuoso" ;
  schema:url <https://virtuoso.openlinksw.com/> .
