Commons:Bots/Requests/FerdiBot

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Operator: Ferdi2005 (talk · contributions · Statistics · Recent activity · block log · User rights log · uploads · Global account information)

Task: it will do a SPARQL query, looking for Wiki Loves Monuments Italy monuments without a category. Then, it’ll search here for photo submitted with that monument’s WLM ID. If it founds one, it’ll create a category and append to that photos the category it has just created. Then it adds the category to wikidata with the property Commons category.

You can find the source code here. Automatic or manually assisted: manually assisted

Edit type (e.g. Continuous, daily, one time run): runs every time the script is launched, once every month

Maximum edit rate (e.g. edits per minute): once every 15 seconda

Bot flag requested: (Y/N): N

Programming language(s): PHP using boz-mw framework. Ferdi2005 (Posta) 07:52, 19 July 2019 (UTC)[reply]

Discussion

[2019-07-29 21:15:10][INFO] login with username 'FerdiBot'
Inizializzzo connessione con usernameFerdiBot</br>  # Initializing connection with username FerdiBot
Esecuzione della query SPAQRL # executing SPARQL query
	SELECT ?item ?itemLabel ?value ?city ?cityLabel ?sitelink ?coords ?citycat WHERE {
	?item wdt:P2186 ?value.
	?item wdt:P17 wd:Q38.
	?city wdt:P373 ?citycat
	FILTER NOT EXISTS { ?item wdt:P373 ?x. }
	FILTER NOT EXISTS { ?item wdt:P935 ?y. }
	SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE], en, it". }
	?item wdt:P131 ?city.
	OPTIONAL { ?item wdt:P625 ?coords.}
	?city wdt:P373 ?citycat
	OPTIONAL {?sitelink schema:isPartOf <https://commons.wikimedia.org/>;schema:about ?item. }
	}
	LIMIT 500</div> <br/> <ol><li> Eseguo operazioni sul monumento [http://www.wikidata.org/entity/Q2391849] complesso nuragico di Tamuli (Q2391849) </a> </br> #Executing operations on the monument
Cerco foto che abbiano il WLMID di quel monumento salvato #looking for photos with that WLMID
Non abbiamo trovato categorie simili.Vuoi che il nome della categoria sia complesso nuragico di Tamuli? Rispondi Y se sì oppure scrivi il nome che la categoria deve avere. Scrivi abort per stoppare ed andare avanti." # We didn't find similar categories. Do you want "complesso nuragico di Tamuli" as category name? Reply Y if yes or write the name the category should have. Write abort to stop and go to the next monument
string with # are my translations from english--Ferdi2005 (Posta) 21:19, 29 July 2019 (UTC)[reply]
Could you please create report in wiki-text, so participants of this discussion could analyze it? --EugeneZelenko (talk) 14:28, 30 July 2019 (UTC)[reply]
@EugeneZelenko: What do you mean for report in Wikitext?--Ferdi2005 (Posta) 19:40, 30 July 2019 (UTC)[reply]
I meant table with links to Wikidata item, possible match and place category when no match found published in your or bot user space. --EugeneZelenko (talk) 13:52, 31 July 2019 (UTC)[reply]
So, you propose to have the bot writing the created categories on a page? An interesting solution would be create manually assisted categories (manual name and printing of similar name categories) and then add to created categories the "To check - WLMIT" category, so I or another volunteer can check the created categories and see if there's any problem. What do you think about this? @EugeneZelenko: --Ferdi2005 (Posta) 19:31, 7 August 2019 (UTC)[reply]
Goal of this test is to check how well bot detects existed categories not linked to Wikidata. There is no need to create new ones at that stage. --EugeneZelenko (talk) 14:10, 8 August 2019 (UTC)[reply]

Closing as stale because of missing feedback from the operator. --Krd 15:36, 10 October 2019 (UTC)[reply]