Surgical residency is a minimum of 5 years, sometimes the intern will be watched by a junior resident (3rd year), a senior resident (4th year) or the chief resident (5th year). The chief resident is the intern's immediate boss, but even the chief resident is still just a resident. They still answer to the attending physician who ultimately is the one responsible for all clinical decisions. For the attending to be absent during surgery and only residents there, is called "shadow surgery". Other than life and death situations, surgery can not start without the attending present. Think of the chief resident as the quarterback and the attending is the coach.
It is also possible (s)he may work directly with the attending physician (the one who actually gets paid, and is the physician on the chart). The attending might be in private practice, or part of a group in private practice, or might be part of a university staff overseen by a chairman ((s)he's the one who answers to the residency review board for that specialty)