Eggscript is a markup language that can be "compiled" into a valid OVOS Skill

EXPERIMENTAL This is an experimental feature

It is intended as an easy way for user to create simple skills, while offering an easy transition to regular skills

It also helps getting a lot of the boilerplate done for you when getting started

You can find a developer preview of eggscript in github

Crash Course

Example files written in eggscript


    // this is a comment
    // all comments and blank lines are ignored
    // special interperter variables can be set with @var syntax
    // - @name -> skill name
    // - @author -> skill author
    // - @email -> author contact
    // - @license -> skill license
    // - @interpreter -> supported interperter, eg, cli
    // - @compiler -> supported compiler, eg, mycroft skill

    @author jarbasai
    @license MIT
    @name hello world
    @version 0.1.0

    // this script can be used standalone in the cli
    @interpreter cli
    // a standalone python file can be generated
    @compiler cli
    // a mycroft skill can be generated
    @compiler mycroft

    // intent definition
    # hello world
    + hello world
    - hello world

    // you can define python code, executed after TTS
    hello = "world"
    if hello == "world":
        print("python code!")


    // this is a comment
    // all comments and blank lines are ignored

    // text after # is the intent name
    # hello world
    // text after + is the user utterance
    + hello world
    // text after - is mycroft's response
    - hello world

    # weather in location
    // you can capture variables and use them using {var} syntax
    + how is the weather in {location}
    - how am i supposed to know the weather in {location}

    # weather
    // this will create a intent file with the 3 + utterances
    + what is the weather like
    + how is the weather
    + how does it look outside
    // this will create a dialog file with the 2 - utterances
    - i do not know how to check the weather
    - stick your head ouf of the window and check for yourself

    # count to 10
    + count to 10
    // if ident level matches its an alternate dialog
    - i will only count to 5
    - i only know how to count to 5
      // use tab for identation
      // each ident level defines a new utterance to be spoken
          - 1
              - 2
                  - 3
                      - 4
                          - 5


    // this is a comment
    // all comments and blank lines are ignored
    // this sample scripts show intent layers usage

    // the number of # in intent definition determines an intent layer
    # tell me about
    + tell me about {thing}
    - {thing} exists

    // N times + will enable layer N
    // to enable layer 2

    // use N times # for layer N
    // this intent is in layer 2, enabled by previous intent
    ## tell me more
    + tell me more
    + continue
    - i do not know more

    // N times - will disable layer N
    // to disable layer 2


Can run a subset of eggscript directly, enough to test simple skills in the terminal

from eggscript import CliInterpreter
from os.path import dirname

c = CliInterpreter()


from eggscript import OVOSSkillCompiler
from os.path import dirname

c = OVOSSkillCompiler()

You can now continue extending your exported skill to add more advanced functionality