
Lea
Autonomous Claude Code task runner — a menu-bar app that tracks your usage and runs a to-do queue headlessly the moment your limit resets. macOS / Windows /…
Install with your AI
Paste into Claude Code, Cursor, or any agent — it reads the repo and wires the tool into your project.
Install and set up Lea (git-clone project) into my current project. Found on https://claudeers.com/lea Repo: https://github.com/bobby33400/Lea Homepage/docs: https://bobby33400.github.io/lea-site/ Detected install method: git-clone → git clone https://github.com/bobby33400/Lea Category: devtools. Platforms: cli, api, desktop. Read the repo's README for exact setup and env vars, then install it and wire it into my project. Claudeers Health Verdict: active; community-verified: false. Confirm the source before running anything.
git clone https://github.com/bobby33400/Lea
// compatibility
| Platforms | cli, api, desktop |
|---|---|
| Operating systems | — |
| AI compatibility | claude |
| License | MIT |
| Pricing | open-source |
| Language | JavaScript |
Lea
Your autonomous Claude assistant that works while you sleep.
Lea is a cross-platform menu-bar / system-tray app that tracks your Claude usage and runs a to-do queue automatically — the moment your limit resets, it picks up the next task and runs Claude headlessly. Queue work before bed, wake up to it done.
┌──────────────┐ reads ┌───────────────────────────┐
│ ccusage │◀───────────│ ~/.claude/projects/*.jsonl │
└──────┬───────┘ └───────────────────────────┘
│ active block: tokens, cost, reset time
┌──────▼───────┐ "limit hit → wait for reset, then retry"
│ Lea Runner │────────────────────────────────────────┐
└──────┬───────┘ │
│ claude -p (isolated by the sandbox backend) │
┌──────▼───────┐ ┌──────▼──────┐
│ Your task │ edits confined to project dir │ tray icon │
│ (a project) │ │ ◷ 2:14 · 3 │
└──────────────┘ └─────────────┘
What it does
- Tracks tokens & the reset clock from Claude Code's local transcripts (via
ccusage) — live token count, cost, burn rate, and a countdown to your next usage-window reset. - Queues to-dos for Claude — each is an instruction + a project folder.
- Runs them autonomously with headless
claude -p. If a run hits the usage limit, the task is requeued and retried automatically once the window resets — looping through your list overnight. - Isolates every run so an unattended mistake can't wreck your machine.
- Keeps your computer awake (only while tasks are pending) so overnight runs actually happen.
Requirements
- macOS, Windows, or Linux, Node 18+.
- The
claudeCLI installed and logged in to your Claude subscription. Verify withclaude --versionandclaude -p "hi". - (Windows/Linux only, optional) Docker if you want sandboxed runs.
Install & run (from source)
git clone https://github.com/bobby33400/Lea.git
cd Lea
npm install
npm start
A small ring icon appears in your menu bar / tray. On macOS it shows a live
countdown like ◷ 2:14 · 3 (2h14m to reset, 3 queued); on Windows/Linux the
countdown is in the tooltip. Click it to add and manage tasks.
Prebuilt installers: push a
v*tag (or run the build workflow) and GitHub Actions produces a.dmg/.zip(macOS),.exe(Windows), and.AppImage(Linux). Or build locally withnpm run dist.
How the autonomous loop works
- Queue tasks during the day; leave Lea running.
- The runner takes the first queued task and runs it. If you still have capacity, it just runs.
- If Claude reports the usage limit is hit, the task goes back to the front of the queue and the runner sleeps until the active block's reset time (plus a small buffer), then retries.
- Successful tasks become done; repeated failures become failed (and can be requeued). Every run's full output is saved to a log.
🔒 Safety model (please read)
Autonomous, unattended Claude is powerful and risky — it edits files and runs commands with nobody watching. Lea defaults to the safest option per platform.
| Platform | Default isolation | How it works |
|---|---|---|
| macOS | Seatbelt sandbox (built-in) | Each run is wrapped in sandbox-exec. File writes are confined to the task's project folder; ~/.ssh, ~/.aws, Keychains, etc. are hard-blocked. Reads, network, and commands stay allowed so Claude's tools work. Zero setup. |
| Windows / Linux | None by default (Docker opt-in) | No lightweight built-in sandbox exists. Lea runs Claude directly and shows a warning, unless you enable the Docker backend. |
Whichever platform you're on:
--permission-mode bypassPermissionsis used so headless runs never block on a prompt — which is exactly why isolation matters.- Start with low-stakes tasks and review logs before trusting Lea with anything important. Use per-project git commits so changes are reversible.
Docker sandbox (recommended on Windows/Linux)
This gives real isolation by running Claude in a container with only the project folder mounted writable.
- Install Docker Desktop (or Docker Engine) and make sure it's running.
- Build the bundled image:
docker build -t lea-claude:latest docker/ - Get a subscription token for headless container auth:
claude setup-token - In Lea → ⚙ Settings → Sandbox backend → Docker, paste the token and
confirm the image name (
lea-claude:latest).
Note: on a Windows host, make sure the drive containing your project is shared with Docker Desktop (Settings → Resources → File sharing).
Configuration (⚙ Settings)
| Setting | Default | Meaning |
|---|---|---|
| Auto-run | on | Master switch for autonomous execution |
| Sandbox backend | auto | auto (Seatbelt on macOS, none elsewhere), docker, or none |
| Keep computer awake | on | Prevent sleep while tasks are pending |
| Quiet hours | off | Pause auto-run during a time window |
| Default model | opus | Model when a task doesn't specify one |
| Task timeout | 30 min | Kill a task that runs too long |
| Max retries | 2 | Retries for non-limit errors |
| Token budget / block | off | Pause after N tokens per usage window |
Settings, tasks, and logs live in the app's data folder
(Settings → Open data folder): ~/Library/Application Support/Lea (macOS),
%APPDATA%\Lea (Windows), ~/.config/Lea (Linux).
Project layout
src/
main.js Electron entry: tray, window, IPC, keep-awake, live title
preload.js contextBridge API for the renderer
config.js settings + cross-platform claude/ccusage/PATH resolution
usage.js polls ccusage → active usage-block snapshot
store.js the to-do queue (tasks.json)
runner.js autonomous orchestrator (run → classify → wait/retry)
sandbox.js isolation backends + headless claude argv (pure, tested)
classify.js ccusage parsing + run-result classification (pure, tested)
icon.js zero-dependency tray + app icon generator
spawnutil.js cross-platform buffered spawn (cross-spawn)
renderer/ the tray UI (index.html, style.css, app.js)
docker/Dockerfile image for the Docker sandbox backend
scripts/selftest.js fast offline logic tests (no tokens spent)
Run the logic tests any time (no tokens spent):
npm run selftest && npm run check
Notes & limitations
- Reset detection uses the rolling usage block reported by
ccusage. Claude also enforces weekly limits; if one is hit, a run may fail in a way that isn't a normal short-window reset — check the task log. - Lea uses your own Claude account and respects your own limits.
- Contributions welcome — see CONTRIBUTING.md.
License
MIT © Lea contributors. Not affiliated with Anthropic. “Claude” is a trademark of Anthropic.
// faq
What is Lea?
Autonomous Claude Code task runner — a menu-bar app that tracks your usage and runs a to-do queue headlessly the moment your limit resets. macOS / Windows / Linux. MIT.. It is open-source on GitHub.
Is Lea free to use?
Lea is open-source under the MIT license, so it is free to use.
What category does Lea belong to?
Lea is listed under automation in the Claudeers registry of Claude-compatible tools.
// embed badge
[](https://claudeers.com/lea)
// retro hit counter
[](https://claudeers.com/lea)
// reviews
// guestbook
// related in Developer Tools
The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Curs…
Use Garry Tan's exact Claude Code setup: 23 opinionated tools that serve as CEO, Designer, Eng Manager, Release Manager, Doc Engineer, and QA
AI coding assistant skill (Claude Code, Codex, OpenCode, Cursor, Gemini CLI, and more). Turn any folder of code, SQL schemas, R scripts, shell scripts, docs,…
Makes your AI agent think like the laziest senior dev in the room. The best code is the code you never wrote.