Introduction
Traditional image captioning systems typically follow a standard encoder-decoder architecture, where an image is encoded into a set of features and a language model generates a description word-by-word from scratch. While effective, this "from-scratch" approach suffers from a lack of hindsight. Once a word is generated, the model cannot easily go back to correct errors or refine a generic description into a more precise one.
This paper introduces Modification Networks (MN), a novel "plug-and-play" framework designed to refine existing captions. Rather than generating a sentence from a blank slate, the MN takes a complete (but potentially flawed) draft and learns to model the "residual information." By deciding what to keep, remove, or add, the model shifts the focus from total prediction to strategic modification, consistently improving the performance of state-of-the-art captioning baselines.
The Modification Network Architecture
The proposed framework acts as a secondary refinement layer that can be integrated with any existing captioning model. Its architecture is built around three primary components:
- Feature Extraction (DAN): The model first processes the draft caption using a Deep Averaging Network (DAN), which encodes the variable-length sentence into a fixed-size embedding.
- Language Modeling (Dual LSTMs): The system employs two LSTMs. An Attention LSTM identifies relevant image regions based on the sentence embedding, while a Language LSTM generates the "residual information"—the new content intended to update the draft.
- Residual Gating: This is the core innovation of the MN. The network computes a modification gate ($g_r$) by comparing the decoder's current state with the existing draft caption.
Residual Gating: The Core Innovation
The modification gate serves as a selection mechanism: if the gate value is high, the model retains the word from the original draft; if the gate value is low, it incorporates the residual information generated by the Language LSTM to modify the caption. This allows the model to perform "soft" corrections, maintaining semantic flow while fixing specific errors.
Experimental Results
The authors evaluated the Modification Network using the MSCOCO Karpathy split, testing it on top of three major frameworks: Soft-Attention, Adaptive Attention, and Bottom-Up/Top-Down Attention. In every instance, the MN improved scores across all standard metrics, including BLEU, ROUGE-L, CIDEr, and SPICE.
Notably, when applied to the Bottom-Up/Top-Down model (the strongest baseline), the CIDEr score improved from 1.107 to 1.123, and the SPICE score—which specifically measures semantic quality—rose from 20.2 to 20.3. These results suggest that the refinement process effectively enhances the semantic accuracy of the generated descriptions.
Discussion and Qualitative Analysis
The behavior of the Modification Network can be categorized into three distinct modes:
- Complete Modification: Rewriting the entire sentence when the initial draft is fundamentally incorrect.
- Partial Modification: Refining specific phrases (e.g., changing "on a runway" to "on an airport tarmac").
- Complementary Modification: Adding missing details to a caption that is factually correct but lacks depth.
Qualitatively, the model excels at correcting "hallucinated" objects. For example, if a base model incorrectly identifies an object in a complex scene, the MN can successfully remove the erroneous word and replace it with contextually appropriate details.
Conclusion
The "Look and Modify" approach demonstrates that refinement is often more efficient than creation. By starting with a draft, the model can focus its computational resources on correcting semantic errors rather than relearning basic syntax. While the current implementation adds some computational overhead, its success in image captioning suggests potential applications in other fields, such as Neural Machine Translation (NMT), where a model could similarly refine rough translation drafts.
Summary updated