{
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "$id": "https://taxonmark.com/api/v1/types/prompt-policy-artefact",
    "title": "Prompt / Policy Artefact",
    "type": "object",
    "required": [
        "artefact_kind",
        "applies_to_dois",
        "artefact_hash",
        "effective_date"
    ],
    "properties": {
        "artefact_kind": {
            "title": "Artefact kind",
            "type": "string",
            "enum": [
                "system-prompt",
                "agent-policy",
                "guardrail-config",
                "content-policy",
                "tool-schema"
            ]
        },
        "applies_to_dois": {
            "title": "Applies to system / agent IDs",
            "type": "array",
            "items": {
                "type": "string"
            },
            "description": "Taxonmark IDs (for example TM.AI.2026.7KQ2X) or DOIs registered elsewhere"
        },
        "artefact_hash": {
            "title": "Artefact hash (SHA-256)",
            "type": "string",
            "pattern": "^(sha256:)?[A-Fa-f0-9]{64}$",
            "description": "SHA-256 hex (optionally prefixed sha256:)"
        },
        "escrow_agent": {
            "title": "Escrow agent",
            "type": "string",
            "maxLength": 1000
        },
        "effective_date": {
            "title": "Effective date",
            "type": "string",
            "format": "date"
        },
        "change_summary": {
            "title": "Change summary",
            "type": "string",
            "x-widget": "textarea",
            "maxLength": 20000
        }
    },
    "additionalProperties": true
}