by yogurt-cultures

yogurt-cultures / kefir

turkic morphology project

440 Stars 29 Forks Last release: Not found Other 59 Commits 0 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:




Yogurt is a free software community established at Mustafa Akg羹l Free Software Camp of 2018.

Kefir is a natural language processing kit for Turkic languages, and maybe Finnish and Hungarian in phonology.


There are two competing notions of the predicate in theories of grammar. The competition between these two concepts has generated confusion concerning the use of the term predicate in theories of grammar.

Kefir is designed to construct sentences by using predicate-logic.

>>> ayni = subject('ayn覺')
>>> havuc = subject('havu癟')
>>> gel = predicate('gel', 'third', 'perfective')
>>> yap = predicate('yap', 'third', 'perfective')
>>> dal = predicate('dal', 'third', 'progressive')
>>> dal = predicate(dal, 'third', 'perfective')

>>> birisi = subject('yakup')
>>> [sentence(birisi, eylem) for eylem in (yap, dal,)]
['yakup yapt覺', 'yakup dalmaktayd覺']

>>> [sentence(havuc, eylem) for eylem in (gel, yap, dal)]
['havu癟 geldi', 'havu癟 yapt覺', 'havu癟 dalmaktayd覺']

>>> sebze = predicate(locative('marul'), 'first', 'perfective', True)
>>> dal = predicate(locative('dal'), 'first', 'perfective', True)
>>> [sentence(ayni, eylem) for eylem in (sebze, dal)]
['ayn覺 maruldayd覺k', 'ayn覺 daldayd覺k']


  • nominative
  • genitive
  • dative
  • accusative
  • ablative
  • locative


  • negative
  • zero
  • tobe
  • personal
  • perfective
  • imperfective
  • progressive
  • necessitative
  • future
  • impotential
  • conditional

Grammatical Cases

Implemented 6 grammatical cases:

  • Nominative
  • Genitive
  • Dative
  • Accusative
  • Ablative
  • Locative

Turkish has 9 more:

  • Essive
  • Instrumental
  • Inclusive
  • Abessive
  • Likeness
  • Coverage
  • Qualitative
  • Conditional
  • Possesive

Read more on: Turkish Cases.

TODO: Enum'lardaki rakamlar yerine auto() kullan覺lmal覺.

Nominative Case ('Yal覺n' in Turkish)

The simplest grammatical case, there's no suffix to affix in that case.

Nominative comes from Latin csus nomint蘋vus means case for naming.

Ablative Case ('Ayr覺lma' in Turkish)

A grammatical case for nouns, pronouns and adjectives in the grammar of various languages; it is sometimes used to express motion away from something, among other uses.

儭 Examples:

adalar[dan] geldim
merkez[den] ge癟tim
teyit[ten] ge癟tim
a癟l覺k[tan] 繹ld羹m

Accusative ('襤lgi' in Turkish)

The accusative case (abbreviated acc) of a noun is the grammatical case used to mark the direct object of a transitive verb. The same case is used in many languages for the objects of (some or all) prepositions.

儭 Examples:

aday[覺] yedim
evim[i] yapt覺m
羹z羹m[羹] piirdim

Genitive Case ('Genitifler' in Turkish)

In grammar, the genitive is the grammatical case that marks a word, usually a noun, as modifying another word, also usually a noun.

儭 Examples:

han覺melinin 癟i癟ei (flower of a plant called han覺meli)
kad覺n覺n ayakkab覺s覺 (shoes of the woman)
堥塈堥 堥堛 bbu baytin (the door of a house)
mari[i] nie ma w domu (maria is not at home)

Dative Case ('Y繹nelme' in Turkish)

In some languages, the dative is used to mark the indirect object of a sentence.

儭 Examples:

marya yakup'a bir drink verdi (maria gave jacob a drink)
maria jacob蘋 potum dedit (maria gave jacob a drink)

Locative Case ('Bulunma' in Turkish)

Locative is a grammatical case which indicates a location. It corresponds vaguely to the English prepositions "in", "on", "at", and "by".

儭 Examples:

bah癟e[de] han覺meli var.
yorum[da] iyi beatler var.
kalem[de] g羹zel u癟 var.

Turkish Phonology

In Hungarian, Finnish, and Turkic languages vowel sounds are organized in a concept called vowel harmony. Vowels may be classified as Back or Front vowels, based on the placement of the sound in the mouth.

 Front Vowels
 Unrounded  牠 甬
 Rounded    並潑 並嗯

 Back Vowels
 Unrounded  災 乖晦
 Rounded    罕 矣

TODO: Document consonant harmony.


Swaps front sounds to back, and vice versa.

>>> swap_front_and_back('acak')

>>> swap_front_and_back('ocok')

>>> swap_front_and_back('繹c繹k')

>>> swap_front_and_back('acak')

Voicing or Sonorization ('Yumuama' in Turkish)

To make pronouncation easier, nouns ending with these sounds:

私 並把 系 男

May be softened by replacing them in order:

灸 牢 牡 乖

儭 Examples:

癟o私季n  癟o灸季n
aa並把怯彫  aa牢姊
ka覺系怯彫  ka覺牡怯彫
ren男姆n  ren狂姆n

儭 Examples in other languages:

li狄委  li肖委
stri狄委  stri肖委
proo狄  pro肖委

Devoicing or Desonorization ('Sertleme' in Turkish)

To make pronouncation easier, nouns ending with these sounds:

私 並把 系 男

May be hardened by replacing them in order:

灸 牢 牡 乖

儭 Examples:

癟o私季n  癟o灸季n
aa並把怯彫  aa牢姊
ka覺系怯彫  ka覺牡怯彫
ren男姆n  ren狂姆n

儭 Examples in Other Languages:

dogs  dogs ([氶z])
missed  missed ([st])
whizzed  whizzed ([zd])
proba  prba
郈郋訇訄  proz妦b

Turkish Predication and Copula

Turkish language copulas, called 'ek-eylem' (literally 'suffix-verb'), are one of the most distinct features of Turkish grammar.

TODO: Remove unused imports.

Zero Copula

Zero copula is the rule for third person, as in Hungarian and Russian. That means two nouns, or a noun and an adjective can be juxtaposed to make a sentence without using any copula. Third person plural might be indicated with the use of plural suffix "-lar/-ler".

儭 Examples:

yogurt k羹lt羹r (yogurt [is-a] culture)
abbas yolcu (abbas [is-a] traveller)
evlerinin 繹n羹 yonca (the front of their home [is-a] plant called yonca)

儭 Tests:

>>> zero('yolcu')


Negation is indicated by the negative copula 'deil'. 'Deil' is never used as a suffix, but it takes suffixes according to context.

儭 Examples:

yogurt k羹lt羹r deildir (yogurt [is-not-a] culture)
abbas yolcu deildir (abbas [is-not-a] traveller)
evlerinin 繹n羹 yonca deildir (the front of their home [is-not-a] yonca)

儭 Tests:

>>> negative('yolcu')
'yolcu deil'

To Be

Turkish "to be" as regular/auxiliary verb ('olmak').

儭 Examples:

yogurt k羹lt羹rd羹r (yogurt [is] culture)
abbas yolcudur (abbas [is] traveller)
evlerinin 繹n羹 yoncad覺r (the front of their home [is] plant called yonca)

儭 Tests:

>>> tobe('yolcu')
>>> tobe('羹z羹m')
>>> tobe('yonca')

Personification Copula

儭 Examples:

ben bural覺y覺m (i'm from here)
sen oral覺s覺n (you're from over there)
ayn覺 gezegenliyiz (we're from same planet)

儭 Tests:

>>> personal('u癟ak', Person.FIRST, is_plural=False)

>>> personal('oral覺', Person.SECOND, is_plural=False)

>>> personal('gezegenli', Person.FIRST, is_plural=True)

Inferential Mood ('-mi' in Turkish)

Inferential mood is used to convey information about events which were not directly observed or were inferred by the speaker.

儭 Examples:

elmaym覺覺m (i was an apple as i've heard)
羹z羹lm羹s羹n (you were sad as i've heard)
doktormu (he/she/it was a doctor as i've heard)
羹z羹mm羹s羹n (you were a grape as i've heard)

儭 Tests:

>>> inferential('繹retmen', Person.SECOND, is_plural=False)

>>> inferential('羹z羹l', Person.SECOND, is_plural=False)

>>> inferential('robot', Person.FIRST, is_plural=False)

>>> inferential('robot', Person.THIRD, is_plural=False)

>>> inferential('ada', Person.THIRD, is_plural=False)

Inferential Mood ('-isem' in Turkish)

Inferential mood is a grammatical mood used to express a proposition whose validity is dependent on some condition, possibly counterfactual.

儭 Examples:

elmaysam (if i am an apple)
羹z羹msen (if you are a grape)
b覺癟aklarsa (if they are a knife)

儭 Tests:

>>> conditional('elma', Person.FIRST, is_plural=False)
>>> conditional('羹z羹m', Person.SECOND, is_plural=False)
>>> conditional('b覺癟ak', Person.THIRD, is_plural=True)

Alethic Modality ('-idi' in Turkish)

Linguistic modality that indicates modalities of truth, in particular the modalities of logical necessity, possibility or impossibility.

儭 Examples:

elmayd覺m (i was an apple)
羹z羹md羹n (you were a grape)
doktordu (he/she/it was a doctor)

儭 Tests:

>>> perfective('a癟覺k', Person.FIRST, is_plural=False)

>>> perfective('oral覺', Person.SECOND, is_plural=False)

>>> perfective('dalda', Person.FIRST, is_plural=False)

>>> perfective('dalda', Person.THIRD, is_plural=False)

>>> perfective('dalda', Person.FIRST, is_plural=True)

>>> perfective('dalda', Person.SECOND, is_plural=True)

>>> perfective('dalda', Person.THIRD, is_plural=True)

>>> perfective('gezegende', Person.THIRD, is_plural=True)

The Imperfective ('-iyor' in Turkish)

Grammatical aspect used to describe a situation viewed with interior composition. It describes ongoing, habitual, repeated, or similar semantic roles, whether that situation occurs in the past, present, or future.

儭 Examples:

gidiyorum (i'm going)
kay覺yor (he's skating)
羹z羹ml羹yor (he's graping)

儭 Tests:

>>> imperfective('a癟覺', Person.FIRST, is_plural=False)

>>> imperfective('a癟覺k', Person.FIRST, is_plural=False)

>>> imperfective('oral覺', Person.SECOND, is_plural=False)

>>> imperfective('dal', Person.THIRD, is_plural=False)

>>> imperfective('dal', Person.FIRST, is_plural=True)

>>> imperfective('dal', Person.FIRST, is_plural=True)

>>> imperfective('dal', Person.SECOND, is_plural=True)

>>> imperfective('dal', Person.THIRD, is_plural=True)

The Future Tense ('-iyor' in Turkish)

The future tense is a verb form that generally marks the event described by the verb as not having happened yet, but expected to happen in the future.

儭 Examples:

gidecek (he'll go)
繹lecek (he'll die)
can alacak (he'll kill someone)

儭 Tests:

>>> future('gel', Person.FIRST, is_plural=False)

>>> future('a癟覺k', Person.FIRST, is_plural=False)

>>> future('gel', Person.FIRST, is_plural=True)

Progressive Tense

儭 Examples: g羹lmekteyim (i am in the process of laughing) 繹lmekteler (they are in the process of dying )

儭 Tests:

>>> progressive('gel', Person.FIRST, is_plural=False)

>>> progressive('a癟覺k', Person.FIRST, is_plural=False)

>>> progressive('gel', Person.FIRST, is_plural=True)

Necessitative Copula

儭 Examples:

gitmeliyim (i must go)
ka癟mal覺y覺m (i must run away)

儭 Tests:

>>> necessitative('git', Person.FIRST, is_plural=False)

>>> necessitative('a癟覺k', Person.FIRST, is_plural=False)

>>> necessitative('uza', Person.FIRST, is_plural=True)

Impotential Copula

儭 Examples:

gidemem (i cannot come)
ka癟amay覺z (we cannot run away)

儭 Tests:

>>> impotential('git', Person.FIRST, is_plural=False)

>>> impotential('git', Person.SECOND, is_plural=False)

>>> impotential('git', Person.THIRD, is_plural=False)

>>> impotential('git', Person.FIRST, is_plural=True)

>>> impotential('git', Person.FIRST, is_plural=True)

>>> impotential('git', Person.SECOND, is_plural=True)

>>> impotential('git', Person.THIRD, is_plural=True)

>>> impotential('al', Person.THIRD, is_plural=True)

Contribution Guide

  • Don't load a fixture, code is our data.
  • Don't leave a comment! Docstrings are only for the context and test.
  • Be nice


  • Berk Buzcu (8-bit artwork)
  • Serdar A癟覺kyol (Illustration)
  • Fatih Erikli (Phonological Processes, Predicate Logic)
  • Armagan Amcalar (Javascript Port)
  • Umut Karc覺 (Packaging and Versioning)
  • Kerem Bozda (Editing)


This project is licensed under the terms of the MIT license.

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.