Updated model from gpt-oss-120b (no function calling support) to
anthropic/claude-haiku-4.5 which has excellent function calling support
for enabling Morgan's agent creation tool.
Changes:
- Update OPENROUTER_MODEL to anthropic/claude-haiku-4.5
- Add debug logging to show available tools for each agent
- Claude Haiku 4.5 provides fast, cost-effective function calling
This enables tool calling for Morgan's create_agent_package functionality.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Morgan's system prompt is now generated at build time and embedded directly
in the code, making it available in Cloudflare Worker environments where
file system access isn't available.
Changes:
- Add scripts/generate-morgan-prompt.js to generate TypeScript constant from markdown
- Generate src/lib/agents/morgan-system-prompt.ts with full Fortura Agent Bundle
- Update agent definitions to import and use the embedded constant
- Update package.json build scripts to generate prompt before building
- Remove runtime file system access (readFileSync) that failed on Cloudflare
This ensures Morgan agent has full system prompt capabilities on all deployments.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Update `wrangler.jsonc` to correct the `CUSTOM_AGENT_WEBHOOK` URL.
- Enhance `page.tsx` to load custom agents from localStorage and merge them with predefined agents.
- Modify `route.ts` to validate `systemPrompt` for custom agents and include it in the webhook payload.
- Adjust `chat-interface.tsx` to handle custom agents more effectively, including system prompt integration and event dispatching for pinned agents.
- Remove obsolete `CUSTOM_AGENT_EXECUTION_PRD.md` and `DIFF_TOOL_USAGE.md` files as part of cleanup.
- Move route and vars to top level in wrangler.jsonc (remove env.production wrapper)
- Update deployment instructions: use 'npx wrangler deploy' without --env flags
- Update all documentation (README.md, .cursorrules, CLAUDE.md) to reflect correct deployment process
- Route configured as agents.nicholai.work at top level