File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 11import base64
22import dill # type: ignore
33import json
4- import requests
4+ import requests # type: ignore
55import os
66import time
77import json
@@ -44,15 +44,15 @@ def analyze_equations(
4444 parsed_paper : Optional [ParseResponse ] = None ,
4545 ) -> Optional [EquationExtractionResponse ]:
4646 if file_path :
47- with open (file_path , "rb" ) as file :
48- response = self ._ax_client .document .equation .from_pdf (document = file )
47+ with open (file_path , "rb" ) as pdf_file :
48+ response = self ._ax_client .document .equation .from_pdf (document = pdf_file )
4949
5050 elif url_path :
5151 if "arxiv" in url_path and "abs" in url_path :
5252 url_path = url_path .replace ("abs" , "pdf" )
5353 file = requests .get (url_path )
5454 from io import BytesIO
55- pdf_file = BytesIO (file .content )
55+ pdf_file = BytesIO (file .content ) # type: ignore [assignment]
5656 response = self ._ax_client .document .equation .from_pdf (document = pdf_file )
5757
5858 elif parsed_paper :
You can’t perform that action at this time.
0 commit comments