Fix Schema Generation

This was adapted from @agios' pull request with a minor addition of the
default_string method.