iii-core-primitives
Qué hace
Explica los bloques básicos de iii: funciones, disparadores y workers, y cómo registrar cada uno. Es para desarrolladores que escriben código para un sistema iii en TypeScript, Python o Rust.
Cuándo usarla
- ✓Cuando necesitas registrar una función nueva o vincularle un disparador.
- ✓Cuando quieres que una función se ejecute después de que se llame a otra función.
- ✓Cuando quieres ver qué workers y funciones están conectados en este momento.
Link de la skill
https://github.com/iii-hq/iii/blob/main/skills/iii-core-primitives/SKILL.mdCópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.
Cómo usar
La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.
Mensaje listo para pegar
Para Claude Code, Codex o Cursor: ejecútalo en la carpeta del proyecto y la skill queda instalada.
Descarga el SKILL.md y ponlo en la carpeta de skills de tu agente.
Ejemplo de qué pedirle a la IA
“Registra en TypeScript una función llamada orders::validate y haz que se ejecute cada vez que llegue un pedido nuevo.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
La skill muestra cómo registrar una función con un manejador y vincularla a una fuente de eventos, como un calendario o una cola. También cubre los observadores, que ejecutan una función objetivo después de que se invoque otra, y cómo llamar a funciones directamente o en segundo plano.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
Core Primitives
iii has three top-level primitives:
- Function: a named unit of work such as
orders::validate - Trigger: an event source bound to a function
- Worker: a process that connects to the engine and executes functions
Since 0.25 every function is also observable: iii.observe(source, target) invokes target
on each invocation of source that passes its filters. Observers replace trigger bindings over
time; the built-in providers (http, cron, queue, state, stream, pub/sub, database) still
use trigger types in 0.25, so keep registerTrigger for them. See iii-observe.
Use :: in function IDs, leading slashes in HTTP api_path, and expression for cron config.
Function Registration
Register local handlers when you control the implementation. Register HTTP-invoked functions when iii should call an existing external endpoint.
| Shape | Use for |
|---|---|
registerFunction(id, handler, options?) |
Local worker code |
registerFunction(id, HttpInvocationConfig, options?) |
Existing HTTP services |
registerTrigger({ type, function_id, config, metadata? }) |
Binding a built-in event source (deprecated in 0.25, still required for providers that have not migrated) |
observe({ function_id, args?, filters? }, target, options?) |
Running target after another function's invocations, or on an engine event (iii-observe) |
trigger({ function_id, payload, action?, timeout? }) |
Calling any function by ID |
Functions and triggers can carry metadata for ownership, discovery, and generated skills. Do not put secrets in metadata.
Workers and Registry
A worker is any process that connects to the engine and registers functions or trigger types. There are two common paths:
| Task | Use |
|---|---|
| Create your own worker | Write SDK code that calls registerWorker, registerFunction, and registerTrigger or observe |
| Add an existing capability | Browse https://workers.iii.dev/, then call compose::add worker=<name> |
| Pin a worker version | compose::add worker=<name>@<version> |
| Declare a local worker | Add worker: path://./workers/my-worker under containers: |
| Reproduce a project | Commit the exact versions in worker-compose.yaml |
The public worker registry at workers.iii.dev is for installable workers such as HTTP, state,
queue, pub/sub, cron, database, shell, console, rbac-proxy, and other capability workers.
(iii-sandbox and iii-observability are engine-owned and are not added through the registry.) Those workers may ship their own function-level skills; do not duplicate every capability
as a top-level iii skill.
Worker Manifest
Use iii.worker.yaml when iii should start a local worker project:
name: math-worker
runtime:
kind: python
package_manager: pip
entry: math_worker.py
scripts:
install: "pip install -r requirements.txt"
start: "python math_worker.py"
The manifest describes how to start the process. Once running, the WebSocket connection and function registrations are what make the worker part of iii.
Live Engine Registry
The engine keeps a live registry of connected workers, registered functions, triggers, and trigger types. Read it through the built-in discovery functions:
| Function | Returns |
|---|---|
engine::workers::list |
Connected workers and metrics |
engine::functions::list |
Registered functions |
engine::triggers::list |
Registered triggers |
engine::trigger-types::list |
Advertised trigger types and schemas |
engine::observers::list |
Observers you may see (function_id, namespace, worker filters) |
For topology changes, observe the engine-hosted sources engine::on-workers-changed or
engine::on-functions-changed with deliver: 'input' (see iii-observe). The older
engine::workers-available and engine::functions-available trigger types still fire.
Built-In Trigger Shapes
The workers behind these types have not moved to source functions in 0.25, so bind them with
registerTrigger. Each call logs a one-time deprecation warning per process; it is informational
and the binding works as before. For log, the engine also hosts the observability::on-log
source (iii-observe).
| Trigger type | Registration config | Handler payload |
|---|---|---|
http |
{ api_path: "/orders/:id", http_method: "POST" } |
{ query_params, path_params, headers, path, method, body } |
cron |
`{ expression: "0 0 9 * * * |
Preguntas frecuentes
¿Qué es un observador?
Un observador ejecuta una función objetivo después de cada llamada a otra función, sin cambiar esa función.
¿Qué formato usan los ID de función?
Usan dobles dos puntos, como orders::validate.
¿Puede instalar workers desde un registro?
Sí. La skill cubre la instalación de workers desde el registro público.
Detalles
Descripción original del autor
Use when registering iii functions, binding triggers, observing functions, selecting sync/void/enqueue invocation, creating workers, inspecting the live worker registry, installing registry workers, authoring event sources, moving channel data, or adapting external HTTP functions across TypeScript, Python, and Rust.
repo: iii-hq/iii
Popularidad
- Estrellas en GitHub
- 19 mil
- Posición en el ranking
- #10492
- Licencia
- —
- Actualizada
- 2/11/2026
Comentarios
- …
Más skills de este repositorio
iii-sandbox
19 milAyuda a tu agente a ejecutar código no fiable o generado por IA de forma segura dentro de una máquina virtual aislada y temporal, y descartarla al terminar.
configuration
19 milPermite que tu agente configure un registro compartido de valores de configuración con nombre, validados contra un esquema, para que los workers puedan leer los cambios y reaccionar a ellos.
iii
19 milEnseña a tu agente cómo funcionan los workers de iii, para que pueda añadir una capacidad comprobando primero lo que ya existe y después construyendo un worker.
iii-observability
19 milAyuda a tu agente a añadir trazado, registros estructurados, métricas y alertas a un motor iii, usando OpenTelemetry para que puedas ver lo que está pasando.
Skills parecidas
diffs
394 milPermite que tu agente genere un diff real y compartible de los cambios, como enlace de visualización o archivo de imagen, en lugar de un resumen escrito a mano.
coding-agent
394 milAyuda a tu agente a pasar un trabajo de programación grande a Codex, Claude Code u OpenCode como trabajador en segundo plano, y después revisar su progreso.
gh-issues
394 milAyuda a tu agente a encontrar incidencias de GitHub, elegir cuáles trabajar y abrir pull requests con correcciones, incluido el seguimiento de los comentarios de revisión.