<human>:  I'm looking for a pythonic way to insert a space before capital letters
<bot>:))', '\\1 ', text)

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.