If your goal is to use an AI to change the graphics, that won't work unfortunately. There's probably a way to detect when a villager is herding sheep, but there's not much you can do with that info besides commanding the villager to do something or send a chat with info about the villager.
I bet you already found it, but it seems like you can find the herding graphic in the Tasks section at the bottom of AGE if you're looking at one of the Shepherds. If you select the hunt task, the Proceeding Graphic seems to be the herding graphics. Unfortunately, it seems like you can't vary this graphic by civilization, so that's probably why you're asking about it.
~`o´~ |\ Join the fresh and exciting AI Ladder for its fourth season! ´ ` |_\ | Learn the joy of AI scripting in my guide: The World of AI Scripting ______|______
\ / .....Hinga Dinga Durgen! - SpongeBob
`-=<.__.>=-´[This message has been edited by Leif Ericson (edited 02-05-2020 @ 10:37 PM).]