Skip to main content
The ontology is the “view” that TextQL (particularly, the ‘ontology’ tool) has into a connected data warehouse. It delineates the logical concepts that exist within your business in a way that is easy for TextQL’s AI to understand and generate correct queries. You construct an ontology for your company by defining objects, attributes, and links.
Example Ontology

Example ontology for a ticket selling business. The ontology (left center) is comprised of objects denoting concepts core to the business, each tied to a subset of the user's data warehouse. Links describe related data concepts, such as 'Events at Venues'.

Compared to generating SQL directly from schema annotations, an ontology has the following advantages:
  • The ontology is structured. It is fully known what parts of an AI generated query map onto which parts of the ontology.
  • Ontology queries are much easier for a non-technical user to understand compared to direct SQL.
  • Ontologies can be progressively improved without changing the underlying data model. They are designed to work reasonably on a mapping that is very similar to the data warehouse ERD and only get better with incremental improvements that still don’t change the underlying data infrastructure.
  • Ontologies can be improved in a deterministic manner; if the definition of a KPI in the ontology is changed, TextQL is forced to compute that definition in the calculation.
Automatic Ontology Generation: TextQL supports automatic generation of ontology components:
  • Attribute Auto-Inference: When adding objects from tables, attributes are automatically inferred from table schemas, including column types and primary keys
  • Alation Integration: Import complete ontologies from Alation data catalog, including objects, attributes, and relationships based on join metadata
Full automatic ontology generation from arbitrary database ERDs (without Alation) is a work in progress.