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

# Code Headers

> Indexing @purpose annotations from source files

Files with `@purpose` annotations are automatically indexed into the memory system, making your codebase searchable alongside journal entries.

## How It Works

```typescript theme={null}
/**
 * Memory Indexer Module
 *
 * @purpose Automatic indexing of journal entries and code headers
 */
```

Becomes a memory entry:

* **Source:** `file`
* **Type:** `code-header`
* **Title:** `src/lib/memory-indexer.ts`
* **Content:** `src/lib/memory-indexer.ts: Automatic indexing of journal entries and code headers`

## Scanned Directories

`src/`, `packages/`, `scripts/`, `eval/`, `app/`, `lib/`, `components/`

## File Types

`.ts`, `.tsx`, `.js`, `.jsx`, `.mjs`, `.rs`, `.py`, `.go`, `.sh`

## Update Behavior

* Scans every 5 minutes (every 5th periodic indexer tick)
* Deduped by file path
* If `@purpose` changes, memory is updated and embedding cleared for re-computation
* Capped at 200 files per project

## Searching Code Headers

```bash theme={null}
tenet ask "What does the memory indexer do?"
# Returns the @purpose annotation alongside journal entries
```
