Any way to override view_mode in twig directly?
The fatal error is because Twig set is not able to manipulate arrays. This is only possible by using merge and then only on the top level of the array.

So first get the sub array where the key is placed and then merge the array key:

{% set item_content = item.content %}
{% set item_content = item_content|merge({'#view_mode': 'thumbnail'}) %}
{{ item_content }}


But I doubt that after you've solved the Twig issue this will work, because of how entities are rendered and cached. So you might have more success with Twig Tweak.