<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _parse_record(self, record_type):
 """Parse a record."""

        if self._next_token() in ['{', '(']:
            key = self._next_token()
            self.records[key] = {
                u'id': key,
                u'type': record_type.lower()
            }
            if self._next_token() == ',':
                while True:
                    field = self._parse_field()
                    if field:
                        k, v = field[0], field[1]
                        if k in self.keynorms:
                            k = self.keynorms[k]
                        if k == 'pages':
                            v = v.replace(' ', '').replace('--', '-')
                        if k == 'author' or k == 'editor':
                            v = self.parse_names(v)
                        # Recapitalizing the title generally causes more problems than it solves
                        # elif k == 'title':
                        #     v = latex_to_unicode(v, capitalize='title')
                        else:
                            v = latex_to_unicode(v)
                        self.records[key][k] = v
                    if self._token != ',':
                        break