cobusgreyling/loop-engineering — explained in plain English
Analysis updated 2026-05-18
Set up a daily scheduled loop that triages new GitHub issues automatically
Watch open pull requests for problems and flag them for review
Estimate token cost of a planned automation loop before running it
Scaffold a starter automation project for Claude Code, Codex, or Grok
| cobusgreyling/loop-engineering | amitkumardemo/edgecareer | polymarket-sports/polymarket-trading-bot | |
|---|---|---|---|
| Stars | 141 | 142 | 142 |
| Language | JavaScript | JavaScript | JavaScript |
| Setup difficulty | easy | moderate | hard |
| Complexity | 3/5 | 3/5 | 4/5 |
| Audience | developer | developer | developer |
Figures from each repo's GitHub metadata at analysis time.
Tools are published to npm and runnable via npx without a separate install step.
Loop engineering is a way of working with AI coding tools where, instead of typing prompts yourself, you design automated systems that send the prompts for you. The central idea, credited to Boris Cherny (Head of Claude Code at Anthropic) and Addy Osmani, is that a developer's job is shifting from writing individual instructions to writing the control logic that decides what to tell an AI agent, when, and what to do with the result. This repository collects practical patterns, starter projects, and CLI tools that put that idea into practice. The repo organizes its material around seven named patterns, each suited to a different recurring task: triaging issues on a daily schedule, watching pull requests for problems, sweeping for failing tests, updating dependencies, drafting changelogs, cleaning up after merges, and sorting new issues by priority. Each pattern comes with a markdown description, a recommended cadence (how often to run it), and a "starter" folder you can copy into your own project as a starting point. Three small command-line tools ship alongside the patterns. loop-audit checks how ready a project is to run automated loops and gives it a readiness score with suggestions. loop-init scaffolds a starter setup for a chosen pattern and AI tool combination (currently Grok, Claude Code, or Codex). loop-cost estimates how many tokens a given loop will consume per run, which helps budget before committing to a cadence. All three are published to npm and can be run without installing them first using the npx command. The building blocks the patterns draw on are: scheduling (running on a timer), worktrees (isolated copies of the codebase for safe parallel work), skills (saved project context the AI can recall), external tool connections (via the MCP protocol), sub-agents (separate AI instances handling specific steps), and a persistent state file that keeps memory across runs. A flowchart in the README shows how these connect: schedule triggers triage, triage reads and writes state, a sub-agent implements, another sub-agent verifies, and the result either merges automatically or escalates to a human depending on risk level. The license is MIT.
A collection of patterns and CLI tools for building automated systems that run AI coding agents on a schedule, called loop engineering.
Mainly JavaScript. The stack also includes JavaScript, Node.js, npm.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated easy, with roughly 30min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Verify against the repo before relying on details.