Algorithm 1.
Shifter Effect Learning
|
Input: review documents 𝒟, a vector of quantified effects ft−1, review feature matrix W, parameters matrices Θ, P, Q, common sentiment words Σc | ||
| for each review r in 𝒟 do | ||
| for each shifter w in Σs do | ||
| Identify sentiment contexts Cw of w in r | ||
| Identify the single modified words in Cw and the words must be in Σc | ||
| Construct shifter features in xr by Eq. (7) | ||
| Solve Eq. (9) for f* | ||
| Return: a vector of quantified effects f*, which serves as ft for next iteration | ||