You need to find a family law attorney in your state. They can walk you through what to file because it varies from state to state. I think If you can prove you’re rehabilitated you have a good chance of getting some custody if the very least supervised visitation. First of all, I don’t know what state you are in, but he cannot deny you from seeing your child. You will be able to see her and spend time with her as well. Now, this is what you do, now that you are out start by getting your life back on track. I hope you have gotten a job. If so good next is work on getting an apartment for you and your daughter. In the meantime go online and look for a legal aid attorney in the city you live in. Look in the phone book. Call and see if you can get an appointment to see what can be done to get your daughter back. You will have to go to court.