The Group of Seven (G7) countries will agree on a voluntary AI code of conduct for companies developing AI to reference for mitigating risks and benefits of the technology.