feat: update Makelore modules and conversations
This commit is contained in:
@@ -28,6 +28,25 @@ describe('opencode message normalization', () => {
|
||||
}));
|
||||
});
|
||||
|
||||
it('normalizes provider reasoning, reasoning_content, and reasoning_text aliases', () => {
|
||||
const messages = normalizeOpencodeSessionMessages([{
|
||||
id: 'msg_reasoning_aliases',
|
||||
role: 'assistant',
|
||||
reasoning: 'first',
|
||||
reasoning_content: 'second',
|
||||
content: [
|
||||
{ type: 'reasoning', reasoning_text: 'third' },
|
||||
{ type: 'text', text: 'answer' },
|
||||
],
|
||||
}]);
|
||||
|
||||
expect(messages[0]?.content).toEqual([
|
||||
{ type: 'thinking', thinking: 'first' },
|
||||
{ type: 'thinking', thinking: 'third' },
|
||||
{ type: 'text', text: 'answer' },
|
||||
]);
|
||||
});
|
||||
|
||||
it('surfaces a completed assistant message with no visible content as an error', () => {
|
||||
const messages = normalizeOpencodeSessionMessages([
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user