Repository navigation
Add live wiki diagnostics coverage and read-only compile dry-run API - #837
Open
allenporter wants to merge 1 commit into
Open
allenporter wants to merge 1 commit into
allenporter wants to merge 1 commit into
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #837 +/- ##
==========================================
- Coverage 95.54% 95.51% -0.04%
==========================================
Files 256 256
Lines 27907 28095 +188
==========================================
+ Hits 26665 26835 +170
- Misses 1242 1260 +18 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This branch has not been deployed
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.
Summary
Adds live debugging endpoints so users can inspect why specific notebooks (such as daily journals) are under-cited in their wiki without mutating or rebuilding anything:
GET /api/extended/wiki/diagnostics): Tenant-scoped join of activeUserFileDO+ non-blankNotePageContentDO+ activeWikiSourceRefDO/WikiPageDO, returning each notebook'sfile_id,file_name,ocr_pages,cited_pages,avg_chars_per_page, andcited_slugs, sorted lowest-coverage and largest-notebook first.POST /api/extended/wiki/diagnostics/dry-run): Accepts{file_id?, start_date?, offset_pages?, max_pages?}and runs the exact production pipeline (select_candidate_pages->build_compile_prompt->generate_json->parse_compile_plan) without persisting any changes. Returns the exact pages/OCR snippets sent, candidate slugs, LLMpage_ops, resolved vs. droppedsource_refs, and anydrop_reason(edit_policy,page_cap_exceeded,index_auto_maintained).supernote/models/wiki.py,supernote/client/wiki.py): AddedWikiNotebookCoverageDTO,WikiDiagnosticsResponseVO,WikiDryRunPageDTO,WikiDryRunOpDTO,WikiDryRunResponseVO,WikiClient.get_diagnostics(), andWikiClient.dry_run_compile().Verification
uv run --no-sync pytest tests/server/components/wiki/ -v— 80 passed./script/lint— all checks passed