News for hackers. Stuff that matters.
Re:Annoying A/B testing mistakes every engineer should know by londons_explore on Friday June 16, 2023 @06:57AM (#36354511)
I want an A/B test framework that automatically optimizes the size of the groups to maximize revenue.

At first, it would pick say a 50/50 split. Then as data rolls in that shows group A is more likely to convert, shift more users over to group A. Keep a few users on B to keep gathering data. Eventually, when enough data has come in, it might turn out that flow A doesn't work at all for users in France - so the ideal would be for most users in France to end up in group B, whereas the rest of the world is in group A.

I want the framework to do all this behind the scenes - and preferably with statistical rigorousness. And then to tell me which groups have diminished to near zero (allowing me to remove the associated code).

Re:Annoying A/B testing mistakes every engineer should know by jdwyah on Friday June 16, 2023 @07:21AM (#36354719)
Get yourself a multi arm bandit and some Thompson sampling https://engineering.ezcater.com/multi-armed-bandit-experimen...
Re:Annoying A/B testing mistakes every engineer should know by iLoveOncall on Friday June 16, 2023 @07:02AM (#36354554)
That sounds like you don't want A/B testing at all.
Re:Annoying A/B testing mistakes every engineer should know by londons_explore on Friday June 16, 2023 @07:04AM (#36354576)
Indeed - I really want A/B testing combined with conversion optimization.
Re:Annoying A/B testing mistakes every engineer should know by hotstickyballs on Friday June 16, 2023 @07:05AM (#36354578)
Exactly. That just sounds like a Bayesian update
Re:Annoying A/B testing mistakes every engineer should know by NavinF on Friday June 16, 2023 @07:08AM (#36354608)
Re:Annoying A/B testing mistakes every engineer should know by bobsmooth on Friday June 16, 2023 @07:16AM (#36354677)
Why can't users just tell me what works!
Re:Annoying A/B testing mistakes every engineer should know by quadrature on Friday June 16, 2023 @08:41AM (#36355607)
Curious about your use case.

Is the idea that you wa t to optimize the conversion and then you would remove the experiment code with the winning variant ?.

Or would you prefer to keep the code in and have it continuously optimize variants ?.

Re:Annoying A/B testing mistakes every engineer should know by joseda-hg on Friday June 16, 2023 @09:03AM (#36355864)
There might be a particular situation where B might be more effective than A, and therefore should be kept, if only for that specific situation There might be a cutoff point, where maintaining B would cost more than it's worth, but that's a parameter you will have to determine for each test
Re:Annoying A/B testing mistakes every engineer should know by londons_explore on Friday June 16, 2023 @11:01AM (#36357737)
I'd expect to be running tens of experiments at any one time. Some of those experiments might be variations in wording or colorschemes - others might be entirely different signup flows.

I'd let the experiment framework decide (ie. optimize) who gets shown what.

Over time, the maintenance burden of tens of experiments (and every possible user being in any combination of experiments) would exceed the benefits, so then I'd want to end some experiments, keeping just whatever variant performs best. And I'd be making new experiments with new ideas.

Re:Annoying A/B testing mistakes every engineer should know by withinboredom on Friday June 16, 2023 @09:18AM (#36356085)
Sadly, there is an issue with the Novelty Effect[1]. If you push traffic to the current winner, it probably won't validate that its the actual winner. So you may trade more conversions now, for a higher churn than you can tolerate later.

For example, you run two campaigns:

1. Get my widgets, one year only 19.99!

2. Get my widgets, first year only 19.99!

The first one may win, but they all cancel at the second year because they thought it was only for one year. They all leave reviews complaining that you scammed them.

So, I would venture that this idea is a bad one, but sounds good on paper.

[1]: https://medium.com/geekculture/the-novelty-effect-an-importa...

PS. A/B tests don't just provide you with evidence that one solution might be better than the other, they also provide some protection in that a number of participants will get the status-quo.

Re:Annoying A/B testing mistakes every engineer should know by travisjungroth on Friday June 16, 2023 @11:38AM (#36358448)
> So, I would venture that this idea is a bad one, but sounds good on paper.

It's a great idea, it's just vulnerable to non-stationary effects (novelty effect, seasonality, etc). But it's actually no worse than fixed time horizon testing for your example if you run the test less than a year. You A/B test that copy for a month, push everyone to A, and you're still not going to realize it's actually worse.

Re:Annoying A/B testing mistakes every engineer should know by withinboredom on Friday June 16, 2023 @11:44AM (#36358568)
Yeah. If churn is part of the experiment, then even after you stop the a/b test for treatment, you may have to wait at least a year before you have the final results.
Re:Annoying A/B testing mistakes every engineer should know by miraantabrez on Friday June 16, 2023 @09:26AM (#36356221)
This is a contextual multi-armed bandit. You pass in visitor attributes like location, referrer (did they come from google, a specific ad or directly), are they on mobile or desktop, what operating system, what time of day, day of week, etc, to automatically show the variation most likely to convert each unique user. You can implement this with an ML model, e.g. a gradient boosted decision tree, that is continuously trained on the incoming data. You can set a goal metric to optimize for, like revenue. Like any multi-armed bandit, you'd have an explore / exploit ratio so you can adjust based on new data, e.g. new visitor segments or visitors start preferring different variations. So you don't even need to get rid of variations as they're shown less if they perform worse but if they start performing better, they're shown more again. This is a bit like how ad platforms work. Instead of A/B testing what ad works best, they use ML to match the best ad, out of millions of possible options, to each unique user. This is the optimal approach to landing page optimization. We're building this as a platform and have had great results.

What's interesting about the platform we're building is you don't have to "remove the associated code" to remove variations, as all the variations are in the platform itself. E.g. let's say you're testing a headline. Rather than set up variations of the headline in your code, you make the whole headline configurable in the platform, a bit like how a CMS does. Once that's done, you can set up the headline variations in the platform for the ML to pick from, then add / remove them without touching the code.

Re:Annoying A/B testing mistakes every engineer should know by PheonixPharts on Friday June 16, 2023 @09:46AM (#36356511)
As others have mentioned, you're referring to Thompson sampling and plenty of testing providers offer this (and if you have any DS on staff, they'll be more than happy to implement it).

My experience is that there's a good reason why this hasn't taken off: the returns for this degree of optimization are far lower than you think.

I once worked with a very eager, but junior DS who thought that we should build out a massive internal framework for doing this. He didn't quite understand the math behind it, so I build him a demo to understand the basics. What we realized in running the demo under various conditions is that the total return on adding this complexity to optimization was negligible at the scale we were operating at and required much more complexity than our current set up.

This pattern repeats in a lot of DS related optimization in my experience. The difference between a close guess and perfectly optimal is often surprisingly little. Many DS teams perform optimizations on business processes that yield a lower improvement in revenue than the salary of the DS that built it.

Re:Annoying A/B testing mistakes every engineer should know by brookst on Friday June 16, 2023 @09:57AM (#36356671)
Small nit: it’s a bad idea if NPV of future returns is less than the cost. If someone making $100k/yr can produce one $50k/yr optimization that NPV’s out to $260k, it’s worth it. I suspect you meant that, just a battle I have at work a lot with people who only look at single-year returns.
Re:Annoying A/B testing mistakes every engineer should know by tomfutur on Friday June 16, 2023 @12:26PM (#36359329)
Besides complexity, a price you pay with multi-armed bandits is that you learn less about the non-optimal options (because as your confidence grows that an option is not the best, you run fewer samples through it). It turns out the people running these experiments are often not satisfied to learn "A is better than B." They want to know "A is 7% better than B," but a MAB system will only run enough B samples to make the first statement.