Skip to content

chore(release): v4.8.0 — Multilingual Foundation + Zero-Downtime Reindex - #154

Merged
lyonzin merged 5 commits into
masterfrom
release/v4.8.0
Aug 7, 2026
Merged

lyonzin merged 5 commits into
masterfrom
release/v4.8.0

Conversation

@lyonzin

@lyonzin lyonzin commented Aug 7, 2026 •

Copy link
Copy Markdown
Owner

Resumo executivo

v4.8.0 é a release de fundação que habilita migração pra embeddings multilingual (intfloat/multilingual-e5-large) sem downtime e sem breaking change. Sete fases entregaram security wire, embedding profiles, GPU auto-detect, batch/parallel indexing, resume checkpoint, dual-collection swap zero-downtime, e refactor pra manter complexidade Radon C+.

Zero breaking change: usuário que fizer pip install -U knowledge-rag sem tocar em config.yaml continua com bge-small-en-v1.5 byte-for-byte.

Fases entregues + PRs

Fase PR Escopo
0.5 #147 Security wire (path traversal x5 + prompt injection URL + bearer auth HTTP transports) + BM25 unicode tokenizer
1 #148 Embedding profile + query_prefix/passage_prefix opt-in
2 #149 GPU tri-state auto default + 4-check probe + banner
3 #150 batch_size + parallel_workers config + fix max_results asymmetry (20→100)
4 #151 Reindex checkpoint + resume=True + granular progress fields
5 #152 Zero-downtime nuclear_rebuild(swap=True) via staging collection swap
6 #153 Hotspot decomposition — 40+ helpers extraídos, complexidade D→C

Métricas mensuráveis

  • Recall@10: +1.88pp em benchmark A/B do repo (p<0.001) com multilingual-e5-large; ~+4pp em queries PT-BR (medido antes do release, ver _research/).
  • GPU rebuild time: ~5-8min corpus 3000-4000 docs (RTX 3080 Ti CUDA 12) vs ~40-60min CPU.
  • Storage overhead durante nuclear_rebuild(swap=True): 2x temporário → 1x pós-swap.
  • Complexity: Radon média D (23.4) → C (17.2) na superfície F1-F5. Zero D+ remanescente.
  • Security: 7 vetores fechados que eram latent desde v4.5.1 (primitives existiam, callers nunca wireados).

Migration guide

Full guide: `docs/migration-v4.8.0.md` — TL;DR + FAQ + rollback.

Opt-in quick refs:

  • Multilingual: `profile: "multilingual"` + `reindex_documents(force=True)`
  • GPU auto: novo default (`gpu: "auto"` tri-state), overhead ~500ms-2s em máquinas sem GPU
  • Batch/parallel: `documents.batch_size` + `documents.parallel_workers`
  • Resume: `reindex_documents(force=True, resume=True)`

Test evidence

Suite completa rodada em 6 chunks isolados na branch release:

Chunk Arquivos Passed Xfailed
1 test_config + test_embedding_profile + test_gpu_auto 38 0
2 test_batch_parallel + test_reindex_resume + test_swap_zero_downtime 57 0
3 test_backwards_compat + test_bm25_unicode_tokenizer + test_bm25_tokenizer_fragment 46 0
4 test_search + test_dedup + test_ingestion + test_ingestion_property 64 0
5 test_lazy_embeddings + test_reranker_fallback + test_tools 35 0
6 tests/security/ 143 8
TOTAL — 383 8

Zero failed. Xfaileds em security são gaps conhecidos de symlink handling + wrap-external-source semantic — não são regressões (herdados do master pré-release).

Commits nesta release

  • `0dd28ec` docs(changelog): consolidate Unreleased into v4.8.0
  • `80f4e13` docs(migration): v4.8.0 upgrade guide + FAQ + rollback
  • `627912e` chore(api-surface): regenerate baseline (additive: security module + kwargs novos)
  • `51aa46f` chore(release): bump version to 4.8.0 (pyproject.toml + mcp_server/init.py + npm/package.json)

Test plan

  • Suite completa em 6 chunks — 383 passed / 8 xfailed / 0 failed
  • Version sync validado via `scripts/check_version_sync.py` — 3/3 arquivos em 4.8.0
  • API surface baseline regenerated — diff é additive-only
  • CHANGELOG consolidado sem perda de entries F0.5-F6
  • Migration guide inclui rollback path pra usuário que reindexou com multilingual e queira voltar pra 4.7.1
  • Post-merge: tag v4.8.0 pushed → dispara release.yml (PyPI Trusted Publishing + NPM + Docker)

Summary by CodeRabbit

  • New Features

    • Added multilingual embedding profiles with opt-in migration support.
    • Added GPU auto-detection and configurable parallel indexing.
    • Added detailed reindexing progress, ETA reporting, and resume checkpoints.
    • Added zero-downtime collection rebuilding and swapping.
    • Added security protections, including authentication, path validation, and content sanitization.
    • Improved BM25 candidate-pool handling.
  • Documentation

    • Added the v4.8.0 changelog and Portuguese migration guide, including compatibility, rollback, and upgrade guidance.
  • Release

    • Updated the project to version 4.8.0.

Greptile Summary

The PR prepares the v4.8.0 release metadata and documentation for multilingual embeddings, resumable indexing, GPU auto-detection, and zero-downtime collection swaps.

  • Bumps Python and npm package versions to 4.8.0 and regenerates the public API baseline.
  • Adds the v4.8.0 migration and rollback guide.
  • Updates release notes, tests, benchmarks, and formatting across supporting files.

Confidence Score: 4/5

The PR is not yet safe to merge because the rollback guide can target the wrong database or delete unrelated collections, and the running MCP server still advertises the old release version.

The documented cleanup continues to use a misspelled, non-configurable database path and an ownership-blind substring deletion rule, while the MCP constructor remains hard-coded to 4.6.0 despite the 4.8.0 package bump; these previously reported defects need correction before release.

Files Needing Attention: docs/migration-v4.8.0.md, mcp_server/server.py

Important Files Changed

Filename Overview
docs/migration-v4.8.0.md Adds the release migration and rollback guide; previously reported rollback cleanup defects remain unresolved.
mcp_server/init.py Bumps the package version to 4.8.0, but the previously reported independent server metadata version remains stale.
mcp_server/server.py Primarily reformats existing server code while retaining the release functionality represented by the regenerated API baseline.
pyproject.toml Updates the Python package version to 4.8.0.
npm/package.json Updates the npm package version to 4.8.0.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  C[Compact 384D collection] --> P[Select multilingual profile]
  P --> D[Startup dimension check]
  D --> S[Build staging collection at 1024D]
  S --> V[Validate staging]
  V --> W[Swap staging into production]
  W --> M[Serve multilingual queries]
Loading

Reviews (2): Last reviewed commit: "chore(lint): ruff --fix + ruff format on..." | Re-trigger Greptile

@coderabbitai

coderabbitai Bot commented Aug 7, 2026 •

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

This release updates the public API baseline with security and indexing parameters, adds v4.8.0 migration documentation, records the changelog entry, and synchronizes Python and npm package versions.

Changes

v4.8.0 release surface

Layer / File(s) Summary
Security and indexing API contracts
.github/api-surface-baseline.json
Adds the public mcp_server.security API and optional parameters for external content, resumable indexing, collection swapping, and document reindexing.
v4.8.0 migration documentation
docs/migration-v4.8.0.md
Documents multilingual embeddings, GPU detection, parallel indexing, resumable reindexing, collection swaps, progress fields, security protections, FAQs, rollback steps, and release phases.
Release changelog and version metadata
README.md, mcp_server/__init__.py, npm/package.json, pyproject.toml
Adds the v4.8.0 changelog entry and updates package versions from 4.7.1 to 4.8.0.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the v4.8.0 release and its two main changes: multilingual support and zero-downtime reindexing.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch release/v4.8.0

Comment @coderabbitai help to get the list of available commands.

Comment thread docs/migration-v4.8.0.md
Comment on lines +23 to +25
```python
reindex_documents(force=True)
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Smart reindex breaks dimension migration

When an existing 384D installation switches to the 1024D multilingual profile, the documented reindex_documents(force=True) selects an in-place smart reindex rather than a fresh collection rebuild, causing Chroma to reject the new vectors with a dimension mismatch.

Prompt To Fix With AI
This is a comment left during a code review.
Path: docs/migration-v4.8.0.md
Line: 23-25

Comment:
**Smart reindex breaks dimension migration**

When an existing 384D installation switches to the 1024D multilingual profile, the documented `reindex_documents(force=True)` selects an in-place smart reindex rather than a fresh collection rebuild, causing Chroma to reject the new vectors with a dimension mismatch.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code

Comment thread docs/migration-v4.8.0.md Resolved
Comment thread docs/migration-v4.8.0.md
Comment on lines +169 to +171
for col in client.list_collections():
if "__staging_" in col.name:
client.delete_collection(name=col.name)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Cleanup overmatches collection names

When another legitimate collection contains __staging_ in its name, this broad substring test deletes it even though it is unrelated to the production collection, causing permanent data loss; the application cleanup instead matches the configured ${collection_name}__staging_ prefix.

Prompt To Fix With AI
This is a comment left during a code review.
Path: docs/migration-v4.8.0.md
Line: 169-171

Comment:
**Cleanup overmatches collection names**

When another legitimate collection contains `__staging_` in its name, this broad substring test deletes it even though it is unrelated to the production collection, causing permanent data loss; the application cleanup instead matches the configured `${collection_name}__staging_` prefix.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code

Comment thread mcp_server/__init__.py
sys.stdout = sys.stderr

__version__ = "4.7.1"
__version__ = "4.8.0"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 MCP server version remains stale

The package version is bumped to 4.8.0, but the MCP server constructor still independently advertises version="4.6.0", causing clients to identify the shipped 4.8.0 server as 4.6.0 while the version-sync check continues to pass.

Prompt To Fix With AI
This is a comment left during a code review.
Path: mcp_server/__init__.py
Line: 11

Comment:
**MCP server version remains stale**

The package version is bumped to 4.8.0, but the MCP server constructor still independently advertises `version="4.6.0"`, causing clients to identify the shipped 4.8.0 server as 4.6.0 while the version-sync check continues to pass.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/migration-v4.8.0.md`:
- Line 133: Update the “Canal de report privado” entry in the migration
documentation to use a repository-specific clickable Security Advisory URL or
link directly to SECURITY.md, replacing the host-root `/security/advisories/new`
path while preserving the configured private reporting channel.
- Line 130: Update the migration table row for “Prompt injection via
add_from_url” to remove literal pipe characters from the cell, or move the
sentinel examples such as <|im_start|> below the table. Preserve the fix
description while ensuring the row remains valid Markdown with the intended
columns.
- Around line 5-8: Update the MCP tools compatibility bullet in the migration
document to state that existing calls remain compatible while public signatures
may include new optional parameters, including resume in reindex_documents;
remove the claim that signatures are preserved byte-for-byte.
- Around line 103-105: The migration documentation must describe the cutover as
staged and non-transactional: at docs/migration-v4.8.0.md lines 103-105, replace
“atomic two-step swap,” specify the query source during populate/validation, and
document the failure state after each rename, including production being absent
if the process stops after moving prod to __old_{ts}; at lines 147-151, state
that individual renames are atomic but crash recovery does not guarantee
production availability, and remove “Zero corrupção.”

In `@README.md`:
- Around line 1419-1423: Clarify the v4.8.0 release notes by defining the test
scope associated with each reported result—383 passed/8 xfailed and 557 passed/3
skipped/9 xfailed—or replace them with one authoritative result. Update the
v4.8.0 changelog entry without changing its implementation or migration details.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: e8507895-f39e-4697-9c2b-caee7e31dcf3

📥 Commits

Reviewing files that changed from the base of the PR and between 2f41e26 and 51aa46f.

📒 Files selected for processing (6)
  • .github/api-surface-baseline.json
  • README.md
  • docs/migration-v4.8.0.md
  • mcp_server/__init__.py
  • npm/package.json
  • pyproject.toml

Comment thread docs/migration-v4.8.0.md
Comment on lines +5 to +8
- **`pip install -U knowledge-rag`** — comportamento idêntico à v4.7.1 se você não tocar em `config.yaml`. Zero ação necessária.
- **Opt-in features** requerem edits em `config.yaml` + reindex.
- **Nenhum breaking change.** Assinaturas das MCP tools preservadas byte-for-byte.
- **Ganho principal (multilingual)**: +1.88pp Recall@10 medido no benchmark A/B do repo (p<0.001) e ~+4pp em queries PT-BR.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Correct the signature compatibility statement.

Line 7 says that MCP tool signatures are preserved byte-for-byte. The public API baseline adds optional parameters, including reindex_documents(..., resume=...). Existing calls remain compatible, but the signatures changed.

Proposed wording
- **Nenhum breaking change.** Assinaturas das MCP tools preservadas byte-for-byte.
+ **Nenhum breaking change para chamadas existentes.** A v4.8.0 adiciona parâmetros opcionais às APIs públicas.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- **`pip install -U knowledge-rag`** — comportamento idêntico à v4.7.1 se você não tocar em `config.yaml`. Zero ação necessária.
- **Opt-in features** requerem edits em `config.yaml` + reindex.
- **Nenhum breaking change.** Assinaturas das MCP tools preservadas byte-for-byte.
- **Ganho principal (multilingual)**: +1.88pp Recall@10 medido no benchmark A/B do repo (p<0.001) e ~+4pp em queries PT-BR.
- **`pip install -U knowledge-rag`** — comportamento idêntico à v4.7.1 se você não tocar em `config.yaml`. Zero ação necessária.
- **Opt-in features** requerem edits em `config.yaml` + reindex.
- **Nenhum breaking change para chamadas existentes.** A v4.8.0 adiciona parâmetros opcionais às APIs públicas.
- **Ganho principal (multilingual)**: +1.88pp Recall@10 medido no benchmark A/B do repo (p<0.001) e ~+4pp em queries PT-BR.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/migration-v4.8.0.md` around lines 5 - 8, Update the MCP tools
compatibility bullet in the migration document to state that existing calls
remain compatible while public signatures may include new optional parameters,
including resume in reindex_documents; remove the claim that signatures are
preserved byte-for-byte.

Comment thread docs/migration-v4.8.0.md
Comment on lines +103 to +105
**v4.8.0**: `nuclear_rebuild(swap=True)` (novo default) cria staging collection timestamped → popula → valida três gates (`count >= baseline * 0.9`, 4 de 5 queries canônicas retornam hits, `query()` não raise) → atomic two-step swap via `Collection.modify(name=)` → delete old collection.

Queries continuam servindo da collection antiga durante toda a populate/validate phase. Janela de risco no swap em si: microssegundos entre `rename staging → prod_new` e `delete prod_old`. Se falhar aí, `_cleanup_stale_staging_collections()` do próximo boot resolve orphans (>24h TTL).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

printf '%s\n' '--- target document ---'
sed -n '90,160p' docs/migration-v4.8.0.md
printf '%s\n' '--- related identifiers ---'
rg -n "_cleanup_stale_staging_collections|nuclear_rebuild|Collection\.modify|staging_" . --glob '!node_modules' --glob '!dist' --glob '!build'

Repository: lyonzin/knowledge-rag

Length of output: 20664


🏁 Script executed:

printf '%s\n' '--- cleanup and swap implementation ---'
sed -n '1935,2195p' mcp_server/server.py
printf '%s\n' '--- rebuild implementation ---'
sed -n '2195,2345p' mcp_server/server.py
printf '%s\n' '--- operational documentation ---'
sed -n '86,125p' docs/reindex-operations.md
printf '%s\n' '--- swap tests around failure handling ---'
sed -n '270,380p' tests/test_swap_zero_downtime.py

Repository: lyonzin/knowledge-rag

Length of output: 24684


🏁 Script executed:

printf '%s\n' '--- query path and rebind behavior ---'
rg -n "def query|self\.collection|_populate_staging|_swap_collections_atomic|_rollback_and_cleanup_staging" mcp_server/server.py | head -80
sed -n '1500,1655p' mcp_server/server.py
printf '%s\n' '--- complete swap-related tests ---'
sed -n '1,80p' tests/test_swap_zero_downtime.py
sed -n '380,500p' tests/test_swap_zero_downtime.py
printf '%s\n' '--- AST call-sequence verifier ---'
python3 - <<'PY'
import ast
from pathlib import Path

path = Path("mcp_server/server.py")
tree = ast.parse(path.read_text())
methods = {}
for node in ast.walk(tree):
    if isinstance(node, (ast.FunctionDef, ast.AsyncFunctionDef)):
        methods[node.name] = node

for name in (
    "_swap_collections_atomic",
    "_promote_staging_or_rollback",
    "_rebuild_via_swap",
    "_rollback_and_cleanup_staging",
):
    node = methods[name]
    calls = []
    for child in ast.walk(node):
        if isinstance(child, ast.Call):
            fn = child.func
            if isinstance(fn, ast.Attribute):
                target = ast.unparse(fn)
            elif isinstance(fn, ast.Name):
                target = fn.id
            else:
                target = ast.unparse(fn)
            calls.append((child.lineno, target))
    print(name)
    for lineno, target in sorted(calls):
        print(f"  {lineno}: {target}")
PY

Repository: lyonzin/knowledge-rag

Length of output: 16361


🏁 Script executed:

sed -n '2345,2505p' mcp_server/server.py
printf '%s\n' '--- fake client rename/delete semantics used by tests ---'
sed -n '70,155p' tests/test_swap_zero_downtime.py
printf '%s\n' '--- all swap wording in the affected documentation ---'
rg -n -C 2 "atomic|swap|staging|old|rollback|corrup" docs/migration-v4.8.0.md docs/reindex-operations.md

Repository: lyonzin/knowledge-rag

Length of output: 23029


Document the cutover as non-transactional and correct the recovery guarantee.

Collection.modify(name=...) is atomic per call, but _swap_collections_atomic uses separate renames and a non-fatal delete. If the process stops after prod → __old_{ts}, the production name is absent; _cleanup_stale_staging_collections() does not restore __old_{ts}. Also, _populate_staging rebinds self.collection, so orchestrator queries do not use the old collection throughout populate and validation.

  • docs/migration-v4.8.0.md#L103-L105: Replace “atomic two-step swap” with “staged cutover” and describe the query source and failure state for each step.
  • docs/migration-v4.8.0.md#L147-L151: State that individual renames are atomic, but crash recovery does not guarantee production availability. Remove “Zero corrupção”.
📍 Affects 1 file
  • docs/migration-v4.8.0.md#L103-L105 (this comment)
  • docs/migration-v4.8.0.md#L147-L151
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/migration-v4.8.0.md` around lines 103 - 105, The migration documentation
must describe the cutover as staged and non-transactional: at
docs/migration-v4.8.0.md lines 103-105, replace “atomic two-step swap,” specify
the query source during populate/validation, and document the failure state
after each rename, including production being absent if the process stops after
moving prod to __old_{ts}; at lines 147-151, state that individual renames are
atomic but crash recovery does not guarantee production availability, and remove
“Zero corrupção.”

Comment thread docs/migration-v4.8.0.md
| Vetor | Fix |
|---|---|
| Path traversal em 5 tools (`get_document`, `add_document_from_content`, `update_document_content`, `remove_document_by_path`, `search_similar`) | `validate_path_within` na entrada; retorno estruturado `{"error": "Filepath rejected: ..."}` |
| Prompt injection via `add_from_url` (OWASP LLM01:2025) | `sanitize_external_content` no body fetched; provenance envelope + defuse de sentinels (`<|im_start|>`, `[INST]`, etc.) |

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Fix the Markdown table delimiter collision.

The literal | characters in <|im_start|> make this row parse as four table cells. The fix description can render incorrectly or be truncated. Move sentinel examples below the table, or remove literal pipe characters from the table cell.

🧰 Tools
🪛 markdownlint-cli2 (0.23.2)

[warning] 130-130: Spaces inside code span elements

(MD038, no-space-in-code)


[warning] 130-130: Table column count
Expected: 2; Actual: 4; Too many cells, extra data will be missing

(MD056, table-column-count)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/migration-v4.8.0.md` at line 130, Update the migration table row for
“Prompt injection via add_from_url” to remove literal pipe characters from the
cell, or move the sentinel examples such as <|im_start|> below the table.
Preserve the fix description while ensuring the row remains valid Markdown with
the intended columns.

Source: Linters/SAST tools

Comment thread docs/migration-v4.8.0.md
| Prompt injection via `add_from_url` (OWASP LLM01:2025) | `sanitize_external_content` no body fetched; provenance envelope + defuse de sentinels (`<|im_start|>`, `[INST]`, etc.) |
| Auth bypass em HTTP transports (`sse`, `streamable-http`) | `BearerAuthMiddleware` na ASGI app do FastMCP quando `config.auth_bearer_token` set; token unset → `[WARN]` + comportamento aberto legacy |

Canal de report privado: **GitHub Security Advisory form** — `/security/advisories/new` (Private Vulnerability Reporting habilitado no repo). `SECURITY.md` atualizado.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Use a repository-specific vulnerability-reporting link.

/security/advisories/new is a host-root path and is not a clickable repository advisory link. Point users to this repository’s Security Advisory form, or to SECURITY.md, so reports reach the configured private reporting channel.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/migration-v4.8.0.md` at line 133, Update the “Canal de report privado”
entry in the migration documentation to use a repository-specific clickable
Security Advisory URL or link directly to SECURITY.md, replacing the host-root
`/security/advisories/new` path while preserving the configured private
reporting channel.

Comment thread README.md
Comment on lines +1419 to +1423
### v4.8.0 (2026-08-06) — Multilingual Foundation + Zero-Downtime Reindex

v4.8.0 é a release de fundação para migração pra embeddings multilingual (`intfloat/multilingual-e5-large`) sem forçar downtime nem breaking change. Sete fases entregaram: security wire (7 vetores fechados que existiam desde v4.5.1), embedding profiles com prefix opt-in, GPU auto-detect com dependency chain documentada, batch/parallel indexing configurável + fix da assimetria BM25/semantic candidate pool, progress granular + resume checkpoint, dual-collection swap zero-downtime, e refactor pra manter complexidade Radon C+ na superfície tocada.

Zero breaking change: usuários que atualizarem SEM tocar em `config.yaml` continuam com `bge-small-en-v1.5` byte-for-byte. Opt-in para multilingual: `profile: "multilingual"` + `reindex_documents(force=True)` — durante o reindex, RAG continua servindo da collection antiga (zero downtime via staging swap). Detalhes de upgrade em `docs/migration-v4.8.0.md`.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- README v4.8.0 section ---'
sed -n '1408,1430p' README.md

printf '%s\n' '--- Repository files mentioning the reported test totals ---'
rg -n -i --glob '!node_modules' --glob '!dist' --glob '!build' \
  '383|8 expected|full sweep|v4\.8\.0|passed|expected failures' .

printf '%s\n' '--- Recent tracked files relevant to release notes and test reports ---'
git ls-files | rg -i '(^|/)(README\.md|.*(migration|release|test|report|objective|summary).*)$' | head -200

Repository: lyonzin/knowledge-rag

Length of output: 39060


🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- Refactor audit test-result context ---'
sed -n '1,220p' docs/refactor-audit-v4.8.0-fase-6.md

printf '%s\n' '--- Test-count baseline and test-count checker ---'
cat .github/test-count-baseline.txt
sed -n '1,220p' scripts/check_test_count.py

printf '%s\n' '--- Repository and branch metadata ---'
git remote -v
git branch --show-current
git status --short
git log -1 --format='%H%n%s'

printf '%s\n' '--- Current pull-request metadata, when available ---'
if command -v gh >/dev/null 2>&1; then
  gh pr view --json number,title,body,headRefName,baseRefName 2>/dev/null || true
fi

Repository: lyonzin/knowledge-rag

Length of output: 9719


🏁 Script executed:

#!/bin/bash
set -eu

repo='lyonzin/knowledge-rag'
sha='51aa46f47a347d3262c7876cb3ba87464eecd70d'

if command -v gh >/dev/null 2>&1; then
  printf '%s\n' '--- Pull requests associated with the release commit ---'
  gh api "repos/$repo/commits/$sha/pulls" \
    --header 'Accept: application/vnd.github+json' \
    --jq '.[] | {number, title, body, state, head: .head.ref, base: .base.ref}' \
    2>/dev/null || true

  printf '%s\n' '--- Commit message and check summaries ---'
  gh api "repos/$repo/commits/$sha" \
    --header 'Accept: application/vnd.github+json' \
    --jq '{sha: .sha, message: .commit.message, checks: [.check_runs[]? | {name, conclusion, status}]}' \
    2>/dev/null || true
fi

Repository: lyonzin/knowledge-rag

Length of output: 5385


Clarify the v4.8.0 test-result scope before merge.

The release PR reports 383 passed / 8 xfailed / 0 failed across six chunks. The changelog reports 557 passed / 3 skipped / 9 xfailed / 0 failed for a broader sweep. State the scope of each result, or use one authoritative result.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 1419 - 1423, Clarify the v4.8.0 release notes by
defining the test scope associated with each reported result—383 passed/8
xfailed and 557 passed/3 skipped/9 xfailed—or replace them with one
authoritative result. Update the v4.8.0 changelog entry without changing its
implementation or migration details.

@greptile-apps

greptile-apps Bot commented Aug 7, 2026

Copy link
Copy Markdown

Want your agent to iterate on Greptile's feedback? Start a greploop in Claude Code and it will work through the open comments and keep going until this PR reviews clean.

@lyonzin
lyonzin merged commit 894c569 into master Aug 7, 2026
38 checks passed
@lyonzin
lyonzin deleted the release/v4.8.0 branch August 7, 2026 00:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant