A computer program product comprising a computer readable storage medium having instructions encoded thereon that, when executed by a processor, cause the processor to:
- receive information describing one or more items associated with an entity having a presence on an online system, the information comprising one or more images of each of the one or more items;
- receive a content item to be presented to one or more viewing users of the online system, the content item comprising an image;
- access a trained machine-learning model, the trained machine-learning model trained based at least in part on the information describing the one or more items;
- apply the trained machine-learning model to a set of attributes of the content item to predict a probability that the content item comprises an image of an item associated with the entity;
- determine whether the predicted probability is at least a threshold probability;
- responsive to determining that the predicted probability is at least the threshold probability, add, to the content item, a link to a page associated with the item maintained in the online system, wherein the page comprises a set of the information describing the one or more items;
- determine an opportunity to present content to a viewing user of the online system;
- send the content item comprising the link for display to the viewing user;
- responsive to receiving an interaction with the link from the viewing user, determine a measure of similarity between the item and each additional item of the one or more items, the measure of similarity determined based at least in part on the information describing the one or more items;
- arrange the set of the information describing the one or more items within the page based at least in part on the measure of similarity between the item and each additional item of the one or more items;
- and
- send the page for display to the viewing user.