Thinking in Piles

When there are only a few things, we can talk about each one individually. As their number grows, that becomes harder. We group related things, give the group a name, and use that name to communicate without listing every detail.

Software repositories have the same problem, and AI agents amplify it by increasing the volume of changes. A single change may involve many files, but the conversation is usually about something larger: the formatter, the settings page, or the authentication system. These are the units we use to explain the software and assign work.

Pile makes those units explicit. A pile groups related parts of a repository under a name and a declared purpose. That lets people and AI agents talk about a meaningful whole, then examine its individual parts when they need to.

This guide explains how to think in piles: how to choose useful groups, describe what they mean, and use them as shared vocabulary for working on software.

The Habits You Arrive With

As AI agents handle more typing and code navigation, your role shifts to two main tasks: stating what needs to be done and judging the results. The hard part is communicating clearly—to agents and teammates—what needs to change, where, and why.

Because standard repositories only offer files and folders as a shared vocabulary, team communication breaks down in familiar ways:

  • Folder names are vague guesses. Names like utils, core, or shared describe where code sits, not what it is for. Developers learn the real purpose over months, but AI agents must guess every session.
  • Purpose stays trapped in people’s heads. When nobody tells the agent why a part exists, it might “improve” code that was left alone on purpose, or place new code wherever search leads it.
  • Agents load the wrong context. An agent cannot hold the whole repository at once, and nothing highlights which part matters for the current task.
  • Tasks rely on file paths or vague outcomes. You either micro-manage by listing exact file paths, or describe an outcome and hope the agent finds the right files.
  • Changes sprawl everywhere. A tiny fix arrives touching eight files in five folders. Without explicit boundaries, nobody can tell if the change stayed where it belonged.
  • Code review becomes a bottleneck. Agents create changes faster than humans can review them. Reviewers must reconstruct what each part is supposed to do before checking if the change is correct.

From Files to Piles

Files show how a repository stores code, not how humans or agents think about it. Working directly with files is like writing assembly language: you see low-level details, but miss the big picture.

Piles fix this by raising the level of communication. Instead of focusing on raw files, you work with units that match your mental model: the formatter, the settings page, or the specs.

A Pile Is a Claim, Not Just a Folder

A pile is a part of the repository that declares: I am one thing, and here is why. While folders merely hold files, a pile includes a short text written by a human that explains its exact purpose. Instead of forcing visitors to interpret raw code, the repository tells them what it contains.

A Pile Is Something You Can Use Without Opening It

A good pile clearly states why it exists, what it does, how to use it, and what it excludes. When an intent is written well, you can work with the pile without reading its internal files—just like using a well-designed software library.

This transforms how AI agents work. An agent can read the short intent statements of surrounding piles to learn what they offer without loading their files into context. It keeps its focus on the pile it needs to change, viewing the rest of the codebase as clear summary sentences.

Name the Pile, Not the Files

When assigning work, direct the agent or teammate to a specific pile. For example, “Make the formatter handle time zones” gives the task a clear home. Whoever picks up the task reads the pile’s intent statement and immediately knows what belongs there and what does not.

Look at Everything, Change Only What You Understand

Agents and developers can freely inspect the entire repository to understand context. However, they should only modify a pile after reading its intent statement. This intent serves as the benchmark to evaluate changes: does this pile still fulfill its stated purpose?

Relations Between Piles, Not Between Files

Instead of tracing thousands of file imports, you define high-level relationships between piles (e.g., “this implements those specs” or “this tests that service”). A few sentences outline the whole system, allowing both humans and agents to see how changes propagate.

The Boundary Is Tested by a Sentence, Not by Size

A pile can be large or small. The key test is whether a single sentence can describe its purpose without using multiple conjunctions (“and”). Something deserves to be a pile when it has an independent lifecycle—such as a decisions log that is read and updated on its own schedule.

Before and After: Fixing a Bug

Imagine a bug report states that the date on the settings page is wrong.

Before (File-based approach):

  1. The agent searches the codebase for date formats.
  2. It finds a helper function used in four places and modifies it.
  3. When an unrelated test fails, it updates that test too.
  4. You receive six modified files across four folders with no clear explanation of the main goal.

After (Pile-based approach):

  1. The agent reads the settings page pile’s intent first.
  2. It sees that the helper belongs to a shared formatting library pile whose intent requires deliberate updates.
  3. This clarifies the key question: is the bug in the settings page or the shared formatter?
  4. The agent modifies the formatter pile intentionally, knowing in advance which related tests and piles will be affected.

Before and After: Reviewing a Change

An agent opens a pull request.

Before:

  1. You get thirty files sorted alphabetically by path, forcing you to reconstruct each folder’s purpose from scratch.
  2. You review code line by line without knowing if the agent touched parts of the system it should have avoided.

After:

  1. You see which piles were changed and compare the diff against each pile’s declared intent.
  2. If an unassigned pile was modified, the boundary violation stands out immediately.
  3. Review shifts from “Does this code look reasonable?” to “Does each part still fulfill what it claims to be?”

Signs You Are Thinking in Piles

  • You can name the target pile before starting a change.
  • You assign work by naming a pile rather than listing file paths.
  • You and your AI agents read a pile’s intent statement before editing its contents.
  • You can interact with neighboring piles using only their intent statements.
  • Unexpected piles showing up in a change notice immediately trigger investigation.