The AIA (American Institute of Architects) has a good selection of contracts you can download and edit as you need. Their subcontractor agreements are widely used in the construction industry, and can be adapted to your specific needs. To best protect your interests, it would be wise to have a construction law attorney write up or at least review and edit a contract for you.
AGC Shortform for smaller projects.
AGC Longform for larger projects.
online you should find lots of different subcontractor agreement forms. just read and find the one you want. i personally edit and removed some items and added things to fit my needs. you should do the same
Always use the AIA contract documents, they are created by professionals to everyone protection.