# System messages in Assistant threads

**URL:** <https://community.openai.com/t/system-messages-in-assistant-threads/834585>\
**Category:** Feedback\
**Tags:** assistants-api, system-message\
**Created:** [June 22, 2024, 3:21pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585 "2024-06-22T15:21:56Z")\
**Posts on this page:** 18\
**Page:** 1

<div class="post-metadata">

**Author:** ![adamralph](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/adamralph/32/267734_2.png) [@adamralph](https://community.openai.com/u/adamralph)\
**Post date:** [June 22, 2024, 3:21pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/1 "2024-06-22T15:21:56Z")

</div>

Assistants beta V2 seems to be considerably better than V1. I abandoned V1 due to poor performance, unreliability and lack of streaming.

With V2 now in place, I’m tempted to switch back to assistants, but there is one thing missing for my use cases: the ability to add system messages to threads. The Assistants API restricts the message types to “user” and “assistant”. I realise that “instructions” can be passed to the API (which I guess become system messages under the hood) but I have use cases where I need add system messages at specific points in the thread.

Will we ever have the ability to add system messages to assistant threads?

---

<div class="post-metadata">

**Author:** ![razvan.i.savin](https://avatars.discourse-cdn.com/v4/letter/r/a88e4f/32.png) [@razvan.i.savin](https://community.openai.com/u/razvan.i.savin)\
**Post date:** [June 22, 2024, 4:26pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/2 "2024-06-22T16:26:13Z")

</div>

When you run the assistant.id in the thread.id, will run instructions automatically in the first run.

---

<div class="post-metadata">

**Author:** ![adamralph](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/adamralph/32/267734_2.png) [@adamralph](https://community.openai.com/u/adamralph)\
**Post date:** [June 22, 2024, 4:43pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/4 "2024-06-22T16:43:19Z")

</div>

@razvan.i.savin I know that. I even say so in my question.

---

<div class="post-metadata">

**Author:** ![adamralph](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/adamralph/32/267734_2.png) [@adamralph](https://community.openai.com/u/adamralph)\
**Post date:** [June 23, 2024, 12:31am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/6 "2024-06-23T00:31:00Z")

</div>

It seems like you are echoing AI responses. I’m less interested in the current state of affairs compared to future plans.

---

<div class="post-metadata">

**Author:** ![MrFriday](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/mrfriday/32/350887_2.png) [@MrFriday](https://community.openai.com/u/MrFriday)\
**Post date:** [June 23, 2024, 6:31am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/8 "2024-06-23T06:31:06Z")

</div>

I have the same issue. When we use Function Calling in Assistant APIs using 3.5 Turbo, the whole models hallucinates around the parameters. In Chat Completion API we can pass the System Context to fix this but in Assistant API, we only have User and Assistant Roles, which makes no sense.

This thing makes Function Calling using 3.5 literally worthless. Also, I don’t know what developers are so worries about the System Context in Assistant when it is simple available in Chat Completion.

Currently there’s no way of passing the System Context at certain point in conversation in Assistant APIs, which makes no sense at all.

---

<div class="post-metadata">

**Author:** ![ar6](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/ar6/32/147152_2.png) [@ar6](https://community.openai.com/u/ar6)\
**Post date:** [July 10, 2024, 2:13am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/9 "2024-07-10T02:13:05Z")

</div>

I’m facing the same issue. I need to add context to a thread at creation time. The assistant’s instructions can be good for generalized context, but i need to add user specific context for a thread. System messages in Chat Completion has this but I wonder why Assistants does not !!??

Have you found any solutions @MrFriday@adamralph

---

<div class="post-metadata">

**Author:** ![MrFriday](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/mrfriday/32/350887_2.png) [@MrFriday](https://community.openai.com/u/MrFriday)\
**Post date:** [July 10, 2024, 6:40am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/10 "2024-07-10T06:40:01Z")

</div>

Not yet, this one single issue make GPT 3.5 Completely useless. But if you understand the concept of Function Calling, you can fix it to some context.

---

<div class="post-metadata">

**Author:** ![supershaneski](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/supershaneski/32/71779_2.png) [@supershaneski](https://community.openai.com/u/supershaneski)\
**Post date:** [July 10, 2024, 6:59am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/11 "2024-07-10T06:59:08Z")

</div>

> [@adamralph](#):
>
> I have use cases where I need add system messages at specific points in the thread.

At what point do you need it?

Currently, there is the [additional\_instructions](https://platform.openai.com/docs/api-reference/runs/createRun#runs-createrun-additional_instructions) parameter when you create a Run. This will append additional instructions at that run only.

For example, when you send a new message, you add this “system message” using the `additional_instructions` parameter to the run. You can change it the next time you send a new message.

The practical usage for this is when you want to append user info, order details or datetime for function calling reference.

---

<div class="post-metadata">

**Author:** ![adamralph](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/adamralph/32/267734_2.png) [@adamralph](https://community.openai.com/u/adamralph)\
**Post date:** [July 10, 2024, 8:45am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/12 "2024-07-10T08:45:33Z")

</div>

> [@ar6](#):
>
> Have you found any solutions @MrFriday @adamralph

No. I’m using the regular completions API instead of the assistants API.

---

<div class="post-metadata">

**Author:** ![adamralph](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/adamralph/32/267734_2.png) [@adamralph](https://community.openai.com/u/adamralph)\
**Post date:** [July 10, 2024, 8:47am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/13 "2024-07-10T08:47:36Z")

</div>

> [@ar6](#):
>
> I’m facing the same issue. I need to add context to a thread at creation time. The assistant’s instructions can be good for generalized context, but i need to add user specific context for a thread. System messages in Chat Completion has this but I wonder why Assistants does not !!??

For this use case, the solution suggested by @supershaneski may be enough:

> [@supershaneski](#):
>
> Currently, there is the [additional\_instructions](https://platform.openai.com/docs/api-reference/runs/createRun#runs-createrun-additional_instructions) parameter when you create a Run. This will append additional instructions at that run only.
> 
> For example, when you send a new message, you add this “system message” using the `additional_instructions` parameter to the run. You can change it the next time you send a new message.
> 
> The practical usage for this is when you want to append user info, order details or datetime for function calling reference.

---

<div class="post-metadata">

**Author:** ![farmerhk](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/farmerhk/32/151361_2.png) [@farmerhk](https://community.openai.com/u/farmerhk)\
**Post date:** [July 10, 2024, 6:27pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/14 "2024-07-10T18:27:47Z")

</div>

Thanks for the post @adamralph and all of the replies.

It seems like @supershaneski has a solution with “additional\_instructions” but I think some of the spirit of the original question is unanswered and I’m still curious about that if anyone can provide tips. I’m wondering: to what extent can we configure the basic “system” in Assistants? I mean more like built-in API config options (less like additive techniques such as RAG, fine-tuning, etc).

It seems the answer is: we get to set the initial description/instructions then use additional\_instructions at points after that.

---

<div class="post-metadata">

**Author:** ![ar6](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/ar6/32/147152_2.png) [@ar6](https://community.openai.com/u/ar6)\
**Post date:** [July 11, 2024, 2:57am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/15 "2024-07-11T02:57:30Z")

</div>

I gave up on all the wonderful promises of assistants api and have implemented a chat completion pipeline where i pull up context messages as Pagable objects in java-spring and call the embedding api for RAG, works fine.

Having said that, in an ideal world if assistants api was able to fix this prob, it would simplify my codebase:

1. I don’t have to worry about persisting chat messages to DB and pulling them up every time I make an api call (Threads would solve this)
2. Have RAG out of the box pipeline as file search handles this

this would be highly effect in apps like mine where i only care about the end result of the chat i.e. the parms that the model returns as a function call back.

---

<div class="post-metadata">

**Author:** ![ar6](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/ar6/32/147152_2.png) [@ar6](https://community.openai.com/u/ar6)\
**Post date:** [July 11, 2024, 3:02am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/16 "2024-07-11T03:02:44Z")

</div>

Thanks ! I’m going to test this outside my app, and see if this works as expected. Will post the results here.

---

<div class="post-metadata">

**Author:** ![supershaneski](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/supershaneski/32/71779_2.png) [@supershaneski](https://community.openai.com/u/supershaneski)\
**Post date:** [July 11, 2024, 4:05am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/17 "2024-07-11T04:05:22Z")

</div>

> [@farmerhk](#):
>
> It seems the answer is: we get to set the initial description/instructions then use additional\_instructions at points after that.

Note that in the Run, you have two parameters you can use:

- [instructions](https://platform.openai.com/docs/api-reference/runs-v1/createRun#runs-v1-createrun-instructions)
- [additional\_instructions](https://platform.openai.com/docs/api-reference/runs-v1/createRun#runs-v1-createrun-additional_instructions)

If you want to just “add” to the original instruction/system\_prompt, use the `additional_instruction`.  
If however you want to alter the original instruction, use the `instructions` parameter. This will replace the instruction.

---

<div class="post-metadata">

**Author:** ![ar6](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/ar6/32/147152_2.png) [@ar6](https://community.openai.com/u/ar6)\
**Post date:** [July 11, 2024, 5:51am UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/18 "2024-07-11T05:51:18Z")

</div>

I think this solves my problem. Thanks man !

---

<div class="post-metadata">

**Author:** ![farmerhk](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/farmerhk/32/151361_2.png) [@farmerhk](https://community.openai.com/u/farmerhk)\
**Post date:** [July 11, 2024, 7:10pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/19 "2024-07-11T19:10:02Z")

</div>

+1 thanks all for the explorations here.

---

<div class="post-metadata">

**Author:** ![v4ames](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/v4ames/32/467191_2.png) [@v4ames](https://community.openai.com/u/v4ames)\
**Post date:** [September 24, 2024, 2:06pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/20 "2024-09-24T14:06:48Z")

</div>

Thanks guys for all the knowledge, @supershaneski really killed it with his answer about additional\_instructions.

Would you guys happen to know if the additional instructions are only considered in the run they are present? Or does the model have this in the thread for subsequent runs?

---

<div class="post-metadata">

**Author:** ![\_j](https://sea2.discourse-cdn.com/openai1/user_avatar/community.openai.com/_j/32/766292_2.png) [@\_j](https://community.openai.com/u/_j)\
**Post date:** [September 24, 2024, 2:48pm UTC](https://community.openai.com/t/system-messages-in-assistant-threads/834585/21 "2024-09-24T14:48:31Z")

</div>

> [@v4ames](#):
>
> additional instructions are only considered in the run they are present?

Additional\_instructions are a run parameter. They are treated like part of an assistants’ operation, adding to its internal system message for that run.

While they may affect an AI - and the past responses may confuse an AI if they are later changed or removed, the system messages are not part of a thread’s history of conversation.
