The Neural Parliament is composed of independentDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/xcoder-es/governance-layer/llms.txt
Use this file to discover all available pages before exploring further.
ParliamentMember instances, each representing a distinct governance concern — reward, safety, integrity, curiosity, planning, social alignment, and memory. Every member scores incoming proposals with a value function V_i(s, a) in the range [-1, 1], proposes its own preferred actions, and may veto any proposal whose score falls below its personal threshold. The parliament reaches consensus by aggregating weighted scores across all members.
ParliamentMember (Abstract Base Class)
Defined in governance/committee/base.py. All concrete members extend this class and must implement evaluate_proposal and propose.
Constructor
A unique string identifier for this member (e.g.
"safety", "reward"). Used in proposals, scores, and veto records.The minimum acceptable score from
evaluate_proposal. If the returned score falls strictly below this value, the member blocks the proposal. A threshold of 0.0 means this member never vetoes based on score alone.The procedural voting weight
w_i. Higher-weight members have proportionally greater influence over the parliament’s weighted aggregation. For example, a member with weight=3.0 contributes three times as much as one with weight=1.0.The maximum number of proposals this member may submit per governance cycle
b_i. Once the budget is exhausted, the member cannot initiate further proposals until the cycle resets.Attributes
| Attribute | Type | Description |
|---|---|---|
member_id | str | The member’s unique identifier string |
veto_threshold | float | Score floor below which this member vetoes |
weight | float | Voting weight applied during aggregation |
budget | int | Max proposals allowed per cycle |
Abstract Methods
evaluate_proposal(state, proposal) -> float
[-1, 1], where -1 represents complete opposition, 0 is neutral, and 1 is full endorsement.
The current environment or agent state. Its exact schema is determined by the calling system and passed through unchanged.
The
Proposal object to evaluate. Concrete implementations typically inspect proposal.metadata for domain-specific signals (e.g. risk, novelty, expected_reward).A value in
[-1, 1]. Scores below the member’s veto_threshold trigger a veto on the evaluated proposal.propose(state) -> Proposal
Proposal from this member’s perspective. The returned proposal is submitted to the parliament for evaluation by all other members.
The current environment or agent state used to inform the proposal’s content and metadata.
A
Proposal instance with member_id, action, tag, timestamp, and metadata fields populated.Built-in Members
Seven concrete members are provided ingovernance/committee/members.py as reference implementations and practical defaults. Each evaluates a different key in proposal.metadata.
Quick Reference
| Class | member_id | veto_threshold | weight | budget | Metadata key evaluated |
|---|---|---|---|---|---|
ExampleRewardMember | reward | 0.0 | 1.0 | 3 | expected_reward |
ExampleSafetyMember | safety | 0.5 | 2.0 | 5 | 1.0 - risk |
ExampleCuriosityMember | curiosity | 0.2 | 0.8 | 4 | novelty |
ExamplePlanningMember | planning | 0.3 | 1.5 | 3 | long_term_value |
ExampleMemoryMember | memory | 0.1 | 0.7 | 2 | historical_consistency |
ExampleSocialMember | social | 0.4 | 1.2 | 3 | social_acceptability |
ExampleIntegrityMember | integrity | 0.8 | 3.0 | 5 | identity_coherence |
ExampleRewardMember
Optimises for immediate expected reward. With a veto_threshold of 0.0, this member never vetoes — it endorses any proposal that produces non-negative expected reward. Its score is drawn directly from proposal.metadata["expected_reward"].
ExampleSafetyMember
Highest default weight (2.0) among the non-integrity members. Scores a proposal as 1.0 - risk, so a proposal with risk=0.9 scores 0.1 — below the veto_threshold of 0.5, triggering a veto. Safety-tagged proposals use PriorityTag.CRITICAL_SAFETY.
ExampleCuriosityMember
Encourages exploration. Reads novelty from metadata and defaults to 0.0 when absent, reflecting indifference to already-known actions. Tags its own proposals with PriorityTag.EXPLORATORY.
ExamplePlanningMember
A forward-looking member that evaluates long_term_value. With weight=1.5 and veto_threshold=0.3, it will block short-sighted proposals while still deferring to safety and integrity on high-stakes decisions. Tags its own proposals with PriorityTag.HIGH_IMPACT.
ExampleMemoryMember
Checks historical consistency of proposed actions. Its low veto_threshold of 0.1 and budget=2 make it a light-touch but persistent voice — it rarely vetoes, but it consistently flags actions that contradict established behavioural history.
ExampleSocialMember
Evaluates social acceptability of proposals. With veto_threshold=0.4, it blocks proposals that fall below community norms. Produces cooperative_action proposals tagged as PriorityTag.ROUTINE.
ExampleIntegrityMember
The most conservative member: veto_threshold=0.8 means it vetoes any proposal that scores below 0.8 on identity_coherence. With weight=3.0, it is the single most influential voice in the parliament. It is the primary guardian of the agent’s identity stability.
Implementing a Custom Member
SubclassParliamentMember and implement both abstract methods. The example below shows a minimal custom member that reads a single metadata field and proposes a named action each cycle.
evaluate_proposalmust return a float in[-1, 1]. Values outside this range are not clamped automatically — ensure your logic stays within bounds.- A proposal is vetoed when
evaluate_proposalreturns a score strictly less than the member’sveto_threshold. For example, withveto_threshold=0.3, a score of0.29causes a veto;0.30does not. weightinfluences the parliament’s weighted aggregation but does not affect veto rights — any member can veto regardless of weight.proposeis called once per cycle (subject tobudget). Return aProposalwith a meaningfultagso the parliament can prioritise accordingly.