The Talmud is a record of argument, not a code. It preserves rejected positions alongside accepted ones, digresses at length, and often does not say which way a dispute was decided. For a judge that is a problem, and the eleventh century produced several attempts to solve it. The one by Alfasi was the most successful.
The Sefer ha-Halakhot follows the order of the Talmudic tractates and reproduces the text, but keeps only what bears on practice. Narrative and homiletic passages go, arguments that lead nowhere go, and where the sources conflict he states the ruling. Because it keeps the original order and much of the original language it reads as a compact Talmud rather than as a separate book, which is why it could be printed alongside the Talmud rather than instead of it, and why it sits inside standard editions to this day.
The choice of what to keep is itself a legal act, and later authorities argue with it constantly. Maimonides wrote that almost nothing in it needs correcting; the Provencal scholar Zerachiah ha-Levi wrote a running critique. Together with Maimonides and later Asher ben Yehiel, Alfasi became one of the three authorities whose agreement Joseph Caro used to fix the law in the Shulhan Arukh, which is how a Maghrebi abridgement came to govern Jewish practice worldwide.