ItemValue
NameWIKIDATA-QID (a 5Q bundle. See the member table below for the name of each code)
TAG ID0x014L~0x018L
Section0 0000 (Reference entity), offset within section C = 20~24
KindReference · category: declaration
Hugo sidereference/wikidata-qid.md

Members

This page covers one 5Q set, five codes together. The quantification is the offset within the section, C % 5 (Reference). There is one codec document per code. The fields of the five codec documents are the same; only the DECLARE target and the name (BIND) differ.

TAG IDNameQuantificationCodec IDSpec documentTAG WORD
0x014LWIKIDATA-QID-IDENTIFIEDIdentified0x000001400x00000000/codecs/0x00000140/0000 0001 0100 LLLL
0x015LWIKIDATA-QID-GENERICGeneric0x000001500x00000000/codecs/0x00000150/0000 0001 0101 LLLL
0x016LWIKIDATA-QID-FREE-CHOICEFree-choice0x000001600x00000000/codecs/0x00000160/0000 0001 0110 LLLL
0x017LWIKIDATA-QID-UNIVERSALUniversal0x000001700x00000000/codecs/0x00000170/0000 0001 0111 LLLL
0x018LWIKIDATA-QID-VARIABLEVariable0x000001800x00000000/codecs/0x00000180/0000 0001 1000 LLLL

Fields (spec document)

The order of FIELDs in the document is the order of Payload fields (Codec spec document).

OrderField (BIND)FIELDWidthAccepted form (CODEC)ENUM
1qid#2Remaining raw value (0xFFFF)

WIKIDATA-QID is a declaration Reference that points to a Wikidata item. It writes the numeric part of the Q-ID, without the Q, as an unsigned integer.

Layout

TAG WORD          0000 0001 0100 LLLL      Codec 0x014L~0x018L (Identified 0x014L)
[Length extension TAG]
QID               unsigned big-endian in the shortest width
  • The QID is written in the shortest width. Q1 through Q65535 take 2 WORD in total; above that, 3 WORD.
  • Wikidata data is CC0.
  • If Variable, it is an anonymous variable of the kind the item denotes (Reference Variable).

Examples

ItemWORD sequence
Q5 (human)0141 0005
Q76 (Barack Obama)0141 004C
Q884 (South Korea)0141 0374
Q317521 (Elon Musk)0142 0004 D851
Q30461 (president), Variable0181 76FD

Related pages

Spec document source

This is the spec document 0x00000000/codecs/0x00000140/latest.geul as read by geul show (hex in uppercase).

SPEC-VERSION 0x0001
DOC-ID 0x0426000000000000014000000000
BODY
#1 DECLARE 0x0140
#2 FIELD #1 rest
#3 BIND #1 "WIKIDATA-QID-IDENTIFIED"
#4 BIND #2 "qid"

The above is the codec document of WIKIDATA-QID-IDENTIFIED (0x014L). The codec documents of the other members (WIKIDATA-QID-GENERIC, WIKIDATA-QID-FREE-CHOICE, WIKIDATA-QID-UNIVERSAL, WIKIDATA-QID-VARIABLE) differ only in the codec ID of the DOC-ID, the DECLARE target, and the name bound in #1 (BIND).