All contracts

Workspace Intelligence / JSON Schema

Workspai Workspace Intelligence Evaluation

A live or finalized, provenance-aware measurement of model usage, agent activity, and verified task outcome.

Schema version
workspace-intelligence-evaluation.v1
Contract path
contracts/workspace-intelligence/workspace-intelligence-evaluation.v1.json
Publication
embedded-type, json-schema
Defined fields
49
Artifact bindings
2

Why this contract exists

Architecture role

Defines a versioned interoperability boundary used by Workspai and contract-aware consumers.

Consumption boundary

  • Workspai CLI
  • Workspace Intelligence consumers
  • IDEs and agents

Related commands

Commands are linked only when the runtime contract identifies a direct production relationship. Supporting contracts may be consumed without having a single producer command.

Produced artifacts

These durable files are emitted by registered commands and validated against this contract.

Artifact pathSchemaProducer
.workspai/reports/workspace-intelligence-evaluation-last-run.jsonworkspace-intelligence-evaluation.v1
workspai workspace eval report --json
.workspai/reports/workspace-intelligence-evaluation-live.jsonworkspace-intelligence-evaluation.v1
workspai workspace eval init
workspai workspace eval record --json

Field reference

Every declared schema property or published capability path is listed here. Required means the contract declares or publishes that field at the shown boundary.

Field pathTypeRequiredMeaningConstraints
completedAtstringNoDefines the completedat value at this contract boundary.format: date-time
configurationobjectYesDefines the configuration value at this contract boundary.additionalProperties: false
configuration.baselineRunIdstringNoDefines the baselinerunid value at this contract boundary.minLength: 1
configuration.modelstringNoDefines the model value at this contract boundary.minLength: 1
configuration.providerstringNoDefines the provider value at this contract boundary.minLength: 1
configuration.strategyenumYesDefines the strategy value at this contract boundary.enum: full-corpus, grep, vector, graph, workspace-intelligence, custom
configuration.taskIdstringYesDefines the taskid value at this contract boundary.minLength: 1
configuration.temperaturenumberNoDefines the temperature value at this contract boundary.
eventsarrayYesDefines the events value at this contract boundary.
methodologyobjectYesDefines the methodology value at this contract boundary.additionalProperties: false
methodology.claimBoundarystringYesDefines the claimboundary value at this contract boundary.minLength: 1
methodology.idstringYesDefines the id value at this contract boundary.const: "provider-usage-and-verified-outcome.v1"
runIdstringYesDefines the runid value at this contract boundary.minLength: 1
schemaVersionstringYesDefines the schemaversion value at this contract boundary.const: "workspace-intelligence-evaluation.v1"
sessionIdstringYesDefines the sessionid value at this contract boundary.minLength: 1
startedAtstringYesDefines the startedat value at this contract boundary.format: date-time
statusenumYesDefines the status value at this contract boundary.enum: live, completed, aborted
summaryobjectYesDefines the summary value at this contract boundary.additionalProperties: false
summary.costsarrayYesDefines the costs value at this contract boundary.
summary.costs[].amountnumberYesDefines the amount value at this contract boundary.minimum: 0
summary.costs[].currencystringYesDefines the currency value at this contract boundary.pattern: ^[A-Z]{3}$
summary.costs[].estimatednumberYesDefines the estimated value at this contract boundary.minimum: 0
summary.costs[].providerReportednumberYesDefines the providerreported value at this contract boundary.minimum: 0
summary.efficiencyobjectYesDefines the efficiency value at this contract boundary.additionalProperties: false
summary.efficiency.noProgressDecisionsintegerYesDefines the noprogressdecisions value at this contract boundary.minimum: 0
summary.efficiency.repeatedArtifactReadsintegerYesDefines the repeatedartifactreads value at this contract boundary.minimum: 0
summary.efficiency.tokensPerVerifiedOutcomenumber | nullYesDefines the tokensperverifiedoutcome value at this contract boundary.minimum: 0
summary.latencyMsnumberYesDefines the latencyms value at this contract boundary.minimum: 0
summary.modelCallsintegerYesDefines the modelcalls value at this contract boundary.minimum: 0
summary.outcomeobjectYesDefines the outcome value at this contract boundary.additionalProperties: false
summary.outcome.blockersResolvedintegerYesDefines the blockersresolved value at this contract boundary.minimum: 0
summary.outcome.statusenumYesDefines the status value at this contract boundary.enum: passed, failed, blocked, unknown
summary.outcome.verifiedbooleanYesDefines the verified value at this contract boundary.
summary.tokensobjectYesDefines the tokens value at this contract boundary.additionalProperties: false
summary.tokens.cachedInputintegerYesDefines the cachedinput value at this contract boundary.minimum: 0
summary.tokens.inputintegerYesDefines the input value at this contract boundary.minimum: 0
summary.tokens.observedTotalintegerYesDefines the observedtotal value at this contract boundary.minimum: 0
summary.tokens.outputintegerYesDefines the output value at this contract boundary.minimum: 0
summary.tokens.reasoningintegerYesDefines the reasoning value at this contract boundary.minimum: 0
summary.tokenSourcesobjectYesDefines the tokensources value at this contract boundary.additionalProperties: false
summary.tokenSources.estimatedintegerYesDefines the estimated value at this contract boundary.minimum: 0
summary.tokenSources.providerReportedintegerYesDefines the providerreported value at this contract boundary.minimum: 0
summary.tokenSources.tokenizerCountedintegerYesDefines the tokenizercounted value at this contract boundary.minimum: 0
summary.tokenSources.unavailableintegerYesDefines the unavailable value at this contract boundary.minimum: 0
summary.toolCallsintegerYesDefines the toolcalls value at this contract boundary.minimum: 0
updatedAtstringYesDefines the updatedat value at this contract boundary.format: date-time
workspaceobjectYesDefines the workspace value at this contract boundary.additionalProperties: false
workspace.namestringYesDefines the name value at this contract boundary.minLength: 1
workspace.pathstringYesDefines the path value at this contract boundary.minLength: 1

Canonical machine-readable definition

The raw synchronized contract remains authoritative. The educational sections above are projections of this definition.

Show raw JSON
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://getrapidkit.com/schemas/workspace-intelligence-evaluation.v1.json",
  "title": "Workspai Workspace Intelligence Evaluation",
  "description": "A live or finalized, provenance-aware measurement of model usage, agent activity, and verified task outcome.",
  "type": "object",
  "required": [
    "schemaVersion",
    "runId",
    "sessionId",
    "status",
    "startedAt",
    "updatedAt",
    "workspace",
    "configuration",
    "methodology",
    "events",
    "summary"
  ],
  "properties": {
    "schemaVersion": {
      "const": "workspace-intelligence-evaluation.v1"
    },
    "runId": {
      "type": "string",
      "minLength": 1
    },
    "sessionId": {
      "type": "string",
      "minLength": 1
    },
    "status": {
      "enum": [
        "live",
        "completed",
        "aborted"
      ]
    },
    "startedAt": {
      "type": "string",
      "format": "date-time"
    },
    "updatedAt": {
      "type": "string",
      "format": "date-time"
    },
    "completedAt": {
      "type": "string",
      "format": "date-time"
    },
    "workspace": {
      "type": "object",
      "required": [
        "name",
        "path"
      ],
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1
        },
        "path": {
          "type": "string",
          "minLength": 1
        }
      },
      "additionalProperties": false
    },
    "configuration": {
      "type": "object",
      "required": [
        "taskId",
        "strategy"
      ],
      "properties": {
        "taskId": {
          "type": "string",
          "minLength": 1
        },
        "strategy": {
          "enum": [
            "full-corpus",
            "grep",
            "vector",
            "graph",
            "workspace-intelligence",
            "custom"
          ]
        },
        "provider": {
          "type": "string",
          "minLength": 1
        },
        "model": {
          "type": "string",
          "minLength": 1
        },
        "temperature": {
          "type": "number"
        },
        "baselineRunId": {
          "type": "string",
          "minLength": 1
        }
      },
      "additionalProperties": false
    },
    "methodology": {
      "type": "object",
      "required": [
        "id",
        "claimBoundary"
      ],
      "properties": {
        "id": {
          "const": "provider-usage-and-verified-outcome.v1"
        },
        "claimBoundary": {
          "type": "string",
          "minLength": 1
        }
      },
      "additionalProperties": false
    },
    "events": {
      "type": "array",
      "items": {
        "$ref": "model-usage-event.v1.json"
      }
    },
    "summary": {
      "type": "object",
      "required": [
        "modelCalls",
        "toolCalls",
        "tokenSources",
        "tokens",
        "latencyMs",
        "costs",
        "outcome",
        "efficiency"
      ],
      "properties": {
        "modelCalls": {
          "type": "integer",
          "minimum": 0
        },
        "toolCalls": {
          "type": "integer",
          "minimum": 0
        },
        "tokenSources": {
          "type": "object",
          "required": [
            "providerReported",
            "tokenizerCounted",
            "estimated",
            "unavailable"
          ],
          "properties": {
            "providerReported": {
              "type": "integer",
              "minimum": 0
            },
            "tokenizerCounted": {
              "type": "integer",
              "minimum": 0
            },
            "estimated": {
              "type": "integer",
              "minimum": 0
            },
            "unavailable": {
              "type": "integer",
              "minimum": 0
            }
          },
          "additionalProperties": false
        },
        "tokens": {
          "type": "object",
          "required": [
            "input",
            "output",
            "cachedInput",
            "reasoning",
            "observedTotal"
          ],
          "properties": {
            "input": {
              "type": "integer",
              "minimum": 0
            },
            "output": {
              "type": "integer",
              "minimum": 0
            },
            "cachedInput": {
              "type": "integer",
              "minimum": 0
            },
            "reasoning": {
              "type": "integer",
              "minimum": 0
            },
            "observedTotal": {
              "type": "integer",
              "minimum": 0
            }
          },
          "additionalProperties": false
        },
        "latencyMs": {
          "type": "number",
          "minimum": 0
        },
        "costs": {
          "type": "array",
          "items": {
            "type": "object",
            "required": [
              "currency",
              "amount",
              "providerReported",
              "estimated"
            ],
            "properties": {
              "currency": {
                "type": "string",
                "pattern": "^[A-Z]{3}$"
              },
              "amount": {
                "type": "number",
                "minimum": 0
              },
              "providerReported": {
                "type": "number",
                "minimum": 0
              },
              "estimated": {
                "type": "number",
                "minimum": 0
              }
            },
            "additionalProperties": false
          }
        },
        "outcome": {
          "type": "object",
          "required": [
            "status",
            "verified",
            "blockersResolved"
          ],
          "properties": {
            "status": {
              "enum": [
                "passed",
                "failed",
                "blocked",
                "unknown"
              ]
            },
            "verified": {
              "type": "boolean"
            },
            "blockersResolved": {
              "type": "integer",
              "minimum": 0
            }
          },
          "additionalProperties": false
        },
        "efficiency": {
          "type": "object",
          "required": [
            "tokensPerVerifiedOutcome",
            "noProgressDecisions",
            "repeatedArtifactReads"
          ],
          "properties": {
            "tokensPerVerifiedOutcome": {
              "type": [
                "number",
                "null"
              ],
              "minimum": 0
            },
            "noProgressDecisions": {
              "type": "integer",
              "minimum": 0
            },
            "repeatedArtifactReads": {
              "type": "integer",
              "minimum": 0
            }
          },
          "additionalProperties": false
        }
      },
      "additionalProperties": false
    }
  },
  "additionalProperties": false
}