@sema-agent/core
Version:
Stateless, task-oriented AI agent core
20 lines (19 loc) • 971 B
JavaScript
export const SAFETY_AXIS_VOCABULARY = {
toolEffect: ["read", "write", "idempotent"],
egress: [true, false],
irreversibility: ["never", "maybe", "always"],
safetyAxis: ["egress", "irreversible", "shell"],
severity: [1, 2, 3, 4, 5],
shellGate: ["always"],
permissionDecision: ["allow", "ask", "deny"],
};
const _toolEffectExhaustive = true;
void _toolEffectExhaustive;
export function markTightenMessage(toolName, mark) {
switch (mark) {
case "interaction": return `tool "${toolName}" asks for a person's confirmation (server-declared) — explicit approval required`;
case "egress": return `tool "${toolName}" performs an external write (egress) — explicit approval required`;
case "irreversible": return `tool "${toolName}" performs an irreversible action — explicit approval required`;
case "unproven": return `tool "${toolName}" was not shown to be reversible — explicit approval required`;
}
}