docs: def _add_dict_row(self, feature_dict, key=None):
          """ Add a dict row to the matrix
  
          :param str key: key used when rows is a dict rather than an array
          :param dict feature_dict: a dictionary of features and weights
          """
          self._update_internal_column_state(set(feature_dict.keys()))
  
          # reset the row memoization
          self._row_memo = {}
  
          if key is not None:
              if key in self._row_name_idx:
                  self._rows[self._row_name_idx[key]] = feature_dict
                  return
              else:
                  self._row_name_idx[key] = len(self._rows)
                  self._row_name_list.append(key)
  
          self._rows.append(feature_dict)