A computer program product comprising a non-transitory computer readable medium having instructions encoded thereon that, when executed by a processor, cause the processor to:
- receive a request for a feed of content for presentation to a user of an online system from a client device associated with the user;
- retrieve information associated with a user of an online system, the information maintained by the online system;
- obtain one or more content items maintained by the online system associated with one or more other users connected to the user via the online system, the one or more other users having a bi-directional connection to the user via the online system;
- retrieve additional content items associated with users who are not connected to the user via the online system and having one or more characteristics from a set of characteristics by:
- identifying an interest of the user from the retrieved information associated with the user;
- and
- retrieving content items associated with the identified interest by:
- identifying content items provided to the online system by users who are not connected to the user;
- determining a score for each identified content item based on a length of time that an identified content item has been presented to users by the online system;
- and
- retrieving identified content items as the additional content items based on the score;
- determine measures of relevance for each of the retrieved additional content items and for one or more content items associated with the one or more other users connected to the user via the online system based on characteristics of the additional content items and the one or more content items associated with the one or more other users connected to the user via the online system as well as the retrieved information associated with the user;
- generate the feed of content for presentation to the user based on the determined measures of relevance, the feed of content including at least one of the additional content items;
- and
- communicate the feed of content including at least one or the retrieved content items to a client device for presentation to the user.