SlideShare uma empresa Scribd logo
1 de 33
Baixar para ler offline
Machine Learning, Faster
@neal_lathia
Machine Learning Lead
Monzo Chat
https://monzo.com/blog/2018/11/02/monzo-chat/
https://cloud.google.com/customers/monzo/
The main problems that we aim to solve with
machine learning include helping customers
find the right answers to their queries (in the
help screen of the app) and helping agents to
diagnose and respond to customer queries
swiftly (in the internal tooling).
Our most impactful model is an encoder based
on [1] that we train on chat data.
[1] Attention is all you need
https://arxiv.org/abs/1706.03762
Customer Operations
https://monzo.com/blog/2018/08/01/data-help/
How can we accelerate the
development of machine learning?
(1) Deploying, (2) Validing
(3) Reusing, (4) Templating
Deploying
From validated idea → production in < 1 day.
Quickly deploying models to
production is one of the biggest
roadblocks for impactful
machine learning.
https://monzo.com/blog/2016/09/19/building-a-modern-bank-backend/
What did we decide?
We created a tool to easily create a new
microservice. It included:
● A Python web server (Sanic)
● Deploying any kind of model (PyTorch,
Keras, Scikit-Learn)
● Selectively include add-ons, e.g. our
in-house model zoo library for NLP
● Command-line utilities for deploying
across the staging and production
environments.
Goal: if you can write a
predict() function, then you
can deploy a machine learning
model to production without
breaking anything.
Validating
Maintaining & debugging production models.
Quickly diagnosing minor issues
with machine learning models in
production is nearly impossible.
When I search for X, where is Y?
● Diagnosing this problem via unit or
integration tests did not work; revisiting the
model training was too slow.
● We added validation testing: making easy
predictions in production & validate that
they make the expected predictions.
● We get alerted when they fail. Most times,
it’s the pipeline, not the model!
Validation testing
Keeping track of the online
performance of machine
learning models is going beyond
what we traditionally do when
deploying software.
Reusing
> 1 feature from 1 model
Can we quickly reuse an existing
model to tackle a new problem?
Existing model
Similar problem
● How can we redirect a subset of
conversations, based on their topic, to a
different queue?
● This is desperately needed to handle a high
volume of messages.
● Most of the research around this focuses
on transfer learning or fine-tuning.
Reusable solution
● We wrote a service that interacts with our
saved response recommender system --
but uses the recommendations to make a
queue assignment decision.
● Deployed this within less than a day &
used it to tackle a period of high inbound
demand on customer service.
Combining a rule engine over an
existing model creates a new
decision system. Rule engines &
ML can coexist!
Templating
Staying 10 steps behind the latest research
How can we quickly evaluate the
new state of the art in machine
learning?
2018 was transformative for
NLP
From shallow to deep language model pretraining
● Deep Contextualised Word Representations (ELMo, Feb 2018)
● Universal Language Model Fine-tuning for Text Classification
(ULMFit, May 2018)
● Pre-training of Deep Bidirectional Transformers for Language
Understanding (BERT, October 2018)
● … and more
http://ruder.io/nlp-imagenet/
● Completely split out the process of
generating clean, well-formatted, and
labelled text-based datasets for supervised
learning from any of the code that does the
learning itself.
● Created a number of plug-and-play Colab
notebooks for ULMFit, BERT (and PyText).
● Focus on time to results and common
requirements instead of specific prediction
problems. The most promising will be
taken forward later.
Approach research as an
exercise in creating templates
“To increase your success rate,
double your failure rate” (& get
to the same results in half the
time)
Conclusions
Speed & Machine Learning
● Deploying, validating, reusing, templating.
● Adopting the best practices from
engineering; tweaking the ones that do not
work for machine learning.
● Research time is well spent if we get some
tools (bonus: we also get some results).
● Always a work in progress!
Thanks!
@neal_lathia
https://monzo.com/careers/

Mais conteúdo relacionado

Semelhante a Machine Learning, Faster

Implementation Of Incremental Development Process
Implementation Of Incremental Development ProcessImplementation Of Incremental Development Process
Implementation Of Incremental Development Process
Sherry Bailey
 
john warns resume
john warns resumejohn warns resume
john warns resume
john warns
 
Resume_Brijesh_Pavith
Resume_Brijesh_PavithResume_Brijesh_Pavith
Resume_Brijesh_Pavith
beeemused
 

Semelhante a Machine Learning, Faster (20)

DESIGN AND DEVELOPMENT OF BUSINESS RULES MANAGEMENT SYSTEM (BRMS) USING ATLAN...
DESIGN AND DEVELOPMENT OF BUSINESS RULES MANAGEMENT SYSTEM (BRMS) USING ATLAN...DESIGN AND DEVELOPMENT OF BUSINESS RULES MANAGEMENT SYSTEM (BRMS) USING ATLAN...
DESIGN AND DEVELOPMENT OF BUSINESS RULES MANAGEMENT SYSTEM (BRMS) USING ATLAN...
 
Natural Language Processing at Scale
Natural Language Processing at ScaleNatural Language Processing at Scale
Natural Language Processing at Scale
 
Kavitha Elangovan
Kavitha ElangovanKavitha Elangovan
Kavitha Elangovan
 
Implementation Of Incremental Development Process
Implementation Of Incremental Development ProcessImplementation Of Incremental Development Process
Implementation Of Incremental Development Process
 
Stefan Geissler kairntech - SDC Nice Apr 2019
Stefan Geissler kairntech - SDC Nice Apr 2019 Stefan Geissler kairntech - SDC Nice Apr 2019
Stefan Geissler kairntech - SDC Nice Apr 2019
 
john warns resume
john warns resumejohn warns resume
john warns resume
 
Beware the monolith
Beware the monolithBeware the monolith
Beware the monolith
 
CV Jose Maria Estevez Canales - EN
CV Jose Maria Estevez Canales - ENCV Jose Maria Estevez Canales - EN
CV Jose Maria Estevez Canales - EN
 
CV
CVCV
CV
 
Software development with agile methodologies
Software development with agile methodologiesSoftware development with agile methodologies
Software development with agile methodologies
 
Hybrid model for software development
Hybrid model for software developmentHybrid model for software development
Hybrid model for software development
 
A comprehensive guide to prompt engineering.pdf
A comprehensive guide to prompt engineering.pdfA comprehensive guide to prompt engineering.pdf
A comprehensive guide to prompt engineering.pdf
 
Resume_Brijesh_Pavith
Resume_Brijesh_PavithResume_Brijesh_Pavith
Resume_Brijesh_Pavith
 
DataScientist Job : Between Myths and Reality.pdf
DataScientist Job : Between Myths and Reality.pdfDataScientist Job : Between Myths and Reality.pdf
DataScientist Job : Between Myths and Reality.pdf
 
Introducing Langsmith_ Your All-in-One Solution for Debugging, Testing, Evalu...
Introducing Langsmith_ Your All-in-One Solution for Debugging, Testing, Evalu...Introducing Langsmith_ Your All-in-One Solution for Debugging, Testing, Evalu...
Introducing Langsmith_ Your All-in-One Solution for Debugging, Testing, Evalu...
 
Future of Fintech - A Whitepaper by RapidValue
Future of Fintech - A Whitepaper by RapidValueFuture of Fintech - A Whitepaper by RapidValue
Future of Fintech - A Whitepaper by RapidValue
 
Consulting
ConsultingConsulting
Consulting
 
The Jnaapti Virtual Coach Platform
The Jnaapti Virtual Coach PlatformThe Jnaapti Virtual Coach Platform
The Jnaapti Virtual Coach Platform
 
Mendix Essentials Presentatie Gerolf Roovers26/08/2011
Mendix Essentials Presentatie Gerolf Roovers26/08/2011Mendix Essentials Presentatie Gerolf Roovers26/08/2011
Mendix Essentials Presentatie Gerolf Roovers26/08/2011
 
Duraichi _Dotnet_6yrsexp_cv
Duraichi _Dotnet_6yrsexp_cvDuraichi _Dotnet_6yrsexp_cv
Duraichi _Dotnet_6yrsexp_cv
 

Mais de Neal Lathia

Using Smartphones to Research Daily Life
Using Smartphones to Research Daily LifeUsing Smartphones to Research Daily Life
Using Smartphones to Research Daily Life
Neal Lathia
 

Mais de Neal Lathia (20)

AI & Personalised Experiences
AI & Personalised ExperiencesAI & Personalised Experiences
AI & Personalised Experiences
 
Opportunities & Challenges in Personalised Travel
Opportunities & Challenges in Personalised TravelOpportunities & Challenges in Personalised Travel
Opportunities & Challenges in Personalised Travel
 
Bootstrapping a Destination Recommendation Engine
Bootstrapping a Destination Recommendation EngineBootstrapping a Destination Recommendation Engine
Bootstrapping a Destination Recommendation Engine
 
Machine Learning for Product Managers
Machine Learning for Product ManagersMachine Learning for Product Managers
Machine Learning for Product Managers
 
Mining Smartphone Data (with Python)
Mining Smartphone Data (with Python)Mining Smartphone Data (with Python)
Mining Smartphone Data (with Python)
 
Happier and Healthier with Smartphone Data
Happier and Healthier with Smartphone DataHappier and Healthier with Smartphone Data
Happier and Healthier with Smartphone Data
 
Data Science in Digital Health
Data Science in Digital HealthData Science in Digital Health
Data Science in Digital Health
 
Using Smartphones to Measure (and Intervene in) Daily Life
Using Smartphones to Measure (and Intervene in) Daily LifeUsing Smartphones to Measure (and Intervene in) Daily Life
Using Smartphones to Measure (and Intervene in) Daily Life
 
Analysing Daily Behaviours with Large-Scale Smartphone Data
Analysing Daily Behaviours with Large-Scale Smartphone DataAnalysing Daily Behaviours with Large-Scale Smartphone Data
Analysing Daily Behaviours with Large-Scale Smartphone Data
 
Cambridge Quantified Self Meetup
Cambridge Quantified Self MeetupCambridge Quantified Self Meetup
Cambridge Quantified Self Meetup
 
Data Science in #mHealth
Data Science in #mHealthData Science in #mHealth
Data Science in #mHealth
 
Tube Star: Crowd-Sourced Experiences on Public Transport
Tube Star: Crowd-Sourced Experiences on Public Transport Tube Star: Crowd-Sourced Experiences on Public Transport
Tube Star: Crowd-Sourced Experiences on Public Transport
 
Emotion Sense: From Design to Deployment
Emotion Sense: From Design to DeploymentEmotion Sense: From Design to Deployment
Emotion Sense: From Design to Deployment
 
Opportunities and Challenges of Using Smartphones for Health Monitoring and I...
Opportunities and Challenges of Using Smartphones for Health Monitoring and I...Opportunities and Challenges of Using Smartphones for Health Monitoring and I...
Opportunities and Challenges of Using Smartphones for Health Monitoring and I...
 
Using Smartphones to Research Daily Life
Using Smartphones to Research Daily LifeUsing Smartphones to Research Daily Life
Using Smartphones to Research Daily Life
 
The Ubhave Framework
The Ubhave FrameworkThe Ubhave Framework
The Ubhave Framework
 
Contextual Dissonance: Design Bias in Sensor-Based Experience Sampling Methods
Contextual Dissonance: Design Bias in Sensor-Based Experience Sampling MethodsContextual Dissonance: Design Bias in Sensor-Based Experience Sampling Methods
Contextual Dissonance: Design Bias in Sensor-Based Experience Sampling Methods
 
The Ubhave Project (Part 1/2)
The Ubhave Project (Part 1/2)The Ubhave Project (Part 1/2)
The Ubhave Project (Part 1/2)
 
Open Source Smartphone Libraries for Computational Social Science
Open Source Smartphone Libraries for Computational Social Science Open Source Smartphone Libraries for Computational Social Science
Open Source Smartphone Libraries for Computational Social Science
 
Building Systems to Capture, Measure, and Use Emotions and Personality
Building Systems to Capture, Measure, and Use Emotions and PersonalityBuilding Systems to Capture, Measure, and Use Emotions and Personality
Building Systems to Capture, Measure, and Use Emotions and Personality
 

Último

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Último (20)

Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 

Machine Learning, Faster

  • 2.
  • 3.
  • 4.
  • 7. The main problems that we aim to solve with machine learning include helping customers find the right answers to their queries (in the help screen of the app) and helping agents to diagnose and respond to customer queries swiftly (in the internal tooling). Our most impactful model is an encoder based on [1] that we train on chat data. [1] Attention is all you need https://arxiv.org/abs/1706.03762 Customer Operations
  • 9. How can we accelerate the development of machine learning? (1) Deploying, (2) Validing (3) Reusing, (4) Templating
  • 10. Deploying From validated idea → production in < 1 day.
  • 11. Quickly deploying models to production is one of the biggest roadblocks for impactful machine learning.
  • 13. What did we decide? We created a tool to easily create a new microservice. It included: ● A Python web server (Sanic) ● Deploying any kind of model (PyTorch, Keras, Scikit-Learn) ● Selectively include add-ons, e.g. our in-house model zoo library for NLP ● Command-line utilities for deploying across the staging and production environments.
  • 14. Goal: if you can write a predict() function, then you can deploy a machine learning model to production without breaking anything.
  • 16. Quickly diagnosing minor issues with machine learning models in production is nearly impossible.
  • 17. When I search for X, where is Y?
  • 18. ● Diagnosing this problem via unit or integration tests did not work; revisiting the model training was too slow. ● We added validation testing: making easy predictions in production & validate that they make the expected predictions. ● We get alerted when they fail. Most times, it’s the pipeline, not the model! Validation testing
  • 19. Keeping track of the online performance of machine learning models is going beyond what we traditionally do when deploying software.
  • 20. Reusing > 1 feature from 1 model
  • 21. Can we quickly reuse an existing model to tackle a new problem?
  • 23. Similar problem ● How can we redirect a subset of conversations, based on their topic, to a different queue? ● This is desperately needed to handle a high volume of messages. ● Most of the research around this focuses on transfer learning or fine-tuning.
  • 24. Reusable solution ● We wrote a service that interacts with our saved response recommender system -- but uses the recommendations to make a queue assignment decision. ● Deployed this within less than a day & used it to tackle a period of high inbound demand on customer service.
  • 25. Combining a rule engine over an existing model creates a new decision system. Rule engines & ML can coexist!
  • 26. Templating Staying 10 steps behind the latest research
  • 27. How can we quickly evaluate the new state of the art in machine learning?
  • 28. 2018 was transformative for NLP From shallow to deep language model pretraining ● Deep Contextualised Word Representations (ELMo, Feb 2018) ● Universal Language Model Fine-tuning for Text Classification (ULMFit, May 2018) ● Pre-training of Deep Bidirectional Transformers for Language Understanding (BERT, October 2018) ● … and more http://ruder.io/nlp-imagenet/
  • 29. ● Completely split out the process of generating clean, well-formatted, and labelled text-based datasets for supervised learning from any of the code that does the learning itself. ● Created a number of plug-and-play Colab notebooks for ULMFit, BERT (and PyText). ● Focus on time to results and common requirements instead of specific prediction problems. The most promising will be taken forward later. Approach research as an exercise in creating templates
  • 30. “To increase your success rate, double your failure rate” (& get to the same results in half the time)
  • 32. Speed & Machine Learning ● Deploying, validating, reusing, templating. ● Adopting the best practices from engineering; tweaking the ones that do not work for machine learning. ● Research time is well spent if we get some tools (bonus: we also get some results). ● Always a work in progress!