Hi,
I was looking for an web based API to query the coordinate property of wiki
articles. Is there a way to do that ? It should be such that given location
coordinates it should give be the related articles.
thanks
-Arpit
What's the best way to tell if an article is in a general category? Specifically, given a page title, I want to know if that page is (transitively) in Category:Song. For example, I can get
http://en.wikipedia.org/w/api.php?action=query&prop=categories&titles=bohem…
which gives me (in part)
<page pageid="41953" ns="0" title="Bohemian Rhapsody">
<categories>
<cl ns="14" title="Category:1975 singles" />
<cl ns="14" title="Category:1976 singles" />
<cl ns="14" title="Category:1991 singles" />
<cl ns="14" title="Category:1992 singles" />
<cl ns="14" title="Category:All articles with unsourced statements" />
<cl ns="14" title="Category:Articles with hAudio microformats" />
<cl ns="14" title="Category:Articles with unsourced statements from April 2010" />
<cl ns="14" title="Category:BRIT Award for British Single" />
<cl ns="14" title="Category:Christmas number-one singles in the United Kingdom" />
<cl ns="14" title="Category:Dutch Top 40 number-one singles" />
<cl ns="14" title="Category:Good articles" />
<cl ns="14" title="Category:Grammy Hall of Fame Award recipients" />
<cl ns="14" title="Category:Irish Singles Chart number-one singles" />
<cl ns="14" title="Category:Music videos directed by Bruce Gowers" />
<cl ns="14" title="Category:Number-one singles in Australia" />
<cl ns="14" title="Category:Number-one singles in New Zealand" />
<cl ns="14" title="Category:Number-one singles in Spain" />
<cl ns="14" title="Category:Parlophone singles" />
<cl ns="14" title="Category:Queen (band) songs" />
<cl ns="14" title="Category:RPM Top Singles number-one singles" />
<cl ns="14" title="Category:Rock ballads" />
<cl ns="14" title="Category:Singlechart" />
<cl ns="14" title="Category:Singlechart usages for Billboardhot100" />
<cl ns="14" title="Category:Singlechart usages for Dutch100" />
<cl ns="14" title="Category:Singlechart usages for New Zealand" />
<cl ns="14" title="Category:Singlechart usages for UK" />
<cl ns="14" title="Category:Songs written by Freddie Mercury" />
<cl ns="14" title="Category:UK Singles Chart number-one singles" />
<cl ns="14" title="Category:Use British English from August 2010" />
<cl ns="14" title="Category:Use dmy dates from August 2010" />
</categories>
</page>
What I really want to know is if the page is in Category:Song. In fact, it is, because of the category chain: 1975 singles -> 1975 songs -> Songs by year -> Songs, but finding that path involved some intuition about likely paths to explore. Lacking such intuition, is there any better mechanism in the API other than an exhaustive search through the category tree?
--
Roy Smith
roy(a)panix.com
Hi everyone,
As you may know, we're working on an update to Pending Changes for
next month. One thing we're trying to do is to improve the perceived
performance:
https://bugzilla.wikimedia.org/show_bug.cgi?id=25289
("Make review load faster by speeding up display of old revisions")
The problem, in a nutshell, is that the diff page includes two parts:
the diff itself, and a parsed version of the later revision. If the
later revision is not the latest revision, that revision isn't cached.
For complicated pages, parsing can take 20 seconds or longer.
Priyanka is the dev working on this, and the strategy she is pursuing
now is to switch from immediately parsing the later revision, and
instead calling the API to get a parsed version of the latest
revision. What that means is that we can display the diff
immediately, and then inject the diff via Javascript.
In talking to Sam this morning about this, a couple things became clear:
1. This requires action=parse, which is already on the list of APIs
that generate healthy load
2. While this move should be net-neutral in CPU load, it does shift
the load from general purpose Apaches to the API servers, the latter
of which are more heavily loaded
Additionally, it's theoretically possible that this will actually
generate more load, since it'll be easier for people to skim the
history, unintentionally generating lots of (never completed) API
calls.
How big of a problem is this?
Rob
(sending to main tech lists, crossposted to Tech Blog[0], feel free to forward
anywhere else you'd like)
Greetings MediaWiki hackers!
I am pleased to announce the upcoming MediaWiki Hack-A-Ton in Washington, DC.
As you are all aware, every year in April our good friends at
Wikimedia Deutschland
host the annual "MediaWiki Developers Meetup" in Berlin. At that
event, the program
is focused on demonstrations, workshops and small group discussions. To
complement this, we're planning the DC meetup to be focused solely on hacking,
bugfixing and getting down and dirty with the code.
We're scheduling this for October 22nd-24th in Washington, DC. Some of
the details
haven't been ironed out yet, but will be announced over the coming
days as it is.
So clear your calendars, and keep your eyes on MediaWiki.org[1] and the mailing
lists for more information.
Some travel assistance may be available for those coming a long way. I've also
been told there will be swag of some sort for attendees :)
-Chad
[0] http://techblog.wikimedia.org/2010/09/hack-a-ton-dc/
[1] http://www.mediawiki.org/wiki/Hack-A-Ton_DC
Hi,
Does the following API call expand templates recursively ?
http://en.wikipedia.org/w/api.php?action=expandtemplates&text={{Project:San…
ie. if the expansion of the template "Project:Sandbox" has a template in
it, will that get expanded as well ? If not, what is the easiest way to
do this ?
Thanks
Chandra Sekhar
Hello All,
For disambiguation pages like these
http://en.wikipedia.org/wiki/Cricket_(disambiguation)
Is there support in the API to get information about the domain to which the
page belongs like "Insects", "Theatre","Sports and Games" and such? I
couldn't locate it by myself, hence asking for help.
Cricket may also refer to:
*Insects*
Cricket (insect), family Gryllidae, also known as "true crickets"
Tettigoniidae, known as katydids or bush-crickets
*Theatre*
Cricket (musical), a musical by Andrew Lloyd Webber and Tim Rice
*Sports and games*
Cricket (darts), a game using the standard 20-number dartboard
Thanks,
Best Regards
Prateek
Hi,
I would like to get a list of all links. Basically, this query produces the
expected result:
http://en.wikipedia.org/w/api.php?action=query&titles=Active_Worlds&prop=lin
ks
However, I would like to get the PageID for each link (instead of or
together with the name). Is there a simple way to do this?
Best regards,
Christian
This Query seems to work well for the Wictionary, however I would like
something for the main Wikipedia. How can I change it:
http://en.wiktionary.org/w/api.php?action=query&prop=revisions&rvprop=conte…
Also, is there a way to make the Wictionary automatically go to the
recommended definition lookup (bacterium)?
Thanks!
Jeff
Hi,
I have the xml dump of wikipedia. I am trying to locate tables. And a
few tables that I found have their column names specified in templates.
Can someone tell me where in the XML file do I look for templates ?
I have the file "pages-articles.xml.bz2 6.1 GB" downloaded from
http://download.wikimedia.org/enwiki/20100916/ which says it contains
the templates.
Thanks
Chandra Sekhar
Hi,
I'm looking for some API that could help me get the "tables" alone from
a page if it exists.
I've looked at : http://en.wikipedia.org/w/api.php
But nothing seems to be working on tables alone.
I'm new here, so if I am not looking at the right place, please point me
to appropriate links.
Thanks
Chandra Sekhar