4 ms·
It's not as simple as that. There are multiple ways to figure out which ad to show to a user, but I think the most efficient way (development and compute) is to
by ahmedalsudani 8y ago
It's not as simple as that. There are multiple ways to figure out which ad to show to a user, but I think the most efficient way (development and compute) is to put a user in segments (e.g. lives in area X, searched for Y, age Z, ...) and then do the bidding magic. There are tight tolerances for bidding--you want it to happen within a fraction of a second so the ad quickly loads for the user. Feeding purchase data is likely something that requires a bit of work, and I imagine the ad team at Amazon doesn't see enough value to prioritize it (especially since they make money either way--the advertisers pay for the ad with a higher CPC).
One thing to keep in mind is that the purchase data is per-user, so it's different from the segment approach I was mentioning above. It would require a whole new schema* that is queried whenever bids are processed for an ad event.
* Sorry for using the word schema here. It was used a lot on a team I was on in a similar context, and it bothered me at first but I got used to it. What I mean by schema is a "blob" with purchase data that is periodically processed by the bidding subsystem to add bid exclusions per user.