deepseek-ai/deepseek-harness · error · LlmError
UNSUPPORTED_CONTENT
UNSUPPORTED_CONTENT
Error message
pi-ai chat history cannot represent structured assistant image output
What it means
Error "pi-ai chat history cannot represent structured assistant image output" thrown in deepseek-ai/deepseek-harness.
Source
Thrown at packages/llm/llm-pi-ai/src/replay.ts:158
}
}
/** Convert provider-neutral blocks without trusting them as same-model replay. */
function foreignAssistant(message: Message): AssistantMessage {
const source = message.source.kind === 'model' ? message.source : undefined
const content: AssistantMessage['content'] = []
for (const block of message.content) {
switch (block.type) {
case 'text': content.push({ type: 'text', text: block.text }); break
case 'reasoning': content.push({ type: 'thinking', thinking: block.text }); break
case 'tool-call': content.push({
type: 'toolCall',
id: block.id,
name: block.name,
arguments: parseArguments(block.arguments),
}); break
case 'image':
throw new LlmError('pi-ai chat history cannot represent structured assistant image output', 'UNSUPPORTED_CONTENT')
default:
// plugin-added block types are not representable in pi-ai.
break
}
}
return {
role: 'assistant',
content,
// Deliberately never equals a catalog API: absent replay state is foreign
// even if source names the same provider/model as this request.
api: 'dsh-foreign',
provider: source?.provider ?? 'dsh-foreign',
model: source?.model ?? 'dsh-foreign',
usage: emptyPiUsage(),
stopReason: content.some(piece => piece.type === 'toolCall') ? 'toolUse' : 'stop',
timestamp: 0,
}
}View on GitHub (pinned to b150a551b8)
Solutions
- Remove structured assistant image output from the chat history before replay.
When it happens
Trigger: Thrown at packages/llm/llm-pi-ai/src/replay.ts:158 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of deepseek-ai/deepseek-harness@b150a551b8 (2026-08-24).
Data as JSON: /api/errors/dff9df7343c8ab3b.
Report an issue: GitHub.