Court documents show the suspected Batman massacre gunman was seeing a psychiatrist specialising in schizophrenia before the attack in Colorado.
The motion named Lynne Fenton for the first time as defence attorneys sought to gain access to a package James Holmes had mailed to her prior the July 20 mass shooting, which also wounded 58 people.
Reports surfaced this week that Holmes – who recently dropped out of the University of Colorado – had sent a notebook to a university psychiatrist that included details and drawing of his plans to kill people.
There were conflicting reports about whether the package reached the school in time to potentially prevent the massacre but officials remained tight-lipped due to a strict gag order imposed by the judge overseeing the case.
Judge William Sylvester unsealed some court filings on Friday after defence attorneys argued that Holmes's right to a fair trial had been violated and that the judge's gag order had been breached.
In a preview of likely battles to come, the defence lawyers also argued that the contents of the package should not be used as evidence because communications between Holmes and Fenton were "protected". The filing said Holmes was Fenton's "psychiatric patient".
Fenton teaches at the University of Colorado's medical school and heads student mental health services there, in addition to conducting research in schizophrenia and other mental illnesses.
But the document did not indicate how long Holmes had been seeing Fenton or whether she was treating him for mental illness.
Prosecutors rebuffed the defence motion, arguing that news stories about the package contained significant "factual errors" and that there was no evidence the government was responsible for the leaks.
The reporting mistakes may indicate that reporters are "getting information from hoaxers, fraudsters or maybe from nobody at all by creating fake 'law enforcement sources' out of whole cloth," prosecutors wrote.
They also indicated that a FoxNews.com report that the package contained a notebook "full of details" about the suspected gunman's plans for a massacre was incorrect.
Holmes, who was studying neuroscience in a doctoral program at the University of Colorado Denver, is expected to be formally charged at his next court hearing on Monday.
Sylvester ordered a hearing on the defence motions to also be held on that day.
Separately, attorneys for 21 US news organisations filed a motion asking the Sylvester to reverse his order to seal court records in the case.
The judge has ordered prosecutors and the defence to file their motions under seal, and ordered the University of Colorado to withhold records that concern Holmes.
Shooting people at random
Holmes gained access to the movie theatre in Aurora, Colorado outside Denver via a fire exit shortly after the screening of The Dark Knight Rises began and threw two canisters of noxious gas into the auditorium, witnesses said.
After firing one round directly into the air with a pump-action shotgun, he began shooting people at random with a military-style assault rifle capable of firing 50 to 60 rounds a minute.
Authorities say Holmes – who had dyed his hair a reddish orange – claimed he was the Joker, Batman's sworn enemy in the comic book series that inspired director Christopher Nolan's film trilogy, which features British-born actor Christian Bale as "the caped crusader".
He gave himself up outside the cinema, still clad in the body armour witnesses described the gunman wearing.
Authorities said Holmes booby-trapped his apartment with the aim of killing anyone who went outside, likely targeting police and first responders. It was days before neighbours were allowed back in the three-story building.
Holmes (24) is being held in solitary confinement at the Arapahoe County Detention Centre and could face the death penalty if convicted, although Colorado has only executed one person since capital punishment was reinstated in 1976. – Sapa-AFP