It's not exactly string-based as it accepts bigint key, but I guess it's possible to hash a string when you pass it to the function.
I assume that if you do it this way, then you see a string key in logs, views of current/locked queries, etc. Which should immensely help when debugging any kind of problems.