Can any one help me to integrate AI in mac m1 with Appium

i tried to install AI plug in in with appium in mac m1 as this page
https://appiumpro.com/editions/39-early-stage-ai-for-appium-test-automation

but i got error
Original error: Could not load your custom find module ‘ai’. Did you put it somewhere Appium can ‘require’ it? Original error: Error: Cannot find module ‘canvas’