This sounds like a riddle or a description of a mythical creature. Here is how we can break down the clues:
Shepherd: This suggests someone who tends to sheep.
Legs and horns of a goat: This implies a creature with the physical characteristics of a goat.
Possible interpretations:
A goat-like creature: Perhaps the riddle refers to a mythical being like a satyr, a creature with a human-like upper body and the legs and horns of a goat.
A shepherd dressed as a goat: This could be a playful or symbolic image. A shepherd might wear goat horns and skins for a ritual or celebration.
A shepherd with goat-like qualities: This might suggest a shepherd who is especially agile, strong, and resourceful, traits often associated with goats.
To get a definitive answer, you would need more context. Is this from a poem, a story, or a riddle?
Let me know if you have more information!