I don't think this is something you can learn from a book. It takes exposure to the speech patterns of American speakers.
In American pronunciation the T after N can be silent in relaxed speech or as the result of intonation
-- if the T precedes an unstressed lax (short) vowel.
interview...can sound like... innerview
winter ....can sould like....winner
dentist....can sound like ...dennist
semantic...can sould like....semannic
----
In many words after N the T is followed by a lax vowel that receives a secondary stress. In these cases the T is pronounced.
context.....the e has a secondary stress so it sounds like con text
content....the e has a secondary stress so it sounds like con tent
dentist....if you stress the i sounds like den...tist
semantic....can sound like se man tic
cantankerous.....sounds like can tan k'r's
-----
However, in speech with careful enunciation, in ALL situations it is possible to pronounce the T for the sake of clarity.
It was a winner of a winTer. In this case you would naturally pronounce the T for the sake of clarity.