1. A method comprising, by one or more computing devices: receiving, by one or more computing devices, from a client system of a first user of an online social network, an unstructured text query to search for posts of the online social network, the text query comprising one or more n-grams; parsing, by the one or more computing devices, the text query to identify one or more n-grams; searching, by the one or more computing devices, a personalized index of keyword phrases associated with the first user to identify one or more keyword phrases matching one or more of the n-grams of the text query, the index of keyword phrases being based on content extracted from posts authored by one or more second users of the online social network that have been viewed by the first user; calculating, by the one or more computing devices, a keyword score for each of the identified keyword phrases; generating, by the one or more computing devices, one or more user interface elements corresponding to one or more suggested queries, respectively, each suggested query comprising one or more n-grams identified from the text query and one or more identified keyword phrases having a keyword score greater than a threshold keyword score; and providing, by the one or more computing devices, to the client system of the first user in response to receiving the text query, instructions for displaying a user interface comprising one or more of the user interface elements corresponding to one or more of the suggested queries, respectively, to search for posts of the online social network.
1. A method comprising, by one or more computing devices: receiving, by one or more computing devices, from a client system of a first user of an online social network, an unstructured text query to search for posts of the online social network, the text query comprising one or more n-grams; parsing, by the one or more computing devices, the text query to identify one or more n-grams; searching, by the one or more computing devices, a personalized index of keyword phrases associated with the first user to identify one or more keyword phrases matching one or more of the n-grams of the text query, the index of keyword phrases being based on content extracted from posts authored by one or more second users of the online social network that have been viewed by the first user; calculating, by the one or more computing devices, a keyword score for each of the identified keyword phrases; generating, by the one or more computing devices, one or more user interface elements corresponding to one or more suggested queries, respectively, each suggested query comprising one or more n-grams identified from the text query and one or more identified keyword phrases having a keyword score greater than a threshold keyword score; and providing, by the one or more computing devices, to the client system of the first user in response to receiving the text query, instructions for displaying a user interface comprising one or more of the user interface elements corresponding to one or more of the suggested queries, respectively, to search for posts of the online social network. 17. The method of claim 1 , wherein the suggested queries are sent for display on a webpage of the online social network accessed by a browser client on the client system of the first user.