{"id":23,"date":"2026-08-04T11:05:00","date_gmt":"2026-08-04T11:05:00","guid":{"rendered":"https:\/\/demos.canvaswp.com\/ai-coding\/2026\/08\/04\/why-the-second-suggestion-was-the-one-you-wanted\/"},"modified":"2026-08-04T11:05:00","modified_gmt":"2026-08-04T11:05:00","slug":"why-the-second-suggestion-was-the-one-you-wanted","status":"publish","type":"post","link":"https:\/\/demos.canvaswp.com\/ai-coding\/2026\/08\/04\/why-the-second-suggestion-was-the-one-you-wanted\/","title":{"rendered":"Why the Second Suggestion Was the One You Wanted"},"content":{"rendered":"<p class=\"wp-block-paragraph\">We spend most of our research time on ranking rather than generation, and the reason is a number we did not like: for a long stretch, twenty-two per cent of accepted suggestions were the second one offered, not the first.<\/p>\n<h2 class=\"wp-block-heading\">Generic beats specific, until it does not<\/h2>\n<p class=\"wp-block-paragraph\">A model trained on the whole world of public code prefers the shape the whole world uses. Your repository is not the whole world. It has a logger, a result type and an error convention, and the completion that uses them is often ranked second behind the one that would compile anywhere.<\/p>\n<h2 class=\"wp-block-heading\">Ranking against the repository<\/h2>\n<p class=\"wp-block-paragraph\">The fix was to score candidates against the conventions the index has already observed: which helpers this package calls, which error type crosses this boundary, which naming pattern the sibling functions use. None of it is clever. All of it is local.<\/p>\n<p class=\"wp-block-paragraph\">Second-suggestion acceptance fell from twenty-two per cent to six. Total acceptance rose by nine points. The model did not change.<\/p>","protected":false},"excerpt":{"rendered":"<p>For three months our acceptance rate was stuck. The completions were right; the order was wrong. Fixing the order moved acceptance more than any model change we made that year.<\/p>\n","protected":false},"author":56,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[7,8],"class_list":["post-23","post","type-post","status-publish","format-standard","hentry","category-research","tag-evaluation","tag-ranking"],"_links":{"self":[{"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/posts\/23","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/users\/56"}],"replies":[{"embeddable":true,"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/comments?post=23"}],"version-history":[{"count":0,"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/posts\/23\/revisions"}],"wp:attachment":[{"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/media?parent=23"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/categories?post=23"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/demos.canvaswp.com\/ai-coding\/wp-json\/wp\/v2\/tags?post=23"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}