跳转到内容

SPARQL/WIKIDATA 词汇数据

来自维基教科书,开放世界中的开放书籍

WIKIDATA 上的数据包含的信息不仅仅是三元组,这些概念:Q 项目与事物或想法相关。自 2018 年以来,维基数据还存储了一种新的数据类型:词语、短语和句子,以多种语言描述,并以多种语言描述。此信息存储在新的实体类型中,称为词条 (L)、形式 (F) 和义项 (S)。

评论本章尚未完成。请帮助扩展它。

词汇表 SPARQL 代码

词条是语言的词汇元素,例如词语、短语或前缀(参见 维基百科上的词条)。词条是维基数据模型意义上的实体。词条使用以下信息进行描述

  • ID。词条的 ID 以“L”开头,后面跟着十进制表示的自然数,例如 L3746552。这些 ID 在管理词条的存储库中是唯一的。ID 可以与存储库的概念基础 URI 结合起来形成词条的唯一 URI。
  • 词形,用作词条的人类可读表示,例如“run”。
  • 词条所属的语言。这是一个对具体项目的引用,例如 英语 (Q1860)
  • 词条所属的词汇类别。这是一个对具体项目的引用,例如 形容词 (Q34698)
  • 词条陈述的列表,用于描述词条的属性,这些属性不是特定于形式或义项的(例如,派生自或语法性别或句法功能)

?l a ontolex:LexicalEntry .
?l wikibase:lemma ?word .
?l dct:language wd:Q1860 . # 英语
?l wikibase:lexicalCategory ?category .

  • 形式列表,通常每个相关的语法特征组合对应一个。形式使用以下信息进行描述
    • ID。形式的 ID 以其所属词条的 ID 开头,后面跟着一个连字符(“-”)和一个“F”,再跟着十进制表示的自然数:例如 L3746552-F7
    • 一个表示,将形式拼写为字符串。
    • 定义给定形式适用于哪种句法角色的语法特征列表。这些特征是具体项目的引用,例如 分词 (Q814722),表示分词
    • 形式陈述的列表,进一步描述形式或其与其他形式或项目的关联(例如,IPA 音标 (P898)发音音频与…押韵使用到…为止在…区域中使用

?l ontolex:lexicalForm ?form .
?form a ontolex:Form .
?form ontolex:representation ?word .
?form wikibase:grammaticalFeature ?feat .

  • 义项的列表,描述词条的不同含义(例如,英语名词 bank 的“金融机构”和“水体的边缘”)。义项使用以下信息进行描述
    • ID。义项的 ID 以其所属词条的 ID 开头,后面跟着一个连字符(“-”)和一个“S”,再跟着十进制表示的自然数:例如 L3746552-S4。这些 ID 在管理词条的存储库中是唯一的。ID 可以与存储库的概念基础 URI 结合起来形成义项的唯一 URI。
    • 释义,使用自然语言定义义项的含义。
    • 义项陈述的列表,进一步描述义项及其与义项和项目的关联(例如,翻译同义词反义词内涵语域表示唤起)。

?l ontolex:sense ?sense .
?sense a ontolex:LexicalSense .
?sense skos:definition ?gloss .
FILTER(LANG(?gloss) = "sv")

前缀仅用于词汇数据

PREFIX ontolex: <http://www.w3.org/ns/lemon/ontolex#>
PREFIX dct: <http://purl.org/dc/terms/>

试试看!

获取特定词条的瑞典语释义

[编辑 | 编辑源代码]
SELECT  ?sense ?gloss
WHERE {
      VALUES ?l {wd:L35455}.   # Swedish noun "vara"
      ?l ontolex:sense ?sense.
      ?sense skos:definition ?gloss.
      # Get only the swedish gloss, exclude otherwise
      FILTER(LANG(?gloss) = "sv")
 }

试试看!

获取具有 P5137(此义项的项目)的特定词条的义项

[编辑 | 编辑源代码]
SELECT ?sense ?gloss
WHERE {
      VALUES ?l {wd:L39751}.   # Swedish adjective "smaklös"
      ?l ontolex:sense ?sense.
      ?sense skos:definition ?gloss.
      # Exclude lexemes without a linked QID from at least one sense
      ?sense wdt:P5137 [].     # has P5137 (item for this sense)
}

试试看!

描述颜色的词条

[编辑 | 编辑源代码]
# By Vesihiisi
SELECT ?l ?lemma ?languageLabel  WHERE {
  ?l a ontolex:LexicalEntry; 
       dct:language ?language; 
       wikibase:lemma ?lemma .
  ?l wdt:P31 wd:Q376431.   # color term
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ?languageLabel

试试看!

每种语言的词语

[编辑 | 编辑源代码]

以下是每种语言的词语数量概述

SELECT  (?language AS ?label) (COUNT(*) AS ?count) 
WHERE {
   ?l a ontolex:LexicalEntry ; wikibase:lemma ?word .
   BIND( LANG(?word) AS ?language ) 
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} 
GROUP BY ?language 
ORDER BY DESC(?count)

试试看!

英语和美式英语

[编辑 | 编辑源代码]

此查询列出英语和美式英语中所有不同的词语

SELECT  ?l ?english ?american
WHERE {
      ?l wikibase:lemma ?english .  FILTER(LANG(?english)="en-gb")
      ?l wikibase:lemma ?american . FILTER(LANG(?american)="en")
      FILTER(?english!=?american)
}
ORDER BY ?english

试试看!

词汇类别的概述

[编辑 | 编辑源代码]

以下是英语中最常用的词汇类别的概述

SELECT ?categoryLabel (COUNT(*) AS ?count) 
WHERE {
   ?l a ontolex:LexicalEntry ; wikibase:lemma ?word ; wikibase:lexicalCategory ?category; dct:language ?language.
   ?language wdt:P218 'en'
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} 
GROUP BY ?categoryLabel
ORDER BY DESC(?count)

试试看!

最长的词语

[编辑 | 编辑源代码]

以下是以英语为例的最长词语列表

SELECT DISTINCT ?l ?word ?len 
WHERE {
  {
   ?l a ontolex:LexicalEntry ; dct:language wd:Q1860 ; wikibase:lemma ?word .
   BIND(strlen(?word) as ?len)  
  } UNION {
   ?l a ontolex:LexicalEntry ; dct:language wd:Q1860 ; ontolex:lexicalForm/ontolex:representation ?word .
   BIND(strlen(?word) as ?len)  
  }
} 
order by DESC(?len) 
LIMIT 20

试试看!

形容词

[编辑 | 编辑源代码]

此示例展示了(英文)形容词及其原级、比较级和最高级形式。通过更改VALUES ?language { wd:Q1860 },可以将此查询更改为任何语言。

# adjectives
SELECT DISTINCT ?l ?word (GROUP_CONCAT(DISTINCT ?subfeatLabel; SEPARATOR=", ") AS ?subfeatures) 
        (GROUP_CONCAT(DISTINCT ?positive;    SEPARATOR=", ") AS ?Positive)
        (GROUP_CONCAT(DISTINCT ?comparative; SEPARATOR=", ") AS ?Comparative)
        (GROUP_CONCAT(DISTINCT ?superlative; SEPARATOR=", ") AS ?Superlative)
WHERE {
   VALUES ?language { wd:Q1860 } # English
  
   ?l a ontolex:LexicalEntry ; wikibase:lemma ?word; wikibase:lexicalCategory wd:Q34698 .      # adjective
   ?l dct:language ?language.

OPTIONAL {      
   ?l ontolex:lexicalForm ?form1 .
   ?form1 ontolex:representation ?positive ;       wikibase:grammaticalFeature wd:Q3482678 .   # positive
   OPTIONAL { ?form1 wikibase:grammaticalFeature ?subfeat . FILTER(?subfeat != wd:Q3482678 ) } 
}

   ?l ontolex:lexicalForm ?form2 .
   ?form2 ontolex:representation ?comparative ;    wikibase:grammaticalFeature wd:Q14169499 .   # comparative
   OPTIONAL { ?form2 wikibase:grammaticalFeature ?subfeat . FILTER(?subfeat != wd:Q14169499 ) } 

   ?l ontolex:lexicalForm ?form3 .
   ?form3 ontolex:representation ?superlative ;    wikibase:grammaticalFeature wd:Q1817208 .    # superlative
   OPTIONAL { ?form3 wikibase:grammaticalFeature ?subfeat . FILTER(?subfeat != wd:Q1817208 ) } 
 
   # use ?word if ?positive is blank
   BIND(IF(BOUND(?positive),?positive,?word) AS ?positive).
  
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". 
                           ?subfeat rdfs:label ?subfeatLabel.
                          }
}
GROUP BY ?word ?l
ORDER BY ?word ?l
LIMIT 20000

试试看!

此示例展示了(英文)动词及其变位形式。此查询非常复杂,因为 Wikidata 中的动词变位建模非常复杂。通过更改VALUES ?language { "en" },可以将此查询更改为任何语言。目前,只有少数动词被变位。

# verbs
SELECT ?l ?word (GROUP_CONCAT(DISTINCT ?subfeatLabel; SEPARATOR=", ") AS ?subfeatures) 
          ?single1 ?single2 ?single3 ?plural1 ?plural2 ?plural3
WHERE {
   VALUES ?language { "en" }
  
   ?l a ontolex:LexicalEntry ; wikibase:lemma ?word; wikibase:lexicalCategory ?category .
   FILTER(?category = wd:Q24905 ) # verb
   FILTER(LANG(?word) = ?language)

OPTIONAL { 
   ?l ontolex:lexicalForm ?form1 .
   { ?form1 ontolex:representation ?single1 ; wikibase:grammaticalFeature wd:Q51929218 .  # first-person singular
   } UNION 
   { ?form1 ontolex:representation ?single1 ; wikibase:grammaticalFeature wd:Q21714344 .  # first person
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q146786 .   }               # without plural
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q51929154 . }               # without plural person
   } UNION
   { ?form1 ontolex:representation ?single1 ; wikibase:grammaticalFeature wd:Q51929131 .  # singular person
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person 
   } UNION
   { ?form1 ontolex:representation ?single1 ; wikibase:grammaticalFeature wd:Q110786 .    # singular
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form1 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person
   }
   FILTER(LANG(?single1) = ?language )
   OPTIONAL { ?form1 wikibase:grammaticalFeature ?subfeat . 
             FILTER(?subfeat != wd:Q51929218 && ?subfeat != wd:Q21714344 )   # not first-person singular / first person
             FILTER(?subfeat != wd:Q51929131 && ?subfeat != wd:Q110786 )     # not singular person / singular
             FILTER(?subfeat != wd:Q51929049 && ?subfeat != wd:Q51929074 ) } # not second person / third person
   }  
OPTIONAL { 
   ?l ontolex:lexicalForm ?form2 .
   { ?form2 ontolex:representation ?single2 ; wikibase:grammaticalFeature wd:Q51929369 .  # second-person singular
   } UNION 
   { ?form2 ontolex:representation ?single2 ; wikibase:grammaticalFeature wd:Q51929049 .  # second person
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q146786 .   }               # without plural
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q51929154 . }               # without plural person
   } UNION
   { ?form2 ontolex:representation ?single2 ; wikibase:grammaticalFeature wd:Q51929131 .  # singular person
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person 
   } UNION
   { ?form2 ontolex:representation ?single2 ; wikibase:grammaticalFeature wd:Q110786 .    # singular
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form2 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person
   }
   FILTER(LANG(?single2) = ?language )
   OPTIONAL { ?form2 wikibase:grammaticalFeature ?subfeat . 
             FILTER(?subfeat != wd:Q51929369 && ?subfeat != wd:Q51929049 )   # not second-person singular / second person
             FILTER(?subfeat != wd:Q51929131 && ?subfeat != wd:Q110786 )     # not singular person / singular
             FILTER(?subfeat != wd:Q21714344 && ?subfeat != wd:Q51929074 ) } # not first person / third person
   }
OPTIONAL { 
   ?l ontolex:lexicalForm ?form3 .
   { ?form3 ontolex:representation ?single3 ; wikibase:grammaticalFeature wd:Q51929447 .  # third-person singular
   } UNION 
   { ?form3 ontolex:representation ?single3 ; wikibase:grammaticalFeature wd:Q51929074 .  # third person
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q146786 .   }               # without plural
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q51929154 . }               # without plural person
   } UNION
   { ?form3 ontolex:representation ?single3 ; wikibase:grammaticalFeature wd:Q51929131 .  # singular person
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person 
   } UNION
   { ?form3 ontolex:representation ?single3 ; wikibase:grammaticalFeature wd:Q110786 .    # singular
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form3 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person
   }
   FILTER(LANG(?single3) = ?language )        
   OPTIONAL { ?form3 wikibase:grammaticalFeature ?subfeat . 
             FILTER(?subfeat != wd:Q51929447 && ?subfeat != wd:Q51929074 )   # not third-person singular / third person
             FILTER(?subfeat != wd:Q51929131 && ?subfeat != wd:Q110786 )     # not singular person / singular
             FILTER(?subfeat != wd:Q21714344 && ?subfeat != wd:Q51929049 ) } # not first person / second person
   }
OPTIONAL { 
   ?l ontolex:lexicalForm ?form4 .
   { ?form4 ontolex:representation ?plural1 ; wikibase:grammaticalFeature wd:Q51929290 .  # first-person plural
   } UNION 
   { ?form4 ontolex:representation ?plural1 ; wikibase:grammaticalFeature wd:Q21714344 .  # first person
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q110786 . }                 # without singular
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q51929131 . }               # without singular person
   } UNION
   { ?form4 ontolex:representation ?plural1 ; wikibase:grammaticalFeature wd:Q51929154 .  # plural person
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person
   } UNION
   { ?form4 ontolex:representation ?plural1 ; wikibase:grammaticalFeature wd:Q146786 .    # plural
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q21714344 . }               # without first person
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q51929049 . }               # without second person
     FILTER NOT EXISTS{ ?form4 wikibase:grammaticalFeature wd:Q51929074 . }               # without third person
   }
   FILTER(LANG(?plural1) = ?language )
   OPTIONAL { ?form4 wikibase:grammaticalFeature ?subfeat . 
             FILTER(?subfeat != wd:Q51929290 && ?subfeat != wd:Q21714344 )     # not first-person plural / first person
             FILTER(?subfeat != wd:Q51929154 && ?subfeat != wd:Q146786 )       # not plural person / plural
             FILTER(?subfeat != wd:Q51929049 && ?subfeat != wd:Q51929074 ) }   # not second person / third person
   }
OPTIONAL { 
   ?l ontolex:lexicalForm ?form5 .
   { ?form5 ontolex:representation ?plural2 ; wikibase:grammaticalFeature wd:Q51929403 . # second-person plural
   } UNION 
   { ?form5 ontolex:representation ?plural2 ; wikibase:grammaticalFeature wd:Q51929049 . # second person
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q110786 . }                # without singular
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q51929131 . }              # without singular person
   } UNION
   { ?form5 ontolex:representation ?plural2 ; wikibase:grammaticalFeature wd:Q51929154 . # plural person
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q21714344 . }              # without first person
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q51929049 . }              # without second person
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q51929074 . }              # without third person
   } UNION
   { ?form5 ontolex:representation ?plural2 ; wikibase:grammaticalFeature wd:Q146786 .   # plural
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q21714344 . }              # without first person
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q51929049 . }              # without second person
     FILTER NOT EXISTS{ ?form5 wikibase:grammaticalFeature wd:Q51929074 . }              # without third person
   }
   FILTER(LANG(?plural2) = ?language )
   OPTIONAL { ?form5 wikibase:grammaticalFeature ?subfeat . 
             FILTER(?subfeat != wd:Q51929403 && ?subfeat != wd:Q51929049 )     # not second-person plural / second person
             FILTER(?subfeat != wd:Q51929154 && ?subfeat != wd:Q146786 )       # not plural person / plural
             FILTER(?subfeat!= wd:Q21714344 && ?subfeat != wd:Q51929074 ) }    # not first person / third person
   }
OPTIONAL { 
   ?l ontolex:lexicalForm ?form6 .
   { ?form6 ontolex:representation ?plural3 ; wikibase:grammaticalFeature wd:Q51929517 . # third-person plural
   } UNION 
   { ?form6 ontolex:representation ?plural3 ; wikibase:grammaticalFeature wd:Q51929074 . # third person
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q110786 . }                # without singular
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q51929131 . }              # without singular person
   } UNION
   { ?form6 ontolex:representation ?plural3 ; wikibase:grammaticalFeature wd:Q51929154 . # plural person
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q21714344 . }              # without first person
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q51929049 . }              # without second person
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q51929074 . }              # without third person
   } UNION
   { ?form6 ontolex:representation ?plural3 ; wikibase:grammaticalFeature wd:Q146786 .   # plural
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q21714344 . }              # without first person
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q51929049 . }              # without second person
     FILTER NOT EXISTS{ ?form6 wikibase:grammaticalFeature wd:Q51929074 . }              # without third person
   }
   FILTER(LANG(?plural3) = ?language )        
   OPTIONAL { ?form6 wikibase:grammaticalFeature ?subfeat . 
             FILTER(?subfeat != wd:Q51929517 && ?subfeat != wd:Q51929074 )     # not third-person plural / third person
             FILTER(?subfeat != wd:Q51929154 && ?subfeat != wd:Q146786 )       # not plural person / plural
             FILTER(?subfeat != wd:Q21714344 && ?subfeat != wd:Q51929049 ) }   # not first person / second person
   }
  
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". 
                           ?subfeat rdfs:label ?subfeatLabel.
                          }
}
GROUP BY ?l ?word ?single1 ?single2 ?single3 ?plural1 ?plural2 ?plural3
ORDER BY ?word ?single1 ?single2 ?single3 ?plural1 ?plural2 ?plural3
LIMIT 20000

试试看!

所有语言中的冠词

[编辑 | 编辑源代码]

此示例展示了多种语言中的冠词。

# articles in all languages
SELECT ?l ?language ?categoryLabel ?word ?subfeatures 
     (GROUP_CONCAT(DISTINCT ?masculine; SEPARATOR=", ") AS ?Masculine ) 
     (GROUP_CONCAT(DISTINCT ?feminine;  SEPARATOR=", ") AS ?Feminine ) 
     (GROUP_CONCAT(DISTINCT ?neuter;    SEPARATOR=", ") AS ?Neuter ) 
WHERE {
SELECT ?l ?language ?categoryLabel ?word (GROUP_CONCAT(DISTINCT ?subfeatLabel; SEPARATOR=", ") AS ?subfeatures) 
     ?masculine ?feminine ?neuter 
WHERE {
   VALUES ?categories { wd:Q103184 wd:Q2865743 wd:Q3813849 } # article or definite article or indefinite article
 
   ?l a ontolex:LexicalEntry ; wikibase:lemma ?word; wikibase:lexicalCategory ?category .
   FILTER(?category = ?categories ) # article or definite article or indefinite article
   BIND(LANG(?word) as ?language)

OPTIONAL { 
   ?l ontolex:lexicalForm ?form1 .
   ?form1 ontolex:representation ?masculine ; wikibase:grammaticalFeature wd:Q499327 . # masculine
   FILTER(LANG(?masculine) = ?language )
   OPTIONAL { ?form1 wikibase:grammaticalFeature ?subfeat . FILTER(?subfeat != wd:Q499327 ) } 
   }
 
OPTIONAL { 
   ?l ontolex:lexicalForm ?form2 .
   ?form2 ontolex:representation ?feminine ; wikibase:grammaticalFeature wd:Q1775415 . # feminine
   FILTER(LANG(?feminine) = ?language )
   OPTIONAL { ?form2 wikibase:grammaticalFeature ?subfeat . FILTER(?subfeat != wd:Q1775415 ) } 
   }  
  
OPTIONAL { 
   ?l ontolex:lexicalForm ?form3 .
   ?form3 ontolex:representation ?neuter ; wikibase:grammaticalFeature wd:Q1775461 . # neuter
   FILTER(LANG(?neuter) = ?language )
   OPTIONAL { ?form3 wikibase:grammaticalFeature ?subfeat . FILTER(?subfeat != wd:Q1775461 ) } 
   }  
   
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". 
                           ?subfeat  rdfs:label ?subfeatLabel.
                           ?category rdfs:label ?categoryLabel.
                          }
}
GROUP BY ?language ?l ?categoryLabel ?word ?masculine ?feminine ?neuter
ORDER BY ?language ?categoryLabel ?subfeatures ?word ?masculine ?feminine ?neuter 
}
GROUP BY ?language ?l ?categoryLabel ?word ?subfeatures
ORDER BY ?language ?l ?categoryLabel ?word ?subfeatures ?masculine ?feminine ?neuter

试试看!

外部工具

[编辑 | 编辑源代码]

有关词汇数据外部工具的列表,请参见Wikidata:Tools/Lexicographical data

参考文献

[编辑 | 编辑源代码]


华夏公益教科书