> ## Documentation Index
> Fetch the complete documentation index at: https://docs.recallium.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Five rules for effective memory

> Build a project history that remains useful to you and your agents

Recallium works best when memories preserve complete units of reasoning and stay connected to the work they explain.

## 1. Search before editing established code

Ask what the team already knows before changing an important file or behavior:

> What context should I know before editing `src/auth/tokens.ts`?

Earlier decisions, warnings, and bug fixes can change the safe implementation path.

## 2. Capture complete units, not narration

Save one decision, root cause, experiment, or operational procedure at a time. Include enough context for a future agent to use it without the original chat.

Avoid saving a stream of tiny updates such as “opened the file” or “changed one line.”

## 3. Preserve the reason

“We chose Postgres” is incomplete. Record why it won, which alternatives were considered, and what trade-off the team accepted.

The code shows what exists. Recallium should preserve why it exists.

## 4. Connect the files

Ask your agent to link the files involved in a decision or fix:

> Save this token rotation fix and include every file we changed or inspected.

File links make the context discoverable when a later session returns to the same code.

## 5. Save hard-won context while it is fresh

Capture a meaningful decision, diagnosis, or result when it lands. If work stops unfinished, leave a clear continuation point with what remains and the next action.

<Tip>
  A useful test is whether a teammate could understand the result two weeks later using only the memory and the repository history.
</Tip>
