-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Problem
When building the AI Chat page for the showcase app, the subagent made 3 API mistakes despite having the skill references available:
Bug 1: Wrong parameter name for createConversation
// ❌ What was written
base44.agents.createConversation({ agentName: 'showcase_assistant' })
// ✅ Correct
base44.agents.createConversation({ agent_name: 'showcase_assistant' })Bug 2: Wrong subscribeToConversation signature
// ❌ What was written
base44.agents.subscribeToConversation({
conversationId: conversation.id,
onMessage: (message) => { ... }
})
// ✅ Correct
base44.agents.subscribeToConversation(conversation.id, (updatedConversation) => { ... })Bug 3: Wrong addMessage signature
// ❌ What was written
base44.agents.addMessage({ conversationId, message: input })
// ✅ Correct
base44.agents.addMessage(conversation, { role: 'user', content: input })Analysis
Looking at the base44-agents.md reference in the skill, the correct signatures ARE documented:
createConversation(params)with example showingagent_namesubscribeToConversation(id, onUpdate?)with positional paramsaddMessage(conversation, message)with conversation object + message object
So the docs are correct, but the agent still hallucinated different patterns. This suggests:
-
The WRONG vs CORRECT table pattern used for other modules (auth, entities, integrations, functions) is missing for agents. The agents module doesn't have an explicit "don't hallucinate" table like the others do in SKILL.md.
-
Adding a WRONG vs CORRECT table for agents in the main SKILL.md (like exists for auth, functions, integrations, entities) would likely prevent these mistakes.
Suggested Fix
Add to the SKILL.md ⚠️ CRITICAL: Do Not Hallucinate APIs section:
### Agents - WRONG vs CORRECT
| ❌ WRONG (hallucinated) | ✅ CORRECT |
|------------------------|-----------|
| \`createConversation({ agentName })\` | \`createConversation({ agent_name })\` |
| \`subscribeToConversation({ conversationId, onMessage })\` | \`subscribeToConversation(id, onUpdateCallback)\` |
| \`addMessage({ conversationId, message })\` | \`addMessage(conversation, { role, content })\` |
| \`getConversation({ id })\` | \`getConversation(id)\` |Origin
All 3 bugs found during QA of the Base44 showcase app's AI Chat page.