Skip to main content

Semantic Layer

Teach agents and AI queries what your data means: how your tables relate and what your business terms stand for.​

Why Use a Semantic Layer​

A database schema says what is stored, not what it means. An AI model that reads only the schema has to guess which columns join two tables and what your users mean by "active customer". Each guess can produce a query that runs, returns rows and answers the wrong question.

The semantic layer lets you state that meaning once, and Squid gives it to every agent and AI query that reads the data.

Overview​

The semantic layer has two parts:

PartWhat it holdsExample
OntologiesRelationships between tables, the business entities they hold, and the properties of those entitiesorders.customer_id is "placed by" customers.id
GlossariesBusiness terms with plain-language definitions, synonyms and query hints"Active Customer" means an order in the last 90 days

Both can be generated from your schemas and knowledge bases. Generation only proposes: nothing reaches your agents until you save it. Connect them to an agent as described in Connected Ontologies and Glossaries.

Admins and developers of an application can also manage them in the Squid Console, under the Ontologies and Glossaries tabs of the Agent Studio.