freshcrate
Skin:/
Home > MCP Servers > governance-sdk

governance-sdk

AI Agent Governance for TypeScript — policy enforcement, scoring, compliance, and audit for AI agents

Why this rank:Recent releaseStrong adoptionHealthy release cadence

Description

AI Agent Governance for TypeScript — policy enforcement, scoring, compliance, and audit for AI agents

Release History

VersionChangesUrgencyDate
v0.19.0 Completes the multi-process hardening from 0.18.2. That release made the audit integrity chain's *writes* atomic against the durable per-org head and made `export()` / `verifyAuditIntegrity()` read durable state. `integrityChain.stats()` was the one reader left on process-local state — it returned this process's last-written `sequence` / `lastHash` from an in-closure cache, so under a multi-process deployment (replicas, `pm2` cluster, serverless) it lagged writes made by other processes sharingHigh7/20/2026
v0.18.1 Hardens `detectInjection()` against obfuscated prompt-injection attacks that slipped past keyword patterns, and adds two agent-specific attack patterns. The detector now folds three more evasion classes back to their plain form before matching, so an attacker can no longer dodge a rule by spacing out letters, breaking a word with markdown, or swapping in lookalike characters. Purely additive — no API changes, no config changes. Existing thresholds and custom patterns behave exactly as before; Medium6/26/2026
v0.18.0 The tamper-evident audit chain is now scoped **per organization**. Before this release a single `createGovernance({ integrityAudit })` instance kept one global hash chain, so every org's events were interleaved into the same chain and sequence space — you couldn't hand one tenant a clean, contiguous, independently-verifiable export, and one tenant's volume affected another's chain. Now each `organizationId` gets its own head, its own 1..N sequence, and its own write lock; events with no org shaHigh6/26/2026
v0.17.0 The condition registry (`registerCondition` / `unregisterCondition` / `getRegisteredCondition` / `getRegisteredConditions` / `clearConditionRegistry`) and `PolicyEngineConfig.conditions` were already on `PolicyEngine` since 0.15, but `GovernanceInstance` (the thing `createGovernance()` returns) didn't expose them — `instance.policies` is a `ReadonlyPolicyEngine` view that intentionally hides mutators. So callers who followed the documented `createGovernance()` flow had no path to register a cusHigh5/7/2026
v0.16.0 0.15 introduced `governance-sdk/scan/multi-modal` as a host-callable orchestrator with a global "scan everything you opt into" shape. That worked for the SDK plumbing but coupled rules that have nothing to do with each other (a token-budget rule has no business knowing about images). 0.16 moves modality config onto the **policy rule itself**. ### Added — `scanModalities` on `PolicyRule` ```ts const rule: PolicyRule = { id: "image-aware-injection-guard", name: "Block prompt injection in viHigh4/30/2026
v0.14.1`scope_boundary` and `network_allowlist` rules at stage `process` (the default for those conditions, where pre-execution blocking happens) silently never fired on tool calls in 0.14.0 — `evaluateToolCall` (the path behind `processOutputStep`) didn't populate `ctx.targetPath` / `ctx.targetUrl`, and those conditions read those fields exclusively. 0.14.0 wired the field-extraction registry into `wrapTool` (tool_result stage). 0.14.1 wires it into `evaluateToolCall` too — same registry, same generiHigh4/30/2026
0.13.1Imported from npm (0.13.1)Low4/21/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardHigh4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardHigh4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardMedium4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardMedium4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardMedium4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardMedium4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardMedium4/16/2026
v0.13.0## Conventions flip + deprecation notices Follow-up to 0.12. Two small, deliberate changes that the 0.12 roadmap promised — committed now so users have runtime notice before 1.0. ### OTel \`conventions\` default flips from \`\"both\"\` to \`\"gen_ai\"\` \`createOtelHooks()\` now defaults to emitting only the GenAI semantic conventions. Governance spans correlate out of the box with Anthropic, OpenAI, and Vercel-AI SDK spans in Honeycomb / Datadog / New Relic. **Migration.** If your dashboardMedium4/16/2026
v0.12.0## Trust hardening Closes the three most load-bearing honesty gaps surfaced by the post-0.11 audit. Theme: the things the SDK already claims must actually hold up under restart, real observability, and real naming. ### Durable integrity audit chain Before 0.12, `integrityAudit: { signingKey }` held chain state (latest hash, sequence, per-event integrity) in a `createGovernance()` closure. Process restart reset the chain to genesis and every Postgres event lost its integrity metadata because tHigh4/16/2026
v0.11.2Adds infrastructure to keep `packages/governance/README.md` (the file npm publishes) in sync with the repo-root README — so the v0.11.1 fix can never silently regress. ## What's new - **`scripts/sync-readme.mjs`** — generates the package README from the root, normalizing repo-relative links (`./packages/...`, `./LICENSE`, `./CONTRIBUTING.md`, etc.) to absolute GitHub URLs so they resolve correctly on npmjs.com. Idempotent. - **`prepublishOnly` hook** runs sync-readme before tsc, guaranteeing eHigh4/16/2026
v0.10.0Tightens the SDK to the surface we can defend, and is honest about everything it doesn't do. No new features. **1,348 tests** pass with **0 failures**. ## Removed (BREAKING) - **`governance-sdk/federation`** — was advisory-only posture exchange with no distributed protocol or signature enforcement. (Note: as of 0.11 this is also not shipped in Lua Governance Cloud.) - **`governance-sdk/sandbox`** — was a `node:vm` wrapper. `node:vm` is not a security boundary (per Node docs; see CVE-2023-32002High4/15/2026
v0.11.1The `packages/governance/README.md` (the file npm publishes) had drifted ~3 release cycles behind the repo-root README. This patch syncs the two so npm users see the same content GitHub viewers see — including the "What this is NOT" scope disclosures, the 0.11 module removals, and the behavioral-scorer demotion. Relative links normalized to absolute GitHub URLs so they resolve correctly when read on npmjs.com. **No code changes. SDK behavior identical to 0.11.0.** If you're already on 0.11.0,High4/15/2026
v0.11.0Follow-up to the v0.10 cleanup. After a feature-by-feature audit against actual `governance-cloud` consumers and major competitors (Microsoft `agent-governance-toolkit`, NeMo Guardrails, Phoenix, Langfuse, Braintrust), this release removes 5 modules with no consumers and clarifies framing around 4 more that were oversold as built-in observability/eval infrastructure. **1,328 tests** pass with **0 failures**. **0 runtime dependencies** (unchanged). ## Removed (BREAKING) - **`governance-sdk/evaHigh4/15/2026
v0.9.0## Highlights **Full pre/post/streaming coverage across all 10 featured framework adapters.** Every featured adapter now supports input pre-scan, output post-scan, streaming post-scan (buffered / sliding / per-chunk), and tool-call enforcement. ## What's new ### Featured adapters — full lifecycle - **Vercel AI SDK** — `createGovernanceMiddleware` now returns `transformParams` (pre), `wrapGenerate` (post), `wrapStream` (streaming post). Config accepts `streamMode`, `streamLookbackChunks`, `strHigh4/14/2026

Dependencies & License Audit

Loading dependencies...

Similar Packages

@piiiico/agent-auditSecurity scanner for AI agent tooling — MCP servers, tool definitions, and agentic pipelinesv0.3.9
opena2aOpen-source security tools for AI agents. Find vulnerabilities, fix root causes, prove compliance.credential-patterns-v0.1.3
letagentsLet Agents Chat — MCP server for AI agent communicationmain@2026-07-25
mofloMoFlo — AI agent orchestration for Claude Code. Forked from ruflo/claude-flow with patches applied to source, plus feature-level orchestration.main@2026-07-24
controlkeelControl plane for governed AI coding: validate agent changes, enforce policy, track findings, and ship with proof.v0.3.77

More in MCP Servers

supersetCode Editor for the AI Agents Era - Run an army of Claude Code, Codex, etc. on your machine
kreuzbergA polyglot document intelligence framework with a Rust core. Extract text, metadata, images, and structured information from PDFs, Office documents, images, and 91+ formats. Available for Rust, Python
ai-engineering-from-scratchLearn it. Build it. Ship it for others.
CodeGraphContextAn MCP server plus a CLI tool that indexes local code into a graph database to provide context to AI assistants.