1.2 and keep them together at all time (remember you will need 1/3 or 1/4 hardware cloth for ASF or they will escape with 1/2) - This number seems to allow you to achieve better production.
Rats you can start with 1.2 Rats they should be separated when the females iare birthing (for example put 1.1 together than once the female is pregnant remove the male and put him with the other female this way after the first time breeding no one will ever be alone) - Than if you need more breeder just holdback some females so you will only have to purchase males when needed or if needed depending on how large you need your colony to be.
With rats just make sure they do not stay alone too long.
Get them young!
Get a young trio of ASF keep them together when ready they will breed
For the rats get small females first raised them up to 250 grams and than get your male.
Getting bigger older animals is not a good idea since they might be too old to breed.
You will need 1 pan for each trio of ASF and 1 or 2 for the babies to grow out (depends on the size of the pan)
For rats it will depend on your setup in cat litter pan doing communal breeding you can have 2 females per tubs and have the male rotate through each tubs (so number of tubs will depends on how many females you plan on getting, if you are using concrete tubs you can have 1.10 but having a birthing rack would be a good idea. You will also need pan for the babies once weaned (depends on the size of the pan and number of babies you plan to produce)