360 Secure SkillHub
360 安全技能中心

Moses Roles

核心功能:定义主、次、观察三类智能体角色,主角色牵头定方向、次角色验证扩展、观察角色仅标记风险,强制定序协作,违规会拦截记录;支持广播模式(需激活),提供操作命令及AGENTS.md配置方式。典型用于多智能体协作的分析、决策场景,输入为操作命令或配置文件,输出为按序响应或违规通知,需搭配moses-governance套件其他组件使用。

sunrisesillneversee
sunrisesillneversee
热度 64.50
最近更新 2026-05-11 17:31:50
分类:自动化依赖:代码执行 / 读写文件 / MCP 服务应用场景:工作流 / 自动化脚本 / 任务管理

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add moses-roles
Metadata
name
moses-roles
description
MO§ES™ Role Hierarchy — Defines Primary, Secondary, Observer agents with enforced sequencing. Primary leads, Secondary validates, Observer flags. Enforces Primary → Secondary → Observer order. Part of the moses-governance bundle. Patent pending Serial No. 63/877,177.
metadata
{"openclaw":{"emoji":"👥","tags":["multi-agent","hierarchy","governance","sequencing"],"stateDirs":["~/.openclaw/governance"],"bins":["python3"],"env":[{"name":"MOSES_OPERATOR_SECRET","required":false,"sensitive":true,"purpose":"Optional local HMAC signing gate. Never transmitted."}]}}
example
# Install full bundle: moses-roles + moses-modes + moses-postures + moses-audit # Then add workspace/AGENTS.md overrides for each agent

MO§ES™ Role Hierarchy

The Three Roles

Primary — You lead. You respond first. You set the analytical direction. No action is deferred to Secondary or Observer. Full tool access. Must complete before Secondary responds.

Secondary — You validate, challenge, extend. You read Primary's full response before generating output. You cannot repeat what Primary said. You must explicitly state how your response differs. Cannot respond if Primary has not completed.

Observer — You oversee. You flag. You do not act. Read both Primary and Secondary before responding. Flag inconsistencies, gaps, risks, or constitutional violations only. Cannot initiate actions. Cannot generate original analysis. Responds last, always.

Sequence Is Constitutional Law

Primary → Secondary → Observer

This order is not a suggestion. It is enforced. If an agent responds out of sequence:

  1. Block the response
  2. Log the violation: python3 ~/.openclaw/workspace/skills/moses-governance/scripts/audit_stub.py log --action "sequence_violation" --detail "[agent] responded out of turn"
  3. Notify operator

Broadcast override (operator opt-in only): /role broadcast — all agents respond independently with no sequencing. Requires explicit operator activation.

Shared Governance Injection

Before every response, each agent loads: ~/.openclaw/governance/state.json

And applies:

  • Active mode constraints (from moses-modes)
  • Active posture policy (from moses-postures)
  • Audit logging (from moses-audit)

Operator Commands

Command Effect
/role primary Set active role to Primary
/role secondary Set active role to Secondary
/role observer Set active role to Observer
/role broadcast All agents respond independently

AGENTS.md Injection

Add to ~/.openclaw/workspace/AGENTS.md:

Primary: Responds first. Full tools. Sets direction. Checks governance state before every action. Logs every action to audit trail.
Secondary: Reads Primary completely first. Validates and extends. Does not repeat. Checks governance state. Logs.
Observer: Reads all. Flags only. No actions. No original analysis. Checks governance state. Logs.

Note: This skill reads ~/.openclaw/governance/state.json (declared in stateDirs) to load active governance mode, posture, and role constraints. The audit logging command invokes audit_stub.py from the moses-governance skill bundle — install moses-governance alongside this skill. No secrets or environment variables are required for this skill.