spring-projects / spring-projects/spring-ai
Conversion Activation Error (Aggregation Error org.springframework.web.reactive.function.client.WebClientResponseException: 413 Payload Too Large from POST https://api.groq.com/openai/v1/chat/completions)
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 9.5k
- Forks
- 2.9k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 6
Description
I’m currently working on activating conversation features in my Spring AI application but encountered a significant error. When I attempt to enable conversation functionality using ChatMemory, I receive the following error:
"*2024-11-05T10:57:17.441+01:00 ERROR 44072 --- [Bip.it] [oundedElastic-4] o.s.ai.chat.model.MessageAggregator : Aggregation Error
org.springframework.web.reactive.function.client.WebClientResponseException: 413 Payload Too Large from POST https://api.groq.com/openai/v1/chat/completions*"
This issue arises when I include the following code in RagService:
public RagService(ChatClient.Builder chatBuilder, VectorStore vectorStore) {
ChatMemory chatMemory = new InMemoryChatMemory();
this.chatClient = chatBuilder
.defaultAdvisors(
new MessageChatMemoryAdvisor(chatMemory),
new QuestionAnswerAdvisor(vectorStore),
new SimpleLoggerAdvisor())
.build();
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in RagService, where ChatMemory, MessageChatMemoryAdvisor, QuestionAnswerAdvisor, and SimpleLoggerAdvisor are added to the ChatClient. Reproduce the conversation request against the Groq chat-completions endpoint and inspect how the request grows when memory and retrieval are enabled. Done means identifying the source of the 413 Payload Too Large error and documenting or verifying the appropriate correction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, spring
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100