git404hub

what is loop.js fr?

loop-js/loop.js — explained in plain English

Analysis updated 2026-05-18

137TypeScriptAudience · developerComplexity · 4/5LicenseSetup · moderate

tl;dr

A framework that runs an AI agent in rounds toward a goal until a separate judge agent confirms it is truly done.

vibe map

mindmap
  root((loop.js))
    What it does
      Goal driven agent rounds
      Separate verify judge
      Cost and time guards
    Tech stack
      TypeScript
      Claude Agent SDK
      Modal
    Features
      Fresh context per round
      Disk backed state
      Cron and Modal scheduling
    Use cases
      Build until tests pass
      Daily scheduled briefs
      Recurring chore upkeep
    Audience
      Developers building agents

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

what do people make with this?

VIBE 1

Run an agent in rounds until tests pass and a build succeeds, judged by a separate agent.

VIBE 2

Schedule a recurring goal, like a daily market brief, that re-checks itself each morning.

VIBE 3

Keep ongoing chores like dependency updates or test coverage on track automatically.

what's the stack?

TypeScriptClaude Agent SDKModalNode.js

how it stacks up fr

loop-js/loop.jsferroxlabs/waylandmodelstudioai/cli
Stars137137137
LanguageTypeScriptTypeScriptTypeScript
Setup difficultymoderatemoderateeasy
Complexity4/53/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

how do i run it?

Difficulty · moderate time til it works · 30min

Requires an Anthropic API key since agents run on the Claude Agent SDK.

Apache 2.0 license, free to use, modify, and distribute including commercially, with patent grant protections.

in plain english

loop.js is a TypeScript framework for running an AI agent repeatedly toward a stated goal until a separate judge agent confirms the work is actually finished. Instead of prompting an AI assistant one message at a time and manually deciding when to stop, a developer defines a goal, a description of what counts as done, and limits on rounds, cost, and time, then lets the framework run the agent in a loop until that bar is met or a limit is hit. The core idea is separating the worker from the judge. Each round of work starts with a fresh context and reads back notes the previous round left on disk, so long runs do not accumulate drift the way one giant conversation would. A separate Verify agent, which can even use a cheaper model and by default cannot make changes, checks each round's result and only its verdict decides whether the loop is done. If the answer is not yet, it must give a reason that gets passed into the next round, and a goal that can never be satisfied ends in an explicit give-up rather than burning through the whole budget. Cost and safety are handled through built in guards: a total dollar limit, a maximum number of rounds, and a timeout per round, all defaulting to tight values so a first run stays cheap. All state is stored on disk, so a run can crash, resume, and even overlap with a scheduled trigger without duplicating work, thanks to a lock that detects a dead owner and takes over. Scheduling is done through loop cron, which installs into an existing scheduler like crontab, launchd, or Windows Task Scheduler, or deploys to the Modal cloud platform, without loop.js running its own background daemon. The README gives example uses ranging from building a game until tests pass, to writing a daily market brief, auditing a trading strategy's orders each day, and keeping recurring chores like dependency updates or test coverage on track. Getting started involves scaffolding a new project with npm, installing dependencies, and setting an Anthropic API key, since the agents run on the Claude Agent SDK. The project is released under the Apache 2.0 license.

prompts (copy fr)

prompt 1
Explain how the Verify agent in this repo decides when a Loop is actually done.
prompt 2
Walk me through defining a goal and limits for a new Loop using this repo.
prompt 3
How does this repo's cron scheduling avoid overlapping runs?
prompt 4
What happens in this repo when a goal can never be satisfied?

Frequently asked questions

what is loop.js fr?

A framework that runs an AI agent in rounds toward a goal until a separate judge agent confirms it is truly done.

What language is loop.js written in?

Mainly TypeScript. The stack also includes TypeScript, Claude Agent SDK, Modal.

What license does loop.js use?

Apache 2.0 license, free to use, modify, and distribute including commercially, with patent grant protections.

How hard is loop.js to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is loop.js for?

Mainly developer.

peek the repo → explain another one

This repo across BitVibe Labs

double-check against the repo, no cap.