Skip to content

Commit

Permalink
created folder for Punjabi language and added query
Browse files Browse the repository at this point in the history
  • Loading branch information
SethiShreya committed Oct 8, 2024
1 parent 3613d2f commit 7d08d75
Showing 1 changed file with 45 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# tool: scribe-data
# All Punjabi (from Gurmukhi Q58635) nouns and their gender.
# Enter this query at https://query.wikidata.org/.
# Note the necessity to filter for "pa" to select Gurmukhi words.

SELECT DISTINCT
?lexeme
(REPLACE(STR(?lexeme), "http://www.wikidata.org/entity/", "") AS ?lexemeID)
?singular
?plural
?gender

WHERE {
VALUES ?nounTypes {wd:Q1084 wd:Q147276} # Nouns and pronouns

?lexeme dct:language wd:Q58635 ;
wikibase:lexicalCategory ?nounTypes ;
wikibase:lemma ?singular .

# MARK: Plural
OPTIONAL {
?lexeme ontolex:lexicalForm ?pluralForm .
?pluralForm ontolex:representation ?plural ;
wikibase:grammaticalFeature wd:Q146786 ;
} .

# MARK: Gender(s)
OPTIONAL {
?lexeme wdt:P5185 ?nounGender .
FILTER NOT EXISTS {
?lexeme wdt:P31 wd:Q202444 .
}
} .

BIND(lang(?singular) AS ?langSingular)
BIND(lang(?plural) AS ?langPlural)

FILTER(?langSingular = "pa")
FILTER(?langPlural = "pa")

SERVICE wikibase:label {
bd:serviceParam wikibase:language "[AUTO_LANGUAGE]".
?nounGender rdfs:label ?gender .
}
}

0 comments on commit 7d08d75

Please sign in to comment.