Emergence of Social Norms in Generative Agent Societies: Principles and Architecture