SEMANTIC LAYER

A semantic layer, emitted with your data.

Every Mock Machines scenario can export a single DuckDB database with an OSI-compatible semantic model generated on top — datasets, dimensions, measures and relationships, defined the moment the data exists.

WHAT IS OSI

The Open Semantic Interchange (OSI) is an open standard for the semantic layer — the place where metrics, dimensions and entity relationships are defined once, in a portable format, instead of being re-implemented in every BI tool, notebook and agent that touches the data.

Mock Machines speaks it natively. Because a scenario already declares its entities, fields and references, the semantic model isn't something you hand-author after the fact — it's derived directly from the world you ran and travels with the data, so metrics and joins mean the same thing everywhere the database goes.

HOW IT WORKS

From scenario to semantic model.

S-01

Run a scenario

Seed a world and advance it. Each entity is a finite-state machine, and every field, reference and state transition is recorded as it runs.

S-02

Export to DuckDB

Roll the run up into a single DuckDB database — one table per machine, foreign keys intact, the whole world queryable in one file.

S-03

Emit the OSI model

Alongside the database, Mock Machines writes a <scenario>.osi.yaml that describes it — the semantic layer, generated automatically, with no hand-mapping.

THE MODEL

Derived from the scenario schema and the exported DuckDB database — no hand-mapping.

# claims_fnol.osi.yaml — generated automatically with the dataset
semantic_model:
  name: "claims_fnol"
  source: "duckdb://claims_fnol.duckdb"
  entities:
    - name: claim
      primary_key: id
    - name: adjuster
      primary_key: id
  dimensions:
    - name: region
      type: categorical
    - name: peril
      type: categorical
    - name: current_state
      type: categorical
  measures:
    - name: claims
      agg: count
    - name: total_reserve
      agg: sum
      column: reserve_estimate
  relationships:
    - from: claim.adjuster_id
      to: adjuster.id
AUTOMATICALLY DERIVED

Everything maps from the model.

D-01

Datasets from machines

Every state machine becomes a dataset — one row per entity, with its fields and end-of-run state as columns, keyed by a stable id.

D-02

Dimensions & measures

Taxonomies and states surface as categorical dimensions; counters and numeric measures become aggregatable metrics — typed and ready to group by.

D-03

Relationships from references

Each reference between entities becomes a foreign-key relationship, so joins are declared in the model rather than guessed at query time.

D-04

AI context for agents

The model carries plain-language descriptions and example values, so an agent querying over MCP or REST knows what every table and column means.

GET ACCESS

Pick a world. Or build your own.

OPTION A · OPEN NOW Try it live

Explore a pre-built scenario over REST & MCP — no signup.

OPTION B · WAITLIST Request editing access

Author and edit your own scenarios. Rolling out in batches.