Replace all words beginning with a capital letter with the same word, but with the first letter capitalized and the rest of the letters lowercase, in all text files in the current directory and its subdirectories.
sed -i 's/\([A-Z]\)\(\w*\)/\U\1\L\2/g' $(find ./ -type f -name "*.txt")