Skip to content

memory.import writes distilled facts from another memory system through every memory.bulk_set check - #161

Merged
zlareb1 merged 57 commits into
mainfrom
pufit/memory-import
Nov 1, 2026
Merged

zlareb1 merged 57 commits into
mainfrom
pufit/memory-import

Conversation

@pufit

@pufit pufit commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

Changelog category (leave one):

  • New Feature

Changelog entry (one or two sentences a user of Loom can read without the diff; the release pull request collects these into the release notes):

A new operation, memory.import (MCP tool loom_memory_import), imports memory items that another memory system already distilled into a namespace, up to 200 per call. Each key is derived from the item's text, so a re-run writes nothing new and reinforces nothing, and every item goes through the same dedupe, conflict, blacklist, pinned and lock checks as memory.bulk_set; items the owner deleted, superseded, rejected, corrected or left as proposals stay as they are. In a namespace on newest_wins an imported item can retire a live memory it updates, as any write there does, and its entry says so (refines). The import never runs the extraction path's value-update linker (detect_updates=False).

Why

An agent that moves to Loom from another host arrives with a memory store of its own: a few thousand distilled items plus manual notes. Over the wire the paths are memory.set one fact at a time (slow), memory.set_from_messages (re-runs the extraction over text that is already distilled) and memory.bulk_set (hidden from MCP on purpose, with no idempotency across re-runs). The loom import-recall, loom import-brain and loom import-clickgap CLI importers each read one source format from the operator's machine. import-recall writes one memory.set per item under recall_<table>_<source_id> keys, a content digest only when the table has no id column; it stays as it is, since moving it onto import: keys would land every earlier import's items a second time. The import needs an idempotent bulk write that keeps every check of the bulk path and that an MCP client can call by name (loom_memory_import; it is listed on no toolset) during the agent's first start.

Scope and risk

  • New: server/memory/api/{models_import,ops_import}.py, server/memory/app/memory_import.py, server/memory/domain/{memory_import,import_keys}.py, server/memory/store/categories.py (category lookups, link states and links in one store module, used by memory.assign_category and the import — assign_category answers exactly as before), one new read key_heads_across_sessions in server/memory/store/reads.py.
  • handle_memory_bulk_set gains three keyword options with defaults that keep its behaviour: dry_run (returns after the verdicts, writing no memory, link or audit row; its vectors still reach the embedding cache and a blacklist hit is counted), conflict_check_cap (the import passes its batch size so every entry is checked whatever bulk_conflict_check_max_entries says) and reinforce (the import turns it off: no restatement, merge or identity duplicate records an evidence event, so a re-run never raises a memory's reinforcement; a merge or identity duplicate answers held).
  • Auth: WRITER plus ns_write through the shared gates; the op is admitted for user-pinned tokens (NARROW_SAFE_OPS) and then links no category (memory.assign_category is refused to such tokens; the entry notes category_refused). Not in _MCP_HIDDEN_OPS, on no roster; reachable through loom_op.
  • Limits: 200 entries; value ≤ 30,000 characters, ≤ 64 tags of ≤ 256 characters, source_trace ≤ 512, category ≤ 256; own rate-limit class (10 burst, 2/s, like knowledge.add); latency budget 30,000 ms like import_curated.
  • Categories: a link already stored for a key, live or rescinded, is left as it is, so a re-run never brings back a link the owner removed; each entry's note says why its category is not linked.
  • Audit: bulk_set's hash-only row, plus one memory.import row with keys and category names when new links are added; no item text in loom.audit_log.
  • Dry run runs every check and writes no memory, link or audit row; it still pays for the embeddings (which land in loom.embedding_cache) and counts a blacklist hit, as the docs say.
  • Before the write the import reads each key's newest version across sessions: a live head holding the item's text is unchanged (or sensitivity_kept when the entry names another sensitivity), so a re-run from another session writes nothing under either memory_bulk_dedup_scope and the stored labels stay; one holding other text (an owner's correction, a pin) is revised; entries repeating a text must be identical, or the request is a 422.
  • Known limits: keys come from the text, so an item edited in the source arrives as a new fact beside the old one (the conflict check may flag the pair); keying on source_trace was not taken because it may be a path several items share. Text that was deleted, retired or rejected under a different key is still imported under its import: key, because the bulk write's dedup sees live rows only; and the heads read and the write are not atomic, so a delete landing between them is written over, and likewise a category rescind between the link read and the insert. A key is a digest of the text, so a guessable text can be confirmed from its key; the docs say not to import a secret as an item.
  • Ordering: the import sends its entries to the bulk write oldest first (by valid_at, an undated one counting as now, then request order), so under newest_wins the newest statement of an attribute survives whatever order the source exported. The bulk write's own in-batch rule is unchanged. Identity dedup binds the live statuses as a parameter (LIVE_STATUSES), shared with the import.
  • Shared write paths: a key of exactly the import: digest shape is embedded and lexically indexed by its value alone on every write path and in loom reembed (no (#key) suffix and no key-axis vector; server/memory/domain/excerpt.py, embed_text.py, server/memory/app/reembed.py, including --in-database). A key vector a build before this one wrote on such a key is cleared by loom reembed --key-only, and a provider migration rebuilds it from the key instead of failing (provider_rebuild_batch.py).
  • Python SDK: the client generator now appends an underscore to a method whose name is a Python keyword, so the method is agent.client.memory.import_ (TypeScript loom.memory.import); the wire name and the TypeScript SDK are unchanged.

Compatibility, rollout and rollback

  • Wire: one new op, memory.import; no existing op or field changed; defaults unchanged.
  • Operator steps: none (no migration, no re-index; the new rate-limit class has defaults).
  • Rollback: no schema change; generated SDK tables and docs revert with the code. Imported rows and category links remain, and a reverted build (or an N-1 replica during a rolling upgrade) embeds an import: key with its (#key) suffix and a key-axis vector on its next write or re-embed of that key.

Tests

  • make format, make lint (every codegen --check, reach census, secrets) and make typecheck pass.
  • New unit tests (in tests/unit/test_memory_import.py and test_memory_categories.py) cover: key derivation and idempotency; re-runs adding no rows and no events; the cap governing the conflict check at bulk_conflict_check_max_entries 0, 50 and 200 (entry 150 refused as too close to a pinned memory); deleted, superseded, rejected, proposed and unknown-status heads; the race of a second import landing between the heads read and the bulk lookup; dry_run reaching every outcome and writing no memory, link or audit row; bounds (201 entries → 422); category_unregistered / category_refused / category_not_linked; a rescinded link left rescinded and no link or audit row on an unchanged re-run; the import's oldest-first order under newest_wins (dated, undated and mixed batches, naive and aware times, each result keeping its own entry's key); the assign_category refactor; memory.bulk_set unchanged by default.
  • At the head: the full make test-unit (24,403 unit and 199 bench tests) and tests/analyzer (12) pass locally. Not exercised here: loom reembed --in-database against a ClickHouse 26.7 server with an aiEmbed collection (its SQL is unit-tested as text and its import-key expression was run on ClickHouse with a constant in place of aiEmbed).
  • tests/integration/test_memory_import.py (17 cases, through the SDK Agent and raw HTTP/MCP) passes at the head against a private ClickHouse and server (with test_memory_bulk.py, 25 cases) and runs in CI; it covers the deleted, rejected, proposed and revised skips against the real read, a rescinded category link and a user-bounded token's category_refused.

AI assistance in the code (leave one; writing this description with AI is fine):

  • AI-generated (an agent wrote most of the diff): Claude Code. Checked: an independent reviewing agent read every commit with probe tests against the real handler path; the inheritance of every bulk_set check, the authorization path, the SQL of the new read (ReplacingMergeTree semantics, read-scope filter), the generator change and the generated files were verified; the full unit suite and the integration file ran against a private stack at each head.

  • I can explain every line of this diff and how it interacts with the rest of Loom.

Checklist

  • make format-check, make lint, make typecheck and make test-unit pass; the integration suite passes if server behaviour changed. (The integration file and test_memory_bulk.py pass locally against a private stack; the full integration suite runs in CI.)
  • Generated files are regenerated in this PR, not by hand: the SDK op tables, docs/reference/configuration.md and the docs/reference/ tables (python scripts/codegen/docs_reference.py), the reach manifest, schemas/schema.sql (make schema-dump) and the Codex plugin copies (python3 scripts/codegen/agent_plugin_sync.py).
  • A new migration is additive and numbered after the latest on main; no merged migration is edited. (No migration.)
  • A behaviour change to any file a plugin ships (hooks/, lib/, bin/, skills/, .mcp.json, the Codex plugin-defaults.json) bumps both plugin manifests' version, and no other open PR uses that version. (No plugin file changed.)
  • The frontend builds (npm --prefix frontend run build) and its tests pass, if frontend/ changed. (Unchanged.)
  • Docs under docs/ describe the system as it now is, and this description names any operator steps and wire changes.

CI

CI runs on every push; the integration file and the targeted unit suites pass locally against a private ClickHouse at the head.

🤖 Generated with Claude Code

@pufit
pufit requested a review from zlareb1 November 1, 2026 11:32
@zlareb1
zlareb1 force-pushed the pufit/memory-import branch 4 times, most recently from 59709c5 to 411982b Compare November 1, 2026 19:12
pufit and others added 25 commits November 1, 2026 20:07
memory.assign_category resolves the name and writes the link through
server/memory/store/categories.py, which resolves any number of names in one read, so
a batch writer can link through the same statements. Its answers are unchanged; the
analyzer corpus records the batched lookup.

Signed-off-by: pufit <[email protected]>
Keys are `import:` and 24 hex characters of the text's SHA-256, and rows are
source_class=imported, so a re-run writes nothing new; each entry reports written,
reinforced, skipped or refused. dry_run stops the bulk write after its verdicts. The
Python client spells the keyword verb with a trailing underscore
(agent.client.memory.import_).

Signed-off-by: pufit <[email protected]>
…lict check

200 is memory.bulk_set's default conflict-check cap, so the response drops its
unchecked count, and 201 or more entries are refused with 422. The docs say a re-run
still reinforces each stored row once.

Signed-off-by: pufit <[email protected]>
…cap setting says

The import passes its own conflict-check cap to handle_memory_bulk_set, so a lowered
LOOM_BULK_CONFLICT_CHECK_MAX_ENTRIES no longer writes entries unchecked; memory.bulk_set
keeps the setting.

Signed-off-by: pufit <[email protected]>
handle_memory_bulk_set takes reinforce_own_key, which only memory.import turns off: a
restatement of a row under the entry's own key records no evidence event, while a merge
or the same text under another key still reinforces that row.

Signed-off-by: pufit <[email protected]>
Before the write it reads each key's newest version in every session of the identity,
tombstones and superseded rows included, and answers skipped/deleted or
skipped/superseded. Outcomes come from models_bulk.REFUSED and an explicit unchanged case;
any other bulk result raises, and a repeat of a refused entry is refused too.

Signed-off-by: pufit <[email protected]>
…te beside memory.bulk_set

Its rate-limit class is sized like knowledge.add (10 burst, 2/s) and its p99 budget is
an import's, 30 s as for memory.import_curated. A user-pinned token may call it, as
memory.bulk_set, and links no category (category_refused); the sharing summary and the
mentor count it as a write.

Signed-off-by: pufit <[email protected]>
…very outcome

The docs and the dry_run field name the embeddings it pays for, the blacklist hit it
counts and the conflicted preview. A unit test runs one request reaching every outcome
dry and for real; the integration test drives agent.client.memory.import_ through the SDK.

Signed-off-by: pufit <[email protected]>
… a batch after writing

A key whose newest readable version is rejected or proposed answers skipped/rejected or
skipped/proposed, as deleted and superseded ones do; unchanged is what the bulk skip gate
reports (unchanged_into) or identity dedup finding the key in another session, so a
concurrent import landing between the read and the write is unchanged. Any other result
after the write is logged and answered skipped/unknown instead of raising.

Signed-off-by: pufit <[email protected]>
…ts read covers

A re-import after memory.delete, memory.clear or a tombstoning expiry answers
skipped/deleted; memory.restore within 14 days or an erasure with purge=true brings the
keys back. The read of each key's newest version covers the sessions the token may read.

Signed-off-by: pufit <[email protected]>
….import's cap

handle_memory_bulk_set sets the import's conflict_check_cap in a request-scoped context
variable that _bulk_conflict_verdicts reads, as detect_updates_override does, instead of
a new keyword: the check is called as before, and so is every replacement of it.

Signed-off-by: pufit <[email protected]>
It imports the pinned memory's exact text, which identity dedup matches by content hash
before any embedding is compared: the entry reinforces the pinned row and nothing lands
under its import key. A merely close text depends on the embedder's similarity.

Signed-off-by: pufit <[email protected]>
A key of exactly the shape memory.import derives (import: and 24 lowercase hex
characters, is_digest_key) gets no (#key) suffix from build_excerpt and no key-axis
text, on the import and on any later memory.set or memory.bulk_set of the key, so the
digest never reads as words and the two vectors stay comparable. Any other key keeps
its suffix. loom reembed sends no empty key text to the embedder and writes such a row
at key dim 0, as the write paths leave it.

Signed-off-by: pufit <[email protected]>
… and tests every skip against ClickHouse

- The conflict cap travels on the bulk write's state instead of a context variable.
- The heads read groups by key alone and returns only what the import reads.
- `reason` is a Literal on the wire; KeyState, a dead fallback and a dead slice are gone.
- The value bound names its real reason, and the docs say only the first 1,200
  characters of an item are embedded and indexed.
- Integration cases for rejected and proposed keys, a user-bounded token's category
  and every stored field of an imported row.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
… entry why its category is not linked

- A re-run reads the links of its keys and adds only pairs never stored, so a link the
  owner rescinded stays rescinded and an unchanged re-run writes no link or audit row.
- `note` is a Literal and names category_not_linked and category_rescinded too.
- The bulk write loses `unchanged_into`: a version-0 result no check refused, no merge
  took and no other key holds is the key's own unchanged answer.
- The digest-key helpers live in `memory/domain/digest_keys.py`, which the excerpt and
  key-axis code import; the recall-importer comparison is gone.
- The docs name the window between the heads read and the write, and the written
  reason is the conflict verdict's status.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
… on any run

- A live key holding other text than the item's is skipped as `revised`: the heads read
  returns the head's content hash, so a re-run no longer overwrites an owner's revision.
- The bulk write's `reinforce=False` (was `reinforce_own_key`) records no evidence event
  for a restatement, merge or identity duplicate, so re-runs never raise reinforcement;
  the outcome is `held`.
- Entries repeating a text must be identical, or the request is a 422 naming both.
- The link-states read is sequentially consistent, since it decides a write.
- The docs state the text-key trade-off: an item edited in the source arrives as a new fact.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
… bulk dedup scope

- A live head holding the item's text is `unchanged` before the bulk write, so a re-run
  from another session writes nothing even with LOOM_MEMORY_BULK_DEDUP_SCOPE=session, and
  the stored labels stay as written.
- The category links are read before the write; only the new links' insert follows it.
- Reasons and notes are spelled as their Literal values only.
- Shorter comments, category_refused names session-bounded tokens, `unknown` is listed on
  the reason field, and the rate-limit test checks only the import's own class.
- `mint_test_token` takes `read_user_id`, which the user-bounded integration case uses.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…ves its link read

- `skipped` is a key left as it is; the skip-reasons and retry comments say what happens.
- The link-states read uses the shared `_SEQUENTIAL` clause and is in the analyzer corpus.
- The docs name text deleted under another key as imported again.
- The 422 integration case checks the refused field and its type.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
… its conflict cap is its batch

- `digest_keys.is_digest_key` is `import_keys.is_import_key`; the wire models are
  `_MemoryImportEntry`, `_MemoryImportResult` and `_MemoryImportTotals`.
- The import passes the number of entries it writes as the conflict-check cap.
- The docs say a re-run is unchanged in every session the token may read, name the
  rescind race, and warn that a key confirms a guessed text.
- Integration cases: a re-run from another session, and a dry run that leaves no
  memory, embedding, link or audit row.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…e pass

- A unit case scripts a `conflict` verdict and checks the entry answers written/conflicted
  with the peer mark asked for its new row.
- `_categorize` decides each entry's note and new link in one loop.
- The docs say pinned and locked refusals come only from a pin or lock landing between
  the import's read and write; the rate-limit comments read ~120/min; the repeat 422 says
  "different fields"; two tests that restated constants are gone.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…hat holds a held one

- A `refines` verdict (newest_wins) answers written/refines, and the docs say an imported
  item can retire a live memory it updates there.
- A held identity duplicate names its keeper in `held_by`.
- The refusal for being too close to a pinned memory is `pinned_peer`, distinct from the
  written `conflicted`.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
… a racing pin meets

- A head stored with status `tombstoned` is `deleted`; `unknown` is left for a status a
  newer schema adds.
- A unit case pins and locks the keys between the import's read and its write and expects
  refused/pinned and refused/locked; `link_states` has a test of its own.
- The op's docstring opens with one full line, which both SDKs publish.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…y run drops an unreachable guard

- `bulk_conflict_check_max_entries` says memory.import checks every entry; the settings
  reference, schema and example are regenerated.
- The dry run no longer special-cases entity resolution: the import's entries carry no
  entities, so resolution writes nothing.
- The dry-run docs name `refines` beside `conflicted` as previewed before the peers settle.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…t the earlier entry

- Under newest_wins, a templated pair inside one batch whose earlier row carries the later
  `valid_at` is no longer retired by the later row, as the store path's
  `later_valid_peers` already decides. An import exported newest-first keeps its newest
  facts.
- memory.import: `content_shas` names the stored content hash apart from the key's
  digest; one warning per call lists the keys with an unknown head status; the category
  loop reads a stored link once; field descriptions are one sentence each.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…ve and aware times compared as UTC

- The pair is swapped, not dropped, when its earlier row carries the later `valid_at`, so
  the older-dated row is superseded in either order.
- `valid_at` values are compared as naive UTC, so a batch mixing naive and aware times no
  longer turns the in-batch pass off.
- A bulk-write test covers newer-first, older-first with mixed time zones, and undated
  pairs; the import test now expects the older fact retired in both orders.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 and others added 10 commits November 1, 2026 20:07
…ur checks lose a dead clause

- `where_sql` takes the table and builds the key-only import-key predicate from its
  `key_text` and `key_dim`, as `in_database_sql` does.
- The provider rebuild tests `is_import_key` alone; `skip_reasons` reads the named
  sensitivity once; the bulk state groups the two caller options under one comment.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
- `where_sql` takes `table` as a required keyword, so a key-only call without one is a
  TypeError, not a KeyError on ''.
- The NARROW_SAFE_OPS reason for memory.import parses; the bulk state's two options have
  one comment line each; the request-size docstring counts a full memory.import.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…space.inventory

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…ed keys

- Each imported item lands once under its own `import:` key with no key vector, so
  counting it lowered the reuse share and a large import could switch the key axis off
  for every hand-written key of the namespace. The probe now skips keys of the import
  shape; a unit test pins the clause, and the architecture page says so.
- The request-size docstring gives the largest memory.import as about 10 MB of ASCII.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
… a named tuple

- `valid_at` is converted to naive UTC when the request is parsed, so two repeats of one
  time in different zone spellings are the same entry, and the sort and the bulk input
  no longer convert it again.
- `IMPORT_KEY_MATCH`, the anchored pattern, is the one spelling the re-embed SQL and the
  key-axis probe use.
- `_Answer` is a NamedTuple with `held_by` defaulting to ''.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…ort docs split the key bullet

- `in_database_settings` sets short_circuit_function_evaluation=force_enable, so an
  import key's row, whose `if` takes the empty branch, never calls the provider.
- The import section splits the key, re-run and edited-item points into three bullets,
  says the newest version across sessions decides, and shortens the skipped cell.
- Two comments read as meant.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…t key

- `--key-only` skips an import key without a key vector and clears one an older build
  embedded; the re-embed bullet says so.
- The `IMPORT_KEY_MATCH` comment gives the real reason for the anchors.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…t imported under their stub

A module first imported during an import test (namespace_ontology, on the newest_wins
path) bound the stub client with `from server.core.ch import get_client`, so a later
test in the process, the analyzer corpus among them, wrote into that test's fake store.
The harness now restores those modules on teardown, as the corpus does.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…ch a coded column accepts

`INSERT … SELECT` skips the insert path's padding, and a coded (Quantized) vector column
refuses an empty array, so the import-key branch wrote `[]` into a column that rejects
it. It now writes the zero vector of the target width at key dim 0, as every write path
stores "no key vector"; the architecture page names `sensitivity_kept` beside the other
live outcomes.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…code span stays on one line

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
@zlareb1
zlareb1 force-pushed the pufit/memory-import branch from 5323781 to df4cc90 Compare November 1, 2026 20:11
zlareb1 and others added 6 commits November 1, 2026 20:55
…its statuses come from one place

- The dry-run field comment and docs say no memory, link or audit row is written and the
  vectors it pays for land in `loom.embedding_cache`, instead of "writes nothing".
- `_LEFT_AS_IS` keys superseded and proposed by the shared status constants.
- The in-database re-embed builds the import-key predicate in the two branches that use
  it, with no fallback; a test pins the whole-namespace heads read.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
The output `dry_run` field, the bulk docstring and the architecture page now match the
input field and the feature docs: no memory, link or audit row is written; the vectors
it embeds land in `loom.embedding_cache`, and a blacklist hit is counted.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
- `holds_item` reads a module-level `_HOLDS_ITEM` set.
- The in-database re-embed asks one local helper for the import-key predicate.
- The request-size docstring says printable ASCII.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…s and the content hash

The analyzer drives the heads read with the identity that goes with each scope.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…nd two comments read true

- The unknown-status warning moves from `_write` to the handler, right after
  `skip_reasons`, so `_write` only partitions and writes.
- `skip_reasons` reads the named sensitivity only in the branch that uses it.
- The key-axis probe comment gives the real reason import keys are left out.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…eads cleanly

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
@zlareb1
zlareb1 merged commit 83e0eae into main Nov 1, 2026
21 of 22 checks passed
@zlareb1
zlareb1 deleted the pufit/memory-import branch November 1, 2026 23:17
zlareb1 added a commit that referenced this pull request Nov 1, 2026
…his PR's callers use

The blacklist check takes the write's captured policy generations and the conflict mark names its namespace in this PR; the fakes #161 added accept both.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…his PR's callers use

The blacklist check takes the write's captured policy generations and the conflict mark names its namespace in this PR; the fakes #161 added accept both.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…import reads the authority

Under Postgres, a by-id tombstone whose publication is pending mirrors its search rows' status and hands its changes to the caller on the pending error, so the blacklist sweep, dedup_resolve and conflicts.resolve announce them and finish what they owe before answering it. memory.import decides what to skip from the authority's heads. memory.search_trace waits at the search barrier; a tier whose check fails leaves its rows out. The decision-record statement has a corpus case under both authorities and an integration test under Postgres. Test fakes take the bulk options #161 added.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…his PR's callers use

The blacklist check takes the write's captured policy generations and the conflict mark names its namespace in this PR; the fakes #161 added accept both.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…import reads the authority

Under Postgres, a by-id tombstone whose publication is pending mirrors its search rows' status and hands its changes to the caller on the pending error, so the blacklist sweep, dedup_resolve and conflicts.resolve announce them and finish what they owe before answering it. memory.import decides what to skip from the authority's heads. memory.search_trace waits at the search barrier; a tier whose check fails leaves its rows out. The decision-record statement has a corpus case under both authorities and an integration test under Postgres. Test fakes take the bulk options #161 added.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…his PR's callers use

The blacklist check takes the write's captured policy generations and the conflict mark names its namespace in this PR; the fakes #161 added accept both.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…import reads the authority

Under Postgres, a by-id tombstone whose publication is pending mirrors its search rows' status and hands its changes to the caller on the pending error, so the blacklist sweep, dedup_resolve and conflicts.resolve announce them and finish what they owe before answering it. memory.import decides what to skip from the authority's heads. memory.search_trace waits at the search barrier; a tier whose check fails leaves its rows out. The decision-record statement has a corpus case under both authorities and an integration test under Postgres. Test fakes take the bulk options #161 added.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…his PR's callers use

The blacklist check takes the write's captured policy generations and the conflict mark names its namespace in this PR; the fakes #161 added accept both.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
zlareb1 added a commit that referenced this pull request Nov 2, 2026
…import reads the authority

Under Postgres, a by-id tombstone whose publication is pending mirrors its search rows' status and hands its changes to the caller on the pending error, so the blacklist sweep, dedup_resolve and conflicts.resolve announce them and finish what they owe before answering it. memory.import decides what to skip from the authority's heads. memory.search_trace waits at the search barrier; a tier whose check fails leaves its rows out. The decision-record statement has a corpus case under both authorities and an integration test under Postgres. Test fakes take the bulk options #161 added.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants