Precinct detective following rules to the letter (8)

I believe the answer is:
district
'precinct' is the definition.
(thesaurus)
'following rules to the letter' is the wordplay.
'following rules' becomes 'di' (I am not sure about this - if you are sure you should believe this answer much more).
'to the letter' becomes 'strict' (I've seen this in another clue).
'di'+'strict'='DISTRICT'
'detective' is the link.
This may not be right. It may belong to another bit of the clue.
Can you help me to learn more?
(Other definitions for district that I've seen before include "Area of a town or city" , "Territory, zone" , "Locality" , "Precinct, section" , "'Area, territory (8)'" .)