Working on saving segment definitions, but we need to cleanup the JSON model first to make sure it can be used everywhere and properly mapped.