flows-network / openai-assistant-telegram

Connect your OpenAI applications based on the Assistant API to Telegram
Apache License 2.0
22 stars 3 forks source link

Bot won't reply in Telegram #2

Closed ekimbasoglu closed 1 month ago

ekimbasoglu commented 1 month ago

Hello👋

I have an active telegram bot and I restarted it by pausing and unpausing but the bot won't respond.

I checked the configuration for each key and there is no problem, I have credit on my OpenAI account as well. The link to the bot is; https://flows.network/flow/info/JobMasterOvde-Bot

image It responds when I type /restart but still doesn't send me any messages on telegram. image

Something in run_message got broken when they updated the API, could somebody show how to debug this project?

ekimbasoglu commented 1 month ago

Update: I found out why it's not responding. Currently, Assistants v1 is updated with v2 and the newer models then 3.5-turbo is not supported with v1 anymore. The current code still uses v1. I don't have the necessary code to update the project, could someone please reach out via email(ekimbasoglu) or in GitHub? 👀 @DarumaDocker @alabulei1

{ "level": "ERROR", "msg": "thread '' panicked at src/lib.rs:106:10:\ncalledResult::unwrap()on anErrvalue: ApiError(ApiError { message: \"The requested model 'gpt-4o-mini-2024-07-18' cannot be used with the Assistants API in v1. Follow the migration guide to upgrade to v2: https://platform.openai.com/docs/assistants/migration.\", type: Some(\"invalid_request_error\"), param: Some(String(\"model\")), code: Some(String(\"unsupported_model\")) })\nnote: run withRUST_BACKTRACE=1environment variable to display a backtrace\n", "function": "run" }

juntao commented 1 month ago

The ASSISTANT_ID environment var associated with your bot is configured with the model it needs to be. You need to log into your openai account and change the model setting for that ASSISTANT_ID

ekimbasoglu commented 1 month ago

@juntao Thank you for your reply and help, instead of this solution/project, I continued using the LLama/HuggingFace model because it's free. I'm closing this issue now 💯