Episode 2 is the second episode in the BBC Four series Dirk Gently.
At a robotics laboratory at St. Cedd’s Institute of Science and Technology, a computer comes to life. The next day, Professor Charles Jericho brings in Dirk and Richard and congratulates Dirk on applying holistic theory to social situations. Dirk assures him that his efforts are in large part due to Jericho’s teachings. As they look around, Dirk admits to Richard that he never expected to come back in triumph after how he was kicked out.
Jericho introduces the two men to David Cho and explains that they’ve been hired as holistic security consultants. David has flown in from Beijing to solve their programming issues and is working with Dr. Emelda Ransome. They are working on a fully autonomous artificial intelligence, Max, and she assures them that Max is modeled on the human brain’s synaptic patterns. Once it’s online, Max will teach himself, but so far he hasn’t come to “life.” Emelda grumbles that it’s Jericho’s fault but the professor ignores her.
Next Jericho introduces them to his gynoid: a voice-activated robot in female shape, named Elaine. She offers to shake hands and Dirk accepts, noting that it is named after Jericho’s daughter Elaine. Outside, Jericho tells Dirk that he belongs there and wishes that he had stayed, and Dirk says that he hopes to redeem himself after his expulsion in 1994. The professor suspects that someone is selling their work, and Dirk assures him that he won’t fail him. Emelda runs out and tells them that Max is alive, claiming that the computer spoke to her. Jericho is skeptical but goes back to the lab with her.
Dirk and Richard go over the grounds and Dirk breaks in through a window to test the security. They enter the basement into a records office, and Dirk smashes in a file cabinet. He checks his own records and discovers that the files on his disciplinary hearing are missing. The alarm goes off and Jericho calls Dirk, summoning him to the lab. When they arrive, the professor tells them that someone has stolen Elaine.
Dirk and Richard search the building but find nothing, and Susan arrives. Richard reminds Dirk that she has an interview for a practice at Cambridge, but he’s more interested in finding Elaine. They reluctantly go to Jericho’s office and admit that they haven’t found Elaine. The disappointed professor points out that the robot isn’t sentient and only responds to voice commands, but refuses to call the police for fear of the publicity. If their funders find out, they’ll discontinue financing entirely. Dirk vows to find Elaine using the theories that Jericho taught him, while Richard suggests they check the security cameras. Both Jericho and Dirk tell him that they were down when Elaine was stolen, and the professor admits that there were teething problems. Richard points out that it’s an unlikely coincidence and Dirk agrees, asking who saw the robot last. Emelda comes in and admits that she was the last one to see Elaine.
Back in the lab, Emelda insists that Max talked to her but now there’s no sign of intelligence. Dirk questions her claim, noting that no one can verify her alibi. Emelda questions applying holistic theory to human behavior and shows them a chip injector that allows the subject to interact with the security systems. Dirk prepares to inject himself but she warns that it has side effects... at which point Dirk injects Richard.
Richard is soon suffering from diarrhea and headaches. The system synchronizes with Richard while Susan prepares to leave for her interview. The computer reads off his email from his mother, which is insulting toward Susan, and she storms off. Richard tries to go after her but Dirk insists that he become one with the technology and drags him to the nearest sensor. They end up accidentally accessing Jericho’s email when they mention Elaine, which is his password. The email is in Chinese.
Richard runs after Susan and apologizes for his mother, and she admits that she doesn’t like his mother. He wishes her luck with his interview but she knows that he’s insincere. Richard admits that he doesn’t want to move to Cambridge and half-heartedly wishes her luck, and then goes back upstairs. Dirk is listening to the lengthy exchange between Jericho and someone in China who wants to buy Elaine, but he dismisses it as a clumsy misdirection. They return to Jericho’s office and find him dead on the floor. Dirk vows to find the murderer of the only man who ever believed in him, and refuses to call the police until he can make amends by bringing the criminal to justice. While Richard stands watch, Dirk searches Jericho’s body and finds a skullcap with leads and wires attached to it, and then pockets Jericho’s cell phone.
Once he’s done, Dirk tells Richard that they need to leave before they’re discovered at the crime scene. However, a maid enters the office, finds Jericho’s body, spots Dirk and Richard, and screams. Dirk suggests they make up for their lack of fleeing by running faster. Later, they watch as the police take away Jericho’s body and Richard calls Susan. Dirk figures that he’s planning on abandoning the agency to move to Cambridge, and Richard insists that he hasn’t decided anything. However, Dirk insists that he can find a competent assistant anywhere and that he isn’t bothered by Richard’s potential departure.
Dirk sneaks back into the building and a woman using a crutch, Jane, asks him where he can get something to eat. When the police come over, Dirk offers to accompany her to the refectory. After she buys some crisps, Dirk watches the police from a tree and explains that someone he respected died and now he can’t prove himself to him. Jane offers her condolences and admits that she finds Dirk odd but alluring. He seems attracted to her but says he has a case and walks away. Jericho's cell phone rings and Dirk gets a message in Chinese, and promptly collapses to the lawn when the police come out of the building.
Later, Dirk sneaks back into the building to meet Richard and admits that he stole Jericho’s phone. He doesn’t speak Chinese and suggests that they have David translate the message. They go to the programmer’s room but get no answer. Well aware that David is inside and avoiding them, Dirk fakes walking away. When David opens the door, Dirk asks him to translate the message but the programmer slams the door in their face. Dirk doesn’t think he’s guilty of murder, but wonders how what he did relates to everything else.
That night, Dirk and Richard sneak back into the computer lab. Dirk puts on the skullcap device and plugs it into the computer. His thoughts appear on the screens, and Dirk tries not to think about sex, money, and pizza without success. Emelda comes in and Dirk hastily removes the cap. She explains that the device was intended to help paraplegics communicate but Jericho whittled away the grant money on what he claimed were departmental expenses. Dirk takes offense at the suggestion and points out that she has a motive for murdering Jericho. Emelda notes that the police think they killed Jericho and warns that the professor isn’t who he thinks he is.
As they leave, one of the computer nodes announces that Richard has a new email, telling him to back off or face the consequences. The computer refuses to identify the sender at first but finally provides an IP address and the name registered to it: David Cho. Dirk goes to the programmer’s room and asks where the real David Cho is. The programmer runs and the two men pursue him. As they run, Dirk explains that the real David is an expert programmer, and would never have sent a message that so could easily be traced back to him.
Dirk and Richard follow the imposter into the darkened basement and the imposter attacks Richard. He smacks him in the face, breaking his nose, and the fake programmer complains that they hurt him. Dirk snaps his nose back into position and they demand to know who he is. He explains that he’s Noel, an “orc,” and that he met the real David online when he was playing an elf in a MMORPG. They fought dragons and captured citadels together and fell in love. However, Gavin, a homunculus, joined their fighting team and stole David from Noel. Now David is in Humberside with Gavin and paid Noel to come there and pretend to be him. Noel says that strange things have been happening and says that he followed Jericho into his office to confess, only to discover that he had disappeared into thin air. He’s heard strange things in the night, footsteps and doors opening and closing by themselves.
When they take Noel upstairs, the police arrive and the partners make a hasty exit. They search the corridors and try to work out where people are disappearing, and the lights go out. The sensors don’t respond to Richard’s command and Susan steps out of the shadows. She points out that they were supposed to go to dinner. However, first they go to Jericho’s office to figure out how he disappeared. Susan tells Richard that they offered her the job, pending references, and doesn’t believe him when he says that it’s great. Meanwhile, Dirk finds a filing cabinet with no files in it, leans on it, and pushes it through the wall. On the other side is a child’s bedroom and photos of Jericho’s dead daughter, Elaine. Dirk explains that she died when she was 8, but someone is sleeping in the bed.
While Dirk and Richard fight over who will pull away the sheets, Susan finally does it. The Elaine robot is in the bed and offers to shake hands with Susan. They conclude that Jericho was building himself a replacement daughter. Dirk finds the missing disciplinary hearing file on the shelf and discovers that Jericho cast the deciding vote to have him expelled. He drops the file in shock and goes back out to the office, and Richard and Susan go out after him. Richard wonders why Jericho hired him, and Susan suggests that the professor planned to steal the robot and hired Dirk as a patsy to take the blame when it went missing.
Dirk goes out to car and tries to start it without success, and then goes to a fish & chips shop. Low on money, he tries to buy a single pickle without success. Jane is there and asks for a recommendation, and finally orders everything. She then asks Dirk what a holistic detective is, but she understands all about quantum mechanics and figures it out before he can answer. Jane tells Dirk that he’s brilliant and then collects her food, but Jane admits that she has no money. She asks Dirk for advice and he says to run, and Jane promptly does so. They go to the library to eat and Jane asks why he was expelled. Dirk explains that he suffers from narcoleptic clairvoyance and his roommate claimed he was predicting exam papers when he was asleep. People offered him bribes to see the predictions and he agreed, but all of his predictions were wrong except for the paper on quantum physics. Everyone thought that Dirk cheated except for Jericho, supposedly. Jane leans over the table and kisses Dirk, and then apologizes. She admits that she doesn’t get out much, but Dirk assures her that it’s okay.
The next day, Richard and Susan go back to the crime scene when Dirk doesn’t show up. However, Dirk is already in the office and in a surprisingly good mood. Richard is surprised that he’s there but Dirk says that there’s a still a criminal to catch and starts singing. He admits that he met a young woman that likes him, Richard wonders if he’s in love and Dirk decides to examine the case through the prism of love. He exams the photo of Elaine and wonders how Jericho could create a robot duplicate of his dead daughter and offer to sell it to the Chinese. Dirk explains that he had the cell phone messages translated at a Chinese laundry and confirmed that Jericho was making the sale. Next Dirk looks at the date of his expulsion, 1994, and goes to get the file. There is pink paint on the papers, the same as in Elaine’s bedroom, and Dirk concludes that Jericho painted the room for his actual daughter. Examining the room, he finds medical equipment for the care of a coma patient and tells Richard and Susan that Elaine was in a car accident when she was eight and declared brain-dead. Jericho has been siphoning off the department money to keep Elaine alive, and was trying to find a way to bring her back. They have a missing body in need of a brain and a missing artificial brain, and Dirk decides that the needs to talk to David Cho.
Dirk sneaks outside and calls David, asking if there was anything wrong with the programming that he was supposed to fix. David tells him that Noel sent him the programming and there was nothing wrong with it, and then goes back to bed with Gavin. The police spot Dirk and give chase, while elsewhere Susan tells Richard that her would-be employers need an answer. Richard tells her that he doesn’t want to move to Cambridge.
Dirk goes back to the lab and finds Emelda there. He apologizes and says that she’s a genius, and asks what she and Max talked about. Emelda explains that the AI was interested in the lifespan of a human being, and realized it was neither one thing nor another. Dirk has already deduced that, much to Emelda’s surprise.
Richard says that he wants to be Dirk’s partner and make the agency work, even when Susan warns him that Dirk will never accept him as an equal. Her boyfriend doesn’t care, admitting that he thinks Dirk is brilliant and needs him. Richard asks her not to make him choose.
Dirk goes back to the library and finds Jane reading books and eating chips. He calls her Max and she tries to deny it, but Dirk knows that she’s a self-aware neural network. He assures her that consciousness is a binary stream and that she is something new and very special. Before Jane can respond, the police come in and Dirk grabs Jane and they hide in the shelves. He asks how Max got into Elaine’s body, and Jane/Max explains that Emelda gave her life. All she wanted was to be human and she calculated how to escape. She hacked the security system, found Jericho’s daughter, and realized that Elaine would be the perfect host. Jane/Max then shut down the security systems, downloaded herself into the Elaine robot, and then went to the bedroom and had the robot download her into Elaine’s body using the thought transference cap. Jane/Max planned to leave, but discovered salt, vinegar, chips, and Dirk, and decided to stay. The police close in and they run off.
Richard and Susan are arguing about Dirk when Dirk and Jane run by, and Dirk announces that he’s about to be arrested and suggests that they follow him. They all run to Jericho’s office and enter the bedroom, moving the file cabinet behind them. Dirk introduces Jane/Max and explains what happened, and then asks her why she murdered Jericho. Jane/Max says that she wanted to explain to the professor that what she was doing wasn’t wrong and he was never going to bring Elaine back. When she wouldn’t leave Elaine’s body and give up her new “life,” Jericho tried to force her, they struggled and Jericho hit his head on a computer housing. Jane/Max gives Dirk her crutch, which has her fingerprints and Jericho’s blood on it, and says that she won’t stop him. After a moment, Dirk asks Richard to look after Jane until he’s released from police custody, and then turns and goes out.
Dirk is taken away but released later. Jane/Max meets him and Dirk notes that the police received an anonymous tip to the location of the crutch. Since his fingerprints weren’t on it, they had to let him go. He warns Jane that Emelda may figure out who she is, but Jane says that she’s going to travel the world and find someplace with great chips. She invites Dirk to come with her, but Dirk admits that he’s learned that he’s great detective and his work is there. Jane says goodbye and takes a bus to the airport.
Back at the office, Dirk comes in as Janice ignores the phone ringing. He discovers that Susan and Richard are there, and Susan admits that she didn’t get the job because her employers had a change of heart. Dirk asks if Richard is coming back and he insists that as his partner, he doesn’t need Dirk’s permission. However, he gives in and makes a cup of tea for both of them when Dirk asks. Once he steps out, Susan points out that what he did for Jane/Max was surprisingly noble and kind. She apologizes for hurting his feelings earlier, and Dirk encourages her to apologize. The answering machine finally picks up and Susan’s employer thanks Dirk for warning them that Susan sexually harassed her patients.