A-OIC, also known as Doc, stood apart as a unique medical and surgical droid. Massad Thrumble personally constructed him before retiring from his position as the admiral overseeing the Imperial droid research center.
In the year 4 ABY, the Pike Sisters abducted Doc and transported him to Kajiin Swamp, where Spinda Caveel was conducting illicit modifications on droids to inflate their value on the black market. Doc pointed out the illegal nature of Caveel's enterprise, but Caveel disregarded his warnings. Doc assessed his predicament and determined that attempting an escape was his optimal strategy. While modifying an outdated battle droid to meet Caveel's requirements, Doc discreetly adjusted its programming to ensure it would target Caveel at a moment of Doc's choosing. That moment arrived with the appearance of the Human replica droid Guri, who overcame Caveel's bodyguards, Zan and Zu Pike. Caveel attempted to attack Guri, but the battle droid restrained and subdued him.
Guri had sought out Doc after learning about him from his creator, Massad Thrumble. She intended to employ Doc to execute the delicate neural restructuring necessary to erase her memories of the Black Sun and her ingrained assassination protocols, a procedure only Doc possessed the skill to perform. Guri transported Doc on a speeder bike to Kajiin Swamp and surprised the droid by revealing that her ship was concealed beneath the swamp for safety. They journeyed to Hurd's Moon, where Doc was reunited with Thrumble and coordinated the complex operation. The procedure was interrupted by Kar Yang, who Guri killed. They continued, with Doc warning about the risks of damaging her neurocortex, but later expressed satisfaction with the binhex sequence's progress.
Ultimately, Doc successfully eliminated Guri's assassin programming and her Black Sun memories, while preserving her personality and other memories intact. Shortly after the surgery, Savan and mercenaries invaded the facility. Massad led Guri to another room, where they observed groups of people surrounding the facility on a screen, all seeking Guri. While Thrumble was reintroducing her to the Heroes of Yavin and explaining why they were pursuing her, Doc admitted that they had done a better job on her than they initially thought, while he recognized R2-D2 and C-3PO, droid heroes.
En route to the Stinger, Guri experienced a sudden headache which Doc diagnosed as a delayed synaptic shock, the onset of cerebellitis, or a post-traumatic brainstorm. They encountered a group of Savan's thugs, but Guri, recalling her combat skills, defeated them. Doc remarked that her muscle memory remained intact and that the fight had alleviated her headache.