Document AutoDoc(), various other improvements

Please have a look at this.

I can also split this tomorrow into multiple PRs if you prefer. I plan to complete the docs for the AutoDoc() function then, but am not sure if I can work more on the tutorial in the near future.