Support both `std::string` and `std::wstring`
Update python wrapper
Parameters should be passed by reference