Support searn through the library interface.