Tier 1: Default Heretics,Raptors
Heretics are a great melee counter to pretty much every t1 melee unit, you will need to learn how to doomblast propely to use them effectively, aswell as when use them as a support unit with worship when necessary, at the start of the game, if you use them well they should be able to beat any other melee starting unit, when the game progresses, and things like ASM,Aspects for banshees, burnas etc... come out you will need to get an Aspiring Champion on them.
Raptors should be your favorite choice to counter setup teams, but they will need quick support from your hero/tics (heretics), or well, I don't like to use them vs setup teams, I find havocs, your hero and NM to provide the setup team counter well enough already, Instead I like to use raptors vs big blobs since their big supression range permits you to approach with your whole army without beign shooted.
Tier 2: Blood letters,Khorne Marines, Blood Crusher, Dreadnought
Blood letters are one of the best units in the chaos arsenal imo, they jump quickly, they do alot of damage, they wipe squads almost instatly, I generally get them vs nids since they counter their whole T2, but they are also amazing vs pretty much everyone but IG.
Khorne marines are situational, you can either use them to fill up a missing melee slot if you have gone for a ranged build with like nade launchers and PMs in t2, or you can go full melee with AC tics,Khorne marines,bloodletters.
Dreadnought, I prefer to keep it ranged with it's autocannon, and get the mark of tzeentch when needed to counter other vehicles, the khorne dread is very strong but also very risky, if you want to get it use it's ability often and value well if it's worth getting it depending on the damage you can cause with it before losing it.
Tier 3: Terminators, Great Unclean One
I'd honestly always get the autocannon, it's just that good, the only time I would get the LC is when I really have no melee or I have to against other LC termies, the GUO imo is the best super unit, does alot of damage to everything, and can tank for a long time, but if you are missing alot of hard and long range av, then in that case you should not get it and get the phobos instead.
What units are good against what types of enemies?
Bloodletters and Kcsm and LC termies do power melee so they are extremely good vs both HI and SHI kind of armor, Tics do the standard melee damage, but they are still good vs everyone, especially sluggas,shees etc...
for instance, what is good against setup teams?
how about light dedicated melee such as banshees?
what about enemy jump squads like storm boys?
Like it was said before, vs setup teams you want to be able to avoid their supression so raptors/bloodletters are their ideal counters, though usually the chaos commanders have other and more reccomendable ways to counter supression teams.
Meanwhile, vs more 'elite' melee units you want to pair up your unit vs them, like AC tics + letters or Kcsm or some CC from your hero vs genstealers/storms since usually you won't be able to beat them in 1v1 fights
How does one respond once anti infantry vehicles come into play?
Usually all of the units that do power melee do some pretty good damage vs tanks and transports, so if you can pair them up with a slow on a vehicle like plagues marines, melta bomb or a lascannon shot you shouldn't have too many troubles in taking it down.
Vs dreds you'll need to keep the distance, and take it down with melta/lascannons/plague marines or your own vehicle, like a tzeentch or khorne dred or a bc under worship with some light av support.