GreyActOwl1 / AlfredAI-Chatbot

Personal Assistant AI Chatbot
https://alfred-ai-theta.vercel.app
MIT License
2 stars 0 forks source link

Multi turn Chat does not respond in build #13

Closed GreyActOwl1 closed 3 months ago

GreyActOwl1 commented 3 months ago
          Chat does not work in deployment. No message response from API. Status code: 500 see preview l[ink](https://alfred-ai-git-5-update-gemini-api-dev-18s-projects.vercel.app/)

Originally posted by @GreyActOwl1 in https://github.com/GreyActOwl1/AlfredAI/issues/7#issuecomment-2282275969

GreyActOwl1 commented 3 months ago

See PR #7 & #10

GreyActOwl1 commented 3 months ago

This commit introduces the chat issue d7ac2b7959bffec3370b852fd4ffda2b8933d2ac. Investigate vercel SDK

GreyActOwl1 commented 3 months ago

Here are the logs from the deployment:

Error fetching data from Gemini AI: ee [AI_LoadAPIKeyError]: Google Generative AI API key is missing. Pass it using the 'apiKey' parameter or the GOOGLE_GENERATIVE_AI_API_KEY environment variable.
    at /var/task/.next/server/app/api/chat/route.js:3:71307
    at Object.s [as headers] (/var/task/.next/server/app/api/chat/route.js:3:71569)
    at rp.doStream (/var/task/.next/server/app/api/chat/route.js:3:68367)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async fn (/var/task/.next/server/app/api/chat/route.js:4:28220)
    at async /var/task/.next/server/app/api/chat/route.js:4:16671
    at async ad (/var/task/.next/server/app/api/chat/route.js:4:15473) {
  cause: undefined,
  [Symbol(vercel.ai.error)]: true,
  [Symbol(vercel.ai.error.AI_LoadAPIKeyError)]: true
}

@jballo this might help with the fix on #10

GreyActOwl1 commented 3 months ago

The issue has been identified: the environment variable was not made available to non-production environments due to a configuration in our secrets manager integration. To prevent this in the future, please ensure that environment variables are added to all necessary environments by selecting them from the drop-down menu. This has now been fixed, addressing the problem identified with PR #10, and the issue will be closed.

Modify_env_image

Note: We will update the integration settings to automate this process going forward. The branch associated with this issue will be closed and deleted without a PR/merge since no code changes were required.