SlideShare une entreprise Scribd logo
1  sur  35











http://tracerybot.azurewebsites.net
# Logs
logs
*.log
npm-debug.log*
.vscode
# Runtime data
pids
*.pid
*.seed
# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov
# TraceryBot
Your personal GitHub code repository README contents
You can add any content that you would like to be displayed
on your Github code repository page.
{
"name": "tracerybot",
"version": "1.0.0",
"description": "Build a bot in Node.js on Microsoft Bot Framework usin
"main": "app.js",
"dependencies": {
"botbuilder": "^3.3.0",
"express": "^4.14.0",
"https": "^1.0.0",
"restify": "^4.1.1",
"tracery-grammar": "^2.7.2"
},
"devDependencies": {},
"scripts": {
"test": "echo "Error: no test specified" && exit 1"
<!doctype html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1
<title>TraceryBot</title>
</head>
<body>
<iframe src="https://webchat.botframework.com/embed/TraceryBot?s=d
style="height: 502px; max-height: 502px;"></iframe>
</body>
</html>
//Add your requirements (as seen in package.json).
var restify = require('restify');
var builder = require('botbuilder');
var tracery = require('tracery-grammar');
// Setup Restify Server
var server = restify.createServer();
server.listen(process.env.port || process.env.PORT || 3978, function ()
console.log('%s listening to %s', server.name, server.url);
});
//Direct to index.html web page
server.get('/', restify.serveStatic({
directory: __dirname,
default: '/index.html'
// Create chat bot
//Generate your appId and appPassword by registering a bot:
// dev.botframework.com
var connector = new builder.ChatConnector({
appId: process.env.MY_APP_ID,
appPassword: process.env.MY_APP_PASSWORD
});
var bot = new builder.UniversalBot(connector);
server.post('/api/messages', connector.listen());
(
'origin': 'Hello, world'
console.log(grammar.flatten('#origin#'));
//=========================================================
// Bots Dialog
//=========================================================
bot.dialog('/', function (session) {
session.send(grammar.flatten('#origin#'));
});
Dialogs = Routing
All bots will have at least one root '/' dialog
• Dialog Handlers
• Waterfall
• Closure
• Dialog Object
• SimpleDialog
Dialogs = Routing
Hello, world!
Hello, world!
Hello, world!
 Create text output
var grammar = tracery.createGrammar({
'origin': ['Hello, world']
})
Hello, world!
Hello, world!
Hello, world!
 Use a replacement symbol to create text
var grammar = tracery.createGrammar({
'noun': ['world'],
'origin': ['Hello, #noun#!']
})
hello, world!
hello, world!
hello, world!
 Use replacement for additional output components
var grammar = tracery.createGrammar({
'noun': ['world'],
'verb': ['hello'],
'origin': ['#verb#, #noun#!']
})
Hello, world!
Hello, world!
Hello, world!
 Add modifiers to grammatically change capitalization
 prepend a/an, etc.
var grammar = tracery.createGrammar({
'noun': ['world'],
'verb': ['hello'],
'origin': ['#verb.capitalize#, #noun#!']
})
grammar.addModifiers(tracery.baseEngModifiers);
Aloha, planet!
Hello, universe!
Hello, world!
Goodbye, world!
 Add additional replacement values for
var grammar = tracery.createGrammar({
'noun': ['world', 'planet', 'universe'],
'verb': ['hello', 'goodbye', 'aloha'],
'origin': ['#verb.capitalize#, #noun#!']
})
grammar.addModifiers(tracery.baseEngModifiers);
//Get Started with Microsoft Bot Framework in Node.js code at docs.botf
//Add your requirements (as seen in package.json).
//These dependencies are installed through Node.js command prompt with
//npm install --save tracery-grammar
var restify = require('restify');
var builder = require('botbuilder');
var tracery = require('tracery-grammar');
// Setup Restify Server
//"npm install --save restify" sets up a server to host your bot online
var server = restify.createServer();
server.listen(process.env.port || process.env.PORT || 3978, function ()
Seamlessly provide disruptive growth strategies with agile scenarios.
Completely bring disruptive cloud solutions from self-sustaining metrics.
Efficiently administrate cutting-edge apps within extensible growth strategies.
Seamlessly administrate robust metrics of cross-platform metrics.
• steps: http://aka.ms/SarahSexton
• GitHub.com/SarahSexton/TraceryBot
• TraceryBot.azurewebsites.net
• slides: http://aka.ms/BotFramework
• http://dev.botframework.com
Getting Started with Microsoft Bot Framework
Getting Started with Microsoft Bot Framework
Getting Started with Microsoft Bot Framework

Contenu connexe

Tendances

Efficient DBA: Gain Time by Reducing Command-Line Keystrokes
Efficient DBA: Gain Time by Reducing Command-Line KeystrokesEfficient DBA: Gain Time by Reducing Command-Line Keystrokes
Efficient DBA: Gain Time by Reducing Command-Line KeystrokesSeth Miller
 
Rails 2010 Workshop
Rails 2010 WorkshopRails 2010 Workshop
Rails 2010 Workshopdtsadok
 
PuppetCamp SEA 1 - Version Control with Puppet
PuppetCamp SEA 1 - Version Control with PuppetPuppetCamp SEA 1 - Version Control with Puppet
PuppetCamp SEA 1 - Version Control with PuppetWalter Heck
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboyKenneth Geisshirt
 
My Robot Poops - In JavaScript (with web sockets)
My Robot Poops - In JavaScript (with web sockets)My Robot Poops - In JavaScript (with web sockets)
My Robot Poops - In JavaScript (with web sockets)Matthew Schiffman
 
Clojure + MongoDB on Heroku
Clojure + MongoDB on HerokuClojure + MongoDB on Heroku
Clojure + MongoDB on HerokuNaoyuki Kakuda
 
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basicsManav Prasad
 
Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...
Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...
Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...Vi Grey
 
node.js workshop- node.js middleware
node.js workshop- node.js middlewarenode.js workshop- node.js middleware
node.js workshop- node.js middlewareQiong Wu
 
Fun with Ruby and Redis
Fun with Ruby and RedisFun with Ruby and Redis
Fun with Ruby and Redisjavier ramirez
 
node.js workshop- node.js basics
node.js workshop- node.js basicsnode.js workshop- node.js basics
node.js workshop- node.js basicsQiong Wu
 

Tendances (19)

Efficient DBA: Gain Time by Reducing Command-Line Keystrokes
Efficient DBA: Gain Time by Reducing Command-Line KeystrokesEfficient DBA: Gain Time by Reducing Command-Line Keystrokes
Efficient DBA: Gain Time by Reducing Command-Line Keystrokes
 
Rails 2010 Workshop
Rails 2010 WorkshopRails 2010 Workshop
Rails 2010 Workshop
 
Drupal, meet Assetic
Drupal, meet AsseticDrupal, meet Assetic
Drupal, meet Assetic
 
Node.js
Node.jsNode.js
Node.js
 
clonehd01
clonehd01clonehd01
clonehd01
 
PuppetCamp SEA 1 - Version Control with Puppet
PuppetCamp SEA 1 - Version Control with PuppetPuppetCamp SEA 1 - Version Control with Puppet
PuppetCamp SEA 1 - Version Control with Puppet
 
Ruby 2.0
Ruby 2.0Ruby 2.0
Ruby 2.0
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboy
 
My Robot Poops - In JavaScript (with web sockets)
My Robot Poops - In JavaScript (with web sockets)My Robot Poops - In JavaScript (with web sockets)
My Robot Poops - In JavaScript (with web sockets)
 
Clojure + MongoDB on Heroku
Clojure + MongoDB on HerokuClojure + MongoDB on Heroku
Clojure + MongoDB on Heroku
 
Ruby Kaigi 2008 LT
Ruby Kaigi 2008 LTRuby Kaigi 2008 LT
Ruby Kaigi 2008 LT
 
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basics
 
Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...
Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...
Phishing for Root (How I Got Access to Root on Your Computer With 8 Seconds o...
 
node.js workshop- node.js middleware
node.js workshop- node.js middlewarenode.js workshop- node.js middleware
node.js workshop- node.js middleware
 
Redis, Resque & Friends
Redis, Resque & FriendsRedis, Resque & Friends
Redis, Resque & Friends
 
Fun with Ruby and Redis
Fun with Ruby and RedisFun with Ruby and Redis
Fun with Ruby and Redis
 
Modern Perl
Modern PerlModern Perl
Modern Perl
 
Crystal Rocks
Crystal RocksCrystal Rocks
Crystal Rocks
 
node.js workshop- node.js basics
node.js workshop- node.js basicsnode.js workshop- node.js basics
node.js workshop- node.js basics
 

En vedette

Bots are the New Apps: Building with the Bot Framework & Language Understanding
Bots are the New Apps: Building with the Bot Framework & Language UnderstandingBots are the New Apps: Building with the Bot Framework & Language Understanding
Bots are the New Apps: Building with the Bot Framework & Language UnderstandingNick Landry
 
Building A Conversational Bot Using Bot Framework and Microsoft
Building A Conversational Bot Using Bot Framework and MicrosoftBuilding A Conversational Bot Using Bot Framework and Microsoft
Building A Conversational Bot Using Bot Framework and MicrosoftPranav Ainavolu
 
Introduction to Microsoft Bot Framework
Introduction to Microsoft Bot FrameworkIntroduction to Microsoft Bot Framework
Introduction to Microsoft Bot FrameworkAlok Rajasukumaran
 
Microsoft bot framework in azure
Microsoft bot framework in azureMicrosoft bot framework in azure
Microsoft bot framework in azureShahriar Hossain
 
Microsoft Bot Framework: Hiking up the Trail of Automation
Microsoft Bot Framework: Hiking up the Trail of AutomationMicrosoft Bot Framework: Hiking up the Trail of Automation
Microsoft Bot Framework: Hiking up the Trail of AutomationDavid Hauck
 
Conversations as a Platform
Conversations as a PlatformConversations as a Platform
Conversations as a PlatformJoshua Drew
 
Introduction to Unity3D and Building your First Game
Introduction to Unity3D and Building your First GameIntroduction to Unity3D and Building your First Game
Introduction to Unity3D and Building your First GameSarah Sexton
 
Cognitive Services: Building Smart Apps with Speech, NLP & Vision
Cognitive Services: Building Smart Apps with Speech, NLP & VisionCognitive Services: Building Smart Apps with Speech, NLP & Vision
Cognitive Services: Building Smart Apps with Speech, NLP & VisionNick Landry
 
김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]
김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]
김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]WSConf.
 
S3 chat bot & the new world
S3 chat bot & the new worldS3 chat bot & the new world
S3 chat bot & the new worldLINE Corporation
 
Word Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with TraceryWord Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with TracerySarah Sexton
 

En vedette (19)

Bots are the New Apps: Building with the Bot Framework & Language Understanding
Bots are the New Apps: Building with the Bot Framework & Language UnderstandingBots are the New Apps: Building with the Bot Framework & Language Understanding
Bots are the New Apps: Building with the Bot Framework & Language Understanding
 
Intro to Bot Framework v3
Intro to Bot Framework v3Intro to Bot Framework v3
Intro to Bot Framework v3
 
Building A Conversational Bot Using Bot Framework and Microsoft
Building A Conversational Bot Using Bot Framework and MicrosoftBuilding A Conversational Bot Using Bot Framework and Microsoft
Building A Conversational Bot Using Bot Framework and Microsoft
 
Introduction to Microsoft Bot Framework
Introduction to Microsoft Bot FrameworkIntroduction to Microsoft Bot Framework
Introduction to Microsoft Bot Framework
 
Microsoft bot framework in azure
Microsoft bot framework in azureMicrosoft bot framework in azure
Microsoft bot framework in azure
 
Intro to Bot Framework
Intro to Bot FrameworkIntro to Bot Framework
Intro to Bot Framework
 
Microsoft Bot Framework: Hiking up the Trail of Automation
Microsoft Bot Framework: Hiking up the Trail of AutomationMicrosoft Bot Framework: Hiking up the Trail of Automation
Microsoft Bot Framework: Hiking up the Trail of Automation
 
Conversations as a Platform
Conversations as a PlatformConversations as a Platform
Conversations as a Platform
 
20160930 bot framework workshop
20160930 bot framework workshop20160930 bot framework workshop
20160930 bot framework workshop
 
Introduction to Unity3D and Building your First Game
Introduction to Unity3D and Building your First GameIntroduction to Unity3D and Building your First Game
Introduction to Unity3D and Building your First Game
 
Bots in the Enterprise
Bots in the Enterprise Bots in the Enterprise
Bots in the Enterprise
 
Cognitive Services: Building Smart Apps with Speech, NLP & Vision
Cognitive Services: Building Smart Apps with Speech, NLP & VisionCognitive Services: Building Smart Apps with Speech, NLP & Vision
Cognitive Services: Building Smart Apps with Speech, NLP & Vision
 
ASP.NET Core 1.0 Overview
ASP.NET Core 1.0 OverviewASP.NET Core 1.0 Overview
ASP.NET Core 1.0 Overview
 
김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]
김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]
김영욱 - Microsoft Bot Framework [WSConf. Seoul 2017]
 
S3 chat bot & the new world
S3 chat bot & the new worldS3 chat bot & the new world
S3 chat bot & the new world
 
Word Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with TraceryWord Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with Tracery
 
Figuranten
FigurantenFiguranten
Figuranten
 
unidades de corel
unidades de corelunidades de corel
unidades de corel
 
Il nucleo
Il nucleoIl nucleo
Il nucleo
 

Similaire à Getting Started with Microsoft Bot Framework

Building a real life application in node js
Building a real life application in node jsBuilding a real life application in node js
Building a real life application in node jsfakedarren
 
Build web application by express
Build web application by expressBuild web application by express
Build web application by expressShawn Meng
 
How to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrainHow to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrainCodemotion Tel Aviv
 
Using and scaling Rack and Rack-based middleware
Using and scaling Rack and Rack-based middlewareUsing and scaling Rack and Rack-based middleware
Using and scaling Rack and Rack-based middlewareAlona Mekhovova
 
Great Developers Steal
Great Developers StealGreat Developers Steal
Great Developers StealBen Scofield
 
Ruby 入門 第一次就上手
Ruby 入門 第一次就上手Ruby 入門 第一次就上手
Ruby 入門 第一次就上手Wen-Tien Chang
 
Introduction To Groovy 2005
Introduction To Groovy 2005Introduction To Groovy 2005
Introduction To Groovy 2005Tugdual Grall
 
Introduction to node.js
Introduction to node.jsIntroduction to node.js
Introduction to node.jsAdrien Guéret
 
2007 09 10 Fzi Training Groovy Grails V Ws
2007 09 10 Fzi Training Groovy Grails V Ws2007 09 10 Fzi Training Groovy Grails V Ws
2007 09 10 Fzi Training Groovy Grails V Wsloffenauer
 
Future of Web Apps: Google Gears
Future of Web Apps: Google GearsFuture of Web Apps: Google Gears
Future of Web Apps: Google Gearsdion
 
Going crazy with Node.JS and CakePHP
Going crazy with Node.JS and CakePHPGoing crazy with Node.JS and CakePHP
Going crazy with Node.JS and CakePHPMariano Iglesias
 
Building web framework with Rack
Building web framework with RackBuilding web framework with Rack
Building web framework with Racksickill
 

Similaire à Getting Started with Microsoft Bot Framework (20)

Sprockets
SprocketsSprockets
Sprockets
 
Building a real life application in node js
Building a real life application in node jsBuilding a real life application in node js
Building a real life application in node js
 
Build web application by express
Build web application by expressBuild web application by express
Build web application by express
 
How to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrainHow to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrain
 
Having Fun with Play
Having Fun with PlayHaving Fun with Play
Having Fun with Play
 
Using and scaling Rack and Rack-based middleware
Using and scaling Rack and Rack-based middlewareUsing and scaling Rack and Rack-based middleware
Using and scaling Rack and Rack-based middleware
 
Great Developers Steal
Great Developers StealGreat Developers Steal
Great Developers Steal
 
"Javascript" por Tiago Rodrigues
"Javascript" por Tiago Rodrigues"Javascript" por Tiago Rodrigues
"Javascript" por Tiago Rodrigues
 
Ruby 入門 第一次就上手
Ruby 入門 第一次就上手Ruby 入門 第一次就上手
Ruby 入門 第一次就上手
 
Introduction To Groovy 2005
Introduction To Groovy 2005Introduction To Groovy 2005
Introduction To Groovy 2005
 
Introduction to node.js
Introduction to node.jsIntroduction to node.js
Introduction to node.js
 
Play!ng with scala
Play!ng with scalaPlay!ng with scala
Play!ng with scala
 
Es.next
Es.nextEs.next
Es.next
 
JavaScript ES6
JavaScript ES6JavaScript ES6
JavaScript ES6
 
The Beauty of Java Script
The Beauty of Java ScriptThe Beauty of Java Script
The Beauty of Java Script
 
2007 09 10 Fzi Training Groovy Grails V Ws
2007 09 10 Fzi Training Groovy Grails V Ws2007 09 10 Fzi Training Groovy Grails V Ws
2007 09 10 Fzi Training Groovy Grails V Ws
 
Future of Web Apps: Google Gears
Future of Web Apps: Google GearsFuture of Web Apps: Google Gears
Future of Web Apps: Google Gears
 
Play á la Rails
Play á la RailsPlay á la Rails
Play á la Rails
 
Going crazy with Node.JS and CakePHP
Going crazy with Node.JS and CakePHPGoing crazy with Node.JS and CakePHP
Going crazy with Node.JS and CakePHP
 
Building web framework with Rack
Building web framework with RackBuilding web framework with Rack
Building web framework with Rack
 

Plus de Sarah Sexton

HoloLens Unity Build Pipelines on Azure DevOps
HoloLens Unity Build Pipelines on Azure DevOpsHoloLens Unity Build Pipelines on Azure DevOps
HoloLens Unity Build Pipelines on Azure DevOpsSarah Sexton
 
A Whirlwind Tour of Recurrent Neural Networks
A Whirlwind Tour of Recurrent Neural NetworksA Whirlwind Tour of Recurrent Neural Networks
A Whirlwind Tour of Recurrent Neural NetworksSarah Sexton
 
Recurrent Neural Networks (RNN)
Recurrent Neural Networks (RNN)Recurrent Neural Networks (RNN)
Recurrent Neural Networks (RNN)Sarah Sexton
 
Developing for Consoles as an Indie in 2018
Developing for Consoles as an Indie in 2018Developing for Consoles as an Indie in 2018
Developing for Consoles as an Indie in 2018Sarah Sexton
 
Implementing LUIS in Node.js
Implementing LUIS in Node.jsImplementing LUIS in Node.js
Implementing LUIS in Node.jsSarah Sexton
 
Code camp HoloLens Build and Deploy
Code camp HoloLens Build and DeployCode camp HoloLens Build and Deploy
Code camp HoloLens Build and DeploySarah Sexton
 
How to Build and Deploy to HoloLens
How to Build and Deploy to HoloLensHow to Build and Deploy to HoloLens
How to Build and Deploy to HoloLensSarah Sexton
 
Breaking into Bots
Breaking into BotsBreaking into Bots
Breaking into BotsSarah Sexton
 
Video game development for everybody
Video game development for everybodyVideo game development for everybody
Video game development for everybodySarah Sexton
 
Building Your First Node.js App and Publishing to Azure
Building Your First Node.js App and Publishing to AzureBuilding Your First Node.js App and Publishing to Azure
Building Your First Node.js App and Publishing to AzureSarah Sexton
 
New High Score! Leaderboards in the Cloud
New High Score! Leaderboards in the CloudNew High Score! Leaderboards in the Cloud
New High Score! Leaderboards in the CloudSarah Sexton
 
Developing for Consoles as an Indie in 2015
Developing for Consoles as an Indie in 2015Developing for Consoles as an Indie in 2015
Developing for Consoles as an Indie in 2015Sarah Sexton
 

Plus de Sarah Sexton (13)

HoloLens Unity Build Pipelines on Azure DevOps
HoloLens Unity Build Pipelines on Azure DevOpsHoloLens Unity Build Pipelines on Azure DevOps
HoloLens Unity Build Pipelines on Azure DevOps
 
A Whirlwind Tour of Recurrent Neural Networks
A Whirlwind Tour of Recurrent Neural NetworksA Whirlwind Tour of Recurrent Neural Networks
A Whirlwind Tour of Recurrent Neural Networks
 
Recurrent Neural Networks (RNN)
Recurrent Neural Networks (RNN)Recurrent Neural Networks (RNN)
Recurrent Neural Networks (RNN)
 
Developing for Consoles as an Indie in 2018
Developing for Consoles as an Indie in 2018Developing for Consoles as an Indie in 2018
Developing for Consoles as an Indie in 2018
 
Implementing LUIS in Node.js
Implementing LUIS in Node.jsImplementing LUIS in Node.js
Implementing LUIS in Node.js
 
Mixed Reality
Mixed RealityMixed Reality
Mixed Reality
 
Code camp HoloLens Build and Deploy
Code camp HoloLens Build and DeployCode camp HoloLens Build and Deploy
Code camp HoloLens Build and Deploy
 
How to Build and Deploy to HoloLens
How to Build and Deploy to HoloLensHow to Build and Deploy to HoloLens
How to Build and Deploy to HoloLens
 
Breaking into Bots
Breaking into BotsBreaking into Bots
Breaking into Bots
 
Video game development for everybody
Video game development for everybodyVideo game development for everybody
Video game development for everybody
 
Building Your First Node.js App and Publishing to Azure
Building Your First Node.js App and Publishing to AzureBuilding Your First Node.js App and Publishing to Azure
Building Your First Node.js App and Publishing to Azure
 
New High Score! Leaderboards in the Cloud
New High Score! Leaderboards in the CloudNew High Score! Leaderboards in the Cloud
New High Score! Leaderboards in the Cloud
 
Developing for Consoles as an Indie in 2015
Developing for Consoles as an Indie in 2015Developing for Consoles as an Indie in 2015
Developing for Consoles as an Indie in 2015
 

Dernier

SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DayH2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DaySri Ambati
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 

Dernier (20)

SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DayH2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 

Getting Started with Microsoft Bot Framework

  • 1.
  • 3.
  • 4.
  • 6.
  • 7.
  • 8.
  • 10.
  • 11.
  • 12.
  • 13. # Logs logs *.log npm-debug.log* .vscode # Runtime data pids *.pid *.seed # Directory for instrumented libs generated by jscoverage/JSCover lib-cov
  • 14. # TraceryBot Your personal GitHub code repository README contents You can add any content that you would like to be displayed on your Github code repository page.
  • 15. { "name": "tracerybot", "version": "1.0.0", "description": "Build a bot in Node.js on Microsoft Bot Framework usin "main": "app.js", "dependencies": { "botbuilder": "^3.3.0", "express": "^4.14.0", "https": "^1.0.0", "restify": "^4.1.1", "tracery-grammar": "^2.7.2" }, "devDependencies": {}, "scripts": { "test": "echo "Error: no test specified" && exit 1"
  • 16. <!doctype html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1 <title>TraceryBot</title> </head> <body> <iframe src="https://webchat.botframework.com/embed/TraceryBot?s=d style="height: 502px; max-height: 502px;"></iframe> </body> </html>
  • 17.
  • 18. //Add your requirements (as seen in package.json). var restify = require('restify'); var builder = require('botbuilder'); var tracery = require('tracery-grammar'); // Setup Restify Server var server = restify.createServer(); server.listen(process.env.port || process.env.PORT || 3978, function () console.log('%s listening to %s', server.name, server.url); }); //Direct to index.html web page server.get('/', restify.serveStatic({ directory: __dirname, default: '/index.html'
  • 19. // Create chat bot //Generate your appId and appPassword by registering a bot: // dev.botframework.com var connector = new builder.ChatConnector({ appId: process.env.MY_APP_ID, appPassword: process.env.MY_APP_PASSWORD }); var bot = new builder.UniversalBot(connector); server.post('/api/messages', connector.listen());
  • 20. ( 'origin': 'Hello, world' console.log(grammar.flatten('#origin#')); //========================================================= // Bots Dialog //========================================================= bot.dialog('/', function (session) { session.send(grammar.flatten('#origin#')); });
  • 21. Dialogs = Routing All bots will have at least one root '/' dialog • Dialog Handlers • Waterfall • Closure • Dialog Object • SimpleDialog
  • 23. Hello, world! Hello, world! Hello, world! Create text output var grammar = tracery.createGrammar({ 'origin': ['Hello, world'] })
  • 24. Hello, world! Hello, world! Hello, world! Use a replacement symbol to create text var grammar = tracery.createGrammar({ 'noun': ['world'], 'origin': ['Hello, #noun#!'] })
  • 25. hello, world! hello, world! hello, world! Use replacement for additional output components var grammar = tracery.createGrammar({ 'noun': ['world'], 'verb': ['hello'], 'origin': ['#verb#, #noun#!'] })
  • 26. Hello, world! Hello, world! Hello, world! Add modifiers to grammatically change capitalization prepend a/an, etc. var grammar = tracery.createGrammar({ 'noun': ['world'], 'verb': ['hello'], 'origin': ['#verb.capitalize#, #noun#!'] }) grammar.addModifiers(tracery.baseEngModifiers);
  • 27.
  • 28. Aloha, planet! Hello, universe! Hello, world! Goodbye, world! Add additional replacement values for var grammar = tracery.createGrammar({ 'noun': ['world', 'planet', 'universe'], 'verb': ['hello', 'goodbye', 'aloha'], 'origin': ['#verb.capitalize#, #noun#!'] }) grammar.addModifiers(tracery.baseEngModifiers);
  • 29. //Get Started with Microsoft Bot Framework in Node.js code at docs.botf //Add your requirements (as seen in package.json). //These dependencies are installed through Node.js command prompt with //npm install --save tracery-grammar var restify = require('restify'); var builder = require('botbuilder'); var tracery = require('tracery-grammar'); // Setup Restify Server //"npm install --save restify" sets up a server to host your bot online var server = restify.createServer(); server.listen(process.env.port || process.env.PORT || 3978, function ()
  • 30. Seamlessly provide disruptive growth strategies with agile scenarios. Completely bring disruptive cloud solutions from self-sustaining metrics. Efficiently administrate cutting-edge apps within extensible growth strategies. Seamlessly administrate robust metrics of cross-platform metrics.
  • 31.
  • 32. • steps: http://aka.ms/SarahSexton • GitHub.com/SarahSexton/TraceryBot • TraceryBot.azurewebsites.net • slides: http://aka.ms/BotFramework • http://dev.botframework.com

Notes de l'éditeur

  1.  Git uses it to determine which files and directories to ignore, before you make a commit. A .gitignore file should be committed into your repository, in order to share the ignore rules with any other users that clone the repository.
  2. A readme (or read me) file contains information about other files in a directory or archive and is commonly distributed with computer software, forming part of its documentation.
  3. A package.json file contains meta data about your app. Most importantly, it includes the list of dependencies to install from npm when running npm install.
  4. ‘origin’ : ‘Hello, world’ Contains the symbol ‘origin’ that is used to represent the grammar that follows, in this case plain text. Console.log(grammar.flatten(‘#origin#)); Applies grammar rules and applies symbol substitution to
  5. The main grammar text generator code producing static output
  6. Using a replacement symbol to replace part of the output
  7. Replacing addition output with symbols. Mention that letter case matches replacement
  8. Mention that modifier is changing case Explain modifiers
  9. Explain modifiers Capitalize the works Make word plural Prefix with “a” or “an” as appropriate
  10. Add additional replacement values for each symbol
  11. Add complexity to sentence structure. Add more replacement options for symbols Etc.
  12. If you want to learn more about chat bots using Tracery, clone my GitHub repository at the URL above!