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

# Lens Packs

> View your knowledge through different lenses for specific use cases.

# Lens packs (v0.41.2.0)

Four bundled schema packs that turn the modusbrain dream cycle into a multi-lens
brain. Activate one with `modusbrain config set schema_pack &lt;name&gt;` and the cycle
picks up the pack's declared phases on the next `modusbrain dream` run.

## The four packs

```
                gbrain-base (shipped v0.38)
                       ▲
                       │ extends
        ┌──────────────┼──────────────────────┐
        │              │                       │
   modusbrain-creator  modusbrain-investor      modusbrain-engineer
   (atom + concept  (deal/thesis/        (learning bridge
    lifecycle)       bet_resolution)      for gstack)
        │              │                       │
        └──────────────┼───────────────────────┘
                       │ extends + borrow chain
                       ▼
              modusbrain-everything (meta-pack)
              one brain, three lenses active
```

### modusbrain-creator

Atom + concept content-creator lifecycle. Drives two cycle phases:

* `extract_atoms` — per source, Haiku extracts 1-3 atoms from each
  transcript with the closed 11-value `atom_type` enum (insight,
  anecdote, quote, framework, statistic, story\_angle, strategy\_angle,
  strategy, endorsement, critique, collection). Writes
  `atoms/&#123;YYYY-MM-DD&#125;/&#123;slug&#125;` pages. Budget cap \$0.30/source/run.
* `synthesize_concepts` — globally aggregates atoms by frontmatter
  `concepts:` ref. Tier by count: T1 ≥10, T2 ≥5, T3 ≥2. T1/T2 get
  Sonnet narratives; T3 falls back to a deterministic stub. Writes
  `concepts/&#123;slug&#125;` pages. Budget cap \$1.50/run.

One calibration domain: `concept_themes` / cluster\_summary / \[concept]
— tier histogram + page count, not Brier (concepts don't have binary
outcomes to score against).

### modusbrain-investor

YC / investor lens. Declares 2 net-new page types on top of
gbrain-base's deal/person/company/yc seed:

* `thesis` (NEW) — investment thesis with thesis\_text + key\_bets\[] +
  market\_view + vintage. Files at `investing/theses/&#123;slug&#125;`. Extractable
  (the LLM mines claims into facts).
* `bet_resolution_log` (NEW) — outcome record for a thesis's bet. FK
  to a take row via take\_id; carries resolved\_outcome + resolved\_at +
  learned\_pattern. Files at `investing/bets/&#123;YYYY-MM&#125;/&#123;slug&#125;`.

No new cycle phases — consumes the existing
extract\_facts/propose\_takes/grade\_takes/calibration\_profile loop. Three
calibration domains: `deal_success` (scalar\_brier over deal-attached
takes), `founder_evaluation` (scalar\_brier over person-attached takes),
`market_call` (weighted\_brier over thesis-attached takes; weighted by
conviction so high-stakes misses cost more).

### modusbrain-engineer

Bridge-only pack. Declares `learning` page type + reuses base `code`.
No new cycle phases — the daemon-side `gstack-learnings` IngestionSource
(T8) watches `~/.gstack/projects/&#123;repo&#125;/learnings.jsonl` and emits
each JSONL line as a `learning` page when this pack is active. Three
calibration domains: `architecture_calls` (scalar\_brier),
`effort_estimates` (weighted\_brier), `risk_assessment` (scalar\_brier).

Speculative ADR/postmortem/refactor\_thesis/tech\_debt types deferred
to v0.42+ — they'll ship when a real user authors the first one (D8).

### modusbrain-everything

Meta-pack stacking creator + investor + engineer via the v0.38
`extends` + `borrow_from` chain. Single-active-pack constraint
preserved — this IS the active pack; the registry walks extends +
borrow to materialize the merged view.

Activate via `modusbrain config set schema_pack modusbrain-everything` and
calibration\_profile produces all 7 domain scorecards in one JSONB.

## Calibration profile widening (T10)

Before v0.41.2.0, `calibration_profiles.domain_scorecards` was a
`JSON.stringify(&#123;&#125;)` placeholder. v0.41.2.0 widens it: each declared
domain produces a `&#123;n, brier, accuracy, aggregator, page_types,
extras&#125;` entry. Four aggregator algorithms (closed enum):

* **scalar\_brier** — `AVG(POWER(weight - outcome::int, 2))`. Default for
  probabilistic predictions.
* **weighted\_brier** — Brier weighted by `ABS(weight - 0.5) * 2`
  (conviction proxy). High-conviction misses cost more.
* **count\_based** — simple `SUM(hit) / COUNT(*)` accuracy without
  Brier. Use when probability isn't natural.
* **cluster\_summary** — descriptive rollup (page count + tier
  histogram). For domains like `concept_themes` where there's no
  binary outcome.

Pack manifests declare domains with `&#123;name, aggregator, page_types&#125;`.
Domain names are OPEN (third-party packs can declare new domain labels
without a modusbrain release). Aggregator algorithms are CLOSED (safe SQL
stays in code, validated at pack-load).

## take\_domain\_assignments table (T1)

New JOIN table (migration v94):
`take_domain_assignments(take_id BIGINT FK, domain TEXT, pack TEXT,
source TEXT, confidence REAL, assigned_at TIMESTAMPTZ, PK(take_id,
domain))`. Multi-domain assignment honest — a take about "Sequoia's
investment in Anthropic" can land in BOTH `deal_success` AND
`market_call` rather than being force-bucketed.

## What this enables for the user

* **Atoms + concepts ship in the binary.** Your OpenClaw's parallel
  atom-pipeline-coordinator + atom-backfill-coordinator + concept-
  synthesis crons can retire (T12 follow-up). One `modusbrain dream` cron
  covers everything.
* **gstack learnings reach modusbrain.** Engineer-pack-active brains
  surface every gstack-logged learning as a queryable page within
  seconds of being written.
* **Multi-lens calibration.** Activate modusbrain-everything and see how
  often you're wrong on deals AND market calls AND architecture
  AND effort estimates in one `modusbrain calibration --json` call.
* **Lossless OpenClaw migration.** The `markdown-greenfield`
  importer (T7, mode='migration') re-ingests existing OpenClaw
  pages with permanent slug-keyed idempotency + per-row JSONL audit
  * the `imported_from` marker so extract\_atoms + synthesize\_concepts
    don't re-extract already-atomized material.

## v0.41.2.1 follow-ups (filed in plan)

* Per-page-type `frontmatter_validators` on PageTypeSchema so the
  atom\_type enum (currently hardcoded in extract\_atoms.ts) reads from
  the active pack manifest at runtime per D11.
* 3-check quality gate (truism / punchline / entity-page reject) as
  a multi-pass extract\_atoms refinement.
* Embedding-similarity dedup in synthesize\_concepts (currently
  exact-string concept ref match only).
* Voice gate integration for T1 Canon narratives.
* op\_checkpoint resumability for cross-cycle continuation in both
  phases.
* Parity-baseline eval gates against your OpenClaw's existing 13K atoms
  * 11K concepts on a 500-page sample subset.
