Skip to content

Releases

v4.0.0

Choose a tag to compare

@StressTestor StressTestor released this 30 Jul 18:10
12c8ef1

upgrading

your existing database will refuse to search until you convert it. vectors are now
normalised on write and similarity is derived as 1 - d^2/2, so a store written by 3.x holds
raw vectors that the new formula would read as confidently wrong similarities. search() throws
with an actionable message rather than answering. two ways out:

prism re-embed          # re-embeds and stamps the new geometry

or call backfillVectorGeometry() to normalise in place without re-embedding, which is fast and
does not touch your provider.

cluster counts change enormously. on a 5285-item corpus at the same 0.85 threshold, 26
clusters became 501. that is the bug below being fixed, not a threshold change. anything
consuming the JSON, or acting on the counts, will see roughly 20x more clusters from the same
input. any cluster count you recorded from 3.x on a corpus of 5000+ items is not comparable.

breaking API changes for anyone importing the library rather than using the CLI:

  • RepoConfig gains required incidents and cluster
  • WeeklyDigestConfig loses similarityThreshold and autoClose (the first is now read per
    repo, the second had no reader)
  • itemMetadata() returns a named ItemMetadata type instead of Record<string, unknown>
  • VectorStore's fourth constructor argument is an options object
  • statePriority() ranks four tiers instead of three

fixed

  • duplicate detection was finding a fraction of the duplicates on any corpus of 5000+ items.
    three compounding bugs. the vec0 table is declared without a distance metric, so sqlite-vec
    returns L2, but store.search filtered 1 - distance >= threshold, which is not cosine at any
    scale. nothing normalised vectors on write, so that conversion was not valid to attempt anyway.
    and cluster.ts routed 5000+ items through a candidate-limited path that passed the clustering
    threshold into that same wrong-scale filter, then truncated whatever survived to K=50. measured
    on a real 5285-item corpus: 26 clusters found where exact pairwise finds 501, and the
    "optimisation" was slower (20.6s against 9.3s). vectors are normalised on write, similarity is
    derived, and the candidate-limited path is gone: vec0 KNN is itself a full scan with a LIMIT,
    so there was never an index to approximate with. closes #19
  • the webhook path no longer overwrites what a scan learned. server/triage.ts wrote
    metadata: { author, state } wholesale, and because upsert replaces metadata_json outright,
    a pull_request.opened webhook draining after a backlog scan dropped every other field the scan
    had stored (labels, diff size, ci status, closing refs, authorIsBot). it now writes only the
    fields the event can actually observe and leaves the rest of the row alone
  • the weekly digest reads per-repo settings instead of a global copy. it was passed
    DEFAULT_REPO_CONFIG.similarityThreshold and clustered every repo at the default, ignoring
    whatever that repo had configured, so its cluster counts disagreed with the backlog scan's for
    the same repo
  • one unusable config.json no longer aborts the whole installation loop. a repo whose config
    cannot be honoured is skipped loudly and by name; the repos after it in the list still get
    scanned

changed

  • incident-closed PRs rank between open and closed rather than as fully open. an item closed by
    a repository-wide event never got a maintainer verdict, so it outranks a deliberate close, but it
    is not evidence of live work the way an open PR is. on the corpus this was built for the tiers
    are 993 open / 1347 merged / 2945 closed, so promoting a ~900-item incident to open-equivalent
    roughly doubled the tier the ranking exists to order
  • bot-authored items are excluded from clustering by default. automation reuses titles for
    unrelated content, so consecutive bot PRs embed as near-identical and surfaced as duplicates
    nobody could act on. set cluster.include_bot_authors: true to restore the old behaviour, or
    list repo-specific automation under cluster.bot_authors. applies to confirmed (identity)
    clusters and to the App's webhook triage, which previously commented on a bot's PR telling it
    the bot had duplicated itself
  • the server/GitHub-App path honours incident windows and the cluster block, declared per repo
    in that repo's config.json. key names follow each file's own convention: the CLI's yaml uses
    cluster.bot_authors / cluster.include_bot_authors, the App's json uses cluster.botAuthors /
    cluster.includeBotAuthors. closes #27
  • confirmed (identity) duplicate clusters pick canonical by earliest-created instead of quality
    score: byte-identical duplicates are a which-was-first question, and a copied PR can outscore the
    original it was lifted from. fuzzy clusters keep the state/CI/score rule

added

  • incident-aware ranking. prism.config.yaml accepts an incidents: list of
    {start, end, reason} windows. a repository-wide event (visibility flip, bulk close, migration)
    closes items for reasons unrelated to their quality, and because selectCanonical() ranks
    lifecycle state before score, those items sank below genuinely-closed siblings, inverting triage
    order for exactly the backlog a maintainer needs. closedAt is captured from both API paths and
    stored in metadata_json (no schema migration); incidentClosed is derived at read time, so
    correcting a window is a config edit rather than a rescan. window bounds require an explicit UTC
    offset and are rejected at load if unparseable or inverted, because an offset-less timestamp
    parses in the host timezone and would select different PRs on a laptop than in CI
  • starmap carries incidentClosed: true on items and on every reference to them (canonical,
    runnerUp, partition, tracker ref and candidates), omitted when false. a consumer contract has to
    accept it in all of those positions
  • starmap items carry createdAt alongside updatedAt, so consumers can reason about
    which-was-first without re-fetching from github
  • scans record authorIsBot from github's own account type (graphql __typename, rest
    user.type) rather than guessing. rows scanned before this field fall back to a login check, so
    bot filtering works without a rescan
  • prism benchmark --out <path> writes a run's results to a chosen file. every run previously
    wrote data/benchmark-results.json, so a second run silently destroyed the first one's numbers
  • prism benchmark --include-bot-authors clusters bot-authored items too, since the benchmark has
    no prism.config.yaml in scope and could otherwise only ever measure the filtered default
  • benchmark results record clusterMembership per model per threshold. cluster counts cannot tell
    you whether a model finding more clusters is catching real duplicates or chaining unrelated
    items, and re-deriving membership means re-embedding the whole corpus
  • embedding models that expect an instruction prefix get one (embeddinggemma).
    EMBEDDING_TEXT_VERSION bumps to 3 so prefixed and unprefixed vectors cannot be mixed. measured
    effect on clustering for this workload: none, kept because it is what the model documents

for contributors

  • server/scheduler.ts builds stored metadata with the shared itemMetadata() instead of its own
    literal, which had drifted behind by three fields
  • a backlog scan fetches closed items only for repos that declare an incident window, bounded by
    the earliest window start. open and closed are fetched separately because since aborts a fetch
    at the first item older than it, so bounding a combined state:"all" call would drop untouched
    open PRs
  • note for existing installs: rows scanned before this release carry no closedAt, and a default
    scan fetches open items only. run prism scan --state all after an incident, or the window
    matches nothing. this is per-incident, not a one-time backfill

v3.1.0

Choose a tag to compare

@github-actions github-actions released this 20 Jul 07:35

What's Changed

  • feat(relations): deterministic PR/issue classification via closing edges by @StressTestor in #21
  • feat: support OpenAI-compatible endpoints by @alteixeira20 in #18

New Contributors

Full Changelog: v3.0.2...v3.1.0

v3.0.2

Choose a tag to compare

@github-actions github-actions released this 15 Jul 07:23
e606690

What's Changed

  • feat(canonical): red CI vetoes bestPick over a green sibling by @StressTestor in #15
  • feat(scorer): failing CI earns no hasTests credit (3.0.2) by @StressTestor in #16

Full Changelog: v3.0.1...v3.0.2

v3.0.1

Choose a tag to compare

@github-actions github-actions released this 13 Jul 09:12
e7da855

What's Changed

Full Changelog: v3.0.0...v3.0.1

v3.0.0

Choose a tag to compare

@github-actions github-actions released this 13 Jul 08:59
d8154bf

What's Changed

  • feat(cluster): confidence tiers, starmap JSON contract, determinism, unified canonical by @StressTestor in #3
  • refactor(confidence): extract shared confidenceTier into src/confidence.ts by @StressTestor in #4
  • fix(canonical): make contested near-tie flag canonical-aware via decideCanonical by @StressTestor in #5
  • feat(init): wire prism init to a real repo with autodetect + verify by @StressTestor in #6
  • feat(canonical): prefer merged PRs as canonical + expose item state in starmap by @StressTestor in #7
  • feat(canonical): tracker substrate (original bug + role-tagged candidates) by @StressTestor in #8
  • security(sanitize): route every title/theme emit through a shared sanitizer by @StressTestor in #9
  • feat(identity): deterministic confirmed-duplicate tier (head-oid / patch-id) by @StressTestor in #10
  • feat(write-gate)!: one dry-run-by-default gate for every GitHub mutation by @StressTestor in #11
  • feat(housekeeping): editable manifest — the triage to-do (no auto-writes) by @StressTestor in #12
  • chore(release): v3.0.0 by @StressTestor in #13

Full Changelog: v2.0.1...v3.0.0

v1.2.0

Choose a tag to compare

@StressTestor StressTestor released this 18 Mar 08:47

benchmark command + nomic-embed-text default + homebrew support

prism benchmark — A/B compare embedding models for duplicate detection quality and speed. auto-pulls missing ollama models, tests at multiple thresholds, outputs speed and cluster overlap tables.

nomic-embed-text default — switched from qwen3-embedding:0.6b. benchmarked on 10K items from sst/opencode: 3.7x faster (791 vs 214 items/min), finds more duplicates (121 vs 110 clusters), 79% overlap with qwen3 at 0.85 threshold. existing configs unaffected.

npm package renamed to prism-triage (pr-prism was taken on npm).

install: brew tap stresstestor/tap && brew install prism-triage

v1.1.0

Choose a tag to compare

@StressTestor StressTestor released this 17 Mar 23:55

hardening + new features. the big ones:

github action — drop StressTestor/pr-prism@main into a workflow and it auto-comments on PRs with duplicate matches. no config needed beyond an embedding API key.

prism compare — quick pairwise similarity check between any two PRs/issues. prism compare 42 99 tells you if they're dupes, related, or unrelated.

docker — docker build -t pr-prism . && docker run --rm --env-file .env pr-prism triage

error handling overhaul — every provider error now tells you what broke, why, and how to fix it. "ollama isn't running. start it with: ollama serve" instead of "TypeError: Cannot read properties of undefined"

pipeline extraction — core pipeline functions are now independently importable. import { runScan, runDupes } from "pr-prism" works for building custom integrations.

author cache — merge counts cached in sqlite with 24hr TTL. repeat rank/triage runs skip ~15s of GitHub API calls.

tests — 78 → 105. added coverage for the LLM reviewer, error classification, and pipeline functions.

fixes

  • embedding API response validation (was crashing on malformed responses)
  • LLM reviewer handles empty/refusal responses
  • SQLite busy_timeout for concurrent access
  • Zod and YAML config errors formatted for humans
  • scoring logic deduplicated between cluster and scorer modules
  • npm audit vulnerability resolved
  • unclosed database handles in triage command
  • multi-repo metadata spreading fixed

full changelog: https://github.com/StressTestor/pr-prism/blob/main/CHANGELOG.md

v1.0.0 — Launch Ready

Choose a tag to compare

@StressTestor StressTestor released this 04 Mar 09:34

pr-prism v1.0.0

first public release. the whole roadmap from v0.9 through v1.0 in one push.

highlights

  • multi-repo support — repos: [a/b, c/d] in config, cross-repo dupe detection with [repo] #123 display
  • per-repo vision docs — different VISION.md per repo via vision_docs: config
  • review storage — reviews persist in db, prism review --top 10 batch mode, --type issue for issues
  • prism stats — per-repo item counts, embedding coverage, model metadata, provider info
  • vision --stats — distribution histogram + section breakdown, screenshot-ready terminal output
  • full prism init — auto-detects ollama models, env var API keys, recommends best provider
  • cluster scoring upgrade — uses full quality signals (tests, CI, diff size, reviews, recency)
  • embedding config tracking — warns when provider/model changes between scans
  • --state all on scan (open + closed items)

v0.9 (credibility + packaging)

  • npm publish readiness (Node >= 20 LTS)
  • GitHub Actions CI (Node 20 + 22 matrix)
  • unified error handling (every error says what, why, and how to fix)
  • embedding crash recovery (resumes from checkpoint)
  • prism doctor diagnostic command
  • --top N, --output markdown, dupes --cluster error handling
  • matryoshka benchmark: 512 dims confirmed safe (91.1% clustering agreement)

stats

  • 78 tests passing
  • 6 embedding providers, 5 LLM providers
  • tested on 6K+ items across real repos
  • zero-cost default stack ($0 to run)

v0.5.0

Choose a tag to compare

@StressTestor StressTestor released this 18 Feb 06:19

what changed

embedding model metadata stored in prism_meta table — switching providers now throws a clear error instead of silently corrupting vectors.

  • re-embed command — switch embedding models without re-scanning github
  • model mismatch detection — changing EMBEDDING_MODEL throws with clear fix instructions
  • config versioning — version: 1 field, forward-compatible schema migrations
  • parseRepo — accepts full github URLs, github.com/o/r, .git suffix
  • init provider detection — probes ollama on init, checks for api keys, pre-fills .env
  • empty state guards — rank/dupes with no data tells you to run scan first
  • threshold 0 bug — --threshold 0 no longer silently ignored
  • biome — lint + format config, unused imports cleaned up
  • publishable — prepare script builds on install, .env.example + prism.config.yaml included in npm tarball
  • cleanup — removed dead listr2 dep, dead --diff flag, dead hasMergeConflicts type field, silently-ignored off_vision threshold

53 tests passing across 9 test files.

v0.4.1 — qwen3-embedding default

Choose a tag to compare

@StressTestor StressTestor released this 18 Feb 04:37

switched default ollama embedding model from mxbai-embed-large to qwen3-embedding:0.6b. bumped local provider batch size from 10 to 50.

tested full pipeline on openclaw/openclaw (7244 items):

  • 674 duplicate clusters (1925 items, ~27%)
  • top 20 PRs scored 0.87-0.91 with real signal differentiation
  • 75 aligned, 3600 drifting, 3569 off-vision
  • ~80 min total embedding time on M1 Air