Setup entrypoints

Fixes #85. Needs review.
You'll need to finish this.