Typing the the is easy in a long reply. The grammar check flags the second copy with a blue mark.
Click it if you want the extra word removed. If you repeated a word on purpose, leave the mark or ignore that word. Ignoring is global, so use it for a token you really want doubled, not for a one-off slip.
The rule is the immediate repeat. It does not judge whether the paragraph is redundant in a broader way.