An IRS Special Agent works for the IRS's Criminal Investigation Unit, also sometimes known as "CI." Special Agents are duly sworn law enforcement officers who are trained to "follow the money." They investigate potential criminal violations of the Internal Revenue Code and related financial crimes. Unless they are working undercover, they will identify themselves with credentials, which include a gold badge. If you would like to see what the badge looks like, see the link below. The same gold badge appears on their business cards. Generally, IRS Special Agents travel in pairs if they are going to interview someone. One conducts the interview while the other takes notes and acts as a witness if necessary.
Usually, IRS Special Agents will show up at the home of a suspected tax evader early in the morning in the hope of catching him or her unaware. If you are contacted by an IRS Special Agent, it is because he or she is conducting a CRIMINAL investigation. Unlike every other person at the IRS, their focus is not on collecting money. The Special Agent's job is to prove that someone has committed a crime and to put him or her in jail. If you are the target of the IRS' investigation, they will read you your Fifth Amendment rights, the same as any police officer would to someone suspected of being a criminal. IRS Special Agents are highly trained financial investigators. If you are the target or subject of an IRS criminal investigation, you are not going to talk your way out of it by "cooperating"; instead, you may be giving the IRS more evidence to use against you in a court of law.
It is possible that the Special Agent is only interested in you as a witness against the IRS investigation. If the IRS Special Agent tells you that you are only a witness, you should still consult with an experienced criminal tax attorney BEFORE speaking with an IRS Agent. If you make misstatements that you think put you in a better light, you could change your role from a witness into a target. The best tactic is to simply tell the Special Agent that you are uncomfortable talking to him or her until you have had the chance to speak with your attorney. Then, ask them for their business card. In this way, your tax attorney can contact the Special Agent directly and determine the best course of action.