AI at the end of the day is a term that describes a lot of tools that has something in common. Islamic opinion will depend on how you use this tool for. If you are developing a drone swarm that will be used to kill people in the war or if you are developing a robot swarm to help do difficult jobs inside factories. It might be the same concept or technology but the usage is very different from Islamic perspective.
Another example is the usage of famous ChatGPT. A student can use it to correct English mistakes or for some help in their school work or they can use it to cheat and produce the full homework or exam. People can use it to write and publish porn stories or can use it to help them write a useful book. Islam also put a special important on intent of the action.