User talk:TomT0m

Jump to: navigation, search

About this board

Previous discussion was archived at User talk:TomT0m/Archive 1 on 2015-08-10.

Reseletti (talkcontribs)

At least some amount of statements you added back in October 2015 that claim that some software to be written in the C++ programming language seem to not be verifiable anywhere. (like e.g. TweetDeck and Lingoes) I removed some of them. Maybe you want to check.

TomT0m (talkcontribs) on the enwiki,s category « free software programmed in C++ on enwiki’s article. If this is not correct, the category needs to be clean as the datas probably comes from here.

Reseletti (talkcontribs)

That just goes to say that the problem is even bigger? Or that you are willing to take care of these erroneous edits of yours if I fix stuff over there?.. :-/

TomT0m (talkcontribs)

That goes to say that the mistakes have to be corrected also on Wikipedia to prevent this to happen again. And that we have a tool to spot mistakes on enwiki.

Suggestion : is there correspondings category on dewiki or frwiki ? We find them, if there is, and we find mistakes candidates by computing the differences with them and wikidata on petscan.

Reply to "wrong programming language?"
VIGNERON (talkcontribs)


Que faire de regional capital (Q20899166) ? Deux ans plus tard, cet élément n'est utilisé que sur Nantes (Q12191) où il fait doublon avec d'autres informations, notamment

(et où il y a un détail perturbant, c'est le chef-lieu de *région* mais la qualificateur donne le *département*).

Qu'en penses-tu ?

TomT0m (talkcontribs)

Ben c’est une entité admissible, dans tous les cas. Je travaille à Module:Class et à Template:Implied_instances actuellement. L’idée c’est de générer une requête sparql automatiquement à partir des déclarations de la classe (et de ses parentes) gui permet de lister ses instances. J ete tiens au courant des progrès.

VIGNERON (talkcontribs)

D'accord. Pas entièrement convaincu mais pourquoi pas. À déployer sur toutes les capitales de région ?

Sinon, j'ai remplacé Loire-Atlantique par Pays de la Loire en qualificateur.

Reply to "Que faire de Q20899166 ?"

{{Q|17343829‎}} not suitable for some unorganized towns

Jc3s5h (talkcontribs)

I have undone your edit to Averill, Vermont (Q1973943) because I don't not believe that unincorporated community is suitable for entities that are recognized as towns or the like by the appropriate higher level government. See Talk:Q17343829#Areas with official status but "streamlined" government.

TomT0m (talkcontribs)

It comes from the enwiki categories. I do not have a deep understanding of those concepts, but it seems related to « census designated place », who are categorized into « uncorporated communities » in wikipedias. To prevent this to happen again, we have to sort out all this not only on Wikidata but also on Wikipedia. I think that to sort of the « I don’t believe » state we need to have to sort out all this : see the enwiki article about Q498162

Jc3s5h (talkcontribs)

I find it impossible to express myself with the editor in use on your talk page, so will discuss this on the talk page for Q17343829.

Reply to "{{Q|17343829‎}} not suitable for some unorganized towns" (talkcontribs)
  • making ISO 639-3 code 'ara' an instance of ISO 639-2 code
  • turning specific subclass of UID into less specific subclass of machine-readable data
  • making language code a subclass of machine-readable data - (can humans not read language codes?)

There are no items about instances of UIDs. The instances are printed on books, written on paper, etc.

Reply to "Strange statements"
GZWDer (talkcontribs)

Your bot has been listed at Wikidata:Requests for permissions/Removal/Inactive bot accounts as being inactive for over two years. As a housekeeping measure it's proposed to remove the bot flag from inactive bot accounts, unless you expect the bot will be operated again in the near future. If you consent to the removal of the bot flag (or do not reply on the deflag page) you can rerequest the bot flag at Wikidata:Requests for permissions/Bot should you need it again. Of course, You may request retaining your bot flag here if you need the bot flag. Regards--GZWDer (talk) 12:36, 26 June 2017 (UTC)

Reply to "InfoRobBot"

Your feedback matters: Final reminder to take the global Wikimedia survey

MediaWiki message delivery (talkcontribs)

(Sorry to write in Engilsh)

Reply to "Your feedback matters: Final reminder to take the global Wikimedia survey"
Pasleim (talkcontribs)

This is a kind reminder that the following properties were created more than six months ago: approximation algorithm (P1171), admissible rule in (P2577). As of today, these properties are used on less than five items. As the proposer of these properties you probably want to change the unfortunate situation by adding a few statements to items.

Reply to "Unused properties"

Share your experience and feedback as a Wikimedian in this global survey

MediaWiki message delivery (talkcontribs)
  1. This survey is primarily meant to get feedback on the Wikimedia Foundation's current work, not long-term strategy.
  2. Legal stuff: No purchase necessary. Must be the age of majority to participate. Sponsored by the Wikimedia Foundation located at 149 New Montgomery, San Francisco, CA, USA, 94105. Ends January 31, 2017. Void where prohibited. Click here for contest rules.
Reply to "Share your experience and feedback as a Wikimedian in this global survey"
Magnus Manske (talkcontribs)

Hi, you uploaded a catalog to Mix'n'match, with a list of domestic animal breeds. As you may have heard, I had a little accident with that tool, and the labels and descriptions have been overwritten. I have restored most catalogs, but I can't find the source data for this one. Do you by any chance still have that file, or know where I could download/scrape the data? The source site isn't overly helpful in that regard...

Reply to "FAO races"
Xaris333 (talkcontribs)

Hello. I am using modules for fetch from Wikidata some informations to Wikipedia templates. I like your solution in Project chat but I need help to change the Module.

For example, I am using w:el:Module:Τρέχονπρωτάθλημα to find the current season. For example, in Cypriot First Division (Q155965), the module find the current season by checking has as part (P527). The current season is the item with the largest edition number (P393).

Can you change this by the way you said it the Project chat? May the current season is the one with not have followed by (P156) or has no value for followed by (P156). Pls tell me if that is possible because that way if much easier to fetch that kind of data from wikidata.

TomT0m (talkcontribs)

Hi, just implemented Module:Event_sequence_number. It implements the same idea that was used in the query. The potential problem is that it requires as many item loading that there is previous events so it's not usable in too long sequences as the number of item loads is expensive - I'm thinking of other ideas.

For the problem of finding the latest season, I think it's enough to use ranks, exactly as we use ranks for the most recent datas for population.

Xaris333 (talkcontribs)

How to use ranks?

TomT0m (talkcontribs)

Pardon me, this is not possible in that case using "instance of" as it has no inverse properties. But your use of "edition of" suggest another thing : can't you use the "edition of" relationship ? To know how to use ranks please see Help:Rank. Only the best rank statements are by default used in queries and lua.

But I also implemented something with your suggestion to follow the "followed by" property in the (renamed) Module:Event_sequence.

Xaris333 (talkcontribs)

I already known rank. I am using it a lot. Ok, its working for latest season only if I have a list of all season on the league item with the propery has as part (P527). Like Cypriot First Division (Q155965). It is that ok?

TomT0m (talkcontribs)

As said in the previous comment, I'd prefer another property. "Has part" in this case is definitely not used in the usual sense of Help:BMP. Maybe edition(s) (P747) would fit better.

Another remark from your item, the victories as qualifiers are redundant. There is already the list of victories in the club item isn't it ? You definitely can do this with a query : The following query uses these:

select ?team ?teamLabel (count(?championship) as ?num_vict) (group_concat(coalesce(year(?date),""); separator=", ") as ?years) where {
    select ?championship ?team ?date {
    	?championship wdt:P31 wd:Q155965 ;
       	              wdt:P1346 ?team .
        ?championship wdt:P582 ?date .
    } order by asc(?date)
  SERVICE wikibase:label {
    bd:serviceParam wikibase:language "en, el" .
} group by ?team ?teamLabel order by desc(?num_vict)

Try it! and that without having to repeat the data everywhere.

Xaris333 (talkcontribs)

Οκ, οκ. If I find easy way to fetch data from wikidata to Wikipedia templates for: 1) latest season 2) first season 3) previous season 4) last champions

I wouldn't need to repeat that data. I have modules for all these but I need modules that are using different properties. Can you help?

W:el:Module:Τρέχονπρωτάθλημα current season

W:el:Module:Προηγούμενοςπρωταθλητής last champions

W:el:Module:Προηγούμενοπρωτάθλημα previous season

W:el:Module:Πρώτηπερίοδος first season

They all are in English language. May I should ask to project chat for ideas.

TomT0m (talkcontribs)

I don't understand what you mean by "I need modules that are using different properties" - followed/preceded by ? . Do you understand a little the stuffs I wrote in Module:Event_sequence ?

It seems you don't use any other module in yours. Usually we use existing modules to help us writing codes like Module:Wikidata who does a few thing to avoid writing over and over again the same code patterns. In "Event sequence", I used Module:PropertyPath which is powerful and can easily be used for your problems here, but it needs you to copy a few modules itself into elwiki to be usable there - For example the template {{Show path items}} uses PropertyPath it shows how easily it becomes to get the previous season of say 1949–50 Cypriot First Division (Q629654)   with {{Show Path Items|Q629654|preceded by}} :

(here I write the property label in english but in elwiki you would be able to use the greek label if you want to) But you'll have to copy a few modules from here to elwiki to get there :

I'm writing a script to automatically import the modules to elwiki, I'll get you in touch when that's done.

You also use the query I wrote with {{Wikidata list}} in your wikipedia to get an automatically updated table.

Xaris333 (talkcontribs)

"different properties" from those I am using now. I preferred followed/preceded by.

I have copied all modules. But I have stopped when I get a message

Script error: The function "main" does not exist.

Don't know what to do about that.

TomT0m (talkcontribs)

Can you point me to the place you get this error ?

Xaris333 (talkcontribs)

Article .

Is using w:el:Module:Τρέχονπρωτάθλημα.

TomT0m (talkcontribs)

OK, I get it. There is several problems indeed. You need to get familiar with programming with modules. There is indeed no "main" function in that module, so the error message is correct.

To call a module within a template, you must provide a function with a single parameter usually called "frame". It's not necessarily called "main" but the name of function must be the the same as used in the #invoke call. You can access the other parameters {{#invoke:youmodule|main|arg1|arg2|plop=bidou}} - here arg1, arg2 and plop thanks through "frame.args". frame.args[1] will have the value "arg1", 2 "arg2" and frame.args["plop"] will have the values "bidou".

The function I wrote don't work like that, so we need to write new one that call my functions.

Such a function would look like

function p.main(frame)
    local arg1 = frame.args[1]
    local arg2 = frame.args[2]
    local plop = frame.args["plop"]
    -- The useful code here

We kind write several of such functions in a module, for example we could write a second function "show_last_event"

function p.show_last_event(frame)
    local start_item = frame.args[1]
    local event_type_item = frame.args[2]
    local item = p.last_in_sequence(start_item, event_type_item)

    -- write here the code to generate a link from an item

    return link

Now the parameters of my functions needs a start_item and an event type. The start_item could be the Qid of the current season, as time won't turn back, and the event type is the item of the page, probably, as it seem to be the item of the competition class. So we can replace the line local event_type_item = frame.args[2] with local event_type_item = frame.args[2] or mw.wikibase.getEntityObject() to set this value by default to the item of the current page.

Xaris333 (talkcontribs)

Thanks for your time and help. My knowledge about programming are not good. I guess we are talking about different things. If you find an easy way to find the first season, the current season, the previous season and the previous winner please tell me. Thanks for all.

TomT0m (talkcontribs)

Oh, I see you replaced with another module. I was working on tighting everything together, this would have definitely worked, as long as the infobox has a parameter for a sample season in the sequence, but it's as you like. If you want my opinion with the complexity of the code you write you definitely could be able to make the rest work.

Xaris333 (talkcontribs)

Please continue what you were doing. I thought you was done, but the templates continue to show the message Script error: The function "main" does not exist so I restore the module. I am not the written of the Module. A Wikipedia friend helps me. Do what you think is correct and I will see the final result.

Reply to "Lua"