fix: ChatBubble crash and DeepSeek API compatibility

- Fix ChatBubble to handle non-string content with String() wrapper
- Fix API route to use generateText for non-streaming requests
- Add @ai-sdk/openai-compatible for non-OpenAI providers (DeepSeek, etc.)
- Use Chat Completions API instead of Responses API for compatible providers
- Update ChatBubble tests and fix component exports to kebab-case
- Remove stale PascalCase ChatBubble.tsx file
This commit is contained in:
Max
2026-01-26 16:55:05 +07:00
parent 6b113e0392
commit e9e6fadb1d
544 changed files with 113077 additions and 427 deletions

View File

@@ -0,0 +1,90 @@
{
"type": "excalidrawlib",
"version": 2,
"library": [
{
"id": "start-end-circle",
"status": "published",
"elements": [
{
"type": "ellipse",
"width": 120,
"height": 60,
"strokeColor": "#1976d2",
"backgroundColor": "#e3f2fd",
"fillStyle": "solid",
"strokeWidth": 2,
"roughness": 0
}
]
},
{
"id": "process-rectangle",
"status": "published",
"elements": [
{
"type": "rectangle",
"width": 160,
"height": 80,
"strokeColor": "#1976d2",
"backgroundColor": "#e3f2fd",
"fillStyle": "solid",
"strokeWidth": 2,
"roughness": 0,
"roundness": {
"type": 3,
"value": 8
}
}
]
},
{
"id": "decision-diamond",
"status": "published",
"elements": [
{
"type": "diamond",
"width": 140,
"height": 100,
"strokeColor": "#f57c00",
"backgroundColor": "#fff3e0",
"fillStyle": "solid",
"strokeWidth": 2,
"roughness": 0
}
]
},
{
"id": "data-store",
"status": "published",
"elements": [
{
"type": "rectangle",
"width": 140,
"height": 80,
"strokeColor": "#388e3c",
"backgroundColor": "#e8f5e9",
"fillStyle": "solid",
"strokeWidth": 2,
"roughness": 0
}
]
},
{
"id": "external-entity",
"status": "published",
"elements": [
{
"type": "rectangle",
"width": 120,
"height": 80,
"strokeColor": "#7b1fa2",
"backgroundColor": "#f3e5f5",
"fillStyle": "solid",
"strokeWidth": 3,
"roughness": 0
}
]
}
]
}