Skip to content

Instantly share code, notes, and snippets.

View JustinaPetr's full-sized avatar

Justina Petraityte JustinaPetr

View GitHub Profile
pipeline:
- name: "intent_featurizer_count_vectors"
- name: "intent_classifier_tensorflow_embedding"
intent_tokenization_flag: true
intent_split_symbol: "+"
interpreter = Interpreter.load('models/current/nlu_model')
print(interpreter.parse("Yes. Can you give me suggestions on how to get there?"))
{
'intent':{
'name':'affirm+ask_transport',
'confidence':0.918471097946167
},
'entities':[
],
'intent_ranking':[
{
templates:
utter_greet:
- "Hey, how can I help you?"
utter_goodbye:
- "Talk to you later!"
- "Goodbye :("
- "Bye!"
utter_affirm:
- "Cool. Let me book the spot for you."
- "Glad to hear. I'll make an RSVP for you."
{
"actions": [
{
"description": "Default Welcome Intent",
"name": "MAIN",
"fulfillment": {
"conversationName": "<INSERT YOUR CONVERSATION NAME HERE>"
},
"intent": {
"name": "actions.intent.MAIN",
{
"actions": [
{
"description": "Default Welcome Intent",
"name": "MAIN",
"fulfillment": {
"conversationName": "welcome"
},
"intent": {
"name": "actions.intent.MAIN",
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import logging
from flask import Flask, Response, Blueprint, request, jsonify
from rasa_core.channels.channel import UserMessage, OutputChannel
from rasa_core.channels.channel import InputChannel
class GoogleAssistant(InputChannel):
@classmethod
def name(cls):
def blueprint(self, on_new_message):
@classmethod
def name(cls)
return ‘google_assistant’
def blueprint(self, on_new_message):
google_webhook = Blueprint('google_webhook', __name__)