Allow file references and contents in chat history as well
To upvote this issue, give it a thumbs up. See this list for the most upvoted issues.
- I will send a message with file content in system message and prompt will contain the identical path.
- The LLM will know that the system message contains it
- I will remove it from the context for the 3 next messages
- Then i will ask it about something regarding that file again and i won’t add it to the context
- It will use the tool to read the file
If it would be just in the history then it wouldn’t have to read the file again…
In this ticket, we will also look at how to use attached files so that their content is not sent to the system prompt and LLM does not subsequently read them right again with a tool, which is unnecessary.
Summary We will implement two distinct behaviors for the @ symbol:
@ above the prompt: Appends content to the system prompt (for instructions, rules, etc.).
@ inside the prompt: Injects file content into the current user prompt for one-time context.
Re-discussion update:
Summary We will implement two distinct behaviors for contexts improvements:
@ context-area: Appends context content to the system prompt (for instructions, rules, etc.), this field is not stored in chat history, it's sent every prompt to LLM together with ECA instructions (we already do that)
# inside the prompt: Injects context identifier (ex: abs file path) only into the current user prompt, saved in chat history messages.
Optional: In the future we may allow users type @ in prompt as well to fill context content in prompt or just add to context area like we do ATM
Done, available in 0.68.0