You should spend some money and better ask a lawyer about to draft the contract. There is http://www.docracy.com/ though if all you want are examples to study.
I don't now enough about the details, but as someone looking to get into freelancing, I would be interested in some kind of "contract builder".