Kahakai is a fork of the Waimea window manager.  It can be scripted
in Python.

WWW: http://kahakai.sourceforge.net