<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://www.stringwiki.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Rebeca123</id>
	<title>String Theory Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://www.stringwiki.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Rebeca123"/>
	<link rel="alternate" type="text/html" href="http://www.stringwiki.org/wiki/Special:Contributions/Rebeca123"/>
	<updated>2026-04-10T19:46:16Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.1</generator>
	<entry>
		<id>http://www.stringwiki.org/w/index.php?title=SPIRES_script&amp;diff=2518</id>
		<title>SPIRES script</title>
		<link rel="alternate" type="text/html" href="http://www.stringwiki.org/w/index.php?title=SPIRES_script&amp;diff=2518"/>
		<updated>2010-07-14T13:38:46Z</updated>

		<summary type="html">&lt;p&gt;Rebeca123: /* thanks */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;SPIRES script is a program written in the [http://www.python.org/ python] programming language that accesses information on papers in the [http://www.slac.stanford.edu/spires/ SPIRES] online high energy physics literature database.  It can access title, author, bibitem and [[References with BiBTeX|BiBTeX]] records, update your local BiBTeX library and download papers from the [http://www.arxiv.org/ arXiv].  A separate program [[#listcitations.py|listcitations.py]] reads through a TeX file and then looks up all the \cite{...} references and outputs the bibitems.  Although originally written for the GNU/Linux command line, the code should be portable enough to run on any operating system with a python interpreter.&lt;br /&gt;
&lt;br /&gt;
===download===&lt;br /&gt;
Download [[Spires.py|spires.py]] and [[Listcitations.py|listcitations.py]].&lt;br /&gt;
&lt;br /&gt;
===installation on a GNU/Linux system===&lt;br /&gt;
The script requires the python interpreter to be installed on your system.  This is automatically installed on most GNU/Linux distributions, but check it is there by typing&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
at the command line and see what happens.&lt;br /&gt;
&lt;br /&gt;
If python is present download [[Spires.py|spires.py]] and run it by typing&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python spires.py hep-th/9711200&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===usage===&lt;br /&gt;
&lt;br /&gt;
The typical accepted inputs are the usual arXiv references, the SPIRES TeX key or a SPIRES-style journal reference&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python spires.py hep-th/9711200&lt;br /&gt;
python spires.py 0705.0303&lt;br /&gt;
python spires.py Maldacena:1997re&lt;br /&gt;
python spires.py CMPHA,43,199&lt;br /&gt;
python spires.py Phys.Rev.,D52,5783&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If no options are specified all possible outputs will be displayed&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tom@fyodor:~$ python spires.py hep-th/9711200&lt;br /&gt;
@Article{Maldacena:1997re,&lt;br /&gt;
     author    = &amp;quot;Maldacena, Juan M.&amp;quot;,&lt;br /&gt;
     title     = &amp;quot;The large N limit of superconformal field theories and&lt;br /&gt;
                  supergravity&amp;quot;,&lt;br /&gt;
     journal   = &amp;quot;Adv. Theor. Math. Phys.&amp;quot;,&lt;br /&gt;
     volume    = &amp;quot;2&amp;quot;,&lt;br /&gt;
     year      = &amp;quot;1998&amp;quot;,&lt;br /&gt;
     pages     = &amp;quot;231-252&amp;quot;,&lt;br /&gt;
     eprint    = &amp;quot;hep-th/9711200&amp;quot;,&lt;br /&gt;
     SLACcitation  = &amp;quot;%%CITATION = HEP-TH/9711200;%%&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
Maldacena, Juan M.&lt;br /&gt;
The large N limit of superconformal field theories and supergravity&lt;br /&gt;
\cite{Maldacena:1997re}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To see all the options access the help page&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tom@fyodor:~$ python spires.py -h&lt;br /&gt;
SPIRES script&lt;br /&gt;
Usage:&lt;br /&gt;
python spires.py reference [ -hbiatcev ] [ --help ] [ --library library.bib ] [ --download download_path/ ]&lt;br /&gt;
&amp;quot;reference&amp;quot; must be a standard arXiv reference, e.g. hep-th/9711200, 0705.0303, Maldacena:1997re or a SPIRES journal reference, e.g. CMPHA,43,199&lt;br /&gt;
Options:&lt;br /&gt;
-h, --help&lt;br /&gt;
displays this help message&lt;br /&gt;
-b&lt;br /&gt;
displays the BiBTeX entry&lt;br /&gt;
-i&lt;br /&gt;
displays the bibitem entry&lt;br /&gt;
-a&lt;br /&gt;
displays the author(s)&lt;br /&gt;
-t&lt;br /&gt;
displays the title&lt;br /&gt;
-c&lt;br /&gt;
displays the TeX citation key&lt;br /&gt;
-e&lt;br /&gt;
displays everything&lt;br /&gt;
-v&lt;br /&gt;
verbose mode&lt;br /&gt;
&lt;br /&gt;
--download download_path/&lt;br /&gt;
for arXiv references downloads a pdf of the paper from the arXiv to the directory download_path/&lt;br /&gt;
--library library.bib&lt;br /&gt;
if it is not already in library.bib, appends the BiBTeX entry to library.bib; use at your own risk&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Each item can be specified individually with switches, e.g. -t for title, -a for authors, -b for BiBTeX entry, -c for SPIRES TeX key.  For example&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tom@fyodor:~$ python spires.py hep-th/9711200 -at&lt;br /&gt;
Maldacena, Juan M.&lt;br /&gt;
The large N limit of superconformal field theories and supergravity&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you have a BiBTeX database file such as library.bib then the script can update the file with the BiBTeX entry if it is not already present&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python spires.py hep-th/9711200 --library library.bib&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To download a PDF of an eprint from the [http://www.arxiv.org/ arXiv] to the directory &amp;lt;code&amp;gt;some_folder/&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python spires.py hep-th/9711200 --download some_folder/&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===listcitations.py===&lt;br /&gt;
To use this program you must download [[Spires.py|spires.py]] and [[Listcitations.py|listcitations.py]] into the same directory.&lt;br /&gt;
&lt;br /&gt;
This program reads a TeX file and then looks up all the \cite{...} references and outputs the bibitems. The typical accepted inputs are the usual arXiv references, the SPIRES TeX key or a SPIRES-style journal reference.  With no options it will output bibitems&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python listcitations.py tex_file.tex&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It can also output BiBTeX entries instead&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python listcitations.py tex_file.tex -b&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
To see all the options access the help page&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tom@tarkovsky:~$ python listcitations.py -h&lt;br /&gt;
list citations script&lt;br /&gt;
Usage:&lt;br /&gt;
python listcitations.py TeX_file_name.tex [ -hbiv ] [ --help ]&lt;br /&gt;
&lt;br /&gt;
TeX_file_name must contain citations as standard arXiv references,&lt;br /&gt;
e.g. hep-th/9711200, 0705.0303, Maldacena:1997re or SPIRES journal&lt;br /&gt;
references, e.g. CMPHA,43,199&lt;br /&gt;
&lt;br /&gt;
Options:&lt;br /&gt;
-h, --help&lt;br /&gt;
displays this help message&lt;br /&gt;
-b&lt;br /&gt;
displays the BiBTeX entry&lt;br /&gt;
-i&lt;br /&gt;
displays the bibitem entry&lt;br /&gt;
-v&lt;br /&gt;
verbose mode&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===future features===&lt;br /&gt;
&lt;br /&gt;
* allow alias citations such as \cite{mypaper} for listcitations.py&lt;br /&gt;
&lt;br /&gt;
===technical details===&lt;br /&gt;
&lt;br /&gt;
The code is very modular so it is easy to write your own programs using the functions defined in spires.py.  Just import the functions in spires.py with &amp;lt;code&amp;gt;import spires&amp;lt;/code&amp;gt;; you can use spires.py as a library of SPIRES-related functions (see [[Listcitations.py|listcitations.py]] as an example).&lt;br /&gt;
&lt;br /&gt;
===comments and bugs===&lt;br /&gt;
If you have any comments or find bugs, please contact [[User:Tom|Tom]].&lt;br /&gt;
&lt;br /&gt;
===thanks===&lt;br /&gt;
Thanks to Travis C. Brooks of [http://www.slac.stanford.edu/spires/ SPIRES] for his help and [http://theory.tifr.res.in/~kevin/ Kevin Goldstein] for pointing out the python &amp;lt;code&amp;gt;urllib&amp;lt;/code&amp;gt; library.&lt;br /&gt;
*[http://www.superiorpapers.com/reasons.php buy term papers]&lt;br /&gt;
&lt;br /&gt;
===licence===&lt;br /&gt;
This script is Copyright 2007 Tom Brown and made available under the [http://www.gnu.org/copyleft/gpl.html GNU General Public Licence].&lt;/div&gt;</summary>
		<author><name>Rebeca123</name></author>
	</entry>
</feed>