doeg / toke

☁ an experimental linguistics DSL

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

              (`  ).                     _
             (     ).                 .:(`  )`.
)           _(       '`.             :(   .    )
        .=(`(      .   )         .--  `.  (    ) )
       ((    (..__.:'-'       .+(   )   ` _`  ) )
`.     `(       ) )  t o k e  (   .  )     (   )  ._
  )      ` __.:'   )         (   (   ))     `-'.-(`  )
)  )  ( )       --'           `- __.'         :(      ))
.-'  (_.'          .')                    `(    )  ))
                  (_  )                     ` __.:'

☁ toke ☁

A (very experimental) DSL for phrase grammar, more usefully referred to as "mad libs for twitter bots".

import toke from "toke";
console.log(toke.mk("{NP} {VP}");
// "The first toad was cursed by a dog"

Each token is a POS tag enclosed in {delimiters}.

About

☁ an experimental linguistics DSL

License:GNU General Public License v2.0


Languages

Language:JavaScript 100.0%