Feat/vep 0005 richer scopes#190
Merged
plind-junior merged 2 commits intoJun 16, 2026
Merged
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ff19d86 to
f3ab51c
Compare
3 tasks
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.
What changed
Introduces structured
ArtifactScope(visibility,project,agent) onClaimandSource, plus viewer-context filtering inkb.search,kb.context,vouch search, andvouch context. A newscopingmodule resolves viewer context (request param → env → config) and filters claim/source hits post-retrieval. JSON schemas regenerated;kb.capabilitiesadvertisesscoping.Why
A single flat
scopeenum can't express which project or agent owns an artifact. With multi-agent KBs and deterministic sync, retrieval surfaces unrelated project claims and can't distinguish one agent'sprivatenotes from another's. VEP-0005 defines structured scopes so shared KBs stay usable.Fixes #189
What might break
scope: projectstrings still parse; artifacts rewrite to the object form on next write (lazy migration).projectoragentset see fewer hits (intentional). Default viewer (no project/agent) behaves as before.kb.searchresult shape: Now matches MCP —{backend, viewer, hits}instead of a bare hit list. JSONL clients that expected an array need to readresult.hits.claim/sourcescopechanged from enum string to object.privatefilters retrieval only; artifacts remain plaintext on disk.VEP
VEP-0005: Richer scopes on Claim/Source (draft — should be accepted or marked in-progress before merge)
Tests
make checkpasses locally (lint + mypy + pytest)tests/test_scoping.py; updated JSONL/embedding search tests)CHANGELOG.mdupdated under## [Unreleased]