Assistant replied nothing not even role

here is my code to chat with Assistant I already created.

assistant = client.beta.assistants.retrieve(assistant_id=assistantid)
thread = client.beta.threads.create()

message = client.beta.threads.messages.create(, role="user", content="What can you help me with?")

run = client.beta.threads.runs.create(,

run_status = client.beta.threads.runs.retrieve(,
messages = client.beta.threads.messages.list(

for message in reversed(
  print(message.role, ": ", message.content[0].text.value)

Can Anyone tell me about this Why it’s not give any response?

I think my assistant is facing some issue because I same issue. It was working fine previously but suddenly do not giving any reply.

1 Like

Same here actually.

It worked before. But now When tested it again. It stops working.

do you have any idea why this happens, any clue?

I suggest using, at first, a simple try+except statement for every OpenAI call. Something like replacing your first line

   assistant = client.beta.assistants.retrieve(assistant_id=assistantid)
except Exception as e:
  print(f"\nGot a retrieve error : {e}")

You can then use a more specific set of catching exceptions. You can see the types of exceptions the OpenAI python github repo (in the README)