exploring the business use cases for amazon machine learning - june 2017 aws online tech talks

25
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Kumar Venkateswar, Product Manager, Amazon AI 6/12/2017 Amazon Machine Learning

Upload: amazon-web-services

Post on 23-Jan-2018

956 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.

Kumar Venkateswar, Product Manager, Amazon AI

6/12/2017

Amazon Machine Learning

Page 2: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Agenda

Smart applications by example

Developing with Amazon ML

Demo

How Amazon ML fits into other AWS AI services

Q&A

Page 3: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Machine learning and smart applications

Machine learning is the technology that

automatically finds patterns in your data and

uses them to make predictions for new data

points as they become available

Your data + machine learning = smart applications

Page 4: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Challenge: Insurance companies spend billions of

dollars on roof losses annually

Solution: BuildFax provides roof age and condition

estimates with the help of Amazon ML.

BuildFax

Amazon Machine Learning democratizes the process of building predictive models. It's easy and fast to

use, and has machine-learning best practices encapsulated in the product, which lets us deliver results

significantly faster than in the past.

Joe Emison

Founder & Chief Technology Officer

Page 5: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Challenge: Restaurant owners want to use data to

better serve their customers

Solution: Upserve provides predictions on the

number of customers and items ordered with the

help of Amazon ML.

Upserve

Using Amazon Machine Learning, we can predict the total number of customers who will walk through a

restaurant’s doors in a night. As a result, restaurateurs can better prep and plan their staffing for that night.

Bright Fulton

Director of Infrastructure Engineering

Page 6: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

And a few more examples…

Fraud detection

(binary)

Detecting fraudulent transactions, filtering spam emails,

flagging suspicious reviews, …

Personalization

(categorical)

Recommending content, predictive content loading,

improving user experience, …

Targeted marketing

(binary/categorical)

Matching customers and offers, choosing marketing

campaigns, cross-selling and up-selling, …

Content classification

(categorical)

Categorizing documents, matching hiring managers and

resumes, …

Churn prediction

(binary)

Finding customers who are likely to stop using the

service, free-tier upgrade targeting, …

Customer support

(categorical)

Predictive routing of customer emails, social media

listening, …

Page 7: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

But why not use business rules instead?

Page 8: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Smart applications by counter-example

SELECT c.ID

FROM customers c

LEFT JOIN orders o

ON c.ID = o.customer

LEFT JOIN products p

ON p.ID = o.product

GROUP BY c.ID

HAVING o.category = ‘toys’

AND ((p.description LIKE ‘%copter%’

AND o.date > GETDATE() - )

OR (COUNT(*) > 2

AND SUM(o.price) > 150

AND o.date > GETDATE() – 40)

)

Use machine learning

technology to learn

your business rules

from data, instead of

endlessly iterating

business rules

Page 9: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Trainmodel

Evaluate andoptimize

Retrieve predictions

1 2 3

Building smart applications with Amazon ML

Page 10: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Trainmodel

Evaluate andoptimize

Retrieve predictions

1 2 3

Building smart applications with Amazon ML

- Create a Datasource object pointing to your data

- Explore and understand your data

- Transform data and train your model

Page 11: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Create a Datasource object

>>> import boto3

>>> ml = boto3.client('machinelearning')

>>> ds = ml.create_data_source_from_s3(

DataSourceId = 'my_datasource',

DataSpec= {

'DataLocationS3':'s3://bucket/input/',

'DataSchemaLocationS3':'s3://bucket/input/.schema'},

ComputeStatistics = False)

Page 12: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Explore and understand your data

Page 13: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Train your model

>>> import boto3

>>> ml = boto3.client('machinelearning')

>>> model = ml.create_ml_model(

MLModelId=’my_model',

MLModelType='REGRESSION',

TrainingDataSourceId='my_datasource')

Page 14: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Trainmodel

Evaluate andoptimize

Retrieve predictions

1 2 3

Building smart applications with Amazon ML

- Understand model quality

- Adjust model interpretation

Page 15: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Explore model quality

Page 16: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Fine-tune model interpretation

Page 17: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Fine-tune model interpretation

Page 18: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Trainmodel

Evaluate andoptimize

Retrieve predictions

1 2 3

Building smart applications with Amazon ML

- Batch predictions

- Real-time predictions

Page 19: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Batch predictions

Asynchronous, large-volume prediction generation

Request through service console or API

Best for applications that deal with batches of data records

>>> import boto3

>>> ml = boto3.client('machinelearning')

>>> model = ml.create_batch_prediction(

BatchPredictionId = 'my_batch_prediction’

BatchPredictionDataSourceId = ’my_datasource’

MLModelId = ’my_model',

OutputUri = 's3://examplebucket/output/’)

Page 20: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Real-time predictions

Synchronous, low-latency, high-throughput prediction generation

Request through service API or server or mobile SDKs

Best for interaction applications that deal with individual data

records

>>> import boto3

>>> ml = boto3.client('machinelearning')

>>> ml.predict(

MLModelId=’my_model',

PredictEndpoint=’example_endpoint’,

Record={’key1':’value1’, ’key2':’value2’})

{

'Prediction': {

'predictedValue': 13.284348,

'details': {

'Algorithm': 'SGD',

'PredictiveModelType': 'REGRESSION’

}

}

}

Page 21: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

© 2016, Amazon Web Services, Inc. or its Affiliates. All rights reserved

Demo

Page 22: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

We are here to make machine learning widespread…

by sharing what we use ourselves!

Developer APIs: Rekognition, Polly, Lex, Amazon Kinesis Analytics

Developer platform components: Amazon Machine Learning

Data Scientist platform components: Apache Spark MLlib,

Apache MXNet, Deep Learning AMI

Lower level platform components: Elastic MapReduce, EC2

(CPU, GPU, and FPGA instances)

More to come, of course!

Amazon Confidential

Page 23: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

© 2016, Amazon Web Services, Inc. or its Affiliates. All rights reserved

Q&A

Page 24: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks

Amazon Confidential

What else can we do?

Page 25: Exploring the Business Use Cases for Amazon Machine Learning - June 2017 AWS Online Tech Talks