OpenAI prompt contains user role and system role message, as example below:
message = [
{"role": "system", "content": " You are AI assistant to help answer question"},
{"role": "user", "content": "What is capital of USA?" }
]
But gptCache only consider and caches "user" role part.
If two messages have same "user" msg but different "system" msg, they will be considered the same item, and the cached
result will be used by both.
Expected Behavior
If two messages have same "user" msg but different "system" msg, they MUST not be considered the same cache item.
Current Behavior
OpenAI prompt contains user role and system role message, as example below: message = [ {"role": "system", "content": " You are AI assistant to help answer question"}, {"role": "user", "content": "What is capital of USA?" } ]
But gptCache only consider and caches "user" role part. If two messages have same "user" msg but different "system" msg, they will be considered the same item, and the cached result will be used by both.
Expected Behavior
If two messages have same "user" msg but different "system" msg, they MUST not be considered the same cache item.
Steps To Reproduce
No response
Environment
Anything else?
No response