Skip to content

P2-D: Prototype Recomputer (DELIVERS: prototype quality) #32

@github-actions

Description

@github-actions

Why: Keep volume/shelf prototypes accurate as pages/books change. Prototype updates change which entries should occupy the volume and shelf tier quotas.

  • P2-D1: Implement daydreamer/PrototypeRecomputer.ts

    • Recompute volume medoids (select medoid page per volume)
    • Recompute volume centroids (average of book embeddings)
    • Recompute shelf routing prototypes
    • Update vectors in VectorStore (append new, update offsets)
    • After recomputing each level: recompute salience for affected representative entries via SalienceEngine; run tier-quota promotion/eviction for that tier
  • P2-D2: Add prototype recomputer test coverage

    • tests/daydreamer/PrototypeRecomputer.test.ts
    • Test medoid selection algorithm
    • Test centroid computation
    • Test that tier-quota hotpath entries are updated after prototype recomputation

Exit Criteria: Prototypes stay accurate over time; tier quota entries reflect current prototypes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2: mediumMedium priority — targets v1.0layer: daydreamerBackground consolidation (LTP/LTD, recalc)

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions