Files
amethyst/quartz/plans
Claude d571bee394 fix(store): rank multi-filter search REQs + harden merge from branch audit
Two-reviewer adversarial audit of the branch found no correctness/data-loss/
crash bugs. This closes one gap and applies three robustness fixes:

- Multi-filter search ordering: a REQ whose filters all carry a search term
  (e.g. the client's search-across-kinds) was created_at-ordered via the union
  path. Now relevance-ordered — unionSubqueriesIfNeeded(projectRank) projects
  rank per branch, UNION ALL + GROUP BY row_id MIN(rank) dedups across branches
  keeping the best score. Only when every branch is a search branch; mixed
  search/non-search REQs and count/delete unions stay as before.
- prepareAuthorStreams/prepareTagStreams build cursors via buildStreams, which
  closes already-prepared statements if a later prepare throws (was: stranded
  checked-out, un-reset handles holding read locks in the pooled connection).
- Stream counts computed as Long so authors×kinds / values×kinds can't overflow
  Int back into the eligible band and route a huge fan-out into the merge.
- Renamed CachedStatement.finalize() -> finalizeStatement(): a no-arg finalize()
  is the JVM Object.finalize, risking a GC double-close of the native handle.

Tests: multi-filter search relevance + cross-branch dedup + count parity;
existing merge/cache/search suites green.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XqGuBuSUsRudGerPqDuoKA
2026-07-21 23:33:33 +00:00
..

quartz plans

Audited 2026-06-30. 11 plans: 7 shipped (archived), 0 in-progress, 3 queued, 1 closed (negative result).

Queued

Plan Summary
2026-05-08-local-headers-explorer.md Headers-only Bitcoin P2P client to verify NIP-03 OTS attestations without a trusted block explorer.
2026-06-12-giftwrap-deletion-requests.md Let a recipient-authored kind-5 delete/block a gift wrap (kind 1059) addressed to them.
2026-07-03-incremental-negentropy-storage.md Always-current (created_at, id) index so cold NEG-OPENs stop paying a full scan + seal (~340 ms at 50k vs strfry's ~21 ms).
2026-07-04-small-req-floor.md Small-REQ dispatch floor: decomposed, inline fast path tried and reverted (no wire-level win); floor is transport-side.

Archived (shipped)

Plan Summary
archive/2026-06-03-fix-nip46-bunker-double-resume-plan.md Fix NIP-46 bunker double-resume crash and retry id-reuse races via Channel-per-request + fresh id per attempt.
archive/2026-06-04-auth-scope-vs-policy.md Move relay-server authenticated-identity state from the policy into the engine-owned connection scope.
archive/2026-06-09-clink.md Implement CLINK (Offers/Debits/Manage) Lightning-over-Nostr pointers, events, and client/server in Quartz.
archive/2026-06-11-runstr-interop.md RUNSTR kind-1301 workout events and supporting fitness kinds in Quartz plus Amethyst fitness screens.
archive/2026-06-19-napplet-nip5a-resolver.md Platform-agnostic NIP-5A static-site resolver verifying content-addressed Blossom blobs against signed manifests.
archive/2026-06-20-powr-interop.md Parse and render the POWR/NIP-101e kind-1301 strength-workout dialect alongside the existing RUNSTR dialect.
archive/2026-06-28-git-smart-http-browser.md Git smart-HTTP v2 client to browse NIP-34 repo file trees and render source from the clone URL.