Miscellaneous changes and a few demo scripts.