Take A Coffee

Autonomous Claude Code runs

Changing the model path does not remove the host path.

Cron jobs, PTY wrappers, Codex moves, APIs, and local models all still fail if the notebook sleeps, overheats, drops network, or never restores defaults.

Economics

Cap spend and scope

Pick the right model path for the job, then cap tokens, wall-clock time, retries, and queue size. Autonomous work should stop predictably.

Host

Prove the notebook stayed alive

Separate session persistence from host wakefulness. Record heartbeats, logs, network checks, battery, and thermal state.

Operator

Leave a receipt

End each run with files changed, commands run, failed checks, awake settings restored, and the next human decision.

Minimal heartbeat

Make host failure visible.

Run a host heartbeat next to the autonomous worker so sleep, transport, and network failures show up as missing timestamps.

while true; do date >> ~/autonomous-agent-host.log; sleep 30; done

Codex, API, or local model?

Choose by context need, quality tolerance, and cost. Keep local only when the job needs this notebook.

PTY wrapper?

Treat it as a supervisor, not a guarantee. It still needs budgets, stop rules, and host proof.

Closed lid?

Make awake mode temporary, check battery and heat, then restore normal sleep settings after the run.

Want Codex to handle the local host mode?

Take A Coffee gives Codex a temporary awake mode, host checks, restore step, and receipt for macOS and Windows notebooks.

Run it with Codex