Open
Conversation
Add explicit score semantics and pre-packaging relevance filtering for memory search, including deterministic regression coverage for noisy direct-fact retrieval with integration-heavy memory sets.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
scorebackward-compatibleMigration / Compatibility
thresholdrequest field is opt-in and always takes precedence when supplied.similarityThresholdas the default normalized relevance floor.rankingMinSimilarity; simple/medium direct-query candidates below that semantic floor are filtered before injection candidate selection, and importance/recency ranking boosts only apply above the same floor. SQL and in-memory scorers clamp this value to[0,1].similarityThresholdis not a universal post-retrieval floor; temporal/current-state phrasing intentionally keeps recency/current-state recall intact.ranking_scoreis a composite ranking/debug value and is not normalized;relevanceis normalized to[0,1]for filtering.Threshold Semantics
threshold/ servicerelevanceThreshold: per-request normalized injection relevance floor. It wins over config defaults and applies unless omitted.similarityThreshold: fallback normalized relevance floor for unscoped simple/medium non-temporal searches when no request threshold is supplied. It is bypassed for recall-preserving query/source/as-of cases.rankingMinSimilarity: retrieval-profile semantic floor for ranking eligibility. It prevents importance/recency boosts below the floor in SQL/in-memory scoring and filters sub-floor simple/medium direct-query candidates before final selection.Validation
npx tsc --noEmitnpm run buildnpm run generate:openapigit diff --checknpm testnpm test -- dual-write-representationsnpm test -- retrieval-policy retrieval-relevance-regression pgvector-smoke dual-write-representationsnpm test -- memory-search-runtime-config retrieval-policy retrieval-relevance-regression pgvector-smoke dual-write-representationsnpm test -- retrieval-policy retrieval-relevance-regression current-state-ranking search-pipeline-runtime-confignpx fallow audit --health-baseline=.fallow/health-baseline.json --dupes-baseline=.fallow/dupes-baseline.json --base=origin/mainnpm test -- retrieval-relevance-regression retrieval-trace memory-search-runtime-config scoped-dispatch search-pipeline-runtime-config namespace-retrieval response-schema-coverage memory-route-config-overrideLinear Scope
Delivered or ready for review in this repo:
precisionAtK >= 0.8) plus exact fixture exclusion checkssemantic_similarity,ranking_score, andrelevancePaired GTM-1113 SDK PRs:
Not closed by this PR: