You could have a look at the Mozart/Oz community. Oz is a language supporting logic and constraint programming out of the box and people are using these capabilities to play linguistic with graph matching.
See http://www.lifl.fr/~duchier/papers/duchier-xdg-cslp2004.pdf for a possibly enlightening example. I know that right now people are working on graphs as first-class finite domain entities to be integrated in Oz (or the constraint solver that was forked from Mozart/Oz, known as Gecode) : http://cpgraph.info.ucl.ac.be/. Incidentally, there is a CPython wrapper for Gecode waiting to be finished, but that is not likely to be ready next month. Cheers, Aurélien. -- http://mail.python.org/mailman/listinfo/python-list