Automaton is an external node classifier for puppet that supports mongo db as well as flat files. It has a simple command line interface, and a REST interface if needed