Conversation
… phase 2) (#431) * feat(rag): bilingual dora kb — labeled french working translation (#424 p2) french users now get regulation snippets in french, not just a french answer over english source text. the kb is seeded in both languages and retrieval prefers the user's locale, falling back to english when a french chunk is missing. - translateComplianceKb: generates dora-articles.fr.json (working llm translation), flagged official:false with an eur-lex disclaimer + source url - seedComplianceKb: loads en + fr files, tags each chunk metadata.lang / official - complianceKbRetriever: language-filtered search (fr -> en -> unfiltered fallback), carries metadata.official through to the source object - contextFormatter.formatSources: prefer metadata.url over the 'regulation' category tag (this also makes phase 1's eur-lex link actually reach the ui) + expose official - frontend: Source.official type + a "working translation" badge on unofficial chunks, en/fr i18n strings - unit tests: lang filter + en fallback, url precedence, official flag pass-through the french text is a labeled non-official working translation; the authoritative text stays the official eur-lex french version, linked on every citation. * ci: correct compliance kb seed comment to 116 entries (58 en + 58 fr)
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
5 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.
Promotes #424 phase 2 to production (squash-merged to dev in #431).
What ships
dora-articles.fr.json, 58 entries) — a labeled, non-official working translation.formatSourcesnow prefersmetadata.urlover the'regulation'category tag — this also retroactively fixes phase 1's EUR-Lex link, which was being shadowed and never reached the UI.Trust
The authoritative text remains the official EUR-Lex French version, linked on every citation. The machine translation is never presented as the regulation itself.
Deploy
CD re-seeds
compliance_kbautomatically (smart-sync, detached): point count 58 → 116 triggers a re-embed (~20 min, non-blocking). No manual ops step.All CI green on #431 (backend, frontend, E2E, docker build, security audit).