Modeling Background Knowledge with Frame Semantics for Fine-grained Sentiment Classification

Muhammad Okky Ibrohim, Valerio Basile, Danilo Croce, Cristina Bosco, Roberto BasiliACL 2025

TL;DR

This paper introduces BACKGEN, a novel framework that generates structured "background knowledge" (BK) using Frame Semantics to improve sentiment classification in few-shot learning scenarios. By synthesizing conceptual patterns from data, BACKGEN provides robust context for LLMs, significantly reducing errors compared to traditional example-based prompting.

What Problem Does This Paper Address?

Few-shot learning, particularly in-context learning (ICL) with Large Language Models (LLMs), is powerful but highly sensitive to the selection of example prompts. This sensitivity leads to unstable performance, as irrelevant or poorly chosen examples can confuse the model. While methods exist to select better examples, they often incur high computational costs. The authors tackle this by proposing a knowledge-driven approach that replaces example-based prompting with structured background knowledge, aiming for more stable and generalizable sentiment classification, especially for phrases whose sentiment depends on implicit commonsense knowledge.

Methods

BACKGEN employs a three-step pipeline:

  1. Frame-based Parsing: It leverages Frame Semantics to extract structured representations of events, participants, and their relationships from annotated examples. This moves beyond simple lexical similarity to capture deeper conceptual structures.
  2. Frame-based Clustering: Similar frames and semantic roles are grouped together to identify shared conceptual patterns. This process is done separately for positive and negative sentiments to maintain polarity coherence.
  3. Background Knowledge Generation: An LLM is used to synthesize the common information within each cluster into concise, natural language statements. These statements act as background knowledge (BK) and are injected into prompts.

For sentiment classification, the authors compare three prompting strategies: zero-shot (no examples), few-shot (1-2 examples, randomly selected or similarity-based), and BK-shot (using generated BK statements). Retrieval of BK for the BK-shot approach is done using either frame-based kernel similarity or text similarity (Sentence-BERT embeddings).

Datasets

The authors created an SPC dataset for the environmental sustainability domain by extending an existing English dataset with data from the social media platform X. This dataset consists of tweets discussing environmental and socio-political issues, where sentiment often relies on domain-specific background knowledge. The final dataset comprises 2,573 phrases after filtering.

Key Insights and Ideas

  • Beyond Surface-Level Cues: The core idea is that sentiment often hinges on implicit commonsense knowledge that goes beyond the literal words. BACKGEN aims to capture this by generating abstract conceptual patterns.
  • Frame Semantics for Structure: Using Frame Semantics is crucial for moving beyond lexical similarity. It allows the model to understand the underlying event structure and role relationships, enabling more robust generalization.
  • Structured Knowledge as a Stable Alternative: Replacing potentially noisy example selection with structured, generalized BK offers a more stable and reliable way to guide LLMs, reducing performance variance.
  • Text Similarity Outperforms Frame Similarity for Retrieval: Interestingly, the study found that text-based embeddings (Sentence-BERT) were more effective for retrieving relevant BK than frame-based kernel similarity, suggesting that broader contextual understanding from embeddings is more beneficial for this task.

Key Results

BACKGEN consistently outperforms zero-shot and traditional few-shot approaches.

  • Error Reduction: The BK-based prompting achieved up to 29.94% error reduction over zero-shot and 22.73% over the best few-shot baseline (2-shotRand) for Mistral-7B. For Llama3-8B, the error reduction was 26.76% over zero-shot and 19.59% over 2-shotRand.
  • Model Performance: The best configuration (2-BK TSim) with Mistral-7B achieved a weighted F₁ score of 0.950, and with Llama3-8B, it reached 0.902.
  • Retrieval Strategy: Text similarity-based retrieval (BKTsim) generally performed better than frame similarity-based retrieval (BKKernel).

Limitations and Future Work

  • Domain Specificity: The current BK database is limited to the environmental sustainability domain, and its effectiveness in other sentiment analysis tasks needs exploration.
  • Parser Dependency: The quality of generated BK is inherently tied to the accuracy of the frame parser used.
  • Bias in BK: The clustering process might overrepresent certain perspectives, potentially introducing biases into the generated BK. Future work should focus on detecting and mitigating these biases.
  • BK Quality Evaluation: The paper did not directly assess the quality (fluency, generalizability) of the generated BK itself, which is a direction for future research.
  • Broader Applications: The authors suggest exploring BACKGEN for other tasks requiring commonsense reasoning (e.g., question answering, stance detection) and investigating its cross-domain generalization.
  • Explainability: Connecting BK to model predictions could enhance explainability, making model reasoning more interpretable.