OntoDoc: Automatically Generating Ontology Resource Descriptions
Organizations: University of Texas at Arlington, Arlington TX 76013, US
Abstract
Knowledge graphs and ontologies form the backbone of structured, machine-readable knowledge representation, yet ontology terms often lack natural language descriptions, limiting their accessibility and reuse. Existing ontology verbalization approaches tend to rely on rule-based or template-driven techniques that operate on strict, formal schema axioms, resulting in rigid verbalizations that fail to convey richer contextual semantics. We present OntoDoc, a multi-agent framework for automatically generating natural language descriptions for any Internationalized Resource Identifier (IRI) within a SPARQL endpoint or RDF file. OntoDoc operates through a four-stage pipeline: (1) a Database Context agent that adaptively explores the knowledge graph via SPARQL to collect semantically informative triples about the target IRI; (2) a Web Context agent that retrieves and re-ranks encyclopedic background knowledge from Wikipedia and the open web; (3) an Assumption Generation agent that synthesizes both contexts into a structured, evidence-grounded list of intermediate assumptions; and (4) a Description Generation agent that produces the final natural language description from the grounded assumptions. We evaluate OntoDoc on three knowledge graphs spanning biomedical, agricultural, and cross-domain settings, using both automatic scoring via Large Language Models (LLMs) and human evaluation with 11 annotators. OntoDoc consistently matches or exceeds a naive LLM baseline and a template-based ontology verbalizer in accuracy. Furthermore, it vastly outperforms both baselines in the completeness of the generated descriptions, delivering an average 12% improvement in completeness over the naive baseline across all domains, and improving completeness scores by as much as 2.8 points on a 5-point scale relative to the ontology verbalizer.
Figures & tables
| Tool | Description |
| get_iri_information | Retrieves rdf:type, rdfs:label, rdfs:comment, dcterms:description, and skos:definition; also checks whether the IRI is used as a predicate. |
| get_outgoing_triples | Returns triples where the IRI is subject ( ), max 200. |
| get_incoming_triples | Returns triples where the IRI is object ( ), max 200. |
| get_predicate_usage | For property IRIs, returns sample triples ( ) and distinct rdf:type values of subjects and objects. |
| execute_sparql | Executes SPARQL SELECT/ASK queries with filtering, grouping, aggregation, and arbitrary patterns. |
| Assumption | Reasoning |
| LacrosseLeague is a class representing organized sports leagues specifically for the sport of lacrosse. | The IRI is typed as an OWL Class, specifically a subclass of SportsLeague , indicating that it represents a type of sports league focused on lacrosse. This is directly stated in triples 1 and 3. |
| LacrosseLeague is an internationally recognized concept describing leagues, associations, or organizations where lacrosse teams compete. | Multiple labels in different languages such as ‘lacrosse league’, ‘lacrosse bond’, ‘Lacrosse-Liga’ and others indicate the concept is universally recognized as a lacrosse sporting league entity. This is supported by triples 3–9. |
| … | |
| Model | Win Rate (w/ assumptions) | Win Rate (w/o assumptions) |
| gpt-4.1-mini | 47.02% | 47.68% |
| gemini-2.5-flash-lite | 23.18% | 19.21% |
| glm-4.7-flash | 29.80% | 33.11% |
| Knowledge Graph | Sample Size (n) | Assumptions Step Win Rate |
| DBpedia | 30 | 57.00% |
| BioBricks-MeSH | 51 | 61.00% |
| SOCKG | 70 | 54.00% |
| Knowledge Graph | Metric | OntoDoc | Naive |
| DBpedia (n=30) | Accuracy | 4.20 | 4.30 |
| Clarity | 4.47 | 4.73 | |
| Completeness | 3.97 | 3.67 | |
| Cruciality | 3.90 | 4.43 | |
| BioBricks-MeSH (n=51) | Accuracy | 3.76 | 3.65 |
| Clarity | 4.43 | 4.24 |
| Knowledge Graph | Metric | Naive | OntoDoc | Verbalizer |
| DBpedia | Accuracy | 4.20 | 4.30 | 1.50 |
| Clarity | 4.80 | 4.70 | 1.00 | |
| Completeness | 3.40 | 4.00 | 1.20 | |
| Cruciality | 4.50 | 4.10 | 1.50 | |
| BioBricks-MeSH | Accuracy | 3.65 | 4.00 | 3.41 |
| Clarity | 4.24 | 4.71 | 3.94 |
| KG | Accuracy | Clarity | Completeness | Cruciality |
| DBpedia | 4.43 | 4.36 | 4.36 | 4.20 |
| BioBricks-MeSH | 4.51 | 4.49 | 4.43 | 4.34 |
| SOCKG | 3.93 | 3.65 | 3.72 | 3.74 |
| Score | Label | Description |
| 1 | Poor | There are no accurate statements about the term. All the claims that are present in the description are factually incorrect. |
| 2 | Fair | The description contains at least one accurate statement, but one or more clearly incorrect claims are also present. |
| 3 | Good | All statements are plausibly accurate, but at least one is imprecise, overgeneralized, or weakly supported by the available evidence. |
| 4 | Very Good | All statements are accurate and reasonably precise, with only minor ambiguities in phrasing that do not mislead the reader. |
| 5 | Excellent | All statements are factually correct and expressed with full precision. There are no misleading, ambiguous, or unsupported claims. |
| Score | Label | Description |
| 1 | Poor | The description is largely incomprehensible and the reader cannot extract a coherent meaning from it. |
| 2 | Fair | The description is difficult enough to follow that it requires significant effort to infer the core meaning. |
| 3 | Good | The core meaning is accessible, but at least one sentence or phrase is notably ambiguous or awkwardly constructed. |
| 4 | Very Good | The description is generally clear and easy to read, with only minor phrasing issues that do not impede understanding. |
| 5 | Excellent | The description is completely clear, fluent, and unambiguous throughout. |
| Score | Label | Description |
| 1 | Poor | The description covers only a superficial aspect of the concept and most essential information is absent. |
| 2 | Fair | The description covers some essential information but is missing one or more details that are critical to understanding the concept. |
| 3 | Good | The description covers the core of the concept adequately, but omits at least one secondary detail that would be expected in an ideal description of the term. |
| 4 | Very Good | The description covers all essential information needed to understand the concept, but omits secondary details that would further enrich it. |
| 5 | Excellent | The description covers all essential information and relevant secondary details, giving a full and representative picture of the concept. |
| Score | Label | Description |
| 1 | Poor | The description is dominated by off-topic or irrelevant content and appears to address a different concept entirely. |
| 2 | Fair | It is clear that the right concept is being described, but multiple non-essential details are present that significantly dilute the focus. |
| 3 | Good | The description is mostly about the right concept, but includes at least one tangential or redundant detail that adds noise without aiding understanding. |
| 4 | Very Good | The description is well-focused with at most one minor unnecessary detail that does not materially harm the overall description. |
| 5 | Excellent | Every included detail is essential toward understanding the concept, and nothing is superfluous. |
Knowledge Graphs
Knowledge graphs represent entities and relationships as structured, queryable networks for integrating data and supporting reasoning.
See all 251 papers