Favicon of Loop.js

Loop.js

A local AI agent framework that retries tasks with independent completion checks, saved state and scheduling, with optional cloud execution on Modal.

Screenshot of Loop.js website

Loop.js is an AI agent framework for developers who want repeated attempts at a task with a separate check of the result. You define the goal and completion criteria, and the engine coordinates work until the verifier accepts it or a stopping condition ends the run.

  • Independent verification: A separate agent checks each attempt in its own session, is read-only by default and can use a different model from the worker.
  • Guided retries: Each attempt starts with fresh context and reads handoff notes from disk; failed checks give the next attempt a reason to address, and an impossible goal can end with an explicit give-up verdict.
  • Resumable tasks: Saved execution state lets interrupted work continue, while locking prevents overlapping triggers from running the same task concurrently.
  • Stopping limits: Model spending caps, attempt limits and timeouts stop work without treating an exhausted budget as successful completion.
  • Scheduled upkeep: Recurring checks can reopen completed tasks when their requirements no longer hold, such as a daily report that needs fresh data.

You can use the terminal app or embed the TypeScript engine in another product, with progress events and verification verdicts. The executor uses the Claude Agent SDK.

Local scheduling works on macOS, Windows and Linux through the operating system's scheduler, with state stored in the project directory. An optional Modal backend executes jobs in the cloud and stores state on a Modal Volume; that deployment requires a Modal token and an Anthropic API key. Loop.js is open source under Apache 2.0.

Similar to Loop.js