Load skills into agent context at startup for instant availability
Skill preloading injects full skill content into agent context when the agent starts. This gives agents domain-specific knowledge without requiring invocation or context loading during execution.
Agent System Prompt:[Agent instructions from AGENT.md]---Preloaded Skills:# Skill: pro-workflow[Full content of skills/pro-workflow/SKILL.md]---# Skill: api-conventions[Full content of skills/api-conventions/SKILL.md]---
---name: project-patternsdescription: Common patterns in this codebase---# Project Patterns## File Organization- `src/routes/` — API endpoints- `src/services/` — Business logic- `src/db/` — Database queries## API Endpoint Pattern```typescriptexport async function handler(req: Request, res: Response) { const validation = validateInput(req.body); if (!validation.success) { return res.status(400).json({ error: validation.error }); } const result = await service.execute(validation.data); return res.status(200).json(result);}
Now when planner creates plans, it knows:- Where to place files- How to structure endpoints- Validation patterns to use### Orchestrator with Multiple Skills```yaml---name: orchestratortools: ["Read", "Glob", "Grep", "Bash", "Edit", "Write"]skills: - "pro-workflow" - "project-patterns" - "testing-strategy"model: opusmemory: project---# OrchestratorMulti-phase development with Pro Workflow patterns, project structure knowledge, and testing strategy.
Orchestrator starts with:
pro-workflow — Research > Plan > Implement workflow
project-patterns — File organization and code patterns
When you are implementing an API endpoint, it is very important to remember that you should always validate the user input before you process it, because if you don't validate the input, the user might send invalid data and cause errors in your application.
## Error HandlingOur application uses custom error classes that extend the base Error class. Each error has a code property and a statusCode property. The code is a string identifier like 'NOT_FOUND' and the statusCode is the HTTP status code to return, like 404.