[FEATURE] Bedrock Knowledge Base Retrieve API should return citation-compatible content for Converse API
Problem
Bedrock Converse API supports native citations when DocumentBlock objects are present in conversation context. However, the Bedrock Knowledge Base Retrieve API returns plain text chunks — not DocumentBlock objects. This means agents using KB retrieval cannot leverage native citations without significant workarounds.
Current behavior
KB Retrieve API → { text: "chunk of text", score: 0.85, location: { s3Location: { uri: "s3://..." } } }
The response contains:
content.text — plain string (the retrieved chunk)
location.s3Location.uri — source document URI
score — relevance score
Desired behavior
The Retrieve API should offer an option to return results in a format compatible with Bedrock Converse API citations, e.g.:
KB Retrieve API → { documentBlock: { source: { bytes: <...> }, name: "doc.pdf", format: "pdf" }, ... }
Or at minimum, return enough structured metadata (document name, page/section, byte range) that an SDK or agent framework can construct DocumentBlock objects without fetching the full source document from S3.
Workaround today
- Call KB Retrieve to get text chunks + S3 URIs
- Fetch the full source document from S3 (
GetObject)
- Construct
DocumentBlock with the document bytes
- Return from tool → Bedrock Converse generates native citations
This is impractical at scale because:
- Full document fetch on every query (50+ page PDFs)
- Loses chunk-level granularity — Bedrock cites the whole doc, not the specific passage
- Latency and cost increase significantly
Context
Impact
This is the missing link between two flagship Bedrock features — Knowledge Bases and native citations. Today, any agent using KB retrieval must either:
- Use prompt-based citations (LLM formats
[1] DocName — "excerpt", parsed client-side) — works but fragile
- Fetch full documents from S3 on every query — works but impractical
A first-party solution from the KB Retrieve API would unblock native citations for the entire Bedrock agent ecosystem.
[FEATURE] Bedrock Knowledge Base Retrieve API should return citation-compatible content for Converse API
Problem
Bedrock Converse API supports native citations when
DocumentBlockobjects are present in conversation context. However, the Bedrock Knowledge BaseRetrieveAPI returns plain text chunks — notDocumentBlockobjects. This means agents using KB retrieval cannot leverage native citations without significant workarounds.Current behavior
The response contains:
content.text— plain string (the retrieved chunk)location.s3Location.uri— source document URIscore— relevance scoreDesired behavior
The Retrieve API should offer an option to return results in a format compatible with Bedrock Converse API citations, e.g.:
Or at minimum, return enough structured metadata (document name, page/section, byte range) that an SDK or agent framework can construct
DocumentBlockobjects without fetching the full source document from S3.Workaround today
GetObject)DocumentBlockwith the document bytesThis is impractical at scale because:
Context
DocumentBlock✅DocumentBlockin tool results (PR feat: support documentblock, imageblock, videoblock in model providers that support it strands-agents/sdk-typescript#576) ✅Impact
This is the missing link between two flagship Bedrock features — Knowledge Bases and native citations. Today, any agent using KB retrieval must either:
[1] DocName — "excerpt", parsed client-side) — works but fragileA first-party solution from the KB Retrieve API would unblock native citations for the entire Bedrock agent ecosystem.