All primitives

Contracts / shared language

Schemas & Ontology Versioning

Teach your application what things mean. Schemas define what information is valid; ontologies describe what those concepts mean and how they connect.

The idea

Imagine building a real estate application. A property has an owner. A tenant rents a property. A lease connects that tenant to a property. A schema defines the information each object contains; an ontology describes the meaning behind those objects and the relationships between them. Together, they give people, applications, and AI agents a shared vocabulary.

Real Estate Builder

Schema and ontology workbench

Local interactive demo

Entities

Choose a concept to inspect its schema.

3 concepts in this model

Ontology relationship

SignsCovers

The ontology records what each entity means and how those concepts connect.

Property schema

Fields and types

Version
  • AddressText
  • Number of bedroomsNumber
  • Monthly rentCurrency
  • OwnerPerson reference

This interactive preview is local and resets on refresh. Real contracts keep versions and migration history alongside your application.

Schema

What information is valid?

Fields, types, and constraints define what an object can contain.

Ontology

What does that information mean?

Concepts and relationships give your data a shared meaning.

Versioning

How does the definition evolve?

Record changes over time and keep earlier contracts available for comparison.

What could you build?

  • Industry-specific applications
  • Business knowledge systems
  • Interoperable agents
  • Structured workflows

Good for

  • API and event contracts
  • Knowledge graph vocabularies
  • Safe migrations

Implementation notes

  • Commit contracts beside the code that uses them.
  • Generate validators and types from one source.
  • Attach migration notes to every breaking change.

Implementing it

With a coding agent

Ask your agent to define your data contracts

Agent setup (mock link)

Copy this prompt, fill in the bracketed details, and paste it into your coding agent. It describes the goal, the contract, and the guardrails.

Bracketed text marks details only you can fill in. 840 / 6,000 characters.

Fill in:BUSINESS AREAAPP OR PRODUCTCONTRACT NAMEFIELDS, TYPES, AND REQUIRED RULESKEY TERMS AND HOW THEY RELATEHOW EXISTING DATA SHOULD CHANGEVALID, INVALID, AND BACKWARD-COMPATIBILITY CASES

Good foundation · 72/100

Traditional SDK / API

Publish a data contract

TypeScript
ultrahost.contracts.publish({
  name: "invoice.created",
  version: "2.1.0",
  schema: invoiceCreatedSchema,
})

Key takeaway

Schemas and ontologies help people, applications, and AI agents share a consistent understanding of your business.

Next primitive

Search Engine