Skip to content

Sensorium Interface Frame v1

Source schema: doc/schemas/sensorium-interface-frame.v1.schema.json

One bounded classified value or lifecycle marker inside a Sensorium Interface result batch.

Fields

Field Required Shape Description
schema yes const: sensorium-interface-frame.v1 Contract discriminator.
schema/v yes const: 1 Contract version.
frame/kind yes enum: snapshot, event, gap, end Data or lifecycle shape of this frame.
observed/at yes string Time represented by the source value or marker.
emitted/at yes string Time the interface adapter emitted this frame.
payload/schema-ref no string Schema of an inline or artifact-backed data payload; must equal the descriptor output schema.
payload no unspecified Inline data value for a snapshot or event.
artifact/ref no string Reference to an independently admitted Artifact Delivery value when data is not inline.
gap/from-cursor no string First cursor position in a lost or unavailable ordered-event interval.
gap/to-cursor no string Resume boundary after a lost or unavailable ordered-event interval.
terminal/reason no string Typed reason carried only by the final end frame.
classification yes ref: classification.v1.schema.json Effective classification enforced for this emitted frame, including gap and terminal metadata.

Conditional Rules

Rule 1

When:

{
  "properties": {
    "frame/kind": {
      "enum": [
        "snapshot",
        "event"
      ]
    }
  },
  "required": [
    "frame/kind"
  ]
}

Then:

{
  "required": [
    "payload/schema-ref"
  ],
  "oneOf": [
    {
      "required": [
        "payload"
      ],
      "not": {
        "required": [
          "artifact/ref"
        ]
      }
    },
    {
      "required": [
        "artifact/ref"
      ],
      "not": {
        "required": [
          "payload"
        ]
      }
    }
  ],
  "not": {
    "anyOf": [
      {
        "required": [
          "gap/from-cursor"
        ]
      },
      {
        "required": [
          "gap/to-cursor"
        ]
      },
      {
        "required": [
          "terminal/reason"
        ]
      }
    ]
  }
}

Rule 2

When:

{
  "properties": {
    "frame/kind": {
      "const": "gap"
    }
  },
  "required": [
    "frame/kind"
  ]
}

Then:

{
  "required": [
    "gap/from-cursor",
    "gap/to-cursor"
  ],
  "not": {
    "anyOf": [
      {
        "required": [
          "payload/schema-ref"
        ]
      },
      {
        "required": [
          "payload"
        ]
      },
      {
        "required": [
          "artifact/ref"
        ]
      },
      {
        "required": [
          "terminal/reason"
        ]
      }
    ]
  }
}

Rule 3

When:

{
  "properties": {
    "frame/kind": {
      "const": "end"
    }
  },
  "required": [
    "frame/kind"
  ]
}

Then:

{
  "required": [
    "terminal/reason"
  ],
  "not": {
    "anyOf": [
      {
        "required": [
          "payload/schema-ref"
        ]
      },
      {
        "required": [
          "payload"
        ]
      },
      {
        "required": [
          "artifact/ref"
        ]
      },
      {
        "required": [
          "gap/from-cursor"
        ]
      },
      {
        "required": [
          "gap/to-cursor"
        ]
      }
    ]
  }
}

Field Semantics

schema

  • Required: yes
  • Shape: const: sensorium-interface-frame.v1

Contract discriminator.

schema/v

  • Required: yes
  • Shape: const: 1

Contract version.

frame/kind

  • Required: yes
  • Shape: enum: snapshot, event, gap, end

Data or lifecycle shape of this frame.

observed/at

  • Required: yes
  • Shape: string

Time represented by the source value or marker.

emitted/at

  • Required: yes
  • Shape: string

Time the interface adapter emitted this frame.

payload/schema-ref

  • Required: no
  • Shape: string

Schema of an inline or artifact-backed data payload; must equal the descriptor output schema.

payload

  • Required: no
  • Shape: unspecified

Inline data value for a snapshot or event.

artifact/ref

  • Required: no
  • Shape: string

Reference to an independently admitted Artifact Delivery value when data is not inline.

gap/from-cursor

  • Required: no
  • Shape: string

First cursor position in a lost or unavailable ordered-event interval.

gap/to-cursor

  • Required: no
  • Shape: string

Resume boundary after a lost or unavailable ordered-event interval.

terminal/reason

  • Required: no
  • Shape: string

Typed reason carried only by the final end frame.

classification

  • Required: yes
  • Shape: ref: classification.v1.schema.json

Effective classification enforced for this emitted frame, including gap and terminal metadata.