I'm trying to recall a story I read about a man alone on a Mars outpost except for the companionship of a dog that had already either been modified post-birth or natally bioengineered to have human-level intelligence.
Over the course of the story, the dog starts getting progressively more moody and withdrawn, and, as is later revealed, develops a bitter obsession with looking up and cataloguing historical articles that contain a phrase like "Fortunately, the only casualty was a dog." By the end, I think the dog may have been psychotic.
I think the man may have been an ultra-wealthy individual who privately bankrolled his exile and the dog's elevation to sapience, but I'm not certain.
I think this was likely in an issue of a magazine like Analog, Asimov's SF, or Clarkesworld, or in a "Year's Best" collection, and was likely from one of the past two decades.