Spaces:
Runtime error
Runtime error
Commit
·
4289cb8
1
Parent(s):
23255b8
Update app.py
Browse files
app.py
CHANGED
@@ -48,7 +48,7 @@ def generate_response(prompt):
|
|
48 |
# Function to search PubMed for articles
|
49 |
def search_pubmed(query, retmax):
|
50 |
Entrez.email = '[email protected]'
|
51 |
-
handle = Entrez.esearch(db="pubmed", term=query, retmax=retmax)
|
52 |
record = Entrez.read(handle)
|
53 |
handle.close()
|
54 |
idlist = record['IdList']
|
|
|
48 |
# Function to search PubMed for articles
|
49 |
def search_pubmed(query, retmax):
|
50 |
Entrez.email = '[email protected]'
|
51 |
+
handle = Entrez.esearch(db="pubmed", term=query, retmax=retmax, sort = 'relevance')
|
52 |
record = Entrez.read(handle)
|
53 |
handle.close()
|
54 |
idlist = record['IdList']
|