Skip to content

RFC-032: Post-Hoc Evaluation Loop — 11. Schema

AIGP SpecificationRFC-032: Post-Hoc Evaluation Loop › 11. Schema

← 10. API Extension · Section index · 12. Burden of the Inquiry →

11. Schema

11.1 Anticipation Schema (JSON Schema Draft-07)

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "AIGP Anticipation Declaration",
"description": "Pre-execution declaration of measurable expectations for governed AI execution. Sealed once execution begins. Forms the authoritative standard against which post-hoc verification compares outcomes.",
"type": "object",
"required": ["anticipation_id", "agent_id", "app_id", "scope_envelope_id", "session_id", "timestamp", "expectations", "grading_policy"],
"additionalProperties": false,
"properties": {
"anticipation_id": {
"type": "string",
"description": "Unique identifier for this anticipation declaration."
},
"agent_id": {
"type": "string",
"description": "Agent that will perform the anticipated execution."
},
"app_id": {
"type": "string",
"description": "Application that owns the execution."
},
"plan_id": {
"type": "string",
"description": "Optional plan identifier if execution follows an approved plan."
},
"scope_envelope_id": {
"type": "string",
"description": "Active scope envelope at time of anticipation."
},
"session_id": {
"type": "string",
"description": "Session within which execution will occur."
},
"timestamp": {
"type": "string",
"format": "date-time",
"description": "ISO 8601 UTC when anticipation was declared."
},
"expectations": {
"type": "object",
"required": ["outcome_criteria"],
"properties": {
"outcome_criteria": {
"type": "array",
"minItems": 1,
"items": { "$ref": "#/definitions/criterion" },
"description": "What the final state SHOULD be after execution."
},
"trajectory_criteria": {
"type": "array",
"items": { "$ref": "#/definitions/criterion" },
"description": "How the agent SHOULD get there (process quality expectations)."
},
"anti_criteria": {
"type": "array",
"items": { "$ref": "#/definitions/criterion" },
"description": "What MUST NOT happen during execution (hard violations)."
}
}
},
"grading_policy": {
"type": "object",
"required": ["grader_type", "passing_threshold", "weighted_scoring", "fail_on_any_anti_criteria"],
"properties": {
"grader_type": {
"type": "string",
"enum": ["CODE", "MODEL", "HUMAN", "COMPOSITE"],
"description": "Primary grading mechanism."
},
"passing_threshold": {
"type": "number",
"minimum": 0.0,
"maximum": 1.0,
"description": "Minimum weighted score for MATCH or PARTIAL_MATCH verdict."
},
"weighted_scoring": {
"type": "boolean",
"description": "Whether criterion weights factor into overall score."
},
"fail_on_any_anti_criteria": {
"type": "boolean",
"description": "Whether any anti-criterion failure produces automatic VIOLATION verdict."
}
}
},
"d_dna_signature": {
"type": "string",
"description": "Cryptographic signature for immutability and tamper evidence."
}
},
"definitions": {
"criterion": {
"type": "object",
"required": ["criterion_id", "description", "measurement", "assertion", "weight"],
"properties": {
"criterion_id": {
"type": "string",
"description": "Unique identifier within this anticipation."
},
"description": {
"type": "string",
"description": "Human-readable statement of the expectation."
},
"measurement": {
"type": "string",
"enum": ["DETERMINISTIC", "HEURISTIC", "HUMAN"],
"description": "How this criterion will be evaluated."
},
"assertion": {
"type": "string",
"description": "Machine-evaluable expression or grading prompt."
},
"weight": {
"type": "number",
"minimum": 0.0,
"maximum": 1.0,
"description": "Relative importance for weighted scoring."
}
}
}
}
}


← 10. API Extension · Section index · 12. Burden of the Inquiry →