Dire anteaters by and large aren't especially smart, but even an animal can learn the behavior patterns of its intended prey. Brother Varn's armor and bones (protected to some extent by his armor, and so not fully digested) prove to be a useful lure.
This anteater has worked out that someone will eventually take interest in its last meal and lurks immediately overhead. The result, it hopes, is a chain of people who one after another discover how those bones got partially digested.
It will be equally happy if some undead or scavenging animal comes to investigate its leavings. Dire anteaters aren't picky eaters. If it's small enough to swallow, it'll give it a go. A really ambitious one may try to swallow prey as large as it is, but most are content, fortunately or unfortunately, with people.