def extract_pdf_links(urls):
    """Filters the input list of urls to look for PDF files. Also removes the rest of the path after the filename

    Parameters
    ----------
    urls : [string]
        A list of urls

    Returns
    -------
    [string]
        A filtered list of input urls
    """
    pdfs = []
    for url in urls:
        u, sep, tail = url.lower().partition('.pdf')
        url = u + sep
        if ".pdf" in url or ".PDF" in url:
            pdfs.append(url)
    return pdfs