Skip to content

smorky850612/Aurakit / skills/aura

All-in-one fullstack dev engine. /aura: 46 modes (build/fix/clean/deploy/review/spec/lore/ax/experiment/payment/debug/qa/orchestrate/escalate+), 6-layer security with 32 hooks, tiered models (ZERO/ECO/PRO/MAX), 8 languages, 16 specialized agents, SPEC/EARS/TRUST5/XLOOP/RALF/Autopus absorbed. ~55% token savings.

FileKindSize
SKILL.mdskill md29.2 KB
resources/agent-security.mdmarkdown4.2 KB
resources/agent-spawning.mdmarkdown5.9 KB
resources/agent-team.mdmarkdown5.7 KB
resources/archive-pipeline.mdmarkdown3.5 KB
resources/autopus-agent-teams.mdmarkdown6.8 KB
resources/autopus-ax-annotation.mdmarkdown6.1 KB
resources/autopus-executor-profiles.mdmarkdown9.9 KB
resources/autopus-experiment-loop.mdmarkdown5.9 KB
resources/autopus-lore-commit.mdmarkdown6.0 KB
resources/autopus-pipeline-v2.mdmarkdown8.5 KB
resources/autopus-spec-system.mdmarkdown4.8 KB
resources/autopus-validator-gates.mdmarkdown7.0 KB
resources/autopus-worktree-isolation.mdmarkdown4.6 KB
resources/baas-pipeline.mdmarkdown3.8 KB
resources/batch-pipeline.mdmarkdown4.9 KB
resources/brainstorming.mdmarkdown4.7 KB
resources/branch-finishing.mdmarkdown4.7 KB
resources/build-pipeline.mdmarkdown12.0 KB
resources/build-resolvers-cpp.mdmarkdown10.0 KB
resources/build-resolvers-go.mdmarkdown1.2 KB
resources/build-resolvers-java.mdmarkdown9.1 KB
resources/build-resolvers-kotlin.mdmarkdown8.7 KB
resources/build-resolvers-python.mdmarkdown9.0 KB
resources/build-resolvers-rust.mdmarkdown1.2 KB
resources/build-resolvers-swift.mdmarkdown11.9 KB
resources/build-resolvers.mdmarkdown1.6 KB
resources/business-skills.mdmarkdown7.0 KB
resources/cache-engineering.mdmarkdown6.6 KB
resources/clean-pipeline.mdmarkdown6.5 KB
resources/common-protocol.mdmarkdown7.4 KB
resources/config-schema.mdmarkdown3.0 KB
resources/cross-harness.mdmarkdown16.6 KB
resources/deploy-enterprise.mdmarkdown9.0 KB
resources/deploy-pipeline.mdmarkdown6.9 KB
resources/design-pipeline.mdmarkdown3.2 KB
resources/desktop-pipeline.mdmarkdown3.5 KB
resources/discovery-protocol.mdmarkdown3.3 KB
resources/e2e-pipeline.mdmarkdown7.7 KB
resources/explain-pipeline.mdmarkdown972 B
resources/fix-pipeline.mdmarkdown5.6 KB
resources/framework-patterns.mdmarkdown8.3 KB
resources/gap-check.mdmarkdown3.4 KB
resources/install-guide.mdmarkdown3.4 KB
resources/instinct-system.mdmarkdown6.8 KB
resources/iterate-pipeline.mdmarkdown2.5 KB
resources/language-reviewers.mdmarkdown18.5 KB
resources/loop-pipeline.mdmarkdown3.5 KB
resources/mcp-configs.mdmarkdown4.7 KB
resources/migrate-pipeline.mdmarkdown1.5 KB
resources/mobile-pipeline.mdmarkdown3.5 KB
resources/mode-reference.mdmarkdown6.1 KB
resources/model-routing.mdmarkdown9.1 KB
resources/orchestration-patterns.mdmarkdown5.9 KB
resources/payment-lemonsqueezy.mdmarkdown5.6 KB
resources/payment-pipeline.mdmarkdown10.6 KB
resources/payment-polar.mdmarkdown3.6 KB
resources/payment-steppay.mdmarkdown4.8 KB
resources/payment-stripe.mdmarkdown6.7 KB
resources/payment-toss.mdmarkdown7.2 KB
resources/pipeline-guide.mdmarkdown6.1 KB
resources/plan-pipeline.mdmarkdown2.4 KB
resources/pm-pipeline.mdmarkdown4.5 KB
resources/qa-pipeline.mdmarkdown8.8 KB
resources/report-pipeline.mdmarkdown3.0 KB
resources/review-pipeline.mdmarkdown8.0 KB
resources/rollback-pipeline.mdmarkdown1.3 KB
resources/security-rules.mdmarkdown17.5 KB
resources/snippets-guide.mdmarkdown4.6 KB
resources/status-dashboard.mdmarkdown5.3 KB
resources/style-guide.mdmarkdown2.7 KB
resources/systematic-debugging.mdmarkdown5.7 KB
resources/tdd-pipeline.mdmarkdown4.4 KB

resources/autopus-experiment-loop.md

View on GitHub
# Autopus XLOOP — Experiment Loop

> Absorbed from Autopus-ADK. XLOOP = Autonomous metric-driven improvement loop.
> Continuously measures → changes → measures → decides → repeats.

---

## Overview

XLOOP is an autonomous improvement loop that:
1. Measures a baseline metric
2. Makes a focused change
3. Measures the new metric
4. Keeps or discards the change based on improvement
5. Repeats until improvement threshold or circuit breaker

Unlike ITERATE (which targets a fixed gap), XLOOP explores improvement space autonomously.

---

## Metric Types

```
performance  → benchmark time (ms), throughput (req/s)
quality      → test coverage (%), lint score
size         → bundle size (KB), binary size
complexity   → cyclomatic complexity, file line count
custom       → any numeric metric you define
```

---

## XLOOP Protocol

### Init

```bash
/aura experiment:init [metric-type] [target]
# Example:
/aura experiment:init performance p99<50ms
/aura experiment:init coverage >=85%
/aura experiment:init size bundle<200KB
```

Creates: `.aura/experiments/{id}/baseline.json`

### Measure Baseline

```bash
/aura experiment:metric
```

Runs measurement command appropriate for metric type:
```bash
# Performance
npx autocannon -d 10 http://localhost:3000/api/endpoint
# Coverage
npx vitest run --coverage --reporter=json | jq '.total.lines.pct'
# Bundle size
npx next build && du -sh .next/static/chunks/*.js | sort -rh | head -5
```

### Change Cycle

```bash
/aura experiment:commit [change-description]
# Agent makes focused change, measures new metric
# Decision: keep (improved) or discard (no improvement)
```

Decision formula:
```
improvement_ratio = (new_metric - baseline_metric) / baseline_metric

Keep if:
  improvement_ratio > 0 (better than baseline)
  AND simplicity_score > 0.001 (change is worth the complexity)

simplicity_score = improvement_ratio / lines_changed
```

### Record

```bash
/aura experiment:record [notes]
# Saves iteration result to .aura/experiments/{id}/history.json
```

### Summary

```bash
/aura experiment:summary
# Show: baseline → best result, all iterations, kept/discarded changes
```

### Reset

```bash
/aura experiment:reset
# Discard all uncommitted changes, return to baseline
```

---

## Circuit Breaker

Stops XLOOP when exploration is exhausted:

```
Trigger: N consecutive iterations with no improvement (default N=10)
Action: STOP → report best achieved result → suggest manual review
```

Configure N:
```json
// .aura/config.json
{
  "experiment": {
    "circuit_breaker_n": 10,
    "min_improvement_ratio": 0.01
  }
}
```

---

## Scope Validation

Before each change, XLOOP validates change is within scope:

```
Valid scope changes:
  ✅ Algorithm optimization in same function
  ✅ Caching addition (no interface change)
  ✅ Database query optimization
  ✅ Bundle splitting / code splitting

Out of scope (requires manual approval):
  ❌ Interface/API changes
  ❌ Database schema changes
  ❌ Dependency version upgrades
  ❌ Architecture changes
```

---

## Simplicity Gate

Even if a change improves the metric, it's discarded if:
```
simplicity_score = improvement_ratio / lines_changed < 0.001

Example:
  10% improvement with 100 lines changed → score = 0.001 → borderline
  10% improvement with 50 lines changed  → score = 0.002 → keep
  1% improvement with 200 lines changed  → score = 0.00005 → discard
```

Purpose: Prevent overcomplicated "improvements" that gain little but add maintenance burden.

---

## SIGINT / Crash Handling

If experiment is interrupted:
```
1. Save current iteration state to .aura/experiments/{id}/checkpoint.json
2. Record: was change kept or discarded at interrupt point
3. On resume (/aura experiment:resume): restore from checkpoint
```

Never leave repository in a modified state without recording.

---

## History Format

`.aura/experiments/{id}/history.json`:

```json
{
  "id": "exp-001",
  "metric": "performance.p99",
  "target": "< 50ms",
  "baseline": 87.3,
  "started": "2025-01-15T10:00:00Z",
  "iterations": [
    {
      "n": 1,
      "change": "Add Redis cache for user lookups",
      "metric_before": 87.3,
      "metric_after": 62.1,
      "improvement": 0.288,
      "lines_changed": 34,
      "simplicity_score": 0.0085,
      "decision": "keep",
      "files": ["src/lib/user.ts", "src/lib/cache.ts"]
    },
    {
      "n": 2,
      "change": "Optimize DB query with index hint",
      "metric_before": 62.1,
      "metric_after": 61.8,
      "improvement": 0.005,
      "lines_changed": 8,
      "simplicity_score": 0.000625,
      "decision": "discard",
      "reason": "simplicity_score below threshold"
    }
  ],
  "best_result": 62.1,
  "best_improvement": "28.8%",
  "status": "completed",
  "circuit_breaker_triggered": false,
  "consecutive_non_improvements": 0
}
```

---

## `/aura experiment:` Mode

```bash
/aura experiment:init performance p99<50ms    → Initialize experiment
/aura experiment:metric                        → Measure current metric
/aura experiment:commit "add caching"          → Execute change + measure + decide
/aura experiment:record                        → Save iteration result
/aura experiment:summary                       → Show progress report
/aura experiment:reset                         → Undo uncommitted changes
/aura experiment:resume                        → Resume interrupted experiment
/aura experiment:list                          → List all experiments in .aura/
```

---

## Integration with AuraKit

XLOOP can be triggered from any mode:

```bash
/aura build: user auth --xloop performance
# After BUILD completes, automatically enters XLOOP to optimize

/aura experiment:init coverage >=85% --auto
# Fully autonomous: runs until target or circuit breaker
```

Config for autonomous mode:
```json
{
  "experiment": {
    "auto_mode": true,
    "target_metric": "coverage",
    "target_value": 85,
    "max_iterations": 20,
    "circuit_breaker_n": 5
  }
}
```

Reports stored in `.aura/experiments/` for audit trail.
rea-analysis-optimizationmorluto/reaOptimize REA providers and shared analysis workflows for agent context, latency, CPU, and memory while preserving correctness and Evidence. Use for analysis bottlenecks and cache or query design; CI/test-suite optimization belongs to rea-ci-tests-audit.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
rea-ci-tests-auditmorluto/reaAudit REA CI and test suites for correctness, fixture drift, false passes, and measured performance; use for suite or workflow investigations and efficiency changes, rather than ordinary feature testing or a single test failure.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
rea-tool-designmorluto/reaAudit, investigate, design, or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
ponytail-auditDietrichGebert/ponytailQuality audit of the whole repo: bugs, security, real load, missing tests, speed, and what to delete. Most important first.Stars: 194kUpdated Claude CodeCodexVerifiedInstall