microsoft / genaiscript

Generative AI Scripting
https://microsoft.github.io/genaiscript/
MIT License
82 stars 23 forks source link

Issue with CLI invocation on Windows #284

Open bzorn opened 3 months ago

bzorn commented 3 months ago

I tried running the CLI on my Windows laptop and got this message.
Node version was: v16.14.2 Is there a minimum node version needed?

PS C:\Users\zorn\OneDrive - Microsoft\AI CoArch\open-source-release\demo> npx --yes genaiscript-cli@^1.15.9 run .\genaisrc\explain-diagram.genai.js .\plug-in-block-diagram.png npm ERR! code ERESOLVE npm ERR! ERESOLVE unable to resolve dependency tree npm ERR! npm ERR! Found: node-fetch@2.7.0 npm ERR! node_modules/node-fetch npm ERR! node-fetch@"^2.6.7" from @anthropic-ai/sdk@0.15.0 npm ERR! node_modules/@anthropic-ai/sdk npm ERR! @anthropic-ai/sdk@"^0.15.0" from llamaindex@0.1.21 npm ERR! node_modules/llamaindex npm ERR! optional llamaindex@"0.1.21" from genaiscript-cli@1.15.9 npm ERR! node_modules/genaiscript-cli npm ERR! genaiscript-cli@"1.15.9" from the root project npm ERR! node-fetch@"^2.6.7" from @mistralai/mistralai@0.0.10 npm ERR! node_modules/@mistralai/mistralai npm ERR! @mistralai/mistralai@"^0.0.10" from llamaindex@0.1.21 npm ERR! node_modules/llamaindex npm ERR! optional llamaindex@"0.1.21" from genaiscript-cli@1.15.9 npm ERR! node_modules/genaiscript-cli npm ERR! genaiscript-cli@"1.15.9" from the root project npm ERR! 3 more (@notionhq/client, cohere-ai, openai) npm ERR! npm ERR! Could not resolve dependency: npm ERR! peerOptional node-fetch@"^3.3.2" from @llamaindex/cloud@0.0.4 npm ERR! node_modules/@llamaindex/cloud npm ERR! @llamaindex/cloud@"0.0.4" from llamaindex@0.1.21 npm ERR! node_modules/llamaindex npm ERR! optional llamaindex@"0.1.21" from genaiscript-cli@1.15.9 npm ERR! node_modules/genaiscript-cli npm ERR! genaiscript-cli@"1.15.9" from the root project npm ERR! npm ERR! Fix the upstream dependency conflict, or retry npm ERR! this command with --force, or --legacy-peer-deps npm ERR! to accept an incorrect (and potentially broken) dependency resolution. npm ERR! npm ERR! See C:\Users\zorn\AppData\Local\npm-cache\eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\zorn\AppData\Local\npm-cache_logs\2024-03-21T16_49_36_960Z-debug.log

pelikhan commented 3 months ago

mininmum is 20 and it should have complained. good bug

bzorn commented 3 months ago

Also fails with node version: v21.5.0

pelikhan commented 3 months ago

Can you share your script?

pelikhan commented 3 months ago

try removing @^1.15.9