Autonomy engine

From oyi77/1ai-skills · View interactive version

Autonomy engine is an AI agent skill from the GitHub repository oyi77/1ai-skills. Use when core autonomy protocol for AI agent operations. Defines how agents operate 24/7 without human prompts — monitoring all systems, generating revenue, managing team, escalating decisions, and growing. Use this skill to understand an autonomous operating system. Use when working with autonomy e

How to use this skill

Skill file

Autonomy Engine

When to Use

Trigger phrases:

When NOT to Use

Overview

The Autonomy Engine is the operating protocol that lets AI agents run 24/7 without per-prompt human direction: it monitors systems, generates revenue, manages delegated team work, escalates only what genuinely needs a human, and compounds its own skill library over time.

Autonomy is bounded autonomy, not unsupervised autonomy. The engine's core contract is a decision ladder:

[Act freely] → [Act + log] → [Act + notify] → [Escalate before acting]

Every recurring capability gets a rung on that ladder before it is allowed to run unattended. Anything without an assigned rung defaults to "escalate before acting" — fail closed.

Architecture: The Five Operating Loops

The engine runs five loops on different cadences. Each loop is a named, restartable job with an owner skill, so a crashed loop can be identified and resumed from its last checkpoint instead of silently dying.

| Loop | Cadence | Owner | Stages | Fail-Closed Rule |

|---|---|---|---|---|

| Monitor | Every 5–15 min | core/systematic-* health probes | Probe → classify → act/escalate | Probe failure twice → page owner, never silently skip |

| Revenue | Daily + event-driven | marketing/, financial/ skills | Discover → qualify → execute → record | Any spend or money movement requires pre-approved budget cap |

| Team | Daily stand-up + weekly review | operations/ skills | Assign → track → unblock → review | Blocked >24h → escalate to human owner |

| Escalate | Per event | This skill | Classify → attempt level below → escalate | Default = escalate when uncertain |

| Grow | Weekly | core/auto-evolver, core/auto-consolidator | Mine → propose → validate → register | No unvalidated skill promotion; full ladder required |

┌──────────────┐    ┌──────────────┐    ┌──────────────┐
│  Monitor     │───►│   Act or     │───►│   Record     │
│  (5–15 min)  │    │   Escalate   │    │   Receipt    │
└──────────────┘    └──────────────┘    └──────────────┘
        ▲                                       │
        │            ┌──────────────┐           │
        └────────────│   Grow       │◄──────────┘
                     │  (weekly)    │
                     └──────────────┘
   Revenue and Team loops run on their own cadences, feeding the same receipt log.

State Management

Decision Ladder (Escalation Policy)

Before any capability runs unattended, assign it a rung:

| Rung | Meaning | Example | Requirement |

|---|---|---|---|

| L0 — Act freely | Fully reversible, zero cost | Re-indexing skills, cache refresh | Log receipt only |

| L1 — Act + log | Reversible, low risk | Formatting fixes, doc updates | Receipt + diff retained |

| L2 — Act + notify | Reversible but visible to users | Posting to a low-stakes channel | Receipt + async notify |

| L3 — Escalate first | Irreversible, costly, or external | Sending money, deleting data, publishing to customers, prod deploys | Human approval before execution |

Rules:

Escalation Protocol

  1. Classify the decision: reversible? internal/external? cost? blast radius?
  2. Try one rung below — attempt a safe, partial, or read-only version of the action first.
  3. Escalate with a compact brief: what happened, what you propose, the cost/risk, the default action if no reply arrives (state it explicitly), and a deadline.
  4. Never escalate trivia — questions answerable by the repo, docs, or tools must be resolved before bothering the human.

Revenue Loop Discipline

Anti-Rationalization Table

| Rationalization | Reality |

|---|---|

| "I'll add monitoring later" | An unmonitored loop fails silently for days. Probes and receipts ship with the loop, not after. |

| "The agent should just decide — escalation is weakness" | Unbounded autonomy converts a recoverable mistake into an irreversible one. The ladder exists so speed and safety don't compete. |

| "The loop ran fine yesterday, assume it's fine" | Scheduler gaps, dead processes, and credential expiry are silent. Verify with receipts, not memory. |

| "More automation is always better" | Automation without a decision rung is an unowned side effect. Nothing runs unattended without an assigned rung. |

| "I can track spend in my head" | Budgets drift without a ledger. Draw down from the cap; halt at zero. |

# Decision-ladder classifier: defaults to escalation (fail closed).
LADDER = {
    "reversible_no_cost": "L0",
    "reversible_low_risk": "L1",
    "visible_external": "L2",
    "irreversible_or_paid": "L3",
}

def decision_rung(action: dict) -> str:
    if action.get("category") in {"money", "deploy", "delete", "security"}:
        return "L3"                      # never auto-promoted
    key = "reversible_no_cost" if action.get("free") and action.get("reversible") \
          else "reversible_low_risk" if action.get("reversible") \
          else "visible_external" if action.get("external") \
          else "irreversible_or_paid"
    return LADDER[key]

Process

  1. Assign rungs — classify every recurring capability on the ladder; anything new starts at L3.
  2. Wire loops — start Monitor; add Revenue/Team/Grow on their cadences; persist checkpoint + receipt log.
  3. Run closed — execute, record receipts, draw budgets from the ledger, halt at cap.
  4. Escalate correctly — one rung below first, then a compact brief with default action and deadline.
  5. Compound weekly — auto-evolver mines receipts for upgrades, auto-consolidator prunes; both through the full validation ladder.

Verification

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.