In Dune, Hawat is the Mentat Master of Assassins who has served House Atreides for multiple generations, until Duke Leto Atreides is killed by a Harkonnen attack. Hawat himself is captured by the Imperial Sardaukar during the attack and acquired by the Baron Vladimir Harkonnen through subterfuge.
Baron Vladimir Harkonnen, recognizing good talent and seeking a replacement for his late Mentat Piter De Vries, wishes to utilize Hawat's immense abilities. Calculating that Hawat would direct his efforts for revenge towards the Imperium instead of House Harkonnen, the Baron manages to enlist Hawat into his service while secretly making him chemically dependent on an antidote to a permanent latent poison developed by Piter De Vries and administered to Hawat in his food after his capture. The Baron, himself a dangerous intellect, also keeps Hawat's abilities in check by feeding him false data, specifically, permitting him to believe that Lady Jessica had been the traitor responsible for the Atreides' destruction.
In spite of these immense obstacles, Hawat very nearly brings down the Harkonnens from within. The Baron's nephew and heir Feyd-Rautha attempts to fight a drugged slave to impress the onlooking Count Fenring and his wife Lady Margot. Hawat arranges for Feyd to confront a trained Atreides soldier with his capacities fully intact, his plan being to discredit the Harkonnen slavemaster and replace him with someone loyal to Feyd. This later leads to an assassination attempt on the Baron, as Hawat encourages the ambitions of the Feyd against his uncle. One of The Baron's male slave lovers is implanted with a poison needle; the Baron, warned by Hawat, eludes the attempt on his life and forces Feyd to personally kill every female slave in the pleasure houses.
At the conclusion of the novel, Hawat is coerced to assassinate Leto's son, Paul Atreides. Paul suspects this, but out of gratitude to Hawat's exceptional loyalty, Paul gives him the opportunity to take anything Hawat wishes of him — even his life. Hawat chooses death rather than betray Paul.
Read more about this topic: Hawat