Skip to main content
Batoi AIF Docs

Prompt Governance

Manage prompts as versioned, reviewable execution assets.

Version Foundation release Early foundation work Reviewed Jul 21, 2026 Next review Sep 21, 2026

Owner: Batoi Engineering Reviewed by: Batoi AIF Maintainers Source revision: cd680e8

AIF is the public engineering framework. For the managed intelligence capability used across supported Platform and Flex workflows, see Batoi Intelligence.
Browse Batoi AIF Documentation Prompt Governance

Prompt Governance

Prompt governance prevents production AI behavior from being hidden in page handlers or ad hoc strings.

Each governed prompt should have:

  • stable prompt code
  • purpose
  • immutable semantic version
  • template
  • input schema
  • approval status
  • change notes

Rendering Pattern

$response = $gateway->infer(new InferenceRequest(
    input: '',
    promptCode: 'control-summary',
    variables: [
        'control_name' => 'Access Governance',
        'evidence_notes' => $notes,
    ],
));

The gateway resolves the requested version, or the latest approved semantic version when no version is supplied, then validates variables and renders the template inside the audited boundary.

Operational Guidance

  • Treat prompts as controlled application assets.
  • Version prompts when behavior changes.
  • Do not mutate approved prompt versions.
  • Require approved state in governed mode.
  • Validate required variables before provider execution.
  • Keep human-readable purpose and review notes.
  • Do not mix secrets into prompt templates.
  • Capture prompt code and version in audit evidence.

The in-memory registry supports development and tests. The RAD PDO registry provides workspace-specific persistence.