Skip to content

fix(docs): map live VectorRAG result shapes - #5960

Draft
RaresKeY wants to merge 1 commit into
odysseus-dev:devfrom
RaresKeY:fix/docs-vectorrag-contract
Draft

fix(docs): map live VectorRAG result shapes#5960
RaresKeY wants to merge 1 commit into
odysseus-dev:devfrom
RaresKeY:fix/docs-vectorrag-contract

Conversation

@RaresKeY

@RaresKeY RaresKeY commented Aug 8, 2026

Copy link
Copy Markdown
Member

Summary

Map the live VectorRAG query and indexing result shapes into the existing DocsService contract. Query results now read canonical document text, similarity, and source metadata while retaining legacy aliases, malformed rows are skipped safely, and indexing reports use the canonical indexed/failed counts. This updates the service facade without adding a new runtime route.

Target branch

  • This PR targets dev, not main. All PRs land in dev; main is curated by the maintainer at each release. If your PR is on main by accident, click "Edit" on this PR and change the base.

Linked Issue

Fixes #5949

Part of #4377

Related: #5794

Type of Change

  • Bug fix (non-breaking — fixes a confirmed issue)
  • New feature (non-breaking — adds new behaviour)
  • Breaking change (changes or removes existing behaviour)
  • Refactor / cleanup (behaviour unchanged)
  • Documentation only
  • CI / tooling / configuration

Checklist

  • I searched open issues and open PRs — this is not a duplicate.
  • This PR targets dev
  • My changes are limited to the scope described above — no unrelated refactors or whitespace changes mixed in.
  • I actually ran the app (docker compose up or uvicorn app:app) and verified the change works end-to-end. Type-checks and unit tests are not enough.

The facade mapping is covered by focused tests, but no live Chroma-backed application consumer has been exercised.

How to Test

  1. Run python -m pytest -q tests/test_docs_query_nondict_rows.py tests/test_rag_search_signature.py tests/test_rag_manager_owner_compat.py tests/test_rag_keyword_fallback_owner.py; the validated head reports 6 passing tests and one warning.
  2. Feed DocsService canonical query rows containing document, similarity, and metadata.source, and verify the returned service result preserves those values.
  3. Feed legacy aliases and malformed/non-dictionary rows, and verify legacy data remains accepted while malformed rows are skipped.
  4. Feed canonical indexing results containing indexed_count and failed_count, and verify the service report uses those counters.
  5. If a live consumer is enabled, repeat query and indexing operations against Chroma before publication.

Visual / UI changes — REQUIRED if you touched anything that renders

Anything that changes what the UI looks like — buttons, icons, padding, colors, fonts, spacing, layout, CSS, HTML, SVG, or any static/js/ module that draws to the DOM — needs all of the following. PRs that change rendering without these WILL be closed.

N/A — no rendered UI files or routes are changed.

  • Screenshot or short clip of the change in the running app, attached below. Mobile screenshot too if the change affects mobile.
  • Style match: the change uses Odysseus's existing visual language. Specifically:
    • Reuse existing CSS variables (--red, --fg, --bg, --card, --border, etc.) — do not introduce new color values, font sizes, or spacing units.
    • Reuse existing button/input/card/border classes. Don't invent parallel styling.
    • No Unicode emoji in UI or code. Use inline SVG (matching the monochrome icon style already in static/index.html) or plain text.
    • Monospaced font (Fira Code) for primary UI text. Don't override.
    • Dark theme is the default; any light-mode work must be wired through the existing theme system, not hard-coded.
  • No new component patterns. If a similar widget already exists in the app, extend it instead of writing a parallel one.
  • I am not an LLM agent submitting a bulk PR. If you are, please open an issue describing the problem first — bulk auto-generated PRs that don't match the project's visual style are closed on sight, even when the underlying fix is correct.

Screenshots / clips

N/A — no rendered UI files changed.

@github-actions github-actions Bot added the ready for review Description complete — ready for maintainer review label Aug 8, 2026
@RaresKeY
RaresKeY force-pushed the fix/docs-vectorrag-contract branch from d196405 to f3d911b Compare August 9, 2026 00:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready for review Description complete — ready for maintainer review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DocsService drops live VectorRAG result fields

1 participant