Opinion mining of text documents written in Macedonian language
Paper · 2014 · Andrej Gajduk and Ljupčo Kocarev
Summary
A forum discussion can contain praise, criticism, and matter-of-fact replies about the same subject. To count the opinions in that discussion, a system first has to decide which posts express one. The authors study this problem in Macedonian using posts from the kajgana forum. They divide sentiment analysis into two decisions. The first asks whether a post is subjective or objective. The second assigns a positive or negative label to a post judged subjective. The objective category supplies the third possible outcome, described as neutral in the abstract.
The authors evaluate their approach on 800 manually tagged posts using 10-fold cross-validation. They represent each post through the words or adjacent word pairs it contains and compare several ways to give those features numerical values. The strongest reported combination uses individual words weighted by their frequency in the post and their rarity across posts, a method known as TF-IDF. With a support vector machine, it achieves accuracy of 0.96 on subjectivity, 0.96 on polarity, and 0.92 for the combined task. Naive Bayes, the other classifier tested, scores below the support vector machine for every word-weighting scheme in the comparison without preprocessing.
Several changes intended to improve the input bring little benefit. Accuracy falls in the reported comparison involving removal of common words and reduction of related forms to stems. Adjacent word pairs help slightly when added to individual words in a representation based on feature presence. Rules that give special treatment to negation and emphasis generally make little difference, although the negation rule gives a small gain with unigram presence. The results favor retaining the original words and weighting them by how informative their distribution is across posts.
The paper also uses the best classifier to describe the forum. Its measure of mood is the share of positive posts among posts classified as positive or negative. Food and fashion discussions appear more positive, while global affairs and the economy appear more negative. April and May have the highest reported monthly mood. These comparisons describe automatically classified forum posts. Their value depends on how consistently the classifier works across the groups being compared.
Deep dive: Opinion mining of text documents written in Macedonian language
How a study of Macedonian forum posts used word frequencies to detect opinions, classify sentiment, and compare the mood of discussions. · about 33 minutes to read
The problem and its context
Finding opinions in a stream of posts
The authors begin with a practical change in how opinions become available. People publish their own views on forums, blogs, social networks, and other sites. Someone interested in how a product or a public issue is received can consult those discussions, but reading them in bulk takes time. The paper asks whether automatic classification can do part of that work for discussion written in Macedonian. Its motivation is the possibility of extracting a view of what people are saying without commissioning a survey for every question.
The earlier research cited in the paper illustrates several reasons that such opinions might matter. Some studies examined how opinions encountered online influence what readers think. Others considered consumer reviews and product decisions, or looked for links between online comments and economic outcomes. The authors also describe work on political preferences and stock market prediction. These studies motivate extracting opinion at scale. The Macedonian experiment addresses an earlier step in the process: turning individual posts into labels that can subsequently be counted.
The unit of analysis is the entire post. The authors use a broad understanding of a document that can also encompass a review, a comment, or a webpage, but the document in their experiment is an entry in a forum discussion. Sentiment is an attitude expressed towards a subject, which could be an entity, an event, or an abstract issue. The text people use to express an attitude can convey many emotions and degrees of feeling. The paper follows earlier work in reducing that variety to polarity, the direction of the evaluation.
That choice defines a text classification problem with a compact set of outputs. A post can praise something, express disapproval, or provide information without an evaluative stance. A reply that gives the opening hours of a venue and a reply that praises its service might occur in the same discussion. A forum heading would assign both to the same topic, but only the second reply supplies the kind of attitude that the polarity decision is meant to capture. The method therefore needs a way to recognize opinion before it can say which way the opinion points.
The distinction matters again when the authors aggregate posts. A busy thread could contain many factual replies and a smaller set of strongly favorable or unfavorable comments. Counting all replies as evidence of public feeling would conflate activity with evaluation. By giving objective posts a distinct outcome, the authors can later compute a measure that describes the balance of favorable and unfavorable opinion among posts judged to have one.
Separating the existence of an opinion from its direction
The paper draws its description of polarity from Pang and Lee’s survey. It takes the separation of subjectivity and polarity from prior work by Godbole and colleagues. The two decisions concern different properties of the text. Subjectivity asks whether the writer expresses a view. Polarity assumes that there is a view and asks whether it is favorable or unfavorable. An objective post ends the classification process at the first decision.
This arrangement also defines what the neutral label means in this study. The abstract calls the third output neutral, while the problem statement and dataset describe those posts as objective. Objectivity is a claim about the absence of an expressed evaluative stance. Neutrality can have other meanings in everyday use, including indifference or a balance between positive and negative feelings. The paper’s stated decision procedure gives the third label its narrower meaning, which is the appropriate reading when interpreting the results.
A further assumption makes document-level polarity possible. The authors treat the overall opinion in a subjective post as being about a single issue or item. That allows them to attach one direction to the post as a whole. A sentence of praise and a sentence of criticism can coexist in a forum reply. If they concern different aspects or different objects, deciding which view the overall label represents requires an additional judgment. The task as defined by the paper asks for the overall label and leaves such internal distinctions outside its output.
This simplification is consequential for forum text. The authors describe forum posts as informal and generally less organized than product reviews. A review frequently has an obvious object of evaluation, given by the product under which it appears. A forum post may be connected to a topic by its place in a discussion while sharing little of the heading’s wording. For this experiment the topic structure helps organize the eventual counts. The classification procedure itself represents the words in the post.
How earlier work informed the comparisons
The paper describes bag-of-features representations as common in prior machine learning work on text. A bag of features gives a classifier measurements of selected textual patterns. A feature can be a word or a longer sequence of adjacent words. Once those patterns are chosen, the representation of any post uses the same list of features, with a separate value for each. This gives the authors a way to try several numerical descriptions of the same piece of text while preserving the same classification task.
The paper identifies individual words as the conventional starting point and notes an argument in earlier work for using adjacent pairs. The form of an expression matters when a nearby word cancels or strengthens an evaluation. If a favorable word is preceded by a negator, the pair carries information that the favorable word alone can miss. Pairs preserve part of that local structure, while using individual words pools evidence across the different phrases in which each word occurs. The experiment is set up to compare what those alternatives contribute.
The authors also identify support vector machines and Naive Bayes as established classifiers for text. Their design combines each with several versions of the feature representation. In the authors’ account, previous studies had explored removing common words, reducing words to stems, and treating selected combinations such as negation specially. Those practices supply concrete choices to investigate in Macedonian. The stop-word list is prepared for the experiment, and the stemming procedure is chosen because it can operate from the vocabulary itself.
Put together, the earlier work gives the paper a series of empirical questions. The subjectivity decision and the polarity decision can be treated separately. The same texts can be described by presence, counts, or weighted rates. Local word order can be retained everywhere through adjacent pairs, or used selectively through rules. How these choices behave on the forum data is the question the Macedonian study can answer directly.
The method, step by step
Turning a forum post into a set of measurements
The procedure starts with labeled forum posts and a dictionary of textual features. Here a dictionary is an ordered inventory of things that can be measured in a post. If the features are words, it contains the words that the representation recognizes. If the features include pairs, it can have an entry for a familiar word as well as a distinct entry for a phrase in which that word occurs. Each dictionary entry gets a position in a vector, an ordered sequence of numerical values. All posts use the same positions, which makes values comparable between posts.
The unit the paper calls an n-gram is a sequence of adjacent items. In this study the items are words. A unigram is one word, and a bigram is an adjacent pair in its original order. A unigram representation distinguishes which words appear but does not give the classifier their positions. Bigram features retain order inside each pair. A bag of bigrams still discards the positions of those pairs in the larger post, so its greater sensitivity to context is local.
The choice of what to measure is separate from the choice of which sequences to include. The same word can contribute a value indicating that it occurs, a value indicating how frequently it occurs, or a value that also reflects its distribution across the forum. Conversely, the same presence calculation can be applied to either a word or a pair. This separation lets the authors test whether a gain comes from changing the unit of text, changing the value assigned to it, or using one change together with another.
From Macedonian forum posts to sentiment labels
The steps in order.
Building the dictionary and the labeled data
The source is kajgana, a Macedonian-language forum organized into topics and subtopics. The authors report 47 disjoint topics and over 50,000 subtopics. A post has 60 words on average. Those figures describe the wider body of forum text. Only a labeled subset is used to test whether the classification procedure agrees with human judgments. This distinction matters because the vocabulary is drawn from a much wider collection than the set of posts for which the paper reports evaluation labels.
The authors count 4 million unique words in the forum material. They disregard words with fewer than 5 occurrences, leaving 800,000 unique words. This is a vocabulary filter: it removes feature types below the occurrence threshold. The authors give two reasons for using it. It reduces the number of possible dictionary entries, and it is intended to get rid of typing errors that appear rarely. The filter uses occurrence as its criterion, so an infrequent legitimate form is subject to the same treatment as an infrequent error.
For the labeled subset, the authors manually assign 260 posts to the positive class, 260 to the negative class, and 280 to the objective class. A positive or negative label supplies the same first-stage target, subjective, while the original distinction is needed at the polarity stage. Objective posts provide examples for the other side of the subjectivity decision. They have no positive or negative label under this scheme.
The evaluation uses 10-fold cross-validation. In this procedure, a portion of the labeled posts is held out for testing while a classifier is trained on the rest. The held-out portion changes across folds, so different posts serve as test examples across the evaluation. The authors use this procedure to guard against overfitting. The paper gives the cross-validation design for the labeled set and defines the vocabulary and document statistics in terms of the post collection. Precisely which posts contribute to those statistics within each fold is left unspecified.
Giving each feature a value
The paper starts from a fixed feature dictionary and uses it to represent every post. Its dictionary notation is:
D = {f₁, …, fₘ}
Here D is the set of features, and f denotes a feature. The subscript identifies its position, beginning with f₁ and ending with fₘ. The symbol m is the number of features. The braces enclose the members of the set, the ellipsis stands for the intervening features, and the equals sign identifies D with the displayed collection. The position of a feature in this inventory makes it possible to refer to the same entry across documents.
The basic quantity in the representation is tᵢᵖ, the number of occurrences of the feature at position i in post p. The superscript identifies a post and is an index, instead of a power. The subscript marks the dictionary entry. The paper uses the same occurrence quantity as the starting point for all its feature metrics. How often a word occurs in a post can therefore lead to several different vector values, depending on the way the experiment asks the classifier to use that information.
The presence metric records whether a feature occurs at all.
presenceᵢᵖ = { 1 if tᵢᵖ ≠ 0, 0 otherwise }
The left-hand side is the value of feature i in post p under the presence representation. The symbol tᵢᵖ is its occurrence count, and ≠ means “is unequal to.” The braces give the alternative values. The value is 1 if the feature occurs and 0 if it is absent. In this representation, repeated use of an evaluative word gives the same entry as a single use of it. The classifier can draw on what occurs elsewhere in the post, but that particular entry carries no information about repetition.
The count metric preserves that repetition in the vector.
countᵢᵖ = tᵢᵖ
Here countᵢᵖ is the count feature for entry i in post p, and tᵢᵖ again denotes its number of occurrences there. The equals sign indicates that the vector receives the raw occurrence count. A longer post has more opportunities to repeat an expression. A high count can reflect emphasis, the amount of text written, or both. That is a property of the measurement before classification, regardless of how strongly the classifier ends up using the feature.
Frequency expresses the count in relation to the total counts for the post.
freqᵢᵖ = tᵢᵖ ÷ (∑ⱼ tⱼᵖ)
The expression freqᵢᵖ is the frequency of feature i in post p. The numerator tᵢᵖ is the occurrence count for that feature. The symbol ÷ denotes division. In the denominator, ∑ⱼ means to sum over feature indices j, and tⱼᵖ is the count of feature j in the same post. The parentheses group the summed counts. The resulting value expresses how much of the counted feature activity belongs to the feature of interest. The precise denominator is the sum over the feature representation, which matters when the vocabulary has been filtered or the inventory contains both words and pairs.
The fourth metric combines that within-post frequency with the feature’s reach across posts.
ifreqᵢᵖ = freqᵢᵖ × log(|P| ÷ |Pᵢ|)
The expression ifreqᵢᵖ denotes the paper’s frequency–inverse document frequency value for feature i in post p. The first factor, freqᵢᵖ, is the normalized frequency just defined. The multiplication sign combines it with log, the logarithm of the ratio inside the parentheses. P denotes the full set of posts in the definition, while Pᵢ is the set of posts in which feature i occurs. The vertical bars count the members of a set. Thus |P| counts all the posts included in the document statistic, and |Pᵢ| counts the posts containing the feature. The formula uses the number of containing posts regardless of how many times the feature occurs in any of them.
This last distinction is important. A word can be repeated within a particular discussion yet rarely turn up elsewhere. Its repetitions affect the frequency term in a post. Its scarcity across documents affects the other term. A word widely distributed across the forum receives a smaller inverse document frequency factor. That factor is driven by distribution across posts and supplies no direct judgment about whether a word is favorable, unfavorable, or objective. The classifier relates the resulting feature values to labels using the training examples.
The paper calls this representation inverse frequency or ifrequency in its results. The formula clarifies what is being inverted. It is a document-level prevalence term, used together with a normalized within-document count. The separate measures make it possible to ask whether retaining only the evidence of presence is sufficient, whether repetition adds information, and whether prevalence across the collection helps determine how much a feature should contribute.
Trying removal and reduction of words
The authors test two preprocessing techniques that change the material from which features are drawn. One uses a list of stop words. These are words selected for removal on the assumption that they contribute little information to the task. The authors prepare a Macedonian list manually because a suitable list was difficult to obtain. It contains 170 entries. This filter operates on the identity of the word, unlike the vocabulary cutoff, which operates on how frequently a word was seen.
A stop-word list makes an all-or-nothing choice about the terms it contains. If an entry is removed, a classifier loses direct access to its occurrence as a word feature. This has a different effect from weighting the feature by document frequency. Weighting can reduce the influence of a very common word while preserving some variation among posts. Deletion erases that entry altogether. For the paper’s subjectivity decision, frequent wording can form part of the expression of a view even if it tells a reader little about the thread’s subject. Whether that information is valuable on this dataset is an experimental question.
The second change is stemming, which maps related word forms to a common stem. If several different spellings are grouped, occurrences that would otherwise occupy different dictionary positions can support the same feature. The intended benefit is to collect evidence that is distributed across related forms. A successful grouping can help a classifier when the surface forms vary more than their usefulness for identifying the label.
The authors describe several routes to stemming, including the use of affix rules, successor variety, n-grams, and lookup tables. They choose peak-and-plateau stemming, a procedure based on tries, because they lack a suitable Macedonian rule set for an affix-removal method. A trie groups words along paths of shared initial letters. Words that start alike share part of the path, and the path can branch where possible continuations diverge. The method uses this structure in the vocabulary to look for stem boundaries. The article points to earlier work for the procedure’s details and identifies the availability of the word set itself as the reason for using it here.
Grouping also changes what can be learned from an individual form. If forms grouped together tend to appear in different kinds of posts, a stem puts their evidence into the same feature. If the grouping fails to bring together relevant variants, the hoped-for pooling does not occur. The paper evaluates stemming as part of a preprocessing comparison and later considers the suitability of the chosen algorithm as a possible explanation for the observed accuracy.
Retaining local context with pairs and rules
An ordinary bigram is an additional feature for a pair of consecutive words. It can distinguish a word used on its own from that word in an expression whose direction is modified by its neighbor. The authors compare using such pairs alone and including them alongside unigrams. With both available, a classifier can draw on a broad signal from the single word and a narrower signal from the specific pair. With pairs alone, that broad signal has to be reconstructed from whichever combinations happen to occur in the training examples.
The authors also try what they call rule bigrams. This approach applies a transformation to particular pairs instead of treating every observed pair as an entry of the same kind. The authors give separate roles to words indicating negation and emphasis. A negator can attach a tag to the next word, creating a distinct item for its negated use. An intensifier can attach an emphasis tag. Different intensifiers can lead to the same tagged form, allowing the representation to join evidence from different phrases that strengthen the same underlying expression.
The paper illustrates the idea with phrases that have the structure of a negator followed by a favorable word, or an intensifier followed by an unfavorable word. In the presence representation, a tagged item can mark the relevant local context without requiring the classifier to treat every intensifier and word pairing as unrelated to every other one. The loss of distinctions among intensifiers is part of that design. A shared tag means that the feature carries the presence of emphasis, while the precise word that conveyed the emphasis need not occupy a separate feature for that use.
For metrics based on occurrence counts, the authors propose changing an occurrence’s contribution. Their notation for emphasis is:
t̂ᵢᵖ = 2 × tᵢᵖ
The hatted t, written t̂ᵢᵖ, denotes the adjusted count contribution for feature i in post p. The unhatted tᵢᵖ is the original count quantity. The equals sign relates the adjusted and original contributions, and × denotes multiplication. The multiplier 2 expresses the authors’ instruction to count an emphasized occurrence as 2 occurrences of the corresponding unigram. The rule is triggered by the preceding word. Ordinary occurrences elsewhere in the post are therefore conceptually distinct from the occurrences eligible for the adjustment.
The corresponding equation for negation is:
t̂ᵢᵖ = −tᵢᵖ
The indices and the hat have the same meanings as in the emphasis equation. The minus sign reverses the sign of the contribution. The authors describe a qualifying occurrence as contributing −1 in place of its ordinary positive count. The sign applies to the feature contribution. The procedure still uses the classifier to infer a post label from its full vector, so that a negation adjustment is an input to the polarity decision.
The rules give local linguistic information a fixed numerical treatment. In the tagged version, they make a distinct feature available. In the count-based version, they amplify or reverse a contribution within a feature. The description operates at the level of eligible occurrences. Details such as the treatment of a zero denominator if signed counts cancel in a normalized representation are left open. Similarly, the immediate-neighbor rule supplies a precise local trigger but leaves the scope of longer constructions outside its definition.
Learning the two decisions
After assigning feature values, the authors compare support vector machines, abbreviated SVM, with Naive Bayes, abbreviated NB. The input to either classifier is the vector for a post. A support vector machine learns a boundary between classes, using labeled examples to establish a separation in feature space. Naive Bayes compares how plausible the classes are under their observed feature evidence, using a simplifying assumption about how features contribute within a class. Both procedures can use the fact that different words or patterns occur with different labels. The paper’s comparisons concern their performance with the feature schemes it describes.
The first classifier decision separates subjective posts from objective ones. Positive and negative examples both belong to the subjective side of that decision. If the post goes to the objective side, its final output is objective. If it goes to the subjective side, the polarity decision chooses between the positive and negative labels. The ordering gives the subjectivity stage a gatekeeping role. A post sent down the wrong branch will either miss the polarity decision in spite of expressing a view or be assigned a polarity in spite of having an objective reference label.
This setup calls for more than one view of accuracy. Each binary task can be assessed for how often it gets its particular distinction right. The combined task asks whether the complete procedure delivers the final class assigned by the annotator. The paper reports the binary results as well as a combined result. That makes it possible to see that both parts of the procedure perform well in the reported evaluation while also checking the outcome when both decisions matter to a post’s final label.
Experiments and results
What was evaluated
The 800 manually tagged posts are the evaluation set. Its 260 positive posts and 260 negative posts provide the reference distinction for polarity. Both groups count as subjective at the first stage, where they are distinguished from the 280 objective posts. The labeled distribution tells a reader what kinds of decisions contribute to accuracy on this set. It does not establish the proportions of those classes in the forum at large.
The authors use 10-fold cross-validation throughout the evaluations. The reported metric is accuracy, which counts agreement between the predicted label and the assigned label over the evaluated cases. For subjectivity, agreement means getting the subjective–objective distinction right. For polarity, it means matching the positive or negative label in the polarity task. For full classification, it means reaching the correct final outcome. These are related measurements with different targets. In particular, the paper’s separate polarity score should be read as a result for the polarity decision; the combined score is the reported measure for the complete procedure.
The starting comparison uses unigram features without the optional preprocessing. The authors vary the numerical representation while comparing SVM and NB. These comparisons supply the reference settings for the later experiments with stop words and stemming, ordinary bigrams, and rule bigrams. The strongest weighting in that initial comparison is inverse frequency, followed by presence. For each of the unigram representations in the comparison, SVM outperforms NB.
The best configuration named in the conclusion is SVM with unigram frequency–inverse document frequency features. The conclusion reports 0.96 accuracy for subjectivity, 0.96 for polarity, and 0.92 for total classification. The abstract expresses the overall result as 92% accuracy. The paper gives that result explicitly, so it can be reported directly without reconstructing it from the stage scores. Those scores describe the two binary decisions and would by themselves leave open how errors overlap when decisions are made in sequence.
Accuracy before and after preprocessing
The paper reports a substantial reduction in accuracy for the preprocessing comparison. The SVM score changes from 0.94 to 0.74, and the NB score changes from 0.78 to 0.62. The prose presents these values together in its account of stemming and stop-word removal. It leaves the stage and feature weighting of the quoted comparison unspecified there, so these figures are best read as the accuracy values reported for that comparison. The conclusion separately identifies the settings and tasks for the best scores.
Preprocessing settings on the labeled kajgana posts by accuracy
Accuracy is lower with preprocessing for both tested classifiers.
The numbers
| System or setting | accuracy |
|---|---|
| SVM without preprocessing (this paper) | 0.94 |
| SVM with preprocessing | 0.74 |
| Naive Bayes without preprocessing | 0.78 |
| Naive Bayes with preprocessing | 0.62 |
The direction of the result is shared by both classifiers. The observations therefore support a conclusion about the version of preprocessing tried on this data. Word removal and stem reduction do not provide the improvement the authors were looking for. The comparison makes the loss visible against the corresponding settings without preprocessing. It also preserves the difference between classifier families, with SVM ahead in both conditions shown.
The authors suggest that the stemming procedure may be a poor fit for Macedonian. That explanation is more specific than the accuracy comparison itself. The outcome shows that predictions agree less frequently with the labels under the reported preprocessing condition. To trace the reduction to the stemmer, a reader would need evidence about its particular transformations or a separate score isolating them from the removal of stop words. The figures in the discussion describe the behavior of the reported comparison and leave the respective contributions of those operations open.
What ordinary and rule-based pairs add
The next comparison concerns ordinary bigrams. The authors evaluate presence and inverse frequency using bigrams on their own and together with unigrams. They describe bigrams alone as weak features. In the presence representation, adding bigrams to unigrams increases the reported SVM accuracy from 0.76 to 0.78 and the NB accuracy from 0.63 to 0.67. As in the preprocessing discussion, the prose supplies the accuracy and identifies the representation and classifier for these comparisons. The figures belong to those settings, while 0.92 is the separately reported overall score of the best unigram system.
Presence of words and word pairs on the labeled kajgana posts by accuracy
Adding adjacent word pairs modestly improves the word-presence representation for both classifiers.
The numbers
| System or setting | accuracy |
|---|---|
| SVM with unigram presence | 0.76 |
| SVM with unigram and bigram presence (this paper) | 0.78 |
| Naive Bayes with unigram presence | 0.63 |
| Naive Bayes with unigram and bigram presence | 0.67 |
This result puts a condition on the benefit of local word order. A pair can add information to a representation that already recognizes its individual words, particularly when feature values otherwise say only whether something appears. The reported increase is confined to the presence setting described in the experiment. The strongest overall configuration remains the one using inverse-frequency-weighted individual words. The conclusion’s broad assessment that bigrams do little to help the task is consistent with a small gain in a particular feature setting.
For rule bigrams, the authors compare negation rules, emphasis rules, and a setting with both. They describe overall accuracy as generally unchanged. The exception is a small increase when the negation rule is paired with unigram presence. The conclusion describes the small improvement from rule bigrams as a polarity result. The paper gives the direction of this effect in its discussion. The prose supplies no numeric value for that increase, so its size is best conveyed in the authors’ qualitative terms.
Using the classifier to describe the forum
The authors then apply SVM with unigram inverse frequency to examine variation in the forum. The classifications serve a different purpose at this stage. In cross-validation, predictions can be checked against manual labels. In the forum analysis, the predictions are inputs to counts of favorable and unfavorable posts. Topics and months provide ways to group the posts before looking at those counts.
The paper defines a topic’s mood as follows.
mₜ = pₜ ÷ (pₜ + nₜ)
Here t identifies a topic, and mₜ is the mood value assigned to it. The quantity pₜ counts posts classified as positive for that topic. The quantity nₜ counts posts classified as negative. The plus sign combines the two counts in the parentheses, and ÷ divides the positive count by that combined count. Objective posts are outside the denominator. The result measures the share of positive posts among those given a polarity. The same calculation is applied with a month as the grouping rather than a topic.
The topic comparison places food, represented by the Gourmet’s section, and fashion on the favorable side of the forum’s discussions. Global affairs and the economy have strongly unfavorable mood in the authors’ description. These observations are about the balance of labels assigned to posts within each topic. A topic can have relatively positive mood even if most replies in it are objective, because the mood calculation excludes those replies. The scale captures direction among classified opinions and leaves the amount of opinionated discussion as a separate question.
In the monthly comparison, the authors identify April and May as the months with the highest mood. They suggest good spring weather as a possible explanation. The analysis described in the paper groups and counts predicted labels by month, so the weather explanation is a conjecture about the pattern. The experiment it arises from is classification, and the subsequent aggregation supplies an illustration of what those classifications can be used to describe.
What the ablations show
The weighting choice has the clearest support
The paper studies several variants of the same classification task. Its comparisons are useful because they change particular aspects of the representation while retaining the source and labels. The initial unigram experiment asks how the classifier’s input should encode the words already selected. The experiments with pairs ask whether there is additional evidence in adjacency. The rules ask whether selected kinds of adjacency can be treated together. The preprocessing experiment asks whether removing words or merging related forms improves the evidence available to the classifier.
In the initial comparison, inverse frequency is the strongest representation, followed by presence. This establishes a ranking for the reported unigram experiment. It shows that counting a feature in relation to the post and weighting it by prevalence across the forum can make a better input than the other encodings tested there. Presence also performs relatively well in spite of discarding repetition. An occurrence can be informative simply because it marks an expression that the authors’ classifier has seen associated with the label.
Several aspects of inverse frequency change together relative to presence. The feature can vary with repeated use within a post, its value is normalized against the post’s counted features, and it receives a prevalence factor from the collection. Comparing the separate metrics helps distinguish these alternatives at the level of configurations. The overall ranking alone does not reveal which specific words carried extra weight or whether the gains were concentrated among posts of a particular length, topic, or class. The result identifies the better-performing encoding for these experiments.
SVM’s advantage over NB across the initial representations gives the weighting result further context. Changing between those classifiers changes performance even with the same information presented as input. The comparison consequently supports both choices in the best setting: the feature scheme and the classifier. Its scope is the classifiers and settings the authors evaluated. Fine-grained explanations about which parts of the decision boundary or which feature relationships mattered would require evidence from the fitted classifiers or their errors.
Removing and grouping words can discard evidence
Stop-word removal and stemming both reduce distinctions in the inputs. Removal discards selected words. Stemming groups some differences of form under a shared entry. Each can make a representation easier to learn from if the eliminated differences are incidental to the classification. The measured reduction in accuracy shows that, together in the reported comparison, these operations do not have that effect on kajgana. Both classifiers are less accurate after the preprocessing described by the authors.
The stemmer explanation offered in the paper is plausible in the limited sense that a poor grouping can combine forms that convey different evidence. The comparison also leaves room for effects from filtering, including loss of a word that frequently appears in opinion-bearing constructions. The same accuracy pattern could reflect different mixtures of such effects. The paper gives no breakdown of prediction changes by removed word or grouped form. The controlled conclusion is that the tested preprocessing is weaker than the corresponding untreated input.
This is also why the vocabulary cutoff and the optional stop-word list should be understood separately. The cutoff is part of the described handling of the forum vocabulary and operates on rare features. The list removes selected items on linguistic grounds. The reported preprocessing comparison addresses the added treatments. It does not measure the accuracy effect of varying the corpus frequency threshold, even though that threshold also affects which information can reach the classifier.
General adjacency and targeted rules have different effects
Using bigrams alone is the clearest test of replacing broad word evidence with local phrases. The authors find that this representation is weak by itself. The combination gives a pair a more modest role. When it has been observed in training, the pair can provide extra evidence about the particular context. When it is absent or uninformative, word features remain available. The presence setting is where the paper reports a gain from adding that extra evidence.
This pattern is consistent with a common tradeoff in the representations themselves. A word can recur in many contexts but carry overlapping information in them. A particular bigram appears only when the exact pair occurs in order. The resulting feature can be precise and can also reach fewer posts. The paper reports the direction of the comparison and the small improvement for combined presence. It offers no count of how many pairs had enough examples to be useful, so the coverage of those pairs remains a possible explanation for their limited contribution.
The negation and emphasis comparison asks a narrower question. A rule can group several contexts into a single kind of transformation. That could make evidence available even when individual phrase forms are uncommon. The small benefit for negation with unigram presence suggests that this grouping can sometimes supply information beyond the occurrence of the unmodified word. The reported comparisons with emphasis and with combined rules give little indication of a wider gain.
The result is about this particular encoding of context. The rules operate on adjacent words and use fixed tags or fixed multipliers. Testing them establishes how that treatment works with the study’s feature schemes and labels. The experiments give no direct measurement of how often the rules identify the intended relation in actual posts. A linguistically appropriate rule may affect too few cases to move overall accuracy much, and a frequently applied one can combine helpful and unhelpful changes. The paper’s results leave those explanations open.
The topic and month comparisons answer a separate question
The analyses by topic and month demonstrate what counts can be obtained from the predictions. They hold the selected classifier and representation fixed while changing the grouping of the posts. They therefore show differences in the output distribution under that choice of system. They offer no independent accuracy check for food, fashion, global affairs, or any month.
That distinction matters when interpreting the experimental story as a whole. The representation comparisons say how frequently different settings agree with the manual labels in the evaluation. The aggregation says which groups produce more favorable or unfavorable labels when processed with the selected setting. The latter illustrates an application of the former. The finding that one representation yields the strongest overall accuracy does not by itself show that all topic or month comparisons have the same reliability.
Limitations
Assumptions and qualifications in the paper
The authors make a scope assumption about the language being classified. They treat the overall attitude in a post as directed at a single issue or item. That is compatible with assigning one document-level polarity, and it puts target-specific and aspect-specific sentiment outside the task. A post can praise one feature of a product while criticizing another, or respond to separate claims in a forum discussion. The overall label gives a compressed description of such a post, with no place to preserve both evaluations.
The authors also distinguish objective text from text that expresses an opinion. Their data and problem definition use that distinction, while the abstract calls the objective output neutral. The method gives a reader a concrete interpretation of the category: it is the output of the subjectivity decision when the classifier judges that there is no expressed opinion. The paper leaves open how annotators handled posts with mixed views, uncertainty, or an explicitly indifferent attitude. Those cases matter to interpreting the relation between ordinary meanings of neutrality and the label used in the experiments.
The paper records practical constraints in adapting preprocessing to Macedonian. A suitable list of stop words was difficult to obtain, so the authors made one. They chose a vocabulary-based stemmer because they lacked appropriate language-specific affix rules. The reported reduction for the preprocessing condition is evidence about those choices. Their explanation that the stemmer may be poorly suited to the language is offered as a possibility. An evaluation of a different stemmer or word list lies outside the study.
The weather explanation for the monthly pattern is likewise tentative in the paper. The method assigns a label to each post and uses the month to group the results. It includes no measurement of weather or procedure for isolating its effects. The monthly analysis supports a description of when the classifier assigns the most favorable balance. The suggested cause goes beyond what that grouping can establish.
What the evaluation leaves open
The authors interpret 92% accuracy as comparable to human evaluation. The experiment establishes agreement with manual labels under cross-validation. A direct comparison with human performance would require an independent set of human judgments evaluated against a specified reference, or an account of how consistently different annotators assign the labels. The paper gives the manually assigned class totals but no annotator agreement figure. As a result, the reported accuracy supplies a useful estimate of agreement with the labels the authors used, while the strength of the human comparison remains uncertain.
The sampling procedure for those 800 posts is also sparsely described. The reader knows the platform, the language, the counts by label, and the wider forum’s topic structure. Details of which discussions the labeled posts came from or how they were selected are left open. The approximately even allocation of labeled categories gives the evaluation examples of each outcome. The proportions among the labeled posts do not establish how common any label is across kajgana, and accuracy can depend on that distribution when the method is used on other material.
Cross-validation tests on held-out parts of the labeled collection. The paper gives no separate evaluation on a different forum, on a new time period, or on explicitly separated topics or discussion threads. If related posts share vocabulary, a split that places them in different folds can favor features specific to that discussion. The description leaves the handling of such groups unspecified. The reported evaluation is therefore best interpreted as performance on held-out parts of the labeled kajgana material. Transfer to other kinds of Macedonian writing is an open question.
Another detail concerns the information that defines the representation. The inverse document frequency equation uses a set of posts, and the authors describe a vocabulary cutoff based on the forum material. The account leaves open whether vocabulary selection and document frequency weights were recalculated inside each training fold or set using a larger collection. Those procedures can produce different evaluations of how the classifier handles completely new data. The formula explains which quantities are used once the post collection is chosen. It does not settle how that collection was chosen within the cross-validation runs.
The separate accuracies of 0.96 for subjectivity and 0.96 for polarity are helpful, but they leave the distribution of errors largely invisible. A reader who wants to apply the mood measure would be especially interested in whether the classifier systematically turns positive posts into negative ones or sends them to the objective category. Confusion between the two polarities has a different effect on the counts from an error at the subjectivity gate. Overall accuracy and stage accuracy count correct decisions. They supply limited information about the direction and concentration of incorrect ones.
The report also leaves gaps in its small comparisons. The absence of fold-by-fold scores or uncertainty estimates makes the stability of the slight bigram and negation gains hard to judge. A gain on the reported evaluation can be described as an observed result without assuming it would appear in a fresh sample with the same frequency. The stronger conclusion concerns the configuration the authors found most accurate. Explaining why small changes help would call for more direct evidence about which posts changed labels and how consistently those changes were correct.
What the mood measure can represent
The forum analysis inherits the post-level task’s definition of sentiment. Its unit is a post, and its denominator is made up of posts assigned a positive or negative label. Thus a contributor who writes repeatedly can supply multiple observations. The ratio describes the balance of classified messages within a group. It gives no independent estimate of how many distinct people hold an opinion, how strongly they hold it, or how closely the forum population resembles the wider public.
The ratio can also respond to classifier behavior at either stage. A change in the share of posts sent through the subjectivity gate alters which posts are eligible for the denominator. A change in polarity errors shifts the balance inside that denominator. The study reports no group-specific validation that could tell a reader how those effects vary across topics or months. The broad differences in the figures remain descriptions of the classifier’s outputs on the forum.
Finally, differences in the content of discussions can accompany differences in the mood ratio. Topic groups explicitly discuss different subjects. Month groups can also contain different mixes of topics and contributors. The monthly calculation pools those posts into a period-level value. It offers a way to see a pattern in the output of the classification system and leaves the reasons for that pattern unresolved.
What came after
Jovanoski et al.’s work on sentiment analysis of Macedonian Twitter cites the kajgana study and takes Macedonian sentiment analysis to another setting for online expression. The connection that can be established is a continuation of the language and problem across platforms. The kajgana paper works with entries in a forum, where posts are grouped by discussion topic. The later work addresses sentiment in Macedonian on Twitter.
This change of setting is pertinent to the earlier experiment’s scope. Its strongest evidence concerns the representation of words in kajgana posts. Studying a second platform brings the broader task of recognizing sentiment in Macedonian to a different source of text. The citation and subject establish that relationship. They leave open whether the later study reused the forum corpus, the separation of subjectivity and polarity, or the specific weighting and negation rules. The documented continuation is the study of Macedonian sentiment across online settings, with the earlier paper supplying a forum-based comparison of how words and local word combinations support that task.
Cite
Cite as Andrej Gajduk and Ljupčo Kocarev. 2014. Opinion mining of text documents written in Macedonian language. arXiv (Cornell University).
@misc{gajduk2014opinion,
title = {{Opinion mining of text documents written in Macedonian language}},
author = {Andrej Gajduk and Ljupčo Kocarev},
year = {2014},
doi = {10.48550/arxiv.1411.4472},
eprint = {1411.4472},
archivePrefix = {arXiv},
url = {https://doi.org/10.48550/arxiv.1411.4472}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/gajduk-2014-opinion-mining-text-documents-written/
References
- Y. Lin, J. Zhang, X. Wang, and A. Zhou, “Sentiment classification via integrating multiple feature presentations,” in Proceedings of the 21st international conference companion on World Wide Web, pp. 569–570, ACM, 2012. OpenAlex ↗ · Scholar ↗
- B. Pang, L. Lee, and S. Vaithyanathan, “Thumbs up?: sentiment classification using machine learning techniques,” in Proceedings of the ACL-02 conference on Empirical methods in natural language processing-Volume 10, pp. 79–86, Association for Computational Linguistics, 2002. our card
- J. A. Horrigan, “Online shopping,” Pew Internet & American Life Project Report, vol. 36, 2008. OpenAlex ↗ · Scholar ↗
- W. Antweiler and M. Z. Frank, “Is all that talk just noise? the information content of internet stock message boards,” The Journal of Finance, vol. 59, no. 3, pp. 1259–1294, 2004. OpenAlex ↗ · Scholar ↗
- N. Archak, A. Ghose, and P. G. Ipeirotis, “Show me the money!: deriving the pricing power of product features by mining consumer reviews,” in Proceedings of the 13th ACM SIGKDD international conference on Knowledge discovery and data mining, pp. 56–65, ACM, 2007. OpenAlex ↗ · Scholar ↗
- J. A. Chevalier and D. Mayzlin, “The effect of word of mouth on sales: Online book reviews,” tech. rep., National Bureau of Economic Research, 2003. OpenAlex ↗ · Scholar ↗
- T. Mullen and R. Malouf, “A preliminary investigation into sentiment analysis of informal political discourse.,” in AAAI Spring Symposium: Computational Approaches to Analyzing Weblogs, pp. 159–162, 2006. OpenAlex ↗ · Scholar ↗
- A. Tumasjan, T. O. Sprenger, P. G. Sandner, and I. M. Welpe, “Predicting elections with twitter: What 140 characters reveal about political sentiment.,” ICWSM, vol. 10, pp. 178–185, 2010. OpenAlex ↗ · Scholar ↗
- J. Bollen, H. Mao, and X. Zeng, “Twitter mood predicts the stock market,” Journal of Computational Science, vol. 2, no. 1, pp. 1–8, 2011. OpenAlex ↗ · Scholar ↗
- B. Pang and L. Lee, “Opinion mining and sentiment analysis,” Foundations and trends in information retrieval, vol. 2, no. 1-2, pp. 1–135, 2008. OpenAlex ↗ · Scholar ↗
- H. Tang, S. Tan, and X. Cheng, “A survey on sentiment detection of reviews,” Expert Systems with Applications, vol. 36, no. 7, pp. 10760–10773, 2009. OpenAlex ↗ · Scholar ↗
- M. Tsytsarau and T. Palpanas, “Survey on mining subjective data on the web,” Data Mining and Knowledge Discovery, vol. 24, no. 3, pp. 478–514, 2012. OpenAlex ↗ · Scholar ↗
- N. Godbole, M. Srinivasaiah, and S. Skiena, “Large-scale sentiment analysis for news and blogs.,” ICWSM, vol. 7, 2007. OpenAlex ↗ · Scholar ↗
- T. Nakagawa, K. Inui, and S. Kurohashi, “Dependency tree-based sentiment classification using crfs with hidden variables,” in Human Language Technologies: The 2010 Annual Conference of the North American Chapter of the Association for Computational Linguistics, pp. 786–794, Association for Computational Linguistics, 2010. our card
- J. Read, “Using emoticons to reduce dependency in machine learning techniques for sentiment classification,” in Proceedings of the ACL Student Research Workshop, pp. 43–48, Association for Computational Linguistics, 2005. OpenAlex ↗ · Scholar ↗
- M. J. Paul, C. Zhai, and R. Girju, “Summarizing contrastive viewpoints in opinionated text,” in Proceedings of the 2010 Conference on Empirical Methods in Natural Language Processing, pp. 66–76, Association for Computational Linguistics, 2010. OpenAlex ↗ · Scholar ↗
- M. Rushdi Saleh, M. T. Martín-Valdivia, A. Montejo-Ráez, and L. Ureña-López, “Experiments with svm to classify opinions in different domains,” Expert Systems with Applications, vol. 38, no. 12, pp. 14799–14804, 2011. OpenAlex ↗ · Scholar ↗
- M. Zeng, Y. Yang, and W. Liu, “An approach of text sentiment analysis for public opinion monitoring system,” in Semantic Web and Web Science, pp. 131–141, Springer, 2013. OpenAlex ↗ · Scholar ↗
- T. Mullen and N. Collier, “Sentiment analysis using support vector machines with diverse information sources.,” in EMNLP, vol. 4, pp. 412–418, 2004. OpenAlex ↗ · Scholar ↗
- Q. Ye, B. Lin, and Y.-J. Li, “Sentiment classification for chinese reviews: A comparison between svm and semantic approaches,” in Machine Learning and Cybernetics, 2005. Proceedings of 2005 International Conference on, vol. 4, pp. 2341–2346, IEEE, 2005. OpenAlex ↗ · Scholar ↗
- M. Gamon, “Sentiment classification on customer feedback data: noisy data, large feature vectors, and the role of linguistic analysis,” in Proceedings of the 20th international conference on Computational Linguistics, p. 841, Association for Computational Linguistics, 2004. OpenAlex ↗ · Scholar ↗
- M. Koppel and J. Schler, “The importance of neutral examples for learning sentiment,” Computational Intelligence, vol. 22, no. 2, pp. 100–109, 2006. OpenAlex ↗ · Scholar ↗
- J. Wiebe, T. Wilson, and C. Cardie, “Annotating expressions of opinions and emotions in language,” Language resources and evaluation, vol. 39, no. 2-3, pp. 165–210, 2005. OpenAlex ↗ · Scholar ↗
- P. Chaovalit and L. Zhou, “Movie review mining: A comparison between supervised and unsupervised classification approaches,” in System Sciences, 2005. HICSS'05. Proceedings of the 38th Annual Hawaii International Conference on, pp. 112c–112c, IEEE, 2005. OpenAlex ↗ · Scholar ↗
- C. Strapparava and R. Mihalcea, “Semeval-2007 task 14: Affective text,” in Proceedings of the 4th International Workshop on Semantic Evaluations, pp. 70–74, Association for Computational Linguistics, 2007. our card
- A. Esuli and F. Sebastiani, “Determining term subjectivity and term orientation for opinion mining.,” in EACL, vol. 6, p. 2006, 2006. OpenAlex ↗ · Scholar ↗
- W. B. Frakes and C. J. Fox, “Strength and similarity of affix removal stemming algorithms,” in ACM SIGIR Forum, vol. 37, pp. 26–30, ACM, 2003. OpenAlex ↗ · Scholar ↗
- J. Savoy, “Searching strategies for the hungarian language,” Information processing & management, vol. 44, no. 1, pp. 310–324, 2008. OpenAlex ↗ · Scholar ↗
- D. Sharma, “Stemming algorithms: A comparative study and their analysis,” International Journal of Applied Information Systems, vol. 4, no. 3, pp. 7–12, 2012. OpenAlex ↗ · Scholar ↗
- M. A. Hafer and S. F. Weiss, “Word segmentation by letter successor varieties,” Information storage and retrieval, vol. 10, no. 11, pp. 371–385, 1974. OpenAlex ↗ · Scholar ↗
- M. Ghiassi, J. Skinner, and D. Zimbra, “Twitter brand sentiment analysis: A hybrid system using n-gram analysis and dynamic artificial neural network,” Expert Systems with Applications, 2013. OpenAlex ↗ · Scholar ↗
- R. Socher, A. Perelygin, J. Y. Wu, J. Chuang, C. D. Manning, A. Y. Ng, and C. Potts, “Recursive deep models for semantic compositionality over a sentiment treebank,” in Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), 2013. our card
- S. Wang and C. D. Manning, “Baselines and bigrams: Simple, good sentiment and topic classification,” in Proceedings of the 50th Annual Meeting of the Association for Computational Linguistics: Short Papers-Volume 2, pp. 90–94, Association for Computational Linguistics, 2012. our card
- H. Kang, S. J. Yoo, and D. Han, “Senti-lexicon and improved naïve bayes algorithms for sentiment analysis of restaurant reviews,” Expert Systems with Applications, vol. 39, no. 5, pp. 6000–6010, 2012. OpenAlex ↗ · Scholar ↗