The current solution is put a "Twitter" in a bad area and construct new buildings around. So far seems is working.
I can say that people here are the most friendly ever seen so far (I'm european and I traveled a lot Europe, can't say about others places in the us).
So, I fatigue to think that San Franciscans are "bad" and they left most behind.
IMHO part of the problem is an heritage of and old lifestyle (especially with drugs).
What really upset me a bit is that here these people have no social care for their mental issues. Some are quite dangerous and I got really scared few times when I lived in tenderloin.