code: def build_references(citations, reference_format=False):
      
      # Now, run the method which will take as input:
      # 1. A list of lists of dictionaries, where each dictionary is a piece
      # of citation information corresponding to a tag in the citation.
      # 2. The line marker for this entire citation line (mulitple citation
      # 'finds' inside a single citation will use the same marker value)
      # The resulting xml line will be a properly marked up form of the
      # citation. It will take into account authors to try and split up
      # references which should be read as two SEPARATE ones.
      return [c for citation_elements in citations
              for elements in citation_elements['elements']
              for c in build_reference_fields(elements,
                                              citation_elements['line_marker'],
                                              citation_elements['raw_ref'],
                                              reference_format)]
docs: Build list of reference dictionaries from a references list