Case Study on Ride-Hailing App — Part 2
Visit Quantifiers for the first part of the article.
Problem Statement: How would you design dynamic pricing for a ride-sharing application. What factors will you consider while analyzing the problem?
Priyanka: There were some clarifying questions that I would like to ask to understand the problem in a better way.
Firstly from what I understand, dynamic pricing means that the price of a ride is not constant and depends on a number of variables. For example — When I request a cab ride from my office to home on a rainy day the fare of the ride is not the same as it is on a normal day.
Interviewer: Yes, that is correctly defined.
Priyanka: Should we design a dynamic pricing model assuming it does not exist or improve the existing dynamic pricing model?
Interviewer: You can assume the first option — design a dynamic pricing model assuming it does not exist.
Priyanka: Is there any specific geography that we are considering?
Interviewer: You can focus on India as of now.
Priyanka: Ok since the platform has both driver and rider sides do you want me to focus on any specific one?
Interviewer: You are free to choose.
Priyanka: I would focus on both as I think dynamic pricing affects both parties.
Interviewer: Sure, go ahead.
Priyanka: Firstly, I would like to define the goals of dynamic pricing. Dynamic pricing helps to:
- Reduce the demand supply mismatch
- Compensate drivers by providing them better revenue
- Provide service to people who intend to pay higher for it
Interviewer: That sounds correct.
Priyanka: Now I would like to think about the data variables that might drive the price of a ride:
Weather conditions — Due to harsh weather conditions like heavy rain, thunderstorms there are more road closures leading to traffic jams. The usual trip might take a longer duration. This affects the supply of drivers thus having an effect on fare.
Festivals/Big events — If there are major events like cricket matches or famous personality visits or even during festivals a large number of people request rides. Due to this, there is a sudden demand-supply mismatch.
Traffic/Peak time of the day — After work hours are usually peak hours since a lot of people are returning home from work which also affects the traffic conditions in that area. For example — In normal days before Covid, the road near tech parks was usually jammed around 5–6 pm when most of the people are leaving for their home from work.
Competitive Pricing — Competition plays a huge role in determining the prices especially in a fragmented market like India with two main competitors — Uber and Ola and a few emerging players like Rapido or Jugnoo.
Interviewer: Now that you have identified some of the factors how will you go about implementing the dynamic pricing?
Priyanka: Some of the methods I can think of are:
- We can use a machine learning model to analyze multiple variables, such as historical data, traffic conditions, holidays and weather, to ultimately determine the demand for the drivers. Leveraging this information, we can then generate the optimal price at different times of the day, week and month.
- We can use a deep learning model like Long short-term memory (LSTM) to predict unprecedented events or the future stances of an event as LSTM allows information to persist.[1]
- We need to set thresholds for the difference between supply and demand when surge needs to be enabled or disabled. For example — if demand > supply by 10 cars then we can apply surge pricing and vice versa. We need to experiment with different limits to come up with the optimal number.
Interviewer: How would the dynamic pricing feature get displayed in the app?
Priyanka: We can design the feature in the following ways:
- Notification alerts should be sent to both driver and riders once the surge is going to apply and also once the surge ends so that riders who were not willing to book a ride during surge can wait while those who are willing to pay can take the ride.
- To prevent drivers from taking undue advantage of surges we can set up rules that do not allow a driver to turn off his availability more than a given number of times.
Interviewer: How would you measure the success of your implementation?
Priyanka: Some of the success metrics we can take into consideration are:
- No. of rides requested after seeing the price surge notification.
- No of Daily/Weekly/Monthly Active users
- Average earnings per driver
Interviewer: Thank you. We are done with the discussion.
Reference:
If you like my content on Medium or Quantifiers and find it resourceful, you can show your support by hitting the clap button.
For PM Interviews, you can refer to amazing articles at Technomanagers