The goal of the Alignment-Based Learning (ABL) grammatical inference framework is to structure plain (natural language) sentences as if they are parsed according to a context-free grammar. The framework produces good results even when simple techniques are used. However, the techniques used so far have computational drawbacks, resulting in limitations with respect to the amount of language data to be used. In this article, we propose a new alignment method, which can find possible constituents in time linear in the amount of data. This solves the scalability problem and allows ABL to be applied to larger data sets.