We contrast two views of how contextual influence on sentence meaning composition can be explained. The Semantic Similarity View maintains that discourse context affects sentence meaning mainly because of the semantic similarity between the words in the discourse context and the words in the sentence (as measured by Latent Semantic Analysis). The Free Pragmatic View, in contrast, defends the claim that also pragmatic aspects of the discourse context can affect sentence meaning composition. This effect can be quantitatively modelled by Bayesian Pragmatics. We introduce a Predictive Completion Task in which the hearer at every moment in a communicative situation has to generate a probabilistic prediction about how a discourse being uttered by the speaker is continued. We test the predictions of the two views in EEG using the well-established observation that the conditional probability of a word given a context is negatively correlated with the amplitude of its N400 component.