Configuration
Stand up AGS in a repo: registry auth, license key, policy YAML under .ags/, a commit-msg
hook, and an MCP host so agents can call the governance tools.
Install the package
@tmrxjd:registry=https://npm.pkg.github.com
//npm.pkg.github.com/:_authToken=${AGS_NPM_TOKEN}pnpm add @tmrxjd/agent-governance-systemFull install steps: Install.
License key
Set AGS_LICENSE_KEY (or your host’s mapped env) so product-licensing can unlock the
tier you purchased. Free / Personal / Enterprise capabilities are described under Licensing.
# shell / CI
export AGS_LICENSE_KEY=ags_live_… Policy files under .ags/
Engines read YAML from the repo root. Create the files you need; missing optional engines simply stay inactive until configured.
.ags/versioning.yml— semver packages + bump rules.ags/deployment.yml— environments + promotion gates.ags/data-arrays.yml— ordered / unique lists.ags/canonical.yml— singular SoT registry
schemaVersion: 1
scheme: semver
packages:
- name: "@acme/app"
path: packages/app/package.json
previousVersion: "1.0.0"
bumpRules:
file-create: minor
module-wire: minor
single-change: patch
single-fix: patch
breaking-change: major
milestone-close: none
changelog:
path: CHANGELOG.mdMore complete samples: Examples.
Commit-msg hook
Point core.hooksPath at a hooks directory and validate with the package export:
# .githooks/commit-msg (sketch)
#!/usr/bin/env node
import { validateAgentCommitMessage } from '@tmrxjd/agent-governance-system/commit-msg';
import { readFileSync } from 'node:fs';
const msg = readFileSync(process.argv[2], 'utf8');
const result = validateAgentCommitMessage(msg);
if (!result.ok) {
console.error(result.errors.join('\n'));
process.exit(1);
}git config core.hooksPath .githooks MCP host
Mount the AGS governance MCP server in your IDE so agents can call enforcement_begin, staging_enforce, commit_checkpoint, and the
rest of the catalog:
{
"mcpServers": {
"ags-gov": {
"command": "node",
"args": ["./node_modules/@tmrxjd/agent-governance-system/…/mcp-host.mjs"],
"env": {
"AGS_LICENSE_KEY": "${AGS_LICENSE_KEY}"
}
}
}
}Exact host entrypoint path ships with the package version you install — check the package README after install. Tool catalog and TypeScript imports: API surface.