For seven seasons of Star Trek: The Next Generation -- and its four subsequent films -- Counselor Deanna Troi played a pivotal role aboard the USS Enterprise, but her importance to the NCC1701-D's continuing mission is often overlooked. Early in the The Next Generation pilot episode, "Encounter at Farpoint," Troi and Riker's romantic history was established. Between that and the focus on their relationship in the Star Trek: The Next Generation sequel films and Star Trek: Picard, it's easy to forget that she was always more than the first officer's romantic interest.
Source:https://www.cbr.com/star-trek-the-next-generation-deanna-troi-role-explained/