-
-
Notifications
You must be signed in to change notification settings - Fork 1
Implement pure-function GovernanceEngine for state transition evaluation #42
Copy link
Copy link
Open
Labels
P2-highHigh priority - important for milestone completionHigh priority - important for milestone completionphase-2-governancePhase 2 - Enhanced governance & process integration (current)Phase 2 - Enhanced governance & process integration (current)valueflowsValueFlows ontology compliance and integrationValueFlows ontology compliance and integrationzome-governanceGovernance zome - validation, economic events, commitmentsGovernance zome - validation, economic events, commitments
Milestone
Metadata
Metadata
Assignees
Labels
P2-highHigh priority - important for milestone completionHigh priority - important for milestone completionphase-2-governancePhase 2 - Enhanced governance & process integration (current)Phase 2 - Enhanced governance & process integration (current)valueflowsValueFlows ontology compliance and integrationValueFlows ontology compliance and integrationzome-governanceGovernance zome - validation, economic events, commitmentsGovernance zome - validation, economic events, commitments
Type
Projects
Status
Backlog
Summary
Implement a
GovernanceEnginewith pure-function evaluation logic that determines whether a requested state transition should be approved or rejected. This is the core decision-making component of the governance-as-operator pattern.Context
Currently, governance operations (economic events, commitments, validation receipts) are independent CRUD functions. The governance-as-operator architecture requires a centralized evaluation engine that:
The engine must be a pure function (no side effects) so it can be unit tested independently.
Technical Implementation
1. GovernanceEngine Core
2. Permission Evaluation
VfActionvariants to required roles (already partially defined inget_required_roles_for_action)3. Rule Evaluation
access_requirement,usage_limit,transfer_conditions,custody_requirement,location_restriction4. State Transition Validation
5. Exported Zome Function
Acceptance Criteria
GovernanceEngine::evaluate_transition()implemented as a pure functionevaluate_state_transitionhdk_extern function exposed for cross-zome callsrejection_reasonsandnext_stepsDependencies
Definition of Done