Bringing versioned JSON Schemas, fast validation, and machine-readable data contracts into the database.

Our order application is ready for production. Its AI builder used a specific version of the Order contract. The CI/CD pipeline checked the generated documents and application behavior against that definition. The application now validates incoming orders before storing them.

Then another application starts writing orders to the same database.

It needs to follow the same structural requirements: an item must be present, the quantity must be a positive integer, and the customer’s phone number must be included. Those requirements should not depend on which application writes the document or whether that application remembered to call its validator.

This is where database integration adds value.

The database can bind the stored data to a particular schema version and apply that definition through a constraint. Applications can continue validating earlier for immediate feedback, but the database provides a common check at the point where data is written.

Project Delphi takes that connection further. We plan to bring the JSON Schema repository and its versioning into Oracle AI Database, connect the fast validators directly to constraints, and then carry the proposed Data Semantic Vocabulary alongside the structural definitions.

The first benefit is deliberately practical: manage the schema once, bind a database constraint to an exact version, and validate documents without calling the repository for every write.

This article describes the planned database integration, which follows the Project Delphi launch reference implementation. The SQL and DSV examples illustrate the design; they are not finalized, released interfaces.

Start with ordinary JSON Schema

The first step does not require an application to adopt every part of Project Delphi. It starts with ordinary JSON Schema.

For our order application, the structural requirements are straightforward:

FieldRequirement
itemA nonempty string; required.
quantityAn integer of at least one; required.
phoneNumberA nonempty string; required.

Oracle AI Database already supports JSON Schema validation, including check constraints and reusable JSON domains. The proposed integration does not invent database-side JSON validation. It adds repository-managed identity, versions, and dependencies to the definitions those checks use. [1]

Instead of treating the schema as text supplied to a particular constraint, the database will manage it as a named, versioned object.

For example, the Order definition could be registered as val_orders, version 1.0.0. Applications and database constraints can then identify the same release. The repository retains the registered content and its identity; a later change creates another version rather than replacing the definition underneath existing users.

If the schema references a reusable Address definition, the repository also records the exact version of that dependency. Pinning the root schema is not enough if its referenced requirements can change independently.

This is more than putting schema documents into a table. The intended integration makes the relationship between a schema version and the database objects using it explicit.

The near-term win is useful on its own: JSON Schemas become managed database dependencies, not definitions each application must maintain separately. The vocabulary and repository model are explained in From JSON Schema to a Versioned Software Dependency.

Bind the table to the definition

Suppose the approved Order schema is registered as val_orders, version 1.0.0.

The proposed SQL surface lets a constraint name that version directly:

SQL & PL/SQL

-- Illustrative proposed syntax; not a released interface.

-- 
!DDL Example goes here!

!PL/SQL Example!
DECLARE
    l_content BLOB;
  BEGIN
    SELECT json_serialize(
             JSON('{
               "type": "object",
               "properties": {
                 "item": {
                   "type": "string",
                   "minLength": 1
                 },
                 "quantity": {
                   "type": "integer",
                   "minimum": 1
                 },
                 "phoneNumber": {
                   "type": "string",
                   "minLength": 1
                 }
               },
               "required": ["item", "quantity", "phoneNumber"],
               "additionalProperties": false
             }')
             RETURNING BLOB)
      INTO l_content
      FROM dual;

    DBMS_SPECIFICATIONS.CREATE_SPECIFICATION(
      specification_name => 'val_orders',
      uri                => 'https://www.example.com/val_orders?version=1.0.0',
      description        => 'Customer orders',
      compatibility      => 'BACKWARD',
      content            => l_content,
      business_owner     => 'John Doe'
    );
  END;
  /

--
--

CREATE TABLE orders (
    doc JSON NOT NULL,
    CONSTRAINT orders_contract_ck CHECK (
        doc IS JSON VALIDATE USING CONTRACT val_orders
            VERSION '1.0.0'
    )
);

The important part is not the exact spelling of the proposed syntax. It is the relationship it establishes:

The orders.doc column is checked against val_orders version 1.0.0.

An order such as this satisfies our example requirements:

JSON

{
  "item": "SKU-1234",
  "quantity": 2,
  "phoneNumber": "+1-202-555-0100"
}

An otherwise identical order with quantity zero does not. With the constraint enabled, the database rejects that write. The check applies at the database boundary rather than depending on which client submitted the document.

The application still benefits from validating before it writes. It can give the user an immediate explanation or reject a bad request before doing other work. Database validation provides another boundary; it does not make earlier validation unnecessary.

The document also does not need to carry the complete schema or its version in every row. In this example, the column’s constraint establishes which version governs the stored documents.

The definition used by the application and the definition used by the database should be checked for agreement during deployment. Having both sides validate is not enough if they validate against different requirements.

Keep the repository out of each write

The repository is not in the per-document validation path—even when the repository lives inside the database.

When the constraint is bound and its validator is prepared, the database resolves the selected schema version and its referenced definitions. It then prepares a reusable form that the validation engine can execute.

Incoming orders use that prepared validator. Checking whether a quantity is positive does not require fetching the schema from the repository, resolving its references, or asking a separate service to approve the document.

The repository is not in the validation path – but the database enables it and validates the data

The repository manages the definition. The validation engine checks the data.

That separation is central to the design. Moving the repository into the database should not turn every insert or update into a fresh schema lookup. Nor should the application need to call the repository before making each write.

Preparation may need to happen again after a cache rebuild or a relevant engine or configuration change. When it does, the database must prepare the same pinned definition—not silently select whichever version is newest.

The prepared validator is an execution artifact. It does not become a second, independently maintained schema.

Resolve the definition when needed. Reuse the validator for the documents.

The fast validators make this approach practical. Their role is to keep structural checks affordable in the normal data path, rather than reserve validation for a build pipeline or an occasional inspection. That does not mean validation has no cost; it means the implementation avoids repeatedly doing work that belongs to the schema rather than to each order. The preparation model and performance work are covered in From Definition to Execution: Fast JSON Schema Validation.

Control how constraints adopt new versions

Now suppose someone proposes Order 2.0.0, raising the minimum quantity from one to two.

The repository asks the validation engine whether the change satisfies the configured compatibility policy. Under a policy requiring continued acceptance of previously valid orders, the change fails: an order with quantity one was valid before and would now be rejected.

The candidate can remain a draft while the author revises it or follows an explicitly authorized breaking-change process. Giving it a new version number does not bypass the policy. If the analysis cannot determine compatibility, that uncertainty is not treated as a pass.

The database integration supports two binding choices. A constraint pinned to an exact version stays on that version. Publishing Order 2.0.0 does not change a constraint pinned to Order 1.0.0; adopting the new version requires an explicit migration of the data.

A constraint can also be configured to follow latest. In that mode, it adopts eligible published versions under the configured compatibility policy. It does not follow every edit or newly registered draft: publication rules determine which version becomes the new target.

When that selection changes, the database invalidates the affected cursors and cached validation state, then prepares validation against the selected definition. The repository remains outside the per-document validation path. Incoming orders use the prepared validator rather than resolving latest for every write.

Changing a constraint’s selected version must also account for existing data, whether the change is explicit or follows latest. If a replacement schema raises the minimum quantity from one to two, stored orders with quantity one need attention. Publishing the schema—or rebuilding a cached validator—does not establish that those records satisfy the new requirements.

Following latest allows the production definition to advance beyond the version used in the original build. Compatibility checks control which changes are permitted, but they do not prove that an application implements every new behavioral obligation. Both modes use an authoritative contract: pinning preserves a fixed version, while latest permits the controlled movement under an explicit policy.

Three decisions therefore remain distinct:

DecisionWhat must be established
Approve a new schema versionThe definition meets the applicable publication and compatibility requirements.
Adopt a version in an applicationThe application is ready to use that version, including its behavioral requirements.
Advance a database constraint bindingThe database boundary—and the treatment of existing data—is ready for the change.

The repository connects these decisions through version identity. A binding configured to follow latest permits automated movement to an eligible published version; a pinned binding requires an explicit change.

The compatibility policy determines which changes are allowed. The binding determines whether they are adopted automatically or explicitly.

Make schema dependencies visible to the database

Once constraints refer to registered schema versions, the database can track those relationships.

That gives developers and administrators concrete questions to ask: Which columns depend on Order 1.0.0? Which referenced definitions does it use? What needs review before a version can be retired?

The planned native repository will use those dependencies to protect definitions that are still referenced. A schema version should not disappear while an active constraint depends on it. Likewise, moving a table between environments needs to account for the exact definitions required by its constraints—not just the table’s data.

Database-native management also provides a place to apply access controls and audit changes. Publishing a schema version is different from writing an order document; the permissions and recorded actions should reflect that distinction.

These capabilities are not a replacement for the application’s source repository or delivery workflow. Git still holds source, tests, adapters, and contract bindings. The database manages the registered definitions and the database objects that depend on them.

The benefit is a traceable relationship between the definition, the constraint, and the stored data.

Add DSV alongside the structural definition

The next step builds on that foundation.

The proposed Data Semantic Vocabulary (DSV) adds meaning and usage rules to JSON Schema. Registering those declarations alongside the structural schema gives tools one versioned contract to retrieve, rather than requiring them to reconcile a database schema with separate policy documents.

For our order application, the phone-number definition could include the following:

JSON

{
  "type": "object",
  "properties": {
    "phoneNumber": {
      "type": "string",
      "minLength": 1,
      "description": "Customer contact number for delivery updates",
      "classifications": ["personal-data"],
      "policies": ["phone-no-log", "phone-no-response"]
    }
  },
  "dsv": {
    "classifications": {
      "personal-data": {
        "description": "Personally identifying or contact information"
      }
    },
    "policies": {
      "phone-no-log": {
        "rules": [
          {
            "operation": "log",
            "constraint": "deny",
            "enforcement": "block"
          }
        ]
      },
      "phone-no-response": {
        "rules": [
          {
            "operation": "respond",
            "constraint": "deny",
            "enforcement": "block"
          }
        ]
      }
    }
  }
}

The database constraint checks the structural requirements: the phone number must be present and must be a nonempty string. DSV-aware tools can also retrieve its meaning and the restrictions on logging and confirmation output.

Storing those restrictions in the database does not automatically enforce them everywhere.

The database cannot determine, from the stored order alone, whether an external application later writes the phone number to a log or includes it in a PDF. Nomos checks and the appropriate application controls still need to cover those operations.

In a GitHub Actions workflow, for example, Nomos can evaluate the application change against the same contract version used by the database constraint. If a new logging statement exposes the phone number, the document validator can pass while the Nomos check fails.

That is not an inconsistency. The tools are checking different requirements from the same definition.

Database integration brings the contract closer to the data. It does not turn every behavioral rule into a database constraint. The review, testing, and enforcement boundaries are explained in Valid Data Can Still Be Used Wrong: Introducing Nomos.

Give AI builders a definition before they write the code

The database integration also changes where the database participates in development.

An AI builder can ask for the approved Order contract before generating the application. It can retrieve the structure, meaning, and rules; pin the selected version; and generate code and tests against it.

The build pipeline then checks that implementation. At deployment, the selected contract version is matched to the database constraint. Production writes are validated against the same structural definition.

The database is no longer involved only after the application needs somewhere to store its output. It supplies an authoritative input before the code is written.

Existing database structures can help create that input. Oracle AI Database already provides facilities for deriving JSON Schemas from database objects, including tables, views, and JSON-relational duality views. Those facilities offer a starting point for drafting structural definitions. They do not, by themselves, establish the business meaning or permitted use of a field. [1]

That meaning still needs to come from the people responsible for the data. AI can help draft it, but a generated description does not become authoritative simply because the database can produce a schema.

The intended workflow therefore connects existing structure to reviewed requirements, then makes the resulting contract reusable by development tools.

For Autonomous AI Database, that creates a stronger development proposition: not just a place an AI-generated application can connect to, but a platform that helps the builder determine what it should build against.

Build it into Oracle—and make room for other databases

The Project Delphi reference implementation begins with a contract repository deployed outside Oracle AI Database. The planned database integration brings repository management, version binding, and constraint execution into the database itself.

That is our implementation direction, not a requirement that every Project Delphi user choose Oracle.

The same idea can strengthen other databases: manage versioned definitions, bind data boundaries to exact versions, and execute validation without resolving the repository for every document.

Different databases may use different storage layouts and extension mechanisms. Those implementation details do not need to be identical. What should remain consistent is the meaning of the contract, the identity of the selected version and its dependencies, and the behavior of supported validation rules.

We also plan to work with the SQL standards community to propose a common SQL DDL syntax for defining and managing contracts. The aim is to make these operations consistent across databases while leaving each database free to choose its implementation.

An implementation also needs to be clear about what it supports. Recognizing a DSV declaration is not the same as enforcing it, and matching JSON Schema syntax is not enough if two engines interpret the relevant rules differently.

This is why the open vocabulary, reference code, examples, and conformance work matter. They provide a shared basis for implementations rather than requiring one database to become a remote service for all the others.

The contract should be portable. Each database should be able to make it useful within its own execution model.

Why this matters beyond validation

The immediate gain is straightforward: a database-managed JSON Schema repository, controlled versions, and fast validation in constraints.

The broader opportunity follows from that connection.

A database that makes authoritative definitions available to AI builders becomes involved earlier in application development. A database that applies those definitions to live data becomes more than a passive destination for generated documents. It connects development intent to execution at the data boundary.

For Autonomous AI Database, this creates a path to attracting more application development and runtime workload. The value is not primarily the space occupied by schema documents. It is the SQL, JSON processing, data access, and validation performed by applications built around those definitions.

That is a strategic opportunity, not an automatic revenue outcome. It depends on making the integration useful, accessible, and practical enough for developers and AI tools to adopt.

As AI increases the number and velocity of enterprise applications, Project Delphi gives databases a way to participate in more of that development and runtime activity—not just store the resulting data.

Explore the project here.

Related reading: Overview – link | Vocabulary and repository – link | Nomos – link | Fast validators – link.

Bring the definition into the engine

Our order application began with a shared contract used by its builder and tests. Database integration gives that contract another direct role: governing the structural checks applied when the data is written.

The repository manages the exact definition and how it evolves. The constraint binds to a selected version. The prepared validator checks incoming documents without a repository call for every order. DSV keeps the additional meaning and behavioral requirements alongside the structure, where AI builders and Nomos can use them.

Each component retains a clear responsibility. Together, they connect the software build to the data engine without requiring each application to invent its own interpretation.

The database becomes a platform AI builds from—and an engine that checks the data against the same versioned definition.

Public references

[1] Oracle AI Database JSON Developer’s Guide: JSON Schema. https://docs.oracle.com/en/database/oracle/oracle-database/26/adjsn/json-schema.html