-
Notifications
You must be signed in to change notification settings - Fork 67
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#124 Fixes for update_data.py and reformat/add to noun queries
- Loading branch information
1 parent
22632f5
commit bff1da6
Showing
87 changed files
with
605 additions
and
483 deletions.
There are no files selected for viewing
30 changes: 24 additions & 6 deletions
30
src/scribe_data/language_data_extraction/Arabic/nouns/query_nouns.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,35 @@ | ||
# tool: scribe-data | ||
# All Arabic (Q13955) nouns. | ||
# All Arabic (Q13955) nouns, their plurals and their dual forms. | ||
# Enter this query at https://query.wikidata.org/. | ||
|
||
SELECT DISTINCT | ||
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") as ?lexemeID) | ||
?noun | ||
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") AS ?lexemeID) | ||
?singular | ||
?plural | ||
?dual | ||
|
||
WHERE { | ||
# Nouns and pronouns. | ||
VALUES ?nounTypes { wd:Q1084 wd:Q147276 } | ||
VALUES ?nounTypes {wd:Q1084 wd:Q147276} # Nouns and pronouns # Nouns and pronouns | ||
?lexeme a ontolex:LexicalEntry ; | ||
dct:language wd:Q13955 ; | ||
wikibase:lexicalCategory ?nounType ; | ||
wikibase:lemma ?noun . | ||
wikibase:lemma ?singular . | ||
|
||
FILTER(?nounType = ?nounTypes) | ||
|
||
# Optional selection of indefinite plural forms. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?pluralForm . | ||
?pluralForm ontolex:representation ?plural ; | ||
wikibase:grammaticalFeature wd:Q53997857 ; | ||
wikibase:grammaticalFeature wd:Q146786 ; | ||
} . | ||
|
||
# Optional selection of indefinite dual form. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?dualForm . | ||
?dualForm ontolex:representation ?dual ; | ||
wikibase:grammaticalFeature wd:Q53997857 ; | ||
wikibase:grammaticalFeature wd:Q110022 ; | ||
} . | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 24 additions & 6 deletions
30
src/scribe_data/language_data_extraction/Basque/nouns/query_nouns.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,35 @@ | ||
# tool: scribe-data | ||
# All Basque (Q8752) nouns. | ||
# All Basque (Q8752) nouns and all implemented singular and plural forms. | ||
# Enter this query at https://query.wikidata.org/. | ||
|
||
SELECT DISTINCT | ||
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") as ?lexemeID) | ||
?noun | ||
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") AS ?lexemeID) | ||
?absIndefinite | ||
?absSingular | ||
?absPlural | ||
|
||
WHERE { | ||
# Nouns and pronouns. | ||
VALUES ?nounTypes { wd:Q1084 wd:Q147276 } | ||
VALUES ?nounTypes {wd:Q1084 wd:Q147276} # Nouns and pronouns | ||
?lexeme a ontolex:LexicalEntry ; | ||
dct:language wd:Q8752 ; | ||
wikibase:lexicalCategory ?nounType ; | ||
wikibase:lemma ?noun . | ||
wikibase:lemma ?absIndefinite . | ||
|
||
FILTER(?nounType = ?nounTypes) | ||
|
||
# Optional selection of absolutive singular forms. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?absSingularForm . | ||
?absSingularForm ontolex:representation ?absSingular ; | ||
wikibase:grammaticalFeature wd:Q332734 ; | ||
wikibase:grammaticalFeature wd:Q110786 ; | ||
} . | ||
|
||
# Optional selection of absolutive plural forms. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?absPluralForm . | ||
?absPluralForm ontolex:representation ?absPlural ; | ||
wikibase:grammaticalFeature wd:Q332734 ; | ||
wikibase:grammaticalFeature wd:Q146786 ; | ||
} . | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 36 additions & 6 deletions
42
src/scribe_data/language_data_extraction/Bengali/nouns/query_nouns.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,47 @@ | ||
# tool: scribe-data | ||
# All Bengali (Q9610) nouns. | ||
# All Bengali (Q9610) nouns and their forms in the various cases. | ||
# Enter this query at https://query.wikidata.org/. | ||
|
||
SELECT DISTINCT | ||
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") as ?lexemeID) | ||
?noun | ||
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") AS ?lexemeID) | ||
?nominative | ||
?genitive | ||
?accusative | ||
?locative | ||
|
||
WHERE { | ||
# Nouns and pronouns. | ||
VALUES ?nounTypes { wd:Q1084 wd:Q147276 } | ||
VALUES ?nounTypes {wd:Q1084 wd:Q147276} # Nouns and pronouns | ||
?lexeme a ontolex:LexicalEntry ; | ||
dct:language wd:Q9610 ; | ||
wikibase:lexicalCategory ?nounType ; | ||
wikibase:lemma ?noun . | ||
|
||
FILTER(?nounType = ?nounTypes) | ||
|
||
# Optional selection of nominative form. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?nomForm . | ||
?nomForm ontolex:representation ?nominative ; | ||
wikibase:grammaticalFeature wd:Q131105 ; | ||
} . | ||
|
||
# Optional selection of genitive form. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?genForm . | ||
?genForm ontolex:representation ?genitive ; | ||
wikibase:grammaticalFeature wd:Q146233 ; | ||
} . | ||
|
||
# Optional selection of accusative form. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?accForm . | ||
?accForm ontolex:representation ?accusative ; | ||
wikibase:grammaticalFeature wd:Q146078 ; | ||
} . | ||
|
||
# Optional selection of locative form. | ||
OPTIONAL { | ||
?lexeme ontolex:lexicalForm ?locForm . | ||
?locForm ontolex:representation ?locative ; | ||
wikibase:grammaticalFeature wd:Q202142 ; | ||
} . | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 30 additions & 16 deletions
46
src/scribe_data/language_data_extraction/Bokmål/nouns/query_nouns.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 19 additions & 17 deletions
36
src/scribe_data/language_data_extraction/Czech/nouns/query_nouns.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.