About
Adrafinil is a free, open-source macOS app that keeps your Mac awake while AI agents are working, including with the lid closed. An agent acquires a sleep hold when a turn starts and releases it when idle, and the Mac is allowed to sleep once no sessions hold it. Overlapping sessions are counted, so the last release lets the Mac sleep, and an idle prompt leaves normal sleep enabled. One-click hooks are available for Claude Code, Codex, Hermes, and other agents.
You can also manage holds yourself from the command line. Commands such as adrafinil acquire, adrafinil release, and adrafinil hold --for 30m let you control session holds or set a timed hold for work that continues after an agent replies. Adrafinil can play a chime when a hold engages, report session duration and temperature in a morning summary, release holds when the Mac gets too hot, and remove every hook it added when uninstalled.
Closed-lid operation requires an audited root helper that uses pmset disablesleep, which also blocks idle sleep and resets when the helper restarts. Policy runs without root. If needed, sleep can be restored manually with sudo pmset -a disablesleep 0. Adrafinil is listed as macOS, free, open source, under the MIT license.
What's new
All release notesHomebrew cask adrafinil 1.13.1 (sha256 89eb7c82f0a706235eed5ef13ce5700e6fd12d2e5155cce5d1179decd50dfa0b).