the.ai

Code / Generation

verified

Fill in the Middle

Real editing almost never happens at the end of a file. The cursor sits in the middle, with code above it and code below, and a left-to-right model can only see one of those. Fill-in-the-middle is the training change that lets a model condition on both — and it is what makes autocomplete inside an existing file work at all.

Viz primitive · budget-splitfim-documents = 10

fim-documents holds 9% of the budget; rest holds the remaining 91%.

Training documents rearranged into prefix–suffix–middle order, against the ones left in reading order, in documents. Drag the rate up to watch infilling take the corpus — and note the reported result, which is that left-to-right ability holds at the rates people actually use.

10

Reviewed by opendroid · 2026-08-18