Justin Marquette is an actor who ends up dead in room 147 of a hotel. Three people confess to the murder and each one knows the details of the crime.
After having no theories, Castle and Beckett find out that all three were drugged by the Eternal Horizons Institute who was conducting experiments to change unwanted behavior. They hired Justin to play a murder victim in a video they used in their experiment. All three suspects saw the video and were drugged.
In the end, Justin was killed by Pam, a woman he met at his theater group. Her brother was killed in another Eternal Horizons Institute event that was eventual deemed an accident. When she thought Justin was a part of the group, she was enraged and ended up killing him so that someone involved with EHI would pay.
Alexis and Pi have broken up and he's moved out. Castle wants her to move home but she feels the need to work extra hours to keep her apartment since she signed a lease.
Kate talks to Alexis to make sure she isn't the reason Alexis isn't moving home. After Alexis explains, Kate convinces the girl that there's no need to do penance and that she is welcomed home. Alexis moves back and Castle is thrilled.