2 Answers
- Newest
- Most votes
- Most comments
1
I don't believe you can ever ensure the same answer from an LLM as they are not giving canned responses, but rather doing mathematical calculations based on probability of next words based on weights of the association of words in training data.
Here is an article on the topic: https://cset.georgetown.edu/article/the-surprising-power-of-next-word-prediction-large-language-models-explained-part-1/#:~:text=When%20an%20LLM%20receives%20a,picked%20to%20continue%20the%20text.
Hope this helps!
1
Hi,
See this interesting discussion thread on why LLM completions are different even with temperature = 0
https://community.openai.com/t/a-question-on-determinism/8185/8
Best Didier
Relevant content
- asked 9 months ago

To the original poster, it is possible to implement a cache that enforces returning a consistent response after the first time a prompt is submitted, but that would be up to you to architect and implement. Bedrock doesn't provide response caching on its own.