Intercepting model internal state before output generation.