Post WP-0002/0003 hygiene: update docs and archive finished workplans
Some checks are pending
CI Smoke / host-smoke (push) Waiting to run
CI Smoke / container-smoke (push) Waiting to run

Refresh README and SCOPE to reflect stale/fuzzy/DOM capabilities. Move
EANCH-WP-0001 through EANCH-WP-0003 to workplans/archived/260709-*.
This commit is contained in:
tegwick 2026-07-09 09:29:50 +02:00
parent a1af0c6a45
commit 113358c13c
5 changed files with 30 additions and 33 deletions

View file

@ -21,9 +21,10 @@ The anchor slice has been extracted from the umbrella and now lives here.
`@anchor` alias is retired. Shared-contract changes still happen in the umbrella `@anchor` alias is retired. Shared-contract changes still happen in the umbrella
(`citation-evidence/wiki/`), not here. (`citation-evidence/wiki/`), not here.
Remaining anchor work beyond this MVP slice (stale/orphan semantics, fuzzy EANCH-WP-0002 and EANCH-WP-0003 delivered stale/orphan/fuzzy resolution,
re-anchoring, HTML/Markdown selectors, promoting the PDF spike to a production `PdfViewerAdapter`, and HTML/Markdown selectors plus `evidence-anchor/dom`.
adapter) is tracked as follow-on work — see `workplans/`. Remaining work (FragmentSelector, umbrella viewer wiring) is tracked in
`workplans/`.
## Install model ## Install model
@ -44,20 +45,19 @@ src/
HighlightRenderOptions, DocumentViewerAdapter HighlightRenderOptions, DocumentViewerAdapter
css.d.ts ambient decl for side-effect .css imports css.d.ts ambient decl for side-effect .css imports
selectors/ pure core — no viewer/UI deps selectors/ pure core — no viewer/UI deps
index.ts createSelectors, resolveSelectors, DEFAULT_CONTEXT_CHARS index.ts createSelectors, resolveSelectors, fuzzy, orphan helpers
create.ts selector creation from a captured selection create.ts selector creation (PDF + DOM branches)
resolve.ts resolution + the exact-match confidence ladder resolve.ts resolution ladder + stale/fuzzy recovery
create.test.ts fuzzy.ts / orphan.ts / dom-path.ts
resolve.test.ts *.test.ts
pdf/ adapter boundary — the only place viewer libs live pdf/ PDF adapter boundary
index.ts subpath entry `evidence-anchor/pdf` index.ts subpath entry `evidence-anchor/pdf`
pdf-selector-math.ts pure page + normalized-rect math (capture↔selectors) pdf-viewer-adapter-spike.tsx PdfViewerAdapter (+ PdfSpikeViewer alias)
pdf-selector-math.test.ts pdf-selector-math.ts / scroll-job.ts / *.css
pdf-viewer-adapter-spike.tsx concrete PDF adapter (PdfSpikeViewer) dom/ HTML/Markdown adapter boundary
scroll-job.ts retryable scroll-to-highlight helper index.ts subpath entry `evidence-anchor/dom`
scroll-job.test.ts html-viewer-adapter.tsx HtmlViewerAdapter
highlight-styles.css highlight rendering styles dom-path.ts Range ↔ DomNodePath serialization
debug-textlayer.css optional text-layer debugging styles
``` ```
Boundary rules for the layout (enforced by `eslint.config.js`): Boundary rules for the layout (enforced by `eslint.config.js`):
@ -70,10 +70,9 @@ Boundary rules for the layout (enforced by `eslint.config.js`):
creation/resolution, the adapter types/contract, and the PDF adapter — so creation/resolution, the adapter types/contract, and the PDF adapter — so
consumers resolve every anchor symbol (and their test `vi.mock(...)` calls) consumers resolve every anchor symbol (and their test `vi.mock(...)` calls)
from a single specifier, matching the umbrella's prior `@anchor/index`; from a single specifier, matching the umbrella's prior `@anchor/index`;
- a focused, viewer-free entry is also published at **`evidence-anchor/pdf`** - focused subpath entries: **`evidence-anchor/pdf`** (PDF adapter) and
for consumers that want the PDF surface explicitly. The concrete adapter is **`evidence-anchor/dom`** (HTML/Markdown adapter). The root barrel re-exports
still the explicitly-named `PdfSpikeViewer` spike; promoting it to a both for consumers that want a single import path.
production `PDFViewerAdapter` is registered follow-on work (T06).
## Public API (target surface) ## Public API (target surface)

View file

@ -28,9 +28,10 @@ guess. It also owns the `DocumentViewerAdapter` contract every viewer implements
- selector **creation** from a captured viewer selection (`createSelectors`) - selector **creation** from a captured viewer selection (`createSelectors`)
- selector **resolution** against a document representation (`resolveSelectors`) - selector **resolution** against a document representation (`resolveSelectors`)
- the exact-match confidence ladder and selector-redundancy rules - the exact-match confidence ladder, fuzzy recovery floor, and selector-redundancy rules
- PDF selector math (page number + normalized page rectangles, page-local text) - PDF selector math (page number + normalized page rectangles, page-local text)
- the format-neutral `DocumentViewerAdapter` contract and the first PDF adapter - DOM/structural selector creation and resolution for HTML/Markdown
- the format-neutral `DocumentViewerAdapter` contract, the PDF adapter, and the HTML viewer
- scroll-to-target and highlight-render contracts + helpers - scroll-to-target and highlight-render contracts + helpers
- anchor confidence scoring and ambiguous/unresolved/stale reporting - anchor confidence scoring and ambiguous/unresolved/stale reporting
@ -50,14 +51,11 @@ Selector *behavior* lives here; selector *type interfaces* live in
During the umbrella-first MVP these belong to the appropriate citation-evidence During the umbrella-first MVP these belong to the appropriate citation-evidence
subsystem. This repo may depend on **`citation-engine` only** (DependencyMap §4). subsystem. This repo may depend on **`citation-engine` only** (DependencyMap §4).
### Not in this extraction slice (EANCH-WP-0001) ### Still deferred (beyond EANCH-WP-0002 / EANCH-WP-0003)
- full HTML/Markdown (`DomSelectionCapture`) selector implementation - `FragmentSelector` (export-only deep links)
- production-grade fuzzy / recovery-oriented re-anchoring - wiring `HtmlViewerAdapter` into `citation-work` / the umbrella review shell
- `stale` and orphaned-annotation semantics beyond what upstream already ships - human-confirmation UI for ambiguous/fuzzy matches
These are real INTENT.md goals but are **registered as follow-on work**, not
built during the initial extract-and-verify pass.
--- ---
@ -80,10 +78,10 @@ built during the initial extract-and-verify pass.
## Current State ## Current State
- Status: experimental — extracting from the umbrella into a standalone package - Status: active — standalone package consumed by `citation-evidence`
- Implementation: partial — pure selector + PDF adapter slice exists upstream in - Implementation: PDF + HTML/Markdown selector paths, stale/orphan/fuzzy resolution,
`../citation-evidence/src/anchor/`; extraction tracked by EANCH-WP-0001 `PdfViewerAdapter`, and `HtmlViewerAdapter` (`evidence-anchor/dom`)
- Stability: evolving — shared contracts stable, this repo's package API forming - Stability: evolving — shared contracts stable; viewer wiring in the umbrella is next
- Usage: internal (consumed by `citation-evidence` during MVP) - Usage: internal (consumed by `citation-evidence` during MVP)
--- ---