Skip to content
Back to skills

Autonomous Loop

ASecurity

Main orchestration loop for autonomous coding. Use when running autonomous sessions, orchestrating feature completion, managing continuous loops, or coordinating agent lifecycle.

  • 3 stars
  • 0 votes
  • 0 copies
  • 8 views
  • Added February 8, 2026
developmentpythongogit

Security analysis

A100/100

Pro scans all 5 files and shows the line behind each finding

Scanned February 12, 2026

npx -y skills add adaptationio/Skrillz --skill autonomous-loop --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Autonomous Loop?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Autonomous Loop
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/adaptationio-autonomous-loop/badge)](https://www.skillsdirectory.com/skills/adaptationio-autonomous-loop)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: autonomous-loop
description: Main orchestration loop for autonomous coding. Use when running autonomous sessions, orchestrating feature completion, managing continuous loops, or coordinating agent lifecycle.
version: 1.0.0
category: autonomous-coding
layer: orchestration
---

# Autonomous Loop

Main orchestration loop that runs continuously until all features are complete.

## Quick Start

### Start Autonomous Loop
```python
from scripts.autonomous_loop import AutonomousLoop

loop = AutonomousLoop(project_dir)
result = await loop.run()

print(f"Completed: {result.features_completed}")
print(f"Sessions: {result.sessions_used}")
```

### With Configuration
```python
from scripts.loop_config import LoopConfig

config = LoopConfig(
    max_sessions=10,
    token_budget=500000,
    auto_checkpoint=True
)
result = await loop.run(config)
```

## Autonomous Loop Workflow

```
┌─────────────────────────────────────────────────────────────┐
│                   AUTONOMOUS LOOP                           │
├─────────────────────────────────────────────────────────────┤
│                                                             │
│  ┌────────────────────────────────────────────────────┐    │
│  │  INITIALIZE                                         │    │
│  │  ├─ Detect session type (INIT vs CONTINUE)         │    │
│  │  ├─ Load or create feature list                    │    │
│  │  └─ Initialize state tracker                       │    │
│  └────────────────────────────────────────────────────┘    │
│                         │                                   │
│                         ▼                                   │
│  ┌────────────────────────────────────────────────────┐    │
│  │  FEATURE LOOP                                       │    │
│  │  while (incomplete_features > 0):                   │    │
│  │    ├─ Select next feature                          │    │
│  │    ├─ Create checkpoint                            │    │
│  │    ├─ Implement with TDD                           │    │
│  │    ├─ Run E2E tests                                │    │
│  │    ├─ If pass: mark complete                       │    │
│  │    ├─ If fail: recover or rollback                 │    │
│  │    └─ Check context limits                         │    │
│  └────────────────────────────────────────────────────┘    │
│                         │                                   │
│                         ▼                                   │
│  ┌────────────────────────────────────────────────────┐    │
│  │  CONTEXT CHECK                                      │    │
│  │  if (approaching_limit):                            │    │
│  │    ├─ Compact context                              │    │
│  │    ├─ Prepare handoff                              │    │
│  │    └─ Request continuation                         │    │
│  └────────────────────────────────────────────────────┘    │
│                         │                                   │
│                         ▼                                   │
│  ┌────────────────────────────────────────────────────┐    │
│  │  COMPLETION                                         │    │
│  │  ├─ Generate final report                          │    │
│  │  ├─ Store session memory                           │    │
│  │  └─ Signal completion                              │    │
│  └────────────────────────────────────────────────────┘    │
│                                                             │
└─────────────────────────────────────────────────────────────┘
```

## Loop Result

```python
@dataclass
class LoopResult:
    success: bool
    features_completed: int
    features_total: int
    sessions_used: int
    total_tokens: int
    errors_recovered: int
    duration_minutes: float
    handoff_reason: Optional[str]
```

## Continuation Modes

| Mode | Description | Trigger |
|------|-------------|---------|
| **Auto** | Loop continues automatically | Context limit |
| **Manual** | User confirms continuation | Session end |
| **Scheduled** | Runs at scheduled times | Cron trigger |
| **Event** | Triggered by events | Git push, CI |

## Integration Points

- **autonomous-session-manager**: Session lifecycle
- **coding-agent**: Feature implementation
- **browser-e2e-tester**: Feature verification
- **error-recoverer**: Handle failures
- **checkpoint-manager**: Safe rollback
- **handoff-coordinator**: Session transitions
- **progress-tracker**: Track and report

## References

- `references/LOOP-LIFECYCLE.md` - Loop details
- `references/CONTINUATION-PROTOCOL.md` - Continuation

## Scripts

- `scripts/autonomous_loop.py` - Main loop
- `scripts/loop_config.py` - Configuration
- `scripts/feature_orchestrator.py` - Feature flow
- `scripts/continuation_handler.py` - Continuations

Files in this skill

  • SKILL.md6.2 KB
  • scripts/autonomous_loop.py6.6 KB
  • scripts/continuation_handler.py5 KB
  • scripts/feature_orchestrator.py6.2 KB
  • scripts/loop_config.py4.5 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.