Lab: Rerank and assemble the context
Module 8 · Lab · About 75 minutes · Needs: lessons 1 and 2 of this module, and the Module 6 lab (or the cells in Step 1)
What you are building
On Friday 9 October Hollin's search ends at Module 6: a user and a question in, up to ten permitted chunks out, ordered by fused scores and Module 6's signals. Lesson 1 showed a cross-encoder orders such a list better; Lesson 2 turned a ranked list into a small, labelled context. This lab moves them into the package, on top of Module 6's chunk search: hollin/rerank.py reorders the ten chunks, and hollin/context.py applies the bars, collapses copies, keeps relevant sentences and fits whole blocks into 200 tokens. You re-measure on chunks what the lessons measured on documents, probe every user for leaks, write the tests and commit. No language model is called; Module 9 reads what this lab builds.