Oncina-Garcia RPNI algorithm for learning DFAs
The algorithm is named RPNI, not RNPI.

Given that the language generating the inputs is regular and that enough examples are given (the characteristic set), the algorithm returns the canonical (i.e., minimal) DFA for that language. If the generating language is not regular, the automaton may grow unboundedly with the set of inputs.

Since the algorithm merges states, the output automaton has at most |p| states. Therefore, the output is bounded by the sum of input lengths in p.

A proof appears in "Inferring regular languages in polynomial update time".
There are more details about the algorithm in the "Grammatical Inference" book by Colin de La Higuera.