Find all files with the extension .txt in the current directory and its subdirectories, and for each of those files, use sed to replace any strings of the form ddd-ddd-dddd with ddd.ddd.dddd, creating a backup of the original file with the extension .bk.
find ./ -name "*.txt" | xargs sed -E -i.bk 's/(\d{3})-(\d{3})-(\d{4})/$1.$2.$3/'