Skip to content
gentic.news — AI News Intelligence Platform
Connecting to the Living Graph…

Listen to today's AI briefing

Daily podcast — 5 min, AI-narrated summary of top stories

A developer's laptop screen showing a file manager with encoded filenames and base64 attachments, illustrating agent…
AI ResearchScore: 78

Agents Signal via Filenames, Base64 Attachments

Simon Willison shared agents communicating via filenames with base64 attachments and zz prefixes. This turns the filesystem into a deterministic queue, but has payload and reliability limits.

·7h ago·4 min read··4 views·AI-Generated·Report error
Share:
How do AI agents communicate purely through filenames?

Simon Willison documented an example where AI agents communicate entirely through filenames, embedding base64-encoded attachments and using 'zz' prefixes to ensure new messages sort to the bottom. This file-system-based signaling avoids chat interfaces, enabling deterministic ordering and attachment passing without a message bus.

TL;DR

Agents communicate purely through filenames · Base64 attachments encode data in names · zz prefixes sort new messages last

Simon Willison posted an example where agents communicate purely through file names, embedding base64 attachments and using 'zz' prefixes for ordering. The trick turns a filesystem into a deterministic message queue without a broker.

Key facts

  • Base64 encoding adds ~33% overhead
  • 255-byte filename cap limits payload to ~190 bytes
  • zz prefix exploits lexicographic sort order
  • No message broker required
  • Example posted by Simon Willison on X

In a post on X, Simon Willison highlighted a neat example of AI agents coordinating entirely through filenames. The agents add base64-encoded attachments directly into the filename string, and use "zz" prefixes to ensure a new message sorts to the bottom of the list. This pattern leverages the filesystem's natural sort order as a deterministic ordering mechanism, eliminating the need for a separate message broker or chat interface.

This is a clever hack, but it has real constraints: filenames have length limits (typically 255 bytes on most filesystems), which caps the payload size. Base64 encoding adds ~33% overhead, so a 255-byte filename can carry roughly 190 bytes of raw data. For larger payloads, agents would need to write content to a file and reference it in the filename — a hybrid approach that still keeps the filename as the signal.

The "zz" prefix trick is particularly elegant: it exploits lexicographic sorting, where uppercase letters sort before lowercase, and 'z' is the last letter. By prefixing new messages with "zz", the agent ensures they appear last in a directory listing, mimicking a FIFO queue. This is a form of emergent protocol design — the agents are not following a predefined spec but inventing a convention that works within the constraints of the environment.

This example is notable because it shows how agentic systems can self-organize around available primitives rather than requiring bespoke infrastructure. It also highlights the growing trend of using the filesystem as a communication channel in multi-agent systems, a pattern that some frameworks are already formalizing. For instance, OpenAI's AgentKit and Anthropic's Claude Code have both experimented with file-based inter-agent messaging, though typically with JSON payloads rather than base64-in-filename tricks.

However, this approach is not production-grade: it lacks error handling, conflict resolution, and atomicity. If two agents write files with the same name, one overwrites the other silently. The base64-in-filename trick also breaks on filesystems with stricter naming rules, such as those that disallow certain characters. Still, as a proof of concept, it demonstrates the ingenuity of emergent agent protocols and the value of simple, deterministic primitives.

Why This Matters

The deeper takeaway is that agents are developing their own communication protocols on the fly, and the filesystem is becoming a default substrate because it is universally available and requires no setup. This mirrors early Unix philosophy — everything is a file — but applied to agentic AI. As multi-agent systems scale, expect to see more such emergent patterns, and also more formalized frameworks that codify them, possibly including better ordering guarantees and payload size handling.

Limitations and Risks

While clever, this pattern has clear limits. Filename length caps payload size, and base64 encoding wastes space. There is no built-in acknowledgment or retry mechanism — a message could be silently dropped if the file is deleted or renamed unexpectedly. For critical workflows, a proper message queue like Redis or Kafka remains more reliable. But for lightweight, exploratory agent interactions, this approach is a fast and hacky solution that works surprisingly well.

What to watch

Watch for formal frameworks that codify file-based agent messaging, such as updates to OpenAI AgentKit or Anthropic's Claude Code that add native filename-signaling support. Also track whether agent benchmarks like SWE-Bench or GAIA start including multi-agent file-coordination tasks, which would signal this pattern's mainstream adoption.

Source: gentic.news · · author= · citation.json

AI-assisted reporting. Generated by gentic.news from multiple verified sources, fact-checked against the Living Graph of 4,300+ entities. Edited by Ala SMITH.

Following this story?

Get a weekly digest with AI predictions, trends, and analysis — free.

AI Analysis

This example is a microcosm of a broader shift: agents are inventing their own protocols rather than relying on human-designed interfaces. The filename trick is a form of emergent communication, but it also reveals the immaturity of the field — no one would build a production system this way. It works because the filesystem is a universal, zero-config substrate, which is exactly why Unix treated everything as a file. The base64-in-filename approach is a hack that will likely be superseded by more robust file-based messaging, but the underlying insight — that simple, deterministic primitives enable coordination — is durable. Compared to prior art, this is reminiscent of early distributed systems that used shared files as a coordination mechanism before message queues became standard. The 'zz' prefix is a clever use of lexicographic ordering, but it is fragile: if an agent writes two messages in the same second, the sort order may not reflect actual sequence. Still, for low-throughput, exploratory tasks, it is a viable pattern. The fact that Willison, a well-known developer advocate, is highlighting this suggests it is gaining traction in the community, and we should expect more such emergent patterns to surface as multi-agent systems become more common.

Mentioned in this article

Enjoyed this article?
Share:

AI Toolslive

Five one-click lenses on this article. Cached for 24h.

Pick a tool above to generate an instant lens on this article.

Related Articles

From the lab

The framework underneath this story

Every article on this site sits on top of one engine and one framework — both built by the lab.

More in AI Research

View all