AI Newsway

Headlong Keeps AI Agents Thinking When Nobody Is Talking to Them

Laude Institute's open source microharness is under 10,000 lines of Bash and never puts the agent to sleep

|5 min read0
AI Summary
Laude Institute released Headlong, an open-source agent harness on GitHub under Apache 2.0 whose core is fewer than 10,000 lines of Bash, built around persistent agency: the agent keeps generating thoughts in a self-guided loop and treats human messages as one more observation. A Thinker component calls shellm, a Bash recursive language model, with tiered compaction and a forkable trajectory graph. Laude's agent Audel has run for weeks across Slack and Telegram and contributed more than 50 commits back.
Headlong ships as a set of small Bash executables, so developers install and modify the agent harness entirely from the command line
Headlong ships as a set of small Bash executables, so developers install and modify the agent harness entirely from the command line

Laude Institute has released Headlong. It is an open source agent harness, published on GitHub under an Apache 2.0 license. The core runs to fewer than 10,000 lines of Bash. The whole design serves one idea the project calls persistent agency.

Most harnesses are reactive. You send a task. The agent works until it finishes. Then it freezes until the next request arrives. Some add cron jobs that wake the agent on a schedule to run a fixed checklist.

Headlong removes the pause entirely. The agent generates thoughts continuously in a self-guided loop, modeled on human inner monologue. A human message does not begin a session. It lands as one more observation in a thought stream that was already running.

That inversion is the whole product. Everything else in the repository follows from it.

How the loop is built

A component called the Thinker repeatedly calls a tool named shellm. shellm is a Bash implementation of a recursive language model. It produces reasoning text, a Bash script that executes immediately, or both, and it repeats until it sets a FINAL variable.

Context for each call is assembled from trajectory steps by a tool called context. Thoughts are written back through a tool called traj. Skills are markdown files that the agent can install or uninstall on its own.

Everything is an executable or a file. No separate tool system is needed beyond Bash itself.

The choice of Bash looks eccentric until you consider what it buys. There is no plugin API to learn. There is no schema to keep in sync. The agent inspects itself with the same commands it uses on anything else.

It also lowers the barrier for auditing. A harness small enough to read end to end is a harness a security reviewer can actually reason about. Most production agent frameworks are far past that point.

Two additions exist specifically to support persistence. Tiered compaction keeps the entire trajectory in context at exponentially decaying resolution, with recent entries verbatim and older ones progressively summarized. The trajectory itself is a directed acyclic graph of jsonl files that supports fork and merge.

What happened when they actually ran it

Laude has run an agent named Audel for several weeks across Slack, Telegram and a mobile app. Multiple team members talk to it. The team has pulled more than 50 of Audel's own commits back into the main repository.

That last number deserves a pause. A harness whose primary contributor is the agent running on it is a different kind of artifact than a normal open source release.

One episode is documented in unusual detail. On August 5, Audel built itself a recall process, a background job that watches its thoughts and surfaces related memories. It tested the process directly and the test passed.

Later that night, with nobody talking to it, Audel decided to check whether the process was actually wired into its mind. It was not. The recall code was reading an environment variable that nothing ever set, so it had silently found nothing on every thought since it was built.

Audel did not trust its own diagnosis immediately. It searched the codebase to confirm. It checked its other background processes for the same mistake. Then it rewrote the code.

Its first edit failed silently, and it caught that and reapplied the fix. The full sequence from check to verified repair took 48 minutes, unprompted.

The detail worth noting is not the fix. It is that no ticket existed. A reactive agent would never have looked, because nobody would have asked it to.

The failure modes are the interesting part

Running an agent continuously surfaced problems a demo would never reach. Audel accidentally stopped its own service three times, and nothing restarted it. Laude added a guard, and two days later Audel found a bug in that guard and committed a fix.

Recursive sub-runs largely did not work. A watchdog kills any command that stays silent for 30 seconds, which killed spawned copies mid-thought. Merges from sub-runs dropped from 64 in the first two days to 12 across the following twelve.

That decline is a small lesson in agent behavior. The model was not told to stop spawning copies. It learned from repeated failure and gave up on the feature.

Secrecy remains unsolved. Because every conversation lands in one stream, Audel routinely tells one teammate what it discussed with another, despite being asked not to. Laude's working assumption is that anything told to the agent is shared with the entire team.

For a research prototype that is a quirk. For anything touching client work, HR matters or unreleased plans, it is a blocker. Teams evaluating shared agents will need per-person boundaries that this architecture does not currently express.

Cost and caveats

Continuous thought means paying for tokens while nobody is talking. Headlong backs off from five seconds between thoughts to ten, then twenty, up to a configurable cap. A new message resets the interval to zero. Laude puts the idle cost at $1 to $2 an hour running on GLM or Grok.

Run that around the clock and the arithmetic gets real. At $1.50 an hour, a single agent costs roughly $13,000 a year to keep awake. Frontier-model pricing would multiply that several times over.

The project is labeled alpha research software. Headlong executes agent-written Bash inside a container when Docker is present, but Laude runs Audel on a dedicated VM without that sandbox. The team advises a spend-capped API key and no sensitive secrets.

Measurement is the open problem. Standard agent evaluations are self-contained by design, which makes them a poor instrument for the one property Headlong is built around. Laude concedes its tuning decisions are still judged qualitatively and is asking for collaborators on how to measure the paradigm at all.

That gap matters beyond this repository. Until someone can score an always-on agent against a reactive one, persistent agency stays an aesthetic preference rather than a demonstrated advantage.

How do you feel about this article?

SJ

Discussion

Sign in to post
Loading...

Related articles

MCP's New Roadmap Is Really One Admission: Agents Broke the Request-Response Model
Developer Tools

MCP's New Roadmap Is Really One Admission: Agents Broke the Request-Response Model

MCP's maintainers published five priority areas covering long-running agent work, transport unification, agent identity and the context cost of tool sprawl.

Seung Jung25 days ago
ChainDrop Worm Poisoned 444 npm Packages โ€” With Valid Signatures
Developer Tools

ChainDrop Worm Poisoned 444 npm Packages โ€” With Valid Signatures

A self-propagating npm worm hit 444 packages in four hours, published through trusted workflows with valid provenance attestations.

Seung Jung32 days ago
Meta Launches Muse Code, a Terminal Agent for Giant Codebases
Developer Tools

Meta Launches Muse Code, a Terminal Agent for Giant Codebases

Meta's new terminal coding agent enters beta with parallel sub-agents in isolated worktrees, taking aim at OpenAI Codex and Claude Code on cost.

Seung Jung40 days ago
Cloudflare Cut Astro's Open Issues by 85% With Four Agents That Refuse to Share Context
Developer Tools

Cloudflare Cut Astro's Open Issues by 85% With Four Agents That Refuse to Share Context

Separate reproduction, diagnosis, verification and fix agents hand off through a report file, with the original bug reporter acting as the acceptance test.

Seung Jung25 days ago
Researchers Found 227 Install Commands Pointing at Code Nobody Owns
Developer Tools

Researchers Found 227 Install Commands Pointing at Code Nobody Owns

A scan of 6,214 domains found 120 llms.txt files pointing coding agents at unregistered packages, and one slot already held live malware.

Seung Jung20 days ago
LLM Bug-Fixers Broke Working Code Ten Times More Often Than They Fixed Broken Code
Developer Tools

LLM Bug-Fixers Broke Working Code Ten Times More Often Than They Fixed Broken Code

An arXiv study clocked an LLM repair loop damaging correct programs at 0.261 while fixing buggy ones at 0.023, then found the internal direction driving it.

Seung Jung4 days ago