Architecture
Skill Types
1. Core Skills
Purpose: Built-in tools registered at agent startup. Implementation:Agent.ts (lines 908-2500+) — registerInternalSkills()
Registration:
| Category | Skills | Description |
|---|---|---|
| Research | web_search, browser_navigate, http_fetch, extract_article, download_file | Web browsing and data retrieval |
| Communication | send_telegram, send_whatsapp, send_discord, send_slack, send_email | Multi-channel messaging |
| Telegram Rich UI | telegram_send_buttons, telegram_send_poll, telegram_react, telegram_edit_message, telegram_pin_message | Interactive Telegram features |
| File Operations | read_file, write_file, send_file, send_voice_note | File I/O and delivery |
| System | run_command, get_system_info, system_check | Shell execution and diagnostics |
| Memory | recall_memory, update_user_profile, update_learning, update_journal | Long-term storage |
| RAG | rag_ingest, rag_search, rag_ingest_url, rag_list, rag_delete | Knowledge store operations |
| Orchestration | schedule_task, heartbeat_schedule, spawn_agent, delegate_task | Task scheduling and multi-agent |
| Configuration | manage_config | Runtime config modification |
| Reasoning | deep_reason, request_supporting_data | Extended reasoning and clarification |
| Skills Meta | manage_skills, create_custom_skill, self_repair_skill | Skill lifecycle |
2. Dynamic Plugins
Purpose: Hot-reloadable TypeScript/JavaScript files for custom skills. Location:~/.orcbot/plugins/*.ts or ./plugins/*.ts
Format:
3. Agent Skills (SKILL.md)
Purpose: Declarative skill packages following the agentskills.io spec. Location:~/.orcbot/plugins/skills/*/SKILL.md
Format:
Error Handling
- If the page is protected by CAPTCHA, inform the user
- If selectors fail, try alternative patterns (XPath, data attributes)
- If rate-limited, suggest adding delays between requests
Skill Interface
Metadata Flags
isResearch:- Higher tool repetition budget (10 vs. 5)
- Used for: web_search, browser_navigate, http_fetch
- Prevents premature loop detection during research
- Subject to strict deduplication
- Used for: send_telegram, send_whatsapp, write_file
- Prevents duplicate messages/writes
- Resets transparency nudge timer
- Counts as “substantive progress”
- Used for: web_search, browser_navigate, run_command, deep_reason
- Tells termination review: “real work was done”
- Requires explicit confirmation in autonomy mode
- Used for: run_command, delete_file, install_npm_dependency
- Blocks execution if user approval not granted
- Requires admin privileges
- Filtered out for non-admin tasks
- Used for: run_command, write_file, manage_config, browser_navigate
- Can be executed in parallel with other parallel-safe tools
- Used for: read_file, http_fetch (read-only operations)
- Enables concurrent execution in multi-agent scenarios
Skill Execution Flow
Tool Definitions (Native Tool Calling)
For LLMs that support native function calling (OpenAI, Google), SkillsManager generates JSON schemas:Skill Context (AgentContext)
All skill handlers receive a context object:Prompt Injection
Compact mode (after step 1):Skill Discovery
List all skills:Creating Skills
Option 1: Core Skill (Hardcoded)
EditAgent.ts and register:
Option 2: Dynamic Plugin
Create~/.orcbot/plugins/my-skill.ts:
Option 3: Agent Skill (SKILL.md)
Create directory structure:SKILL.md:
Option 4: Self-Generated Plugin (create_custom_skill)
Ask the agent:Self-Repair
When a plugin fails to load (syntax error, missing dependency), OrcBot auto-triggers repair:self_repair_skill handler:
- Reads the broken plugin file
- Analyzes the error (syntax, type, import)
- Calls LLM to generate a fix
- Writes corrected code
- Reloads plugins
- Validates the fix
Skill Validation
For Agent Skills (SKILL.md), OrcBot validates against the spec:- Name: lowercase, alphanumeric + hyphens, no consecutive hyphens, 1-64 chars
- Description: 10-1024 chars
- Compatibility: 500 chars max
- Body: < 500 lines (warning only, large skills are valid)
Parallel Execution
Skills markedisParallelSafe: true can run concurrently:
- write_file (race conditions)
- send_telegram (message ordering)
- run_command (shared stdout)
Configuration
Further Reading
- Agent Loop — How skills are executed
- Decision Pipeline — Skill validation and guardrails
- Architecture — Overall system design
- Agent Skills Spec — SKILL.md format specification