feat: unify snapshot and incremental Sourcerer indexing - #2
Draft
simianhacker wants to merge 1 commit into
Draft
Conversation
- add ref-addressed incremental branch updates under the v1 schema - use union mappings and mode-scoped Agent Builder queries without anchors - preserve snapshot retention while making orphan cleanup mode-aware - cover setup, updates, retries, deletions, and mixed-mode tool behavior
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
Adds an opt-in incremental update mode for moving branches while keeping immutable snapshot indexing for exact commits. Both modes now share the real
sourcerer-v1-*indices, with mode-specific identity, safe query scoping, and no v2 or empty schema-anchor indices.How to Verify
uv run pytest -qand confirm all tests pass.uv buildand confirm both distributions build.ctx exec local-dev -- uv run sourcerer setuptwice; confirm only the 3 v1 templates and the real v1 refs lookup index exist.simianhacker/code-intelligence-indexeratfb82dea8cff67862268bc019877ea9ec5dcbecd3.elastic/serverless-gitopsbranchmainwithupdate: incremental.sourcerer.*tool throughPOST /api/agent_builder/tools/_executein snapshot and incremental scopes; confirm no unknown-column errors and returned rows carry the scoped org, repo, and completed commit.Breaking Changes
Existing Sourcerer POC indices must be rebuilt before setup because the v1 mappings and refs index mode changed. This temporary POC does not include migration compatibility.