change string to dict