<commit_before><div class="panel panel-default show-tools">
  <div class="panel-heading">
    <%= t('blacklight.tools.title') %>
  </div>

  <div class="panel-body">
  <ul class="nav">
      <% if (@document.respond_to?(:export_as_mla_citation_txt) || @document.respond_to?(:export_as_apa_citation_txt)) %>
        <li class="cite">
         <%= link_to t('blacklight.tools.cite'), citation_catalog_path(:id => @document), {:id => 'citeLink', :data => {:ajax_modal => "trigger"}} %>
        </li>
      <% end %>
    <% if @document.respond_to?( :to_email_text ) %>
      <li class="email">
      <%= link_to t('blacklight.tools.email'), email_catalog_path(:id => @document), {:id => 'emailLink', :data => {:ajax_modal => "trigger"}} %>
      </li>
    <%- end -%>
    <%- if @document.respond_to?( :to_sms_text ) -%>
      <li class="sms">
      <%= link_to t('blacklight.tools.sms'), sms_catalog_path(:id => @document), {:id => 'smsLink', :data => {:ajax_modal => "trigger"}} %>
      </li>
    <%- end -%>
    
    <% if respond_to? :librarian_view_catalog_path and @document.respond_to?(:to_marc) %>
      <li class="librarian_view">
        <%= link_to t('blacklight.tools.librarian_view'), librarian_view_catalog_path(@document), {:id => 'librarianLink', :data => {:ajax_modal => "trigger"}} %>
      </li>
    <% end %>
  </ul>
  </div>
  <%= display_representative_image(@document, :full_size => true) %><commit_msg>trying to speed up show_tools partial<commit_after><div class="panel panel-default show-tools">
  <div class="panel-heading">
    <%= t('blacklight.tools.title') %>
  </div>

  <div class="panel-body">
  <ul class="nav">
      <% if (@document.has? 'bibtex_t') %>
        <li class="cite">
         <%= link_to 'Cite this', citation_catalog_path(:id => @document), {:id => 'citeLink', :data => {:ajax_modal => "trigger"}} %>
        </li>
      <% end %>
    <% if @document.respond_to?( :to_email_text ) %>
      <li class="email">
      <%= link_to 'Email this', email_catalog_path(:id => @document), {:id => 'emailLink', :data => {:ajax_modal => "trigger"}} %>
      </li>
    <%- end -%>
    <%- if @document.respond_to?( :to_sms_text ) -%>
      <li class="sms">
      <%= link_to 'Text this', sms_catalog_path(:id => @document), {:id => 'smsLink', :data => {:ajax_modal => "trigger"}} %>
      </li>
    <%- end -%>
    
    <% if respond_to? :librarian_view_catalog_path and @document.respond_to?(:to_marc) %>
      <li class="librarian_view">
        <%= link_to t('blacklight.tools.librarian_view'), librarian_view_catalog_path(@document), {:id => 'librarianLink', :data => {:ajax_modal => "trigger"}} %>
      </li>
    <% end %>
  </ul>
  </div>
  <%= display_representative_image(@document, :full_size => true) %>
{'fraction_non_alphanumeric': 0.21789741724263367, 'fraction_numerical': 0.0, 'mean_word_length': 3.560530679933665, 'pattern_counts': {'":': 0, '<': 61, '<?xml version=': 0, '>': 93, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '234713', 'n_tokens_mistral': 1037, 'n_tokens_neox': 964, 'n_words': 172}