A simple framework for building complex dialogue systems.


License
BSD-3-Clause
Install
pip install Millet==2.0.0

Documentation

Millet

A simple framework for building complex dialogue systems.

Documentation Status https://travis-ci.org/odryfox/millet.svg?branch=master https://coveralls.io/repos/github/odryfox/millet/badge.svg?branch=master

Installing

pip install Millet

A Simple Example

from typing import List, Type
from millet import Agent, Skill

class MeetingSkill(Skill):
    def start(self, initial_message: str):
        name = self.ask(question="What is your name?")
        self.say(f"Nice to meet you {name}!")

def skill_classifier(message: str) -> List[Type[Skill]]:
    return [MeetingSkill()]

agent = Agent(skill_classifier=skill_classifier)
conversation = agent.conversation_with_user("Bob")
>>> conversation.query("Hello")
["What is your name?"]
>>> conversation.query("Bob")
["Nice to meet you Bob!"]