Patrick SmartPants is the more intelligent version of Patrick, with interest in science and music. He is less interested in the "unintelligent" hobbies that the normal Patrick would do.
Role in episode
Patrick SmartPants has emerged when normal Patrick's head has been accidentally cut off by smashing through a wall as a result of falling from a cliff. SpongeBob then screws in the "smart" head into Patrick, thinking it was Patrick's original head. The "smart" head accidentally forms Patrick SmartPants. He then acts intelligent for the rest of the episode.
Further, towards the episode, Patrick SmartPants does not like how his friends treat him and misses his old friends' interaction with him. He says that would rather sacrifice intelligence so that he can have friendship, so he takes out his "smart" head and SpongeBob puts Patrick's old head back on. From there on, Patrick SmartPants becomes the normal Patrick once again.