rewire
US /ˌriːˈwaɪr/
UK /ˌriːˈwaɪr/

1.
2.
to change the way someone or something thinks or functions, often by altering fundamental patterns or connections
:
•
Therapy can help to rewire your brain to overcome negative thoughts.
•
It's difficult to rewire old habits, but it's possible with effort.