Using the decision envelope pattern for structured thinking.
This skill teaches how to correctly manage the lifecycle of a Decision Envelope. The Decision Envelope is the mandatory boundary for all governed operations in TraceMem.
open), operated upon, and then explicitly closed (commit or rollback).intent string (e.g., customer.onboarding.verification) that describes why this decision exists.automation_mode (e.g., propose, approve, autonomous).decision_close is called in finally blocks or error handlers.Create the Envelope:
Call decision_create with:
intent: A dot-separated string (e.g., financial.report.generate).automation_mode: One of propose, approve, override, autonomous.actor: Your agent identity.Result: You receive a decision_id.
Operate within the Envelope:
Perform all decision_read, decision_evaluate, and decision_write calls using the decision_id.
Close the Envelope:
decision_close with action: "commit".decision_close with action: "rollback" (or abort if strictly tracking abandonment).Note: Writes are only permanently applied when the decision is committed (depending on system configuration, but logically, the decision is not "done" until committed).
task.do or agent.act. Use specific, domain-relevant intents (user.password.reset, invoice.payment.process).autonomous when the task requires human oversight, or propose when you intend to execute immediately.decision_close is attempted.