Most of the film is told as flashback: Puff (Rhys Ifans) testifies to Congress, Lila Jute (Patricia Arquette) tells her story to the police, while a dead Nathan Bronfman (Tim Robbins) addresses an unseen audience in the netherworld.
Lila is a woman with a rare hormonal imbalance which causes thick hair to grow all over her body. During her 20s, Lila decides to leave society and live within nature where she feels free to exist comfortably in her natural state. She writes a successful book about her naked, savage, happy, and free life in the woods embracing nature. Then, at age 30, strong sexual desire causes her to return to civilization and have her hair removed in order to find a partner.
The partner she finds is Dr. Nathan Bronfman, a psychologist researching the possibility of teaching table manners to mice. Lila and Nathan go hiking in the woods one day. Lila sights a naked man in the woods who has believed himself to be an ape his entire life. Lila discards her clothes and chases him until he's cornered on a tree branch. The man falls off the branch and fall unconscious as Nathan comes along. Nathan brings this man to his lab where the man is named Puff. This name is after his French research assistant, Gabrielle's (Miranda Otto) childhood dog. We discover later from her phone call to an unknown person that she is actually an American with a fake French accent. First with the help of Gabrielle and later with Lilaâs help, Nathan performs extensive manner training on Puff, so that he can speak and go through the motions of appreciating high culture, though he still has difficulty controlling sexual urges.
To demonstrate his success, Nathan takes Puff on tour. Puff secretly drinks heavily and patronizes prostitutes. Meanwhile, Nathan and Lila's relationship deteriorates and Nathan has an affair with Gabrielle. Eventually Lila decides to take Puff back into the forest to undo his manner training and return him to his natural state.
Lila and Puff live naked in the woods together until Nathan finds them one day and Puff kills Nathan. Lila turns herself in as the murderer and asks Puff to testify on the waywardness of humanity before he returns to his home in the forest.
After the reporters and spectators leave, Puff comes back out of the forest and gets into a car with Gabrielle. They both drive off to get food (she still speaks with a French accent).
At the end of the film, there is a philosophical passage read while the credits appear. It is an excerpt of William of Ockham from Opera Theologica in which Ockham explains his theory of intuitive cognition. "Intuitive cognition is such that when some things are cognized, of which one inheres in the other, or one is spatially distant from the other, or exists in some relation to the other, immediately in virtue of that non-propositional cognition of those things, it is known if the thing inheres or does not inhere, if it is spatially distant or not, and the same for other true contingent propositions, unless that cognition is flawed or there is some impediment."

Question: Who did Nathan have an affair with?
Answer: Gabrielle
Alternative answer: Gabrielle