Docs menu

Formatting Engine

Scan, diff, apply, and enforce formatting contracts with format_* tools.

What you will learn

  • format_scan
  • format_apply
  • format_enforce

Prerequisites

Surface

Imports@tmrxjd/agent-governance-system/formatting
MCPformat_scan · format_get · format_validate · format_diff · format_apply · format_enforce

What this feature does

Formatting Engine keeps generated and hand-edited governance artifacts in canonical format. Prefer format_apply then format_enforce before docs/chore commits.

How to call it

Call these MCP tools through your AGS / tower-gov host — format_scan, format_get, format_validate, format_diff, format_apply, format_enforce.. Prefer scan/get before validate/diff, and enforce only when the change set is ready.

  1. format_scan
  2. format_diff
  3. format_apply
  4. format_enforce
MCP: format_apply json
{ "paths": [".ags/versioning.yml"] }

What success looks like

format_diff clean

format_enforce ok

Common failure modes

Enforce without apply

Mixed indentation in YAML policies

Formatting unrelated files into wrong Commit-Scope

Related reference

AGS documentation