From behemoths to smaller companies offering novel weapons, tech firms such as Google, Palantir and OpenAI have found themselves at the heart of the US war effort.