Limited support
This feature is only present in Portal 2: Community Edition and Portal: Revolution.

sv_npc_talker_maxdist

🟩 Executable on Server

sv_npc_talker_maxdist <value>

NPCs over this distance from the player won't attempt to speak.