Motivation
Akka Agents currently provide memory managed by Akka. This works well for preserving application-level conversation state, but for every LLM interaction the relevant history still needs to be sent back to the model provider.
Some LLM providers support provider-managed conversation state. For example, the OpenAI Responses API supports resuming from a previous response by passing previous_response_id, allowing a new request to continue from a response already stored by the provider instead of resending the full conversation payload.
Example OpenAI request:
{ "previous_response_id": "resp_abc123", "input": "New message that resumes from response ID 'resp_abc123'"}
Supporting that feature in Akka agents would help optimize some use-cases.
Use-case example:
Processing PDF a document through multiple Akka Agents.
For example an OCR followed by Data extraction steps, the agents start a new OpenAI conversation for each step.
Each conversation rebuilds the full context from scratch, including a large set of page images and OCR text.
Drawbacks:
- We upload the same images to OpenAI multiple times, which adds unnecessary network latency.
- We lose the opportunity to benefit from remote model caching, which could reduce both latency and cost.
Use-case, with remote checkpoint
With remote checkpoint, the process becomes:
- We first create a conversation that builds the document context. In the use-case illustrated above, that context includes the page images and the OCR text.
- For later LLM calls on the same document, we resume from that response checkpoint instead of sending the full context again.
- As a result, we only send the new request plus
previous_response_id, rather than resending the images and OCR payload.
Proposal idea:
From an Akka agent, we need a way to pass previous_response_id to the OpenAI Responses API.
// Agent.java
return effects()
.model(modelProvider)
// Resume from a remote OpenAI checkpoint, not from agent session memory.
.resumeFromProviderCheckpoint(checkpointId)
Motivation
Akka Agents currently provide memory managed by Akka. This works well for preserving application-level conversation state, but for every LLM interaction the relevant history still needs to be sent back to the model provider.
Some LLM providers support provider-managed conversation state. For example, the OpenAI Responses API supports resuming from a previous response by passing previous_response_id, allowing a new request to continue from a response already stored by the provider instead of resending the full conversation payload.
Example OpenAI request:
{ "previous_response_id": "resp_abc123", "input": "New message that resumes from response ID 'resp_abc123'"}Supporting that feature in Akka agents would help optimize some use-cases.
Use-case example:
Processing PDF a document through multiple Akka Agents.
For example an OCR followed by Data extraction steps, the agents start a new OpenAI conversation for each step.
Each conversation rebuilds the full context from scratch, including a large set of page images and OCR text.
Drawbacks:
Use-case, with remote checkpoint
With remote checkpoint, the process becomes:
previous_response_id, rather than resending the images and OCR payload.Proposal idea:
From an Akka agent, we need a way to pass
previous_response_idto the OpenAI Responses API.