Split up __ecto__ functions

Closes #65.