Additional documentation

- Added some documentation around response_set and survey
- Reorganised the code in these somewhat
- Added quick fix for bugs related to new env variables
- Committed schema file, so you can debug the migrations

I branched off the, now closed, `optimising-survey` branch. So you may want to cherry pick commits from this branch.