write contract with AI