Artificial intelligence (AI) is one of the emerging technologies that has attracted a lot of attention in recent years. The tremendous economic effects of this technology and, on the other hand, the potential risks and challenges have caused policymakers in different countries to pay special attention to appropriate policies for developing AI innovation ecosystems. This research identified the basic functions of AI in the world by examining the innovation ecosystem development policies in 6 countries, the United States, China, England, Russia, India, and the UAE, and interviewing AI experts in the Iran. In addition, the present research has identified the actors of this ecosystem and the roles and mutual relationships between them by presenting the structural and functional mapping of the AI innovation ecosystem and offers some policies to improve the development of the AI ecosystem in Iran. The seven basic AI functions identified in this research are policy and governance, education, financing, research, networking, innovative and startup activities, and technical infrastructure development. Also, the results of this research show that Iran's AI ecosystem has 41 governmental, quasi-governmental and private major actors. Moreover, the research results indicate that to develop the country's AI innovation ecosystem and prevent lagging behind other countries, high-level coordination of government, industry and university actors is needed.