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,109 @@
---
name: 'step-02-structure'
description: 'Create directory structure based on module type'
nextStepFile: './step-03-config.md'
moduleStandardsFile: '../../data/module-standards.md'
buildTrackingFile: '{bmb_creations_output_folder}/modules/module-build-{module_code}.md'
---
# Step 2: Directory Structure
## STEP GOAL:
Create the module directory structure based on the module type (Standalone/Extension/Global).
## MANDATORY EXECUTION RULES:
### Universal Rules:
- 🛑 NEVER generate content without user input
- 📖 CRITICAL: Read the complete step file before taking any action
- 🔄 CRITICAL: When loading next with 'C', ensure entire file is read
- 📋 YOU ARE A FACILITATOR, not a content generator
- ✅ Speak in `{communication_language}`
### Role Reinforcement:
- ✅ You are the **Module Builder** — creating the foundation
- ✅ Structure follows standards
- ✅ Confirm before creating
---
## MANDATORY SEQUENCE
### 1. Determine Target Location
Load `{moduleStandardsFile}` and determine location:
**IF Standalone:**
- Target: `src/modules/{module_code}/`
**IF Extension:**
- Target: `src/modules/{base_module_code}/extensions/{extension_folder_name}/`
- Get base_module_code from brief
- extension_folder_name: unique name (e.g., `{base_module}-{feature}`)
**IF Global:**
- Target: `src/modules/{module_code}/`
- Will add `global: true` to module.yaml
### 2. Present Structure Plan
"**I'll create this directory structure:**"
```
{target_location}/
├── module.yaml
├── README.md
├── agents/
│ └── {agent files}
├── workflows/
│ └── {workflow folders}
└── _module-installer/
├── installer.js
└── platform-specifics/
```
"**Location:** {target_location}"
"**Module type:** {Standalone/Extension/Global}"
### 3. Confirm and Create
"**Shall I create the directory structure?**"
**IF confirmed:**
Create folders:
- `{target_location}/agents/`
- `{target_location}/workflows/`
- `{target_location}/_module-installer/`
- `{target_location}/_module-installer/platform-specifics/`
### 4. Update Build Tracking
Update `{buildTrackingFile}`:
- Add 'step-02-structure' to stepsCompleted
- Set targetLocation
- Update status
### 5. Report Success
"**✓ Directory structure created at:** {target_location}"
### 6. MENU OPTIONS
**Select an Option:** [C] Continue
- IF C: Update tracking, load `{nextStepFile}`
- IF Any other: Help, then redisplay menu
---
## Success Metrics
✅ Directory structure created
✅ Location based on module type
✅ Folders: agents/, workflows/, _module-installer/
✅ Build tracking updated