Wikisource:විකි දත්ත
විකිමූලාශ්ර සහ විකි දත්ත අතර ගනු දෙනු සහ තොරතුරු.
Overview
[edit]Wikidata is a "knowledge base" that allows Wikimedia to keep general information in one place. This means things useful to many projects only need to be recorded and maintained once, rather than each of the hundreds of projects spending time maintaining their own versions of the same thing.
Wikidata is made up of "data items" which each relate to a single thing. For example, each author should have a data item, which will connect to every page about that author on any project via interwiki links, and a list of data statements with facts about the author (like date of birth). Each data item has a unique Q-number ID; for example, the author Douglas Adams
is Q42. Similarly, properties are referenced with P-numbers; for example, date of birth
is P569.
Each data item is made up of a label, a description, aliases, a section for labels and descriptions in other languages (based on templates on your talk page), statements, and interwiki links. Practically, from Wikisource's point of view, each data item holds two important things: data statements and interwiki links.
Wikidata can be edited from Wikisource by utilising the WE-Framework gadget available through your Gadgets. The gadget when activated provides types of links to item types in the left toolbar, with a settings that will allows one to toggle on and off item types of interest.
Labels and descriptions
[edit]The label is the title of the data item in bold text. The description is a short line of text underneath it. They will both be displayed in searches for this item and the label will be used wherever the data item is linked. Both are free text fields.
The label should be short and usually lowercase (unless proper noun). It does not need to be unique; the description should disambiguate between different items. Descriptions are also short and usually lowercase; they should not be sentences, just the minimum amount of information (for example, "American author" or "French physicist"; "novel by Charles Dickens" or "short story by H. P. Lovecraft").
Underneath the description will be the text "Also known as:" and a list of aliases. Aliases work as alternatives to the label. Aliases will be picked up in searches and will function as alternative labels if used as a value in a statement. There is no limit to the number of aliases a data item may have.
Different label and descriptions exist for each language; you will probably be seeing just the English set. A babel magic word on your userpage will both display your proficiency with languages and set which additional sets of labels and descriptions are available when you edit. For example, {{#babel:en|fr|de-2}}
, shows fluency in English (en) and French (fr) and a basic understanding of German (de); when editing a data item, the French and German sets of label and description will be shown.
See Wikidata's Help:Label, Help:Description, and Help:Aliases for more information on these things.
Statements
[edit]Most of the data on Wikidata is held in the statements. A basic statement is made up of a property and a value (which are together called the "claim"). To this can be added sources and qualifiers. Multiple values can be assigned to each property. Each value can have multiple sources and/or qualifiers. The type of value allowed depends on the property (many are free text, date-based properties will only allow dates, others will only allow links to other data items).
See Wikidata's Help:Statements for more information on statements.
Interwiki links
[edit]These are called sitelinks on Wikidata. A data item can be connected to a page on Wikisource by going to the data item page on Wikidata and entering the Wikisource page name as a page link. A single data item can only be connected to a single page on each project and vice versa.
Wikisource links are held under the heading Wikisource pages linked to this item. Each page link has three parts: language, code, and linked page.
Interwiki links and some sister links are controlled via this process (both can still be manually entered on Wikisource).
A page on Wikisource can suppress interwiki links held by Wikidata. Adding the {{noexternallanglinks}}
magic word to a page suppresses all interwiki links. Specific languages can be suppressed by listing the language code in the magic word; i.e. {{noexternallanglinks:es|fr|it}}
to suppress links to the Spanish, French and Italian Wikisources.
Adding interwiki links
[edit]- With Javascript enabled:
- Find or create the data item for the page you want connected to Wikidata.
- Go to the section entitled "Wikisource pages linked to this item".
- Click the
[add]
link. - Two fields will appear:
- Enter the "site" (the first field) as "enwikisource". Simply typing "en" will normally be enough as the rest will be auto-completed. Either way, there will be a short period of buffering while Wikidata processes this.
- Enter the "page" (the second field) as the page name, as it appears on Wikisource. There will be a short period of buffering while Wikidata processes this, after which a list of matching pages on Wikisource will appear below the field. The page link can be chosen from this list or, if complete, left as it is.
- Click save.
- With Javascript disabled:
- Find or create the data item for the page you want connected to Wikidata.
- Go to the section entitled "Wikisource pages linked to this item".
- Click the
[add]
link. - You will be taken to a new page with the title "Set a site link" and three fields:
- The first field, "ID", should be preloaded with the data item ID (Q-number). If not, fill this in.
- In the second field, "Site id", enter "enwikisource".
- In the third field, "Site link", enter the page name as it appears on Wikisource.
- Click the "Set the site link" button.
The "language" will be derived from the site, which will appear under "code". The page title will be shown as a link under "linked page".
Adding status badges
[edit]There is the ability to add a status badge to a link to indicate the transcription status of the linked work
- not proofread (not proofread (Q20748091))
- proofread (QQ20748092 (QQ20748092))
- validated (QQ20748093 (QQ20748093))
- problematic (QQ20748094 (QQ20748094))
- digital document (QQ28064618 (QQ28064618))
This status is based on the status of the index: page for the work.
To add the status, it can be added at the time of adding the link, or later by editing the link.
- When editing the interwiki links, click on the badge icon to the right of the link.
- Hover over the ellipsis symbol will produce a drop down list of status, the four Wikisource badges are at the bottom of the list
- Select the appropriate status for the work
- Save the interwiki link.
Editing interwiki links
[edit]- With Javascript enabled:
- Find or create the data item you want to edit.
- Go to the section entitled "Wikisource pages linked to this item".
- Find the specific page link to be editing.
- Click the
[edit]
link at the end of this row. - Make changes:
- The page link can be edited but the site cannot.
- The entire link can be deleted by clicking the "remove" link.
- The page link can be moved to a different data link by clicking the "move" link. Wikidata will ask for the item id (Q-number) of the page the link is to be moved to.
- Add a status badge for the work
- Save the changes or click cancel to abandon them.
WE-Framework gadget
[edit]If an item exists at Wikidata, there is the requirement to add the interwiki link as explained above. (Usually the case when creating author pages.)
If there is not a corresponding item at Wikidata, then the gadget will allow the creation of the item with the interwiki link and the metadata at the same time. (Usually the case when you have transcribed an edition of a work)
Managing data items
[edit]Authors
[edit]Important statements to use for all authors are:
instance of
(P31) →human
(Q5)sex or gender
(P21) → as appropriate for the author—the available options are male (Q6581097), female (Q6581072), intersex (Q1097630), transgender female (Q1052281), transgender male (Q15145783), or genderqueer (Q48270)
Other common statements to add are:
date of birth
(P569)date of death
(P570)place of birth
(P19)place of death
(P20)country of citizenship
(P27)occupation
(P106) → options includeauthor
Q482980, as well as specific professionsfield of work
(P101) → complimentsoccupation
, options includephysics
,chemistry
(or specific sub-fields), etcposition held
(P39)image
(P18) → filename on Commons, usually a portrait of the authornative language
(P103)- Any authority control statement, such as
VIAF identifier
(P214)
Consider adding instance of
→author
(or politician
, etc) by clicking "[add]" in the bottom right of the existing instance of
statement
If you do not personally know the data, it is better to leave the fields empty, than to state than force a data field to state it is unknown.
Works
[edit]Works on Wikidata are split into two data items:
- Work items: For the work in general.
- Edition items: For each specific version or edition.
Each work should have a work item and at least one edition. There may be multiple editions on one Wikisource. Each language subdomain probably uses a different edition, which are all linked to the same work item. Wikipedia and most other projects will usually link directly to the work item, unless there is something of note about a given edition.
Work items should hold information true to all editions, versions, manifestations, or implementations of the work. This includes the title, author and genre, as well as any generally-important information about the first edition such as the original language, country of origin and original publication date.
Edition items should hold information the applies just to that version of the work. This includes some generic information, such as title and author. The edition-specific data should be the publisher (along with location and date of publication), printer, additional work that applies to that edition (such as illustrations, translation or editing credits), and so on. The scan on Commons can be linked, as well as external scans of the same edition.
Work item | Edition items |
---|---|
Treasure Island (Q185118) |
|
Which could be represented as:-
Template:Tree chart/start Template:Tree chart Template:Tree chart Template:Tree chart Template:Tree chart/end
See Wikidata's Books task force for more information. See Wikidata:List of properties for a list of work- and edition-specific properties.
Work items
[edit]Important statements to use for all works are:
- QP31 (QP31) → as appropriate for the work, options include: QQ47461344 (QQ47461344), QQ386724 (QQ386724), QQ8261 (QQ8261), QQ49084 (QQ49084), etc. (combinations of values are quite common)
- QP747 (QP747) → the corresponding edition item(s)
- QP50 (QP50)
- QP1476 (QP1476)
- QP1680 (QP1680)
- QP407 (QP407)
Other common statements to add are:
- QP18 (QP18) → filename on Commons, often the most popular or widely-recognised cover or title page
- QP495 (QP495)
- QP136 (QP136)
- QP921 (QP921) → data item of the topic or subject of the work (reverse property QP805 (QP805) can link back)
- QP840 (QP840)
- QP674 (QP674)
- QP155 (QP155) → data item of the previous item in the series
- QP156 (QP156) → data item of the sequel or next in series
- QP179 (QP179) → data item of the series in which this work is an instalment
- QP825 (QP825)
Authority control that applies to a work includes:
- QP5331 (QP5331)
- QP648 (QP648) (only if it starts with "W")
Edition items
[edit]Important statements to use for all editions are:
- QP31 (QP31) → version, edition or translation (Q3331189) (or any subclass)
- QP629 (QP629) → the corresponding work item
- QP1476 (QP1476)
- QP1680 (QP1680)
- QP50 (QP50)
- QP577 (QP577)
- QP291 (QP291)
- QP123 (QP123)
- QP996 (QP996)
- QP407 (QP407)
- QP953 (QP953) → URL for the text on Wikisource (although this is redundant to the Wikisource site link, it may be of use to other, non-Wikimedia, users of Wikidata's data)
- QP275 (QP275) → matches the licence template, e.g. QQ19652 (QQ19652), QQ6905942 (QQ6905942), etc (most PD-x licences should just use
public domain
on Wikidata)
Other common statements to add are:
- QP18 (QP18) → filename on Commons, often the cover or title page of the edition
- QP955 (QP955)
- QP98 (QP98)
- QP110 (QP110)
- QP495 (QP495) → country data item, useful for work published in countries other than the original
- QP407 (QP407) → language of this edition, useful for translations
- QP393 (QP393) → number of the edition (e.g.
1
,2
, etc) - QP1104 (QP1104)
- QP1957 (QP1957)
Authority control properties that apply to editions include:
- QP212 (QP212), QP957 (QP957)
- QP1144 (QP1144)
- QP243 (QP243)
- QP648 (QP648) (only if it starts with "M")
Links or identifiers of resources that hold scanned copies of works also attach to editions:
- QP724 (QP724)
- QP675 (QP675)
- QP1184 (QP1184) (of which Hathi Trust IDs are an example)
Portals
[edit]Portals can link to a number of items depending on what exists, and the hierarchy of linking
- If a corresponding portal item exists, use QP31 (QP31) → QQ4663903 (QQ4663903) and that item will connect via property QP1204 (QP1204).
- The topic's data item should use the inverse property Template:Property to point back to the portal.
- Where a Wikidata item does not yet exist for the Portal, then the portal will be linked using the topic's Wikisource sitelink.
Illustrations
[edit]Illustrations in a book are generally managed at Commons using "Structured Data on Commons" (SDC).
- The file uses QP1433 (QP1433) to refer to the Wikidata item of the edition it appeared in.
- This means that all illustrations with SDC data require an edition item to exist at Wikidata to be complete
- File-specific data should be set directly on the file at Commons, according to Commons:Structured data/Modeling/Illustrations.
- Generally, unless a specific illustration in a specific edition is famous, there is no dedicated Wikidata item for an illustration
Using Wikidata data at Wikisource
[edit]Data statements
[edit]When used on a page that is connected to Wikidata, the {{#property:
parser function can access data from that item.
Properties can be accessed by the name of the property or by the property number. For example:
{{#property:genre}}
or{{#property:P136}}
will return the "genre" value.{{#property:date of birth}}
or{{#property:P569}}
will return the date of birth value.
Wikidata has a list of its properties, to show what can be returned (if the data item contains the property as one of its statements).
Modules
[edit]Data can also be accessed with Lua modules, which are much more flexible.
Return | Module | Function |
---|---|---|
ID number | WikidataIB | {{#invoke:WikidataIB|pageId}}
|
Label (page title) on Wikidata | WikidataIB | {{#invoke:WikidataIB|label}}
|
Page title on Wikisource | WikidataIB | {{#invoke:WikibaseIB|getAT}}
|
Wikilinked value | WikidataIB | {{#invoke:WikidataIB|getValue}}
|
Non-wikilinked value | WikidataIB | {{#invoke:WikidataIB|getValue|linked=no}}
|
Queries
[edit]Wikidata queries can be formatted using {{SPARQL}}.
See also Category:Wikidata queries
Maintenance
[edit]Some maintenance resources for Wikidata.
Tracking categories:
- Category:Author pages connected to Wikidata, lists all pages in the Author namespace currently linked to Wikidata
- Category:Author pages not connected to Wikidata, lists all pages in the Author namespace that have not yet been linked to Wikidata.
Wikidata queries:
- all books before 1923 in English, without wikisource page, ordered by decreasing number of sitelinks : this list shows the most well known books without wikisource page, either because the wikisource page was not added to wikidata, or because the book has not been transcribed yet.
Useful pages:
See also
[edit]- Wikidata:Wikisource origins of putting Wikisource into Wikidata
- Wikidata:WikiProject Books to read about the difference between literary works (books) and editions. Wikisource typically produces editions.