SlideShare a Scribd company logo
Shivam Dutt Sharma
B.Tech (Computer Science &
Engineering)
Batch 2010 - ‘14
Presently,
Deputy Manager (Online Products)
My Employers
Ferns N Petals
We are India’s largest flower and gifts retailer and one of the largest flower retailers in the world with
a network of 320+ outlets across 120 cities.
Today, Ferns N Petals Group encompasses of :-
❖ FNP Retail & Franchising
❖ FNP E-commerce- India & UAE
❖ FNP Weddings & Events
❖ Floral Touch- India & UAE
❖ FNP Gardens, Flowers ‘N’ More
❖ The Flagship Store by FNP
❖ WDH (Wedding Design Hub)
❖ FNP Cakes 'N' More
❖ FNP Water
❖ FNP Media.
The brand provides solutions for everybody’s floral needs, be it buying flowers for occasions, floral
decor for weddings, parties or just delivering fresh flowers not only in India but across the globe.
What do I do @FernsNPetals?
- I am an Online Product Manager in the E-commerce vertical.
- My key responsibility is to manage an in-house product / microservice
called JARVIS. This JARVIS is not Tony Stark's natural-language user interface
computer system J.A.R.V.I.S.
- JARVIS is an in-house CRM / Ticket Management System for
FernsNPetals. It serves the purpose of a conventional standard query
management platform, however, it has some merits of being an in-house
product which makes the product more scalable and its development more
agile.
- JARVIS is apparently the first microservice written on our tech stack. With this
we moved away from a third party legacy CRM software service of Oracle
called RightNow.
- Another interesting and ambitious project : FNP - Alexa Integration
What do we pick first?
ALEXA SKILL DEVELOPMENT @FNP
Enabling voice orders on our consumer platform
6
What?
Alexa : Amazon Alexa which is simply known
as Alexa, is a virtual assistant developed by
Amazon.
Its capabilities : Voice interaction, music
playback, making to-do lists, setting alarms,
streaming podcasts, playing audiobooks, and
providing weather, traffic, sports, and other real-
time information, such as news.
PROJECT OBJECTIVE : Enable voice orders on Ferns N Petals
through Alexa.
Why?
Ferns N Petals, like majority of the
ecommerce players of its nature and in
similar gifting industry, facilitates the
consumers to place an order either on its
website, m-site or the App. By enabling voice
orders, we will be the first market player in
our industry to do so.
7
VOICE : Why is it on the rise?
POTENTIAL
Humans have come to a
realization that how vast
the potential of VUI is.
They are engaging in voice
experiences beyond
customer service and
search.
ACCESSIBILITY
Now, anyone can
leverage the learnings
from fields like
Automatic Speech
Recognition (ASR),
Natural Language
Understanding (NLU),
and Text To Speech
(TTS).
RESOURCES
Web Services and the IoT
provide ready-made
opportunities for VUI. For
example, a normal Alexa skill
development requires you to
merely have a Amazon
Developer Console Account
& the AWS services.
8
Let’s dive into the,
Alexa world!
Obviously, before you can get on to this interesting ride
with me, it is important for me to
brush up your knowledge on the various aspects and
elements of the Alexa Skill Development
9
What is Alexa Skill Kit?
&
What does it take to build
an Alexa Skill, afterall?
10
ALEXA SKILLS KIT
11
Alexa provides a set of built-in capabilities, referred to as skills. For example, Alexa's abilities include playing
music from multiple providers, answering questions, providing weather forecasts, and querying Wikipedia.
The Alexa Skills Kit lets you teach Alexa new skills. Customers can access these new abilities by asking Alexa
questions or making requests. You can build skills that provide users with many different types of abilities. For
example, a skill might do any one of the following:
● Look up answers to specific questions ("Alexa, ask tide pooler for the high tide today in Seattle.")
● Challenge the user with puzzles or games ("Alexa, play Harry Potter quiz.")
● Control lights and other devices in the home ("Alexa, turn on the living room lights.")
● Provide audio or text content for a customer's flash briefing ("Alexa, give me my flash briefing")
What will it take for me to build an Alexa
Skill?
12
- I should have an Amazon Developer Console account.
- I should have an access to AWS Lambda (which is an Amazon Web Services
offering) where I can run my code in the cloud without any servers.
- Alternatively, I can write a web service and host it with any cloud hosting
provider. The web service must accept requests over HTTPS.
- I should have a decent knowledge of any one of the following programming
languages : Node.js, Java, Python, C#, or Go.
- Regardless of how you create your service, the most important part for you is
to create a custom interaction model for the skill. This would basically define
the requests that the skill can handle
Alexa Developer Console
13
Use Build to set up your skill,
configure the interaction model &
specify the endpoints for your
interaction model.
Use Text to test your skill with either
text or voice.
Use Distribution to preview how your
skill will appear in the skill store.
Use Certification to validate your
skill, run pre-certification tests, and
then submit the skill for certification
Use Analytics to review metrics for
your skill such as number utterances,
customers, and intents invoked.
“Alexa Developer Console is the
place for you to be creating,
managing and publishing your
skills”
Amazon Web Services (AWS)
14
Amazon Web Services (AWS)
15
AWS is a subsidiary of Amazon that provides cloud computing platforms to
individuals, companies and other big scale institutions.
- It works on a metered pay-as-you-go-basis.
- The cloud computing services of AWS provide abstract technical infrastructure
and distributed computing building blocks.
- One such application / service of AWS is “AWS Lambda”. That’s
essentially what we are going to look at and explore while I show you a pilot of
an Alexa Custom Skill. But, everything aside, what is actually AWS Lambda?
- AWS Lambda is a serverless computing service provided by AWS. Lambda
inspects actions within the application and responds by deploying user defined
codes called as FUNCTIONS. Lambda supports the code written in Java,
Python and Node.js.
Alexa Skill Building
16
INVOCATION NAME - Users say a skill's invocation name to begin an interaction with a particular custom
skill. For example, if the invocation name is "Daily Horoscopes", users can say:
User: Alexa, ask Daily Horoscopes for the horoscope for Gemini
INTENTS - An intent represents an action that fulfills a user's spoken request.
UTTERANCES - The sample utterances are set of likely spoken phrases mapped to the intents.
SLOTS - Intents can optionally have arguments called slots.
Let the bots do the thinking!
17
Language Preference : Python
18
Why Python?
1) Simple to learn, read & write.
2) Free & Open Source - Python is an example of free / libre and
open source software FLOSS, which means one can easily
distribute copies of this software, read its source code,
modify it, etc.
3) It is a High level Language - one does not need to bother
about low level details like memory allocation while writing
Python script.
4) It is cross platform. A program written in an operating
system can be run in a different operating system without
any modifications.
5) It supports procedure as well as object oriented
programming paradigm.
6) It is extensible.
19
Applications of Python
20
- Web Development
- Testing
- Computer Vision
- Machine Learning
- Artificial Intelligence
- Deep Learning
- NAtural Language Processing
Python Basics / Fundamentals :-
21
Comments : Comment is an additional text in the program to increase
its readability. A comment starts with ‘#’ and extends till end of the
line. The comments don’t get executed.
Literal Constants : Any number or character or set of characters.
Identifiers : A Python identifier is a name used to identify a variable,
function, class, module or other objects. There is case insensitivity in
Python programming language. No special characters such as @, $,
and % within identifiers. Can start with Letter A to Z or a to z or an
underscore followed by zero or more letters, underscores and digits.
They also have some naming conventions, wherein a class must
always start with an uppercase letter, starting the identifier with a
single leading underscore makes it private, etc.
Variables
22
Variables : are nothing but reserved memory locations to store values. This
means that when you create a variable, you reserve some space in memory.
A = 15
B = 30
C = ‘Shivam’
Print (A, B, C)
Out[] : 15 30 Shivam
Standard Data Types :-
Immutable - Numbers, Strings & Tuples
Mutable - Lists, Dictionaries, Sets
Numbers Data Types - Immutable Data Type
23
Python supports three different numerical values :-
- int (signed integers)
- Complex Numbers
- Float (Real Numbers)
In Python, you can represent Numbers in multiple ways :-
- Binary
- Octal
- Hexadecimal
A = 10 #thisisinteger
B = 10.65 #thisisfloat
C = 10 + 6j #thisiscomplex
print(A, B, C)
Out[] : 10 10.65 (10 + 6j)
Strings - Immutable Data Type
24
- Sequence of characters represented in quotes is known as
strings.
- Python does not support character type; they are treated as
strings of length one.
- Python strings can be defined within a pair of single or double
quotes. It can also be defined within triple single or double
quotes.
A = ‘I am in Amrapali’ #thisisstring
B = “I am in Amrapali” #thisisstring
C = ‘’’I am in Amrapali’’’ #thisisstring
print(A)
Out[] : I am in Amrapali I am in Amrapali I am in Amrapali
Some textbooks for reference :-
25
How to think like a Computer Scientist? - Green Tea Press
Fundamentals of Python Programming - Rick Halterman
A Python Book - Dave Kuhlman
Youtube videos - Edureka
Let’s skip the language basics and get to libraries..
26
Pandas : Pandas is a software library for Data manipulation and
analysis.
NumPy : NumPy is a package for scientific computing.
Features - Multi Dimensional Array, Methods for processing arrays,
Mathematical operations like linear algebra, etc.
matplotlib : Matplotlib is a multi-platform data visualization library
built on NumPy arrays.
NumPy
27
Import numpy as np
a = np.array([1, 2, 3, 4])
print (a)
Creating a single dimensional array :-
Creating a multi dimensional array :-
Import numpy as np
a = np.array([[1, 2, 3, 4], [5,6,7,8]])
print (a)
Pandas
28
Converting a list into Data Frame
import pandas
listx = [10, 20, 30, 40]
Table = pandas.DataFrame(listx)
print(table)
Reading data from csv file
table = pandas.read_csv(“filepath.csv”)
print(table)
Writing to a file
df1 = pd.DataFrame([['a', 'b'], ['c', 'd']],
index=['row 1', 'row 2'],
columns=['col 1', 'col 2'])
df1.to_excel("output.xlsx") # doctest:
+SKIP
matlplotlib
29
Plotting a graph
import pandas as pd
import matplotlib.pyplot as plt
import numpy as np
df = pd.read_csv("/data/training/sales.csv")
x = np.arange(1949, 1960, 0.01)
plt.plot([1520,1676,2042,2364,2700,2867,340
8,3939,4421,4572,5140,5714])
plt.xlabel('Year')
plt.ylabel('Sales')

More Related Content

Similar to Guest Lecture _ Python Basics _ Alexa Skill Dev _ by Shivam Dutt Sharma

Amazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current OfferingAmazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current Offering
Amazon Web Services
 
Insy Labs
Insy LabsInsy Labs
Insy Labs
rakshpma
 
Getting Started with Amazon Lex - AWS Summit Cape Town 2017
Getting Started with Amazon Lex  - AWS Summit Cape Town 2017 Getting Started with Amazon Lex  - AWS Summit Cape Town 2017
Getting Started with Amazon Lex - AWS Summit Cape Town 2017
Amazon Web Services
 
Lamp presentation
Lamp presentationLamp presentation
Lamp presentation
sathyancegonsoft
 
sitNL 2019 - SAP Conversational AI
sitNL 2019 - SAP Conversational AIsitNL 2019 - SAP Conversational AI
sitNL 2019 - SAP Conversational AI
Wim Snoep
 
Amazon Alexa Development Overview
Amazon Alexa Development OverviewAmazon Alexa Development Overview
Amazon Alexa Development Overview
John Brady
 
Technology trends and the skills you should learn
Technology trends and the skills you should learnTechnology trends and the skills you should learn
Technology trends and the skills you should learn
Orange and Bronze Software Labs
 
Bagels & Bytes: Data Scientist Event
Bagels & Bytes: Data Scientist EventBagels & Bytes: Data Scientist Event
Bagels & Bytes: Data Scientist Event
Amazon Web Services
 
RAML - APIs By Design
RAML - APIs By DesignRAML - APIs By Design
RAML - APIs By Design
Uri Sarid
 
Digital Muse “Girl Tech Fest - AWS Alexa Skills Coding Workshop
Digital Muse “Girl Tech Fest - AWS Alexa Skills Coding WorkshopDigital Muse “Girl Tech Fest - AWS Alexa Skills Coding Workshop
Digital Muse “Girl Tech Fest - AWS Alexa Skills Coding Workshop
Dinah Barrett
 
Xuedong Huang - Deep Learning and Intelligent Applications
Xuedong Huang - Deep Learning and Intelligent ApplicationsXuedong Huang - Deep Learning and Intelligent Applications
Xuedong Huang - Deep Learning and Intelligent Applications
Machine Learning Prague
 
Industrial training seminar ppt on asp.net
Industrial training seminar ppt on asp.netIndustrial training seminar ppt on asp.net
Industrial training seminar ppt on asp.net
Pankaj Kushwaha
 
Realizzare un Virtual Assistant con Bot Framework Azure e Unity
Realizzare un Virtual Assistant con Bot Framework Azure e UnityRealizzare un Virtual Assistant con Bot Framework Azure e Unity
Realizzare un Virtual Assistant con Bot Framework Azure e Unity
Marco Parenzan
 
NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!
NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!
NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!
NUS-ISS
 
Touch Screens | The very expensive mistake
Touch Screens | The very expensive mistakeTouch Screens | The very expensive mistake
Touch Screens | The very expensive mistake
Casey Dubbs
 
Introduction to Backend Development (1).pptx
Introduction to Backend Development (1).pptxIntroduction to Backend Development (1).pptx
Introduction to Backend Development (1).pptx
OsuGodbless
 
3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...
3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...
3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...
Daniel Zivkovic
 
Watson products
Watson productsWatson products
Watson products
ronanb3
 
Conversational Document Processing AI with Rui Costa
Conversational Document Processing AI with Rui CostaConversational Document Processing AI with Rui Costa
Conversational Document Processing AI with Rui Costa
Daniel Zivkovic
 
The most efficient development tool is now available in Pakistan.pdf
The most efficient development tool is now available in Pakistan.pdfThe most efficient development tool is now available in Pakistan.pdf
The most efficient development tool is now available in Pakistan.pdf
Connect Solutions
 

Similar to Guest Lecture _ Python Basics _ Alexa Skill Dev _ by Shivam Dutt Sharma (20)

Amazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current OfferingAmazon Web Services - Strategy and Current Offering
Amazon Web Services - Strategy and Current Offering
 
Insy Labs
Insy LabsInsy Labs
Insy Labs
 
Getting Started with Amazon Lex - AWS Summit Cape Town 2017
Getting Started with Amazon Lex  - AWS Summit Cape Town 2017 Getting Started with Amazon Lex  - AWS Summit Cape Town 2017
Getting Started with Amazon Lex - AWS Summit Cape Town 2017
 
Lamp presentation
Lamp presentationLamp presentation
Lamp presentation
 
sitNL 2019 - SAP Conversational AI
sitNL 2019 - SAP Conversational AIsitNL 2019 - SAP Conversational AI
sitNL 2019 - SAP Conversational AI
 
Amazon Alexa Development Overview
Amazon Alexa Development OverviewAmazon Alexa Development Overview
Amazon Alexa Development Overview
 
Technology trends and the skills you should learn
Technology trends and the skills you should learnTechnology trends and the skills you should learn
Technology trends and the skills you should learn
 
Bagels & Bytes: Data Scientist Event
Bagels & Bytes: Data Scientist EventBagels & Bytes: Data Scientist Event
Bagels & Bytes: Data Scientist Event
 
RAML - APIs By Design
RAML - APIs By DesignRAML - APIs By Design
RAML - APIs By Design
 
Digital Muse “Girl Tech Fest - AWS Alexa Skills Coding Workshop
Digital Muse “Girl Tech Fest - AWS Alexa Skills Coding WorkshopDigital Muse “Girl Tech Fest - AWS Alexa Skills Coding Workshop
Digital Muse “Girl Tech Fest - AWS Alexa Skills Coding Workshop
 
Xuedong Huang - Deep Learning and Intelligent Applications
Xuedong Huang - Deep Learning and Intelligent ApplicationsXuedong Huang - Deep Learning and Intelligent Applications
Xuedong Huang - Deep Learning and Intelligent Applications
 
Industrial training seminar ppt on asp.net
Industrial training seminar ppt on asp.netIndustrial training seminar ppt on asp.net
Industrial training seminar ppt on asp.net
 
Realizzare un Virtual Assistant con Bot Framework Azure e Unity
Realizzare un Virtual Assistant con Bot Framework Azure e UnityRealizzare un Virtual Assistant con Bot Framework Azure e Unity
Realizzare un Virtual Assistant con Bot Framework Azure e Unity
 
NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!
NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!
NUS-ISS Learning Day 2017 - Voice Computing - The Next Digital Disruption!
 
Touch Screens | The very expensive mistake
Touch Screens | The very expensive mistakeTouch Screens | The very expensive mistake
Touch Screens | The very expensive mistake
 
Introduction to Backend Development (1).pptx
Introduction to Backend Development (1).pptxIntroduction to Backend Development (1).pptx
Introduction to Backend Development (1).pptx
 
3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...
3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...
3-in-1 talk on Serverless Chatbots, Alexa skills & Voice UI best practices (t...
 
Watson products
Watson productsWatson products
Watson products
 
Conversational Document Processing AI with Rui Costa
Conversational Document Processing AI with Rui CostaConversational Document Processing AI with Rui Costa
Conversational Document Processing AI with Rui Costa
 
The most efficient development tool is now available in Pakistan.pdf
The most efficient development tool is now available in Pakistan.pdfThe most efficient development tool is now available in Pakistan.pdf
The most efficient development tool is now available in Pakistan.pdf
 

Recently uploaded

Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
Claudio Di Ciccio
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
panagenda
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Safe Software
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
Adtran
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 
Full-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalizationFull-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalization
Zilliz
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
Zilliz
 
Video Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the FutureVideo Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the Future
Alpen-Adria-Universität
 
Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
Zilliz
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Speck&Tech
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
Neo4j
 

Recently uploaded (20)

Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 
Full-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalizationFull-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalization
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
 
Video Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the FutureVideo Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the Future
 
Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
 

Guest Lecture _ Python Basics _ Alexa Skill Dev _ by Shivam Dutt Sharma

  • 1. Shivam Dutt Sharma B.Tech (Computer Science & Engineering) Batch 2010 - ‘14 Presently, Deputy Manager (Online Products)
  • 3. Ferns N Petals We are India’s largest flower and gifts retailer and one of the largest flower retailers in the world with a network of 320+ outlets across 120 cities. Today, Ferns N Petals Group encompasses of :- ❖ FNP Retail & Franchising ❖ FNP E-commerce- India & UAE ❖ FNP Weddings & Events ❖ Floral Touch- India & UAE ❖ FNP Gardens, Flowers ‘N’ More ❖ The Flagship Store by FNP ❖ WDH (Wedding Design Hub) ❖ FNP Cakes 'N' More ❖ FNP Water ❖ FNP Media. The brand provides solutions for everybody’s floral needs, be it buying flowers for occasions, floral decor for weddings, parties or just delivering fresh flowers not only in India but across the globe.
  • 4. What do I do @FernsNPetals? - I am an Online Product Manager in the E-commerce vertical. - My key responsibility is to manage an in-house product / microservice called JARVIS. This JARVIS is not Tony Stark's natural-language user interface computer system J.A.R.V.I.S. - JARVIS is an in-house CRM / Ticket Management System for FernsNPetals. It serves the purpose of a conventional standard query management platform, however, it has some merits of being an in-house product which makes the product more scalable and its development more agile. - JARVIS is apparently the first microservice written on our tech stack. With this we moved away from a third party legacy CRM software service of Oracle called RightNow. - Another interesting and ambitious project : FNP - Alexa Integration
  • 5. What do we pick first?
  • 6. ALEXA SKILL DEVELOPMENT @FNP Enabling voice orders on our consumer platform 6
  • 7. What? Alexa : Amazon Alexa which is simply known as Alexa, is a virtual assistant developed by Amazon. Its capabilities : Voice interaction, music playback, making to-do lists, setting alarms, streaming podcasts, playing audiobooks, and providing weather, traffic, sports, and other real- time information, such as news. PROJECT OBJECTIVE : Enable voice orders on Ferns N Petals through Alexa. Why? Ferns N Petals, like majority of the ecommerce players of its nature and in similar gifting industry, facilitates the consumers to place an order either on its website, m-site or the App. By enabling voice orders, we will be the first market player in our industry to do so. 7
  • 8. VOICE : Why is it on the rise? POTENTIAL Humans have come to a realization that how vast the potential of VUI is. They are engaging in voice experiences beyond customer service and search. ACCESSIBILITY Now, anyone can leverage the learnings from fields like Automatic Speech Recognition (ASR), Natural Language Understanding (NLU), and Text To Speech (TTS). RESOURCES Web Services and the IoT provide ready-made opportunities for VUI. For example, a normal Alexa skill development requires you to merely have a Amazon Developer Console Account & the AWS services. 8
  • 9. Let’s dive into the, Alexa world! Obviously, before you can get on to this interesting ride with me, it is important for me to brush up your knowledge on the various aspects and elements of the Alexa Skill Development 9
  • 10. What is Alexa Skill Kit? & What does it take to build an Alexa Skill, afterall? 10
  • 11. ALEXA SKILLS KIT 11 Alexa provides a set of built-in capabilities, referred to as skills. For example, Alexa's abilities include playing music from multiple providers, answering questions, providing weather forecasts, and querying Wikipedia. The Alexa Skills Kit lets you teach Alexa new skills. Customers can access these new abilities by asking Alexa questions or making requests. You can build skills that provide users with many different types of abilities. For example, a skill might do any one of the following: ● Look up answers to specific questions ("Alexa, ask tide pooler for the high tide today in Seattle.") ● Challenge the user with puzzles or games ("Alexa, play Harry Potter quiz.") ● Control lights and other devices in the home ("Alexa, turn on the living room lights.") ● Provide audio or text content for a customer's flash briefing ("Alexa, give me my flash briefing")
  • 12. What will it take for me to build an Alexa Skill? 12 - I should have an Amazon Developer Console account. - I should have an access to AWS Lambda (which is an Amazon Web Services offering) where I can run my code in the cloud without any servers. - Alternatively, I can write a web service and host it with any cloud hosting provider. The web service must accept requests over HTTPS. - I should have a decent knowledge of any one of the following programming languages : Node.js, Java, Python, C#, or Go. - Regardless of how you create your service, the most important part for you is to create a custom interaction model for the skill. This would basically define the requests that the skill can handle
  • 13. Alexa Developer Console 13 Use Build to set up your skill, configure the interaction model & specify the endpoints for your interaction model. Use Text to test your skill with either text or voice. Use Distribution to preview how your skill will appear in the skill store. Use Certification to validate your skill, run pre-certification tests, and then submit the skill for certification Use Analytics to review metrics for your skill such as number utterances, customers, and intents invoked. “Alexa Developer Console is the place for you to be creating, managing and publishing your skills”
  • 15. Amazon Web Services (AWS) 15 AWS is a subsidiary of Amazon that provides cloud computing platforms to individuals, companies and other big scale institutions. - It works on a metered pay-as-you-go-basis. - The cloud computing services of AWS provide abstract technical infrastructure and distributed computing building blocks. - One such application / service of AWS is “AWS Lambda”. That’s essentially what we are going to look at and explore while I show you a pilot of an Alexa Custom Skill. But, everything aside, what is actually AWS Lambda? - AWS Lambda is a serverless computing service provided by AWS. Lambda inspects actions within the application and responds by deploying user defined codes called as FUNCTIONS. Lambda supports the code written in Java, Python and Node.js.
  • 16. Alexa Skill Building 16 INVOCATION NAME - Users say a skill's invocation name to begin an interaction with a particular custom skill. For example, if the invocation name is "Daily Horoscopes", users can say: User: Alexa, ask Daily Horoscopes for the horoscope for Gemini INTENTS - An intent represents an action that fulfills a user's spoken request. UTTERANCES - The sample utterances are set of likely spoken phrases mapped to the intents. SLOTS - Intents can optionally have arguments called slots.
  • 17. Let the bots do the thinking! 17
  • 18. Language Preference : Python 18 Why Python? 1) Simple to learn, read & write. 2) Free & Open Source - Python is an example of free / libre and open source software FLOSS, which means one can easily distribute copies of this software, read its source code, modify it, etc. 3) It is a High level Language - one does not need to bother about low level details like memory allocation while writing Python script. 4) It is cross platform. A program written in an operating system can be run in a different operating system without any modifications. 5) It supports procedure as well as object oriented programming paradigm. 6) It is extensible.
  • 19. 19
  • 20. Applications of Python 20 - Web Development - Testing - Computer Vision - Machine Learning - Artificial Intelligence - Deep Learning - NAtural Language Processing
  • 21. Python Basics / Fundamentals :- 21 Comments : Comment is an additional text in the program to increase its readability. A comment starts with ‘#’ and extends till end of the line. The comments don’t get executed. Literal Constants : Any number or character or set of characters. Identifiers : A Python identifier is a name used to identify a variable, function, class, module or other objects. There is case insensitivity in Python programming language. No special characters such as @, $, and % within identifiers. Can start with Letter A to Z or a to z or an underscore followed by zero or more letters, underscores and digits. They also have some naming conventions, wherein a class must always start with an uppercase letter, starting the identifier with a single leading underscore makes it private, etc.
  • 22. Variables 22 Variables : are nothing but reserved memory locations to store values. This means that when you create a variable, you reserve some space in memory. A = 15 B = 30 C = ‘Shivam’ Print (A, B, C) Out[] : 15 30 Shivam Standard Data Types :- Immutable - Numbers, Strings & Tuples Mutable - Lists, Dictionaries, Sets
  • 23. Numbers Data Types - Immutable Data Type 23 Python supports three different numerical values :- - int (signed integers) - Complex Numbers - Float (Real Numbers) In Python, you can represent Numbers in multiple ways :- - Binary - Octal - Hexadecimal A = 10 #thisisinteger B = 10.65 #thisisfloat C = 10 + 6j #thisiscomplex print(A, B, C) Out[] : 10 10.65 (10 + 6j)
  • 24. Strings - Immutable Data Type 24 - Sequence of characters represented in quotes is known as strings. - Python does not support character type; they are treated as strings of length one. - Python strings can be defined within a pair of single or double quotes. It can also be defined within triple single or double quotes. A = ‘I am in Amrapali’ #thisisstring B = “I am in Amrapali” #thisisstring C = ‘’’I am in Amrapali’’’ #thisisstring print(A) Out[] : I am in Amrapali I am in Amrapali I am in Amrapali
  • 25. Some textbooks for reference :- 25 How to think like a Computer Scientist? - Green Tea Press Fundamentals of Python Programming - Rick Halterman A Python Book - Dave Kuhlman Youtube videos - Edureka
  • 26. Let’s skip the language basics and get to libraries.. 26 Pandas : Pandas is a software library for Data manipulation and analysis. NumPy : NumPy is a package for scientific computing. Features - Multi Dimensional Array, Methods for processing arrays, Mathematical operations like linear algebra, etc. matplotlib : Matplotlib is a multi-platform data visualization library built on NumPy arrays.
  • 27. NumPy 27 Import numpy as np a = np.array([1, 2, 3, 4]) print (a) Creating a single dimensional array :- Creating a multi dimensional array :- Import numpy as np a = np.array([[1, 2, 3, 4], [5,6,7,8]]) print (a)
  • 28. Pandas 28 Converting a list into Data Frame import pandas listx = [10, 20, 30, 40] Table = pandas.DataFrame(listx) print(table) Reading data from csv file table = pandas.read_csv(“filepath.csv”) print(table) Writing to a file df1 = pd.DataFrame([['a', 'b'], ['c', 'd']], index=['row 1', 'row 2'], columns=['col 1', 'col 2']) df1.to_excel("output.xlsx") # doctest: +SKIP
  • 29. matlplotlib 29 Plotting a graph import pandas as pd import matplotlib.pyplot as plt import numpy as np df = pd.read_csv("/data/training/sales.csv") x = np.arange(1949, 1960, 0.01) plt.plot([1520,1676,2042,2364,2700,2867,340 8,3939,4421,4572,5140,5714]) plt.xlabel('Year') plt.ylabel('Sales')

Editor's Notes

  1. Extensible means that it can invoke C & C++ libraries. It can also integrate with Java & .NET components.