Kosmos-G: Generating Images in Context with Multimodal Large Language Models