Two nearby instances of the same word do not automatically establish tashabuh al-atraf. The boundary of the clauses matters: one segment must end with the expression that begins the next.
If the next occurrence advances no new thought, it is only repetition. But a passage ending in “ʿilm” and beginning its next clause with “al-ʿilm” can exhibit the device if the second clause contributes a fresh predication.