In Touhou 17: Wily Beast and Weakest Creature you can get secret spirits if you do a certain specific thing in the given stage's midboss fight. They also award the player with an achievement. What are these?
According to this post on Reddit for...
Stage 1: Squid
You can't kill any of the yellow ghosts that surround the midboss. Once the midboss is beaten, you will receive a Squid. Cool!
Stage 2: Cow
Be as close as possible to the midboss. Not too close of course, leave some room to dodge the Sukun-ish main bullet. It seems as long as you don't shoot while being in the bottom section of the screen (say after dying), you will still get it. Once the midboss is beaten, you will receive a Cow. Awesome!
Stage 3: Chicken
This one is a bit less clear. You need to finish off the midboss using the Otter hyper - out of all three animals, it's definitely the least aggressive. The stage will give a lot of Otters at the start, so it should be pretty easy (again, you need 3 of the same animal spirits in your bar to get a specific hyper). Once the midboss is beaten, you will receive a Chicken. Epic!
Also from what it looks like you can die, use bombs or continues and still get the spirit.