arXiv:2610.25075cs.CVOct 2026

Manuscript Offprint

arXiv:2610.25075

MoCKEFA: Model-Conditioned Keyframe Extraction and Fair Attribution for Video Model Explanation

Lahiru Wijayasingha

Abstract

We show that a video can be represented with just a few keyframes without sacrificing a given model's belief about the video. Our method is the first in it's kind that extracts these keyframes conditioned on the model's prediction which is massively helpful for building explainable video models. We then fairly distribute the importance of the video to the model among the keyframes with game theoretically fair Shapley values. Through qualitative and quantitative experiments, we show that keyframe attribution is superior to the traditional frame attribution. Further we conduct preliminary exploration on highlighting the important changes among the frames by looking at the differences between adjacent keyframes.

1. Introduction

Temporal attribution quantifies each frame’s influence on a video model’s decision. However, some adjacent frames are highly correlated [11][26] and some are noisy making per-frame analysis redundant and difficult to interpret. Our algorithm asks the model itself; not any external entity “which frames are actually important for your decision?”. The answer to this lets us represent the whole video with a few keyframes that the model values. Then we judge the relative importance of these keyframes by “fairly” distributing the total importance of the video among the keyframes. This shift not only enhances interpretability but also significantly reduces computational overhead.

Any method that interprets a model’s decision must not significantly alter the very decision that we are trying to explain. Also, they must not utilize any reference other than the model itself to derive the explanations [18]. Current keyframe extraction methods [7] [10] [42] are designed to enhance (hence change) the model decision. Some methods use an external model to find the keyframes [7]. Such traits make existing methods of keyframe extraction un-

Figure

Figure 1. MoCKEFA framework. Keyframe extraction: model selects keyframes that are important for model's decision. Continuous temporal regions can be represented with just a selected keyframe with minimal change to the model belief. Fair attribution: Shapley values are calculated for each keyframe that gives game-theoretically "fair" attributions

suitable for explaining model decision. We introduce the first Model Conditioned Keyframe Extraction and Fair Attribution (MoCKEFA), an algorithm that coalesces a video stream into cohesive groups sharing a common core characteristic that is essential for the model decision, and extracts a representative keyframe from each group (Figure 1). Crucially, repeating this keyframe in place of the full group does not significantly alter the model's belief, revealing that intra-group changes are largely inconsequential to the decision. Instead, only transitions between keyframes carry meaningful temporal information. This refined understanding of temporal attribution promises to be critical in domains such as medical AI and autonomous driving [23].

Keyframe attribution can be framed as a cooperative game-theoretic problem, where n players jointly contribute to a total payoff. The central question, then, is how to define a fair distribution of this value. Lloyd Shapley [30] addressed this by proposing four axioms that any fair allocation must satisfy (see Section 2); their intuitive appeal has made them the de facto standard for fairness. Shapley further proved that the Shapley value is the unique solution satisfying these axioms, and it has since been widely adopted to compute individual payoffs in n-player games. In computer vision, this framework has been readily adapted—notably, Play Fair [27] employed Shapley values for video frame attribution. Following this lead, we treat each keyframe as a player, with the model's prediction serving as the total payoff.

In frame-wise Shapley attribution such as in Play Fair [27], mutually redundant frames receive nearly equal payoffs—but these payoffs reflect only the unique information each frame contributes relative to others, not any intrinsic value embedded within the frame itself. Consequently, per-frame payoffs alone cannot reliably reveal the true importance of each core characteristic (main distinct concepts in the video). By assigning attribution at the keyframe level, we obtain a far more interpretable representation. Consider Figure 2, where the video is partitioned into three visually coherent shots. Plot G (keyframe-wise) and Plot F (frame-wise) tell contrasting stories: while most frames within a group receive similar frame-level scores, the human mind more naturally grasps the per-keyframe, per-core-characteristic assignment of attribution in plot G. Beyond interpretability, keyframes also offers a practical computational advantage—exact Shapley values require 2n2^{n}-players model evaluations, so reducing the number of players dramatically lowers cost. That said, Figure 2 reveals a subtle limitation: the last frame of the first group and the last two frames of the second group receive above-average attribution, as they lie near the boundary of the next group—which has higher average attribution. This suggests that MoCKEFA by discretizing a continuous physical process, introduces a mild approximation. Nevertheless, we find this approximation sufficiently accurate for our analysis, and in Section 5 we show that finer groupings can arbitrarily approximate the original video.

In general, video understanding models cannot process variable video lengths. A problem arise when we have to remove certain frames in the video to estimate keyframe attributions. Play Fair [27] creates a new multi-scale model that can process variable lengths. But if we calculate attribution with such a secondary model we are actually estimating the attribution given by this new model, not the original model. On the other hand our attribution method does not require any modifications to the model and will work on any model architecture. We show that temporal freezing can be used to significantly reduce the burden of evaluating on a background set required by Shapley value calculation. Temporal freezing also gives more intuitive and quantitatively better results than other filling methods such as all zero values and sampling from a distribution of other videos.

Our contributions to video temporal attribution:

• We introduce the first model conditioned keyframe extraction algorithm suitable for explaining video models that can 1) Use the model output to group adjacent frames of a video into several shots. 2) Extract a keyframe from each shot that can represent the information contained in each shot that is valuable to the model decision.

• Show that temporal freezing is more intuitive and qualitatively better than other methods to fill in missing frames for temporal attribution in videos.

• Show that Sahpley-based keyframe attributions makes more intuitive sense and easy to interpret than other frame-wise attribution baselines.

References (45)