Repository navigation
fix(query): credit a search hit to the speaker who said the word - #365
Conversation
A search hit cited the first line of its chunk, so when that line belonged to another speaker, the citation credited the wrong person for the word that matched. The citation now names the first line of the chunk that holds a query term, and falls back to the first line when none does. Bead akou-z5s.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (2)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthrough
ChangesSearch citations
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~8 minutes Change: Bug fix Merge Risk: ⚪ Minimal · up to Search citations now attribute a hit to a line containing the query term when possible, and the regression test checks the speaker attribution. No actionable merge risk is evident. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…aker and akou start and akou quit finish (#374) ## Problem On 0.6.4, with the Nemotron diarizer on, every call line waited about 2 s for its speaker before it reached the transcript. The first `akou start` after an install gave up at 3 s while the app was still coming up. `akou quit` on Linux could hang after a call. All three are fixed on main and no release carries them yet. ## What 0.6.5 ships - A call line is written when its segment closes, and its speaker follows as a correction to the same line (#359). - `akou start` waits up to 20 s for a slow first launch and stops the idle launcher afterwards (#360). - `akou quit` always finishes on Linux (#367). - A search hit names the speaker who said the matched word (#365). - A file job without speaker labels fetches, and is admitted for, only the models it runs (#364). - Three messages no longer point at a command that cannot help (#366). - Behind the scenes: G1 and G3 pass, G4, G6 and G7 stay Partial (#354, #357, #358, #362, #363, #371, #372), the dictation audio tests wait for the write (#361), and `glama.json` (#373). The Known limitations list in CHANGELOG.md names what the reviews left open: late first lines after a cold start, the four-core x64 line latency, a launcher left by an earlier failed launch, the silent wait in `akou quit`, and two search citation cases. ## The bump - `scripts/stamp-version.ts --set 0.6.5` wrote the 11 stamped places. - By hand: the install line in README.md, the image tags and the `--branch` line in docs/server.md and docs/server-hardware.md, and the "Known in" line in docs/troubleshooting.md. The menu bar item still moves, since nothing touched it after 0.6.4. - docs/gates and docs/ROADMAP.md keep the versions their evidence ran on. - `stamp-version.ts --check --tag v0.6.5` passes, and `--tag v0.6.6` fails as the control. The tag is pushed after the merge.
akou searchcould credit the wrong person. A hit is a BM25 chunk of up to about 60 words, and it can span several speakers. The citation always named the chunk's first line, so a word that Speaker 2 said came back as[17:30 Hands On], the user who opened the chunk. The citation form[HH:MM Name]is meant to say who said it.The citation now names the first line in the chunk that contains a query term, using the same expanded terms the search scored on. It falls back to the first line when no line matches. The chunk and its lines are unchanged, so the context pack is not affected.
Test, red on main and green here, in
tests/query.test.ts:a search hit cites the speaker who said the matched word, not the chunk's first lineThe test builds a chunk where Ann speaks first and Ben says "vendor". It checks that the chunk does open on another line, then that the citation names Ben. On main it named Ann.
Bead: akou-z5s
Summary by CodeRabbit