Add technical spec (unfinished)

This also improves the README.