Let's go with something easy: you see an eagle watching you from a tree. Is it possible to tell if its an eagle, or an eagle with either celestial template or fiendish template and thus most likely a summoned animal?
Can you tell when something has a template?
a "template" is a game mechanic/rule mechanic and nothing your character could perceive.
That said, depending on the template, the targets game world appearance to normal eyesight or detection spells might change. You can perceive that. But that has nothing to do with being a template or not. If you recognize the human looking thing has a big furry tail, then that's what you see. You will never know if that's because it's a human with a template, or a regular MM entry that looks like a human with a furry tail.
As far as knowledge skills go, they can only do, what I described above: take the hints you have and generate knowledge from it. For example, if you see a furry wolf-man, you could roll a skill check to know it's called a werewolf and according to legend is vulnerable to silver. You could not pass it's normal human form and roll a skill check to recognize that this human has a template applied.
The whole notion of a "template" is a meta construct that exists so the creators of monsters don't have to fill volumes over volumes with redundant information. MM1: Monsters. MM2: Infernal Monsters, MM3: Celestial Monsters, MM4: Werewolf Monsters, MM5: Wererat Monsters... etc etc. We can create our own monsters without any single one spelled out in a book by applying templates. But for the game world, the result is a single entity. The concept of a "template" does not exist in game. An infernal spider is an infernal spider. The fact that we got the stats by taking a spider and applying the infernal template is purely a meta information.
Is it possible to tell if its an eagle, or an eagle with either celestial template or fiendish template
You will have to look that up in the description of eagle and celestial or infernal eagle (or the respective templates you applied to get to those monsters). As far as the game world and skills are concerned, it's three different monsters and if there are no hard rules in the MM, then the DM has to decide if the eagle and infernal eagle look alike or not. The pure fact that a template was used to generate their stats is nothing that a skill check could find out.
Most templates change the type or subtype of the creature they are applied to. Sometimes type changes so drastically the appropriate knowledge skill used to ID a creature itself changes.
In the case that the knowledge skill used to ID a creature changes, you can tell from the skill used what general category of being you are dealing with. For example, if you are seeking to identify a bird and you are told to roll Knowledge(religion), the bird must be of the Undead type. Knowledge(religion), Knowledge(local), and Knowledge(planes) all work this way, covering only a single creature type, and thus you can usually assure identification at the type level of Undead, Outsiders, and Humanoids, even without any training in the relevant skills.
Other skills cover broader groups of creatures and so being told to roll such a skill may not be sufficient for type identification. For example, if you are trying to ID what appears to be some sort of zombie and are told to roll Knowledge(nature) the creature may be an Animal, Giant, Vermin, Plant, Monstrous Humanoid, or Fey (and there are even vaguely-humanoid-zombie-looking special Giants, Vermin, Plants, and Monstrous Humanoids!).
Regardless of what skill is used, assessing the creature type of a target is officially generally a DC 10+CR check, or 5+CR for common monsters (probably including those summonable via Summon Monster spells), with 15+CR for exceedingly rare creatures.
However, many published creatures include a 'lore' section, the first entry of which usually but not always reveals the creature's type and all associated traits. The second entry certainly includes the type if the first entry didn't. While these lore sections generally conform to the standard laid out in the rules, in the case of high CR monsters, a section with an apparent -5 DC modifier frequently exists that provides knowledge of a creature's type and whether or not it is extraplanar without revealing any other abilities in particular. A good example of this is the Devourer.