1. A method performed by data processing apparatus, the method comprising: identifying, in a set of images, two or more people that are each depicted in one or more images in the set of images; determining, based on content depicted in the images in the set, a relationship between the two or more people; determining, based at least on the determined relationship, one or more interests of a user viewing the set of images; selecting, for the user, a content item based on the one or more interests; and providing, to a user device of the user, data that cause presentation of the content item at the user device.