Spaces:
Running
Running
Update smart_fallback.py
Browse files- smart_fallback.py +0 -20
smart_fallback.py
CHANGED
|
@@ -303,26 +303,6 @@ async def async_filter_links_by_metadata(search_results, saveLinkFolder, accessi
|
|
| 303 |
|
| 304 |
return better_filter or filtered
|
| 305 |
|
| 306 |
-
import asyncio
|
| 307 |
-
|
| 308 |
-
async def main():
|
| 309 |
-
search_results = [
|
| 310 |
-
'https://dna-explained.com/2024/01/21/bennett-greenspan-meet-my-extended-family-discover-extraordinary-deep-heritage/',
|
| 311 |
-
'https://pubmed.ncbi.nlm.nih.gov/23666864/',
|
| 312 |
-
'https://www.researchgate.net/profile/Jorge_Estevez2/publication/43070682_The_mtDNA_debate_A_dialogo_on_How_important_is_it/links/5890d8dca6fdcc1b414533b9/The-mtDNA-debate-A-dialogo-on-How-important-is-it.pdf',
|
| 313 |
-
'https://www.researchgate.net/publication/388496723_WBSCR16_is_essential_for_mitochondrial_16S_rRNA_processing_in_mammals/fulltext/679e469552b58d39f2620f92/WBSCR16-is-essential-for-mitochondrial-16S-rRNA-processing-in-mammals.pdf?origin=scientificContributions',
|
| 314 |
-
'http://www.ianlogan.co.uk/checker/accession.htm'
|
| 315 |
-
]
|
| 316 |
-
saveLinkFolder = "1YRP0o-F2NrFkUdbGT8_6EGM0g_TjqEmb"
|
| 317 |
-
accession = "MK975884"
|
| 318 |
-
|
| 319 |
-
results = await async_filter_links_by_metadata(search_results, saveLinkFolder, accession)
|
| 320 |
-
print("Results:", results)
|
| 321 |
-
|
| 322 |
-
if __name__ == "__main__":
|
| 323 |
-
asyncio.run(main())
|
| 324 |
-
|
| 325 |
-
|
| 326 |
def filter_links_by_metadata(search_results, saveLinkFolder, accession=None):
|
| 327 |
TRUSTED_DOMAINS = [
|
| 328 |
"ncbi.nlm.nih.gov",
|
|
|
|
| 303 |
|
| 304 |
return better_filter or filtered
|
| 305 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 306 |
def filter_links_by_metadata(search_results, saveLinkFolder, accession=None):
|
| 307 |
TRUSTED_DOMAINS = [
|
| 308 |
"ncbi.nlm.nih.gov",
|