Content inversion for user searches and product recommendations systems and methods
There is provided systems and method for content inversion for use in user searches and product recommendations. The methods include receiving a first content, wherein the first content includes a first sentence having at least one first sentiment expression, creating a syntactic parse tree of the first sentence, identifying a first sentiment in the at least one first sentiment expression, wherein the first sentiment corresponds to a first polarity, determining a first needs expression corresponding to the first sentiment, wherein the first needs expression includes a first subject. The method may further include creating a sub-tree corresponding to the first needs expression, and grouping the content with other content having similar sub-trees.
1. A system, comprising:
one or more processors, one or more computer-readable memories, with program instructions stored on the one or more computer-readable memories, the one or more processors configured to execute the program instructions to cause the system to perform operations comprising:
detecting a search query corresponding to a user;
creating a user syntactic parse tree for the search query, wherein the user syntactic parse tree comprises units of at least one word corresponding to content of the search query;
determining a user sentiment and a search subject corresponding to the search query based on the user syntactic parse tree, wherein the user sentiment comprises a user needs expression for the search subject;
performing an online search utilizing the user sentiment and the search subject with the search query;
analyzing a plurality of search results corresponding to the online search;
determining a subject and a sentiment corresponding to each of the plurality of search results;
determining alignments between words in the search query and each of the plurality of search results;
based on the alignments:
applying weights to each of the words in the plurality of search results, and
calculating generalization scores associated with phrases for the plurality of search results based further on a weighted sum from the weights applied to each of the words;
determining whether the subject and the sentiment of each of the plurality of search results correspond to the search subject and the user sentiment, respectively;
determining a rank corresponding to each of the plurality of search results based on the generalization scores and determining whether the subject and the sentiment of each of the plurality of search results correspond to the search subject and the user sentiment, respectively;
generating a ranked listing of the plurality of search results based on the rank corresponding to each of the plurality of search results, wherein the ranked listing comprises a user interface output for a computing device of the user; and
causing to be displayed, on the computing device of the user, the ranked listing.
2. The system of claim 1 , the operations further comprising:
determining the user needs expression based on the user syntactic parse tree and the user sentiment based on a polarity of the user sentiment.
3. The system of claim 2 , wherein the user needs expression includes the search subject and a search feature corresponding to the search subject.
4. The system of claim 3 , the operations further comprising:
creating a first sub tree, wherein the first sub tree comprises the user sentiment, the search subject, and the search feature, and wherein the determining the rank corresponding to each of the plurality of search results includes:
creating a second sub tree corresponding a first search result of the plurality of search results; and
comparing the second sub tree to the first sub tree.
5. The system of claim 4 , the operations further comprising:
in response to determining that a first rank corresponding to the first search result is higher than a second rank corresponding to a second search result of the plurality of search results, causing the first search result to be ranked above the second search result.
6. The system of claim 1 , the operations further comprising:
causing an advertisement to be provided to the user based on a subject of content of the advertisement corresponding to the search subject.
7. The system of claim 2 , the operations further comprising:
causing a coupon or an offer to be provided to the user based the coupon or the offer corresponding to the user needs expression.
8. A method comprising:
detecting, by a computer system, a search query corresponding to a user;
creating, by the computer system, a user syntactic parse tree for the search query, wherein the user syntactic parse tree comprises units of at least one word corresponding to content of the search query;
determining, by the computer system, a user sentiment and a search subject corresponding to the search query based on the user syntactic parse tree, wherein the user sentiment comprises a user needs expression for the search subject;
performing, by the computer system, an online search utilizing the user sentiment and the search subject;
analyzing, by the computer system, a plurality of search results corresponding to the online search;
determining, by the computer system, a subject and a sentiment corresponding to each of the plurality of search results;
determining, by the computer system, alignments between words in the search query and each of the plurality of search results;
determining one or more generalization scores associated with phrases for the plurality of search results based on a weighted sum from weights of each of the words;
determining, by the computer system, whether the subject and the sentiment of the plurality of search results correspond to the search subject and the user sentiment, respectively;
determining, by the computer system, a rank corresponding to each of the plurality of search results based on the generalization scores and determining whether the subject and the sentiment of each of the plurality of search results correspond to the search subject and the user sentiment, respectively;
generating, by the computer system, a ranked listing of the plurality of search results based on the rank corresponding to each of the plurality of search results, wherein the ranked listing comprises a user interface output for a computing device of the user; and
causing to be displayed, by the computer system on the computing device of the user, the ranked listing.
9. The method of claim 8 , wherein the determining the alignments is further based on one or more subjects in the search query and each of the plurality of search results, and wherein the method further comprises:
determining, by the computer system, the user needs expression based on the user syntactic parse tree and the user sentiment based on a polarity of the user sentiment.
10. The method of claim 9 , wherein the user needs expression includes the search subject and a search feature corresponding to the search subject.
11. The method of claim 10 , further comprising:
creating, by the computer system, a first sub tree, wherein the first sub tree comprises the user sentiment, the search subject, and the search feature, and wherein the determining the rank corresponding to each of the plurality of search results includes:
creating, by the computer system, a second sub tree corresponding a first search result of the plurality of search results; and
comparing, by the computer system, the second sub tree to the first sub tree.
12. The method of claim 11 , further comprising:
in response to determining that a first rank corresponding to the first search result is higher than a second rank corresponding to a second search result of the plurality of search results, causing, by the computer system, the first search result to be ranked above the second search result.
13. The method of claim 8 , further comprising:
causing, by the computer system, an advertisement to be provided to the user based on a subject of content of the advertisement corresponding to the search subject.
14. The method of claim 9 , further comprising:
causing, by the computer system, a coupon or an offer to be provided to the user based the coupon or the offer corresponding to the user needs expression.
15. A non-transitory machine-readable medium having stored thereon machine-readable instructions executable to cause a machine to perform operations comprising:
detecting a search query corresponding to a user;
creating a user syntactic parse tree for the search query, wherein the user syntactic parse tree comprises units of at least one word corresponding to content of the search query;
determining a user sentiment and a search subject corresponding to the search query based on the user syntactic parse tree, wherein the user sentiment comprises a user needs expression for the search subject;
performing an online search utilizing the user sentiment and the search subject;
analyzing a plurality of search results corresponding to the online search;
determining a subject and a sentiment corresponding to each of the plurality of search results;
determining alignments between words in the search query and each of the plurality of search results;
based on the alignments:
applying weights to each of the words in the plurality of search results, and
calculating generalization scores associated with phrases for the plurality of search results based further on a weighted sum from the weights applied to each of the words;
determining whether the subject and the sentiment of each of the plurality of search results correspond to the search subject and the user sentiment, respectively;
determining a rank corresponding to each of the plurality of search results based on the generalization scores and determining whether the subject and the sentiment of each of the plurality of search results correspond to the search subject and the user sentiment, respectively;
generating a ranked listing of the plurality of search results based on the rank corresponding to each of the plurality of search results, wherein the ranked listing comprises a user interface output for a computing device of the user; and
causing to be displayed, on the computing device of the user, the ranked listing.
16. The non-transitory machine-readable medium of claim 15 , the operations further comprising:
determining the user needs expression based on the user syntactic parse tree and the user sentiment based on a polarity of the user sentiment.
17. The non-transitory machine-readable medium of claim 16 , wherein the user needs expression includes the search subject and a search feature corresponding to the search subject.
18. The non-transitory machine-readable medium of claim 17 , the operations further comprising:
creating a first sub tree, wherein the first sub tree comprises the user sentiment, the search subject, and the search feature, and wherein the determining the rank corresponding to each of the plurality of search results includes:
creating a second sub tree corresponding a first search result of the plurality of search results; and
comparing the second sub tree to the first sub tree.
19. The non-transitory machine-readable medium of claim 18 , the operations further comprising:
in response to determining that a first rank corresponding to the first search result is higher than a second rank corresponding to a second search result of the plurality of search results, causing the first search result to be ranked above the second search result.
20. The non-transitory machine-readable medium of claim 15 , the operations further comprising:
causing an advertisement or an offer to be provided to the user based on a subject of content of the advertisement corresponding to the search subject.