feat(governance): agent governance protocol — gates, evidence, charter, SoD, JIT grants#1234
Open
ohdearquant wants to merge 1 commit into
Open
feat(governance): agent governance protocol — gates, evidence, charter, SoD, JIT grants#1234ohdearquant wants to merge 1 commit into
ohdearquant wants to merge 1 commit into
Conversation
…branch Introduces lionagi/governance/ — agent governance protocol with gates, evidence chains, charter DSL, separation of duties, JIT grants, break-glass, and tracing. Wires governance hooks into Branch.operate() and Session.flow() via 3-way merge against main (post-capability-bus changes). Key changes: - New lionagi/governance/ module: 18 files (gates, evidence, charter, compiler, dsl, context, certificate, tracing, breakglass, jit_grant, sod, targets, resolution, governed_tool, flow_integration, session_integration shim) - New lionagi/session/governed_flow.py: governed_flow() async function - Pile: append_only mode + PileAppendOnlyError (guards mutations on evidence piles) - Branch.operate(): ctx: OperationContext param + governance context wiring - Session.flow(): charter-aware OperationContext injection - 496 governance tests passing Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
lionagi/governance/module (17 files): authorization gates (ALLOW/DENY/ADVISORY), append-only hash-chained evidence log, charter YAML DSL + compiler, OperationContext propagation, TaskCertificate, OTel-compatible tracing, break-glass protocol, JIT grants, separation of duties enforcementlionagi/session/governed_flow.pyfor governance-wrappedSession.flow()pile.py(append_only),branch.py(evidence_chain, emit_evidence),session.py(charter-aware OperationContext)Extracted from #1186 (stripped ADR docs, 3-way merged files that diverged on main).
Test plan
uv run pytest tests/governance/— 496 tests pass🤖 Generated with Claude Code