SmythOS Runtime Environment is an open-source runtime and software development kit for building and running AI agents. Developers use it to create, orchestrate, and manage agents across local, cloud, and edge environments, with abstractions for language models, vector databases, storage, and caching. The catalogue add-ons support work with this runtime.
Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/smythos/sre/04-worker-modegit clone --depth 1 https://github.com/SmythOS/sreWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/smythos/sre/04-worker-mode)<a href="https://agentmods.dev/agents/smythos/sre/04-worker-mode"><img src="https://agentmods.dev/badge/agents/smythos/sre/04-worker-mode.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.02561 |
| Opus 5 | $0.00000 | $0.01281 |
| Sonnet 5 | $0.00000 | $0.00512 |
| Haiku 4.5 | $0.00000 | $0.00256 |
Grade A, and why
04-worker-mode scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 317 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Worker Mode
Worker mode allows an agent to dispatch complex, long-running tasks to background "copy" agents while the main agent stays fully interactive. When a worker finishes, its result is automatically surfaced back to the user through the main agent's conversation.
This mode is ideal when users submit tasks that take a while (research, code generation, multi-step analysis) and you want them to continue chatting or submit more tasks without blocking.
See the Worker Mode Example for a complete, runnable implementation.
Enabling Worker Mode
import { Agent, TAgentMode } from '@smythos/sdk';
const agent = new Agent({
name: 'Research Assistant',
behavior: 'You are a research assistant capable of handling complex tasks.',
model: 'gpt-4o',
mode: TAgentMode.WORKER,
});
How It Works
Task Dispatching
When the user asks for something complex, the main agent's LLM evaluates the request:
- Simple tasks (quick questions, math, lookups): The agent answers directly — no worker needed.
- Complex tasks (research, analysis, code generation): The agent dispatches the task to a background worker via the internal
_sre_Worker_Dispatchskill.
The main agent immediately confirms the dispatch and remains available for new prompts.
Copy Agents
Each worker is a "copy" of the main agent — it shares the same skills and model but runs independently in its own chat session. The copy agent:
- Preserves the original agent behavior (system prompt) defined by the developer
- Gets all of the main agent's skills (except internal
_sre_*skills) - Receives additional instructions appended to the behavior, telling it to use
<worker_result>and<worker_question>tags for communication - Has no awareness of the main conversation — it only knows its assigned task
Worker Communication
Workers communicate back to the main agent through two tag-based protocols:
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 317 lines · 0 tokens per session scan A a448d79dea98
04-worker-mode is an agent published in the GitHub repository SmythOS/sre (1,289 stars, last pushed 5mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,561 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other agents, from other repositories
memory
LangGraph supports two types of memory essential for building conversational agents.
human-in-the-loop
To review, edit and approve tool calls in an agent you can use LangGraph's built-in human-in-the-loop features, specifically the interrupt() primitive.
streaming
Streaming is key to building responsive applications. There are a few types of data you’ll want to stream.
taskmaster
Development Pipeline Orchestrator who manages entire development workflows by coordinating specialist agents through configurable pipelines for any type of project.
codecrusher
Senior Developer & Implementation Expert who transforms architectural plans into high-quality, production-ready code across any technology stack.
ship-and-babysit
Commit local changes, push the branch to the user's fork, open or reuse a PR against tinyhumansai/openhuman:main, then babysit CI and CodeRabbit feedback until the PR is green and clean. Use when the user wants an end-to-end ship flow, not just implementation.