mirror of
https://github.com/davila7/claude-code-templates.git
synced 2026-09-19 01:30:23 +08:00
7f890b1b3b
* feat: add Loops component type with referenced components Introduce "loops" as a new first-class component type — autonomous agentic workflows (goal + interval + stop condition) inspired by Loop Engineering and the Forward Future Loop Library. A loop references other components (agents, skills, hooks, commands) and the dashboard renders those references as clickable cards on the loop detail page. - Add 10 starter loops under cli-tool/components/loops/ (engineering, evaluation, operations) - Catalog generator: scan loops + write per-component content files - Dashboard: new type in icons/types/data, /loops page, and a "Referenced Components" section on the loop detail page - CLI: --loop flag installs the loop to .claude/loops/ and auto-installs its referenced components - Docs: CLAUDE.md and cli-tool rule updated Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T9ynMiCHt8JwdMd8KjCkES * feat: add 8 more loops (goal/loop/schedule patterns) Expand the loops catalog to 18, drawing ideas from community "Loop Engineering" patterns. Adds loops across the three trigger verbs (/goal, /loop, /schedule) and emphasizes the verifier-in-the-loop and budget / anti-spin guardrails: - engineering/five-minute-maintainer-loop - engineering/build-test-fix-loop - engineering/anti-spin-build-loop - engineering/completion-contract-loop (goal) - engineering/goal-refiner-loop (goal) - engineering/adversarial-review-loop (cross-model) - operations/overnight-pr-routine-loop (schedule) - evaluation/human-approval-loop (human-in-the-loop) All referenced components verified to exist; catalog regenerated. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T9ynMiCHt8JwdMd8KjCkES --------- Co-authored-by: Claude <noreply@anthropic.com>
2.0 KiB
2.0 KiB
name, description, category, interval, stop-condition, components, tags
| name | description | category | interval | stop-condition | components | tags | |||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| perf-budget-loop | Profiles and optimizes the app pass after pass until it consistently meets a defined performance budget. | engineering | 20m | The target metric meets the budget across repeated runs with no functional regressions. |
|
|
Performance Budget Loop
Loop Engineering — hold the agent to a concrete, measurable budget and let it optimize until the number is real and stable.
🎯 Goal
Drive a target metric (page load, bundle size, p95 latency, etc.) under its budget by profiling, fixing the biggest bottleneck each pass, and re-measuring — without breaking functionality.
⏱️ Schedule
Suggested interval: 20m.
▶️ Run it
/loop 20m "Profile the app against the performance budget. Find the single biggest bottleneck, fix it, and re-measure. Verify no tests break. Continue until the metric meets the budget across three consecutive runs."
🔁 Iteration steps
- Perceive — run
/performance-auditand capture the current metric. - Reason — the
performance-engineeragent identifies the top bottleneck. - Plan — choose one optimization (code-split, cache, query, bundle).
- Act — apply it (e.g.
/optimize-bundle-size). - Observe — re-measure; require the budget to hold across repeated runs before stopping.
🛑 Stopping condition
Metric ≤ budget across consecutive runs, with no functional regression.
🧩 Referenced components
agent:performance-testing/performance-engineer— diagnoses bottlenecks.command:performance/performance-audit— measures each pass.command:performance/optimize-bundle-size— one of the optimization levers.
💡 Example
Targeting a 200 KB JS budget, the loop lazy-loads a chart library, trims a moment.js import, and de-dupes a dependency until the bundle stabilizes under budget.