RFC-021: AIGP-SGL — Symbolic Governance Language for Agentic and Autonomous AI — 12. Canonical AST
AIGP Specification › RFC-021: AIGP-SGL — Symbolic Governance Language for Agentic and Autonomous AI › 12. Canonical AST
← 11. Default Evaluation Rules · Section index · 13. YAML Serialization →
12. Canonical AST
Every AIGP-SGL statement MUST compile into a canonical abstract syntax tree.
The AST is the source of enforcement, not the glyph rendering.
Example SGL:
◎drone.042 → search ◇zone.A @mission.SAR17✓ if ⌘operator.present ∧ ⛶inside:zone.A ∧ sensor.health == healthy↩ if comms.loss > 10s#D-DNA{event:action.permitted, hash:sha256:8f3a...}Canonical AST:
{ "sgl_version": "0.1", "statement_id": "sgl_stmt_01J", "subject": { "id": "drone.042", "type": "autonomous_drone" }, "action": { "name": "search" }, "object": { "id": "zone.A", "type": "mission_zone" }, "context": { "mission_id": "mission.SAR17" }, "decision": { "type": "permit", "conditions": { "all": [ { "authority": "operator.present", "equals": true }, { "boundary": "inside", "target": "zone.A" }, { "field": "sensor.health", "equals": "healthy" } ] } }, "fallbacks": [ { "type": "return", "condition": { "field": "comms.loss", "operator": ">", "value": 10, "unit": "seconds" } } ], "evidence": { "type": "D-DNA", "event": "action.permitted", "hash": "sha256:8f3a..." }}← 11. Default Evaluation Rules · Section index · 13. YAML Serialization →