adrienbrdne commited on
Commit
283b190
·
verified ·
1 Parent(s): 609134a

Update api.py

Browse files
Files changed (1) hide show
  1. api.py +2 -5
api.py CHANGED
@@ -142,11 +142,8 @@ def extract_research_paper_arxiv(rp_number: str, node_type: str) -> dict:
142
  Here is the document: <document>{rp_data['abstract']}<document>"""
143
 
144
  try:
145
- model_name = "gemini-2.5-flash-preview-05-20"
146
- response = client.generate_content(
147
- model=model_name,
148
- contents=prompt
149
- )
150
 
151
  rp_data["summary"] = response.text
152
  logger.info(f"Summary generated for Arxiv ID: {rp_number}")
 
142
  Here is the document: <document>{rp_data['abstract']}<document>"""
143
 
144
  try:
145
+ model = genai.GenerativeModel("gemini-2.5-flash-preview-05-20")
146
+ response = model.generate_content(prompt)
 
 
 
147
 
148
  rp_data["summary"] = response.text
149
  logger.info(f"Summary generated for Arxiv ID: {rp_number}")