Press release · Adrafinil
kageroumado Releases Adrafinil, Keeping a Mac Awake With the Lid Closed Only While AI Coding Agents Are Working
Adrafinil keeps a Mac awake, even with the lid closed, only while AI coding agents such as Claude Code, Codex and Cursor are working, then lets it sleep the moment the last session ends. Free and open source.
Published · Updated . Features and availability describe the product at the update date.
On June 6, 2026, kageroumado released Adrafinil 1.0, a free and open-source macOS utility that keeps a Mac awake while AI coding agents are working, including with the laptop lid fully closed, and lets it sleep as soon as the work is finished.
Conventional keep-awake utilities hold a Mac awake until the user switches them off. Adrafinil instead acts only on request: an agent acquires a wake assertion when a task begins and releases it when the agent goes idle. Overlapping sessions are reference-counted, so the Mac returns to normal sleep when the last one ends. A one-click installer connects Adrafinil to the hook systems of Claude Code, Codex, Cursor, Gemini CLI, Aider, Hermes, OpenCode, Cline and Pi.
Closing the lid locks the screen while work continues underneath, and a chime confirms that the hold is active. A morning summary reports what ran, for how long and how warm the machine became. A thermal cutout force-releases all holds if the Mac overheats in a bag, and assertions whose owning process has died or gone idle are dropped automatically.
Overriding lid-closed sleep requires administrator privileges, so Adrafinil confines that capability to a small privileged helper with a single function, while all policy decisions run unprivileged. Uninstalling removes every hook entry it added to every agent configuration.
Key features
- Wakes only while an AI agent holds an assertion
- Works with the lid fully closed; the screen still locks
- One-click hook integration for nine AI coding agents
- Thermal cutout and idle release
- Sub-50 ms command-line acquire and release
- Morning summary and clean uninstall
How it compares
| App | Price | License | Lid closed | Starts and stops with agent work |
|---|---|---|---|---|
| Adrafinil | Free | MIT | Yes, through a privileged helper (pmset disablesleep) | Yes: hooks for Claude Code, Codex, Cursor and 7 more agents |
| Amphetamine | Free | Proprietary | Closed-Display Mode; Apple silicon laptops need the Power Protect script | Triggers: an app running or frontmost, a Wi-Fi network, devices |
| KeepingYouAwake | Free | MIT | Desktop Macs, and portable Macs with the lid open | Manual, or for a set duration |
| Keepresso | Free | GPL-3.0 | Yes, with no external display, on power or battery | Yes, through an opt-in “AI agent is working” trigger rule |
| caffeinate | Built into macOS | APSL 2.0 source | -s holds off system sleep only on AC power | Holds until a wrapped command or -w process exits |
Availability
Adrafinil is available now as a free download from kagerou.glass/adrafinil and GitHub. It requires macOS 26.4 or later, including macOS 27. The source code is published under the MIT License.
About kageroumado
I'm Mado Kagerou, publishing as kageroumado: an independent researcher and expert Swift engineer with more than ten years of software development experience. As a founder and technical lead, I take projects from architecture through release. My research interests center on computational pharmacology, computational neuroscience and AI safety. My engineering specialties include Apple platform internals, reverse engineering, GPU rendering and local model training.
Research, engineering work and leadership experience
Media contact
kageroumado · [email protected] · kagerou.glass