<pre><code>#All PDFs | Rename { query Arxiv for the abstract by filename, use the page title + ".pdf"}

Get-ChildItem *.pdf | Rename-Item -NewName { 
    $title = (Invoke-WebRequest "https://arxiv.org/abs/$($_.BaseName)").parsedhtml.title
    $title = $title -replace '[\\/:\*\?"&lt;&gt;\|]', '-'       # replace forbidden characters
    "$title.pdf"                                          # in filenames with -
}
</code></pre>

<p>You might want to put a <code>-whatif</code> on the end first, to see what it would do, in case it ruins all the filenames. Or take a backup copy of the folder.</p>

<p>Edit: One of the titles is "Signatures of bifurcation on quantum correlations: Case of quantum kicked top" and the <code>:</code> is not allowed in a filename. Script edited to replace all forbidden characters in Windows filenames with dashes instead.</p>
Rename pdf files from recursive numeric strings into original name from same .html (http link) or .txt file
<p>I download some pdf files from <a href="https://arxiv.org/list/quant-ph/1610?skip=0&amp;show=25" rel="nofollow noreferrer">HERE</a><br></p>

<p>Pdf files are downloaded not using original filenames but by number strings like</p>

<pre><code>1610.00005
1610.00022
</code></pre>

<p>Fortunally in this HTTP link page or txt files (if I copy for offline renaming) I have relative <br><br>
<code>numeric -&gt; original text filename</code> 
<br><br>string corrispondence
<br>
For example when I download this files</p>

<pre><code>- A Note on Time Operators in Relativistic Quantum Mechanics
- A Stronger Theorem Against Macro-realism
- Determining quantum correlations in bipartite systems - from qubit to qutrit and beyond
- Pair entanglement in dimerized spin-s chains
</code></pre>

<p>Files are downloaded with this filenames</p>

<pre><code>1610.00005.pdf
1610.00022.pdf
1610.00041.pdf
1610.00056.pdf
</code></pre>

<p>BUT I want rename into original filesname not in a number string
I'd like to set a http link or text file for path</p>

<p>I have only this codes <br><br>(<em>powershell</em>)</p>

<pre><code>$names = Get-Content c\myfiles
Get-ChildItem C:\somedir\*.pdf | Sort -desc | 
    Foreach {$i=0} {Rename-Item $_ ($_.basename + $names[$i++] + $_.extension) -WhatIf}
</code></pre>

<p>or <em>batch code</em></p>

<pre><code>@echo off
setlocal EnableDelayedExpansion

rem Load the list of authors:
set i=0
for /F %%a in (myfiles.txt) do (
   set /A i+=1
   set "author[!i!]=%%a"
)

rem Do the rename:
set i=0
for /F %%a in ('dir /b *.pdf') do (
   set /A i+=1
   for %%i in (!i!) do ren "%%a" "%%~Na!author[%%i]!%%~Xa"
)
</code></pre>