← 返回 Skills 市场
scottgl9

skelm

作者 Scott Glover · GitHub ↗ · v0.3.8 · MIT-0
cross-platform ✓ 安全检测通过
55
总下载
0
收藏
0
当前安装
2
版本数
在 OpenClaw 中安装
/install skelm
功能描述
Author, run, and operate skelm pipelines — typed TypeScript orchestrations that mix deterministic code, LLM inference, and full agent loops behind a default-...
使用说明 (SKILL.md)

skelm

Build secure, agentic, long-running workflows in TypeScript. Run them anywhere Node runs.

npm license


Why skelm exists

Most LLM workflow tools make security an afterthought. Agents call arbitrary tools, read arbitrary files, hit arbitrary URLs — because the framework has no model for preventing it. When something goes wrong (prompt injection, runaway loops, accidental secret exfiltration), you find out after the fact.

skelm is built the other way around. Every agent step starts with zero privileges. Filesystem roots, network hosts, MCP servers, CLI binaries, secrets — each is declared upfront in the step definition. Anything not declared is denied at dispatch, before the backend ever starts. The audit log records every privileged action in a tamper-evident chain so you can always reconstruct what happened.

The rest of the design follows from that principle:

  • Real TypeScript. Workflows are .ts modules you type-check, refactor, test, and version like any other code. No DSL, no YAML, no JSON config.
  • Three step kinds, none wrapping another. code() for deterministic logic, llm() for single inference calls, agent() for full multi-turn loops. Mix them freely in a single pipeline.
  • Multi-backend agents. Opencode, ACP (Copilot, Claude Code, Gemini), OpenAI, Anthropic, Pi — plus a provider SPI for custom backends. Switch backends by changing one config key.
  • First-class MCP support. MCP servers are lifecycle-managed by the gateway, not bolted on. Attach them per-step; the permission model governs which steps can reach which servers.
  • Native control flow. parallel, forEach, branch, loop, wait, and nested pipelines are core primitives.
  • Schedulable. Cron, interval, webhook, one-shot, and queue triggers. The gateway hosts everything long-running.
  • Tamper-evident audit. Hash-chained audit log. Query it with skelm audit query.

Get started in 60 seconds

# 1. Install the CLI
npm install -g skelm

# 2. Scaffold a project
skelm init my-bot && cd my-bot && npm install

# 3. Run your first workflow
skelm run workflows/hello.workflow.ts --input '{"name":"world"}'

# 4. Stand up the gateway (long-running, handles scheduling + agent steps)
skelm gateway start

When this skill activates

Use this skill when:

  • The user is working in a skelm project (any *.workflow.ts / *.pipeline.ts file)
  • The user wants to scaffold, author, or modify a pipeline
  • The user asks about AgentPermissions, skelm.config.ts, MCP wiring, backend setup
  • The user wants to run, inspect, schedule, or debug a pipeline
  • The user is migrating from another workflow tool (LangChain, Inngest, llm-task, lobster)

The unit of work

A pipeline is a TypeScript file that exports a pipeline() call:

import { code, llm, agent, pipeline } from 'skelm'
import { z } from 'zod'

export default pipeline({
  id: 'my-workflow',
  description: 'What this pipeline does.',
  input:  z.object({ task: z.string() }),
  output: z.object({ result: z.string() }),
  steps: [ /* Step[] */ ],
  finalize: (ctx) => ctx.steps['last-step'] as { result: string },
})

Step kinds: code · llm · agent · parallel · forEach · branch · loop · wait · pipelineStep · idempotent

Import everything from 'skelm'. Access prior step outputs via ctx.steps['step-id'].


Step kind quick reference

code() — deterministic logic

code({
  id: 'parse',
  run: (ctx) => ({ value: (ctx.input as { raw: string }).raw.trim() }),
})

llm() — single-shot inference

llm({
  id: 'classify',
  backend: 'openai',
  prompt: (ctx) => `Classify: ${(ctx.input as { text: string }).text}`,
  output: z.object({ label: z.string(), confidence: z.number() }),
  maxTokens: 512,
})

agent() — full agentic loop (default-deny)

agent({
  id: 'implement',
  backend: 'pi',
  prompt: (ctx) => `Implement ticket ${(ctx.input as { id: string }).id}. Return JSON {prUrl}.`,
  permissions: {
    allowedTools:       ['gh.*'],
    allowedExecutables: ['git'],
    allowedMcpServers:  ['github'],
    fsRead:             ['./'],
    fsWrite:            ['./src/'],
    networkEgress:      { allowHosts: ['api.github.com'] },
  },
  workspace: { mode: 'ephemeral', cleanup: 'on-run-end' },
  output: z.object({ prUrl: z.string() }),
  maxTurns: 20,
})

Default-deny: every AgentPermissions field defaults to deny when omitted. An agent with no permissions block cannot call tools, read files, execute binaries, attach MCP servers, or make network requests.


Permissions are part of the API

Dimension Field Default
Tool allowedTools / deniedTools deny
Executable allowedExecutables deny
MCP server allowedMcpServers deny
Skill allowedSkills deny
Secret allowedSecrets deny
Network networkEgress deny
FS read fsRead deny
FS write fsWrite deny
Approval gate approval

Composition is intersection-only. Project defaults → named profile → step-level. Each layer can only narrow, never widen.

Named profiles in skelm.config.ts:

defaults: {
  permissionProfiles: {
    'github-write': {
      allowedExecutables: ['git'],
      allowedTools:       ['gh.*'],
      allowedMcpServers:  ['github'],
      fsRead:             ['./'],
      fsWrite:            ['./'],
      networkEgress:      { allowHosts: ['api.github.com'] },
    },
  },
}

Apply: permissions: { profile: 'github-write', allowedTools: ['gh.create_pr'] }

Full permissions reference: {baseDir}/references/permissions.md


Project layout

my-project/
├── skelm.config.ts          # Required for gateway + agent steps
├── workflows/
│   └── hello.workflow.ts    # One pipeline per file
├── package.json             # { "dependencies": { "skelm": "^0.3.7", "zod": "^4" } }
└── tsconfig.json

Scaffold a new pipeline from template:

bash {baseDir}/scripts/new-pipeline.sh my-pipeline "What it does"
bash {baseDir}/scripts/new-pipeline.sh my-pipeline "What it does" --agent

Config reference: {baseDir}/references/config.md


CLI essentials

skelm run \x3Cworkflow.ts> --input '\x3Cjson>'   # run once
skelm list                                 # discover pipelines
skelm describe \x3Cid> --format mermaid       # visualize
skelm history --last 10                    # run history
skelm validate \x3Cworkflow.ts>               # static preflight
skelm logs                                 # stream gateway logs
skelm audit query --run \x3Cid>               # tamper-evident audit trail
skelm schedule add \x3Cid> --cron '0 * * * *' # schedule
skelm gateway start                        # long-running gateway

Exit codes: 0 ok · 1 CLI error · 2 schema validation · 3 run failed · 4 cancelled · 5 wait timeout · 6 permission denied · 7 step timeout

Full CLI reference: {baseDir}/references/cli.md


The gateway is the trust boundary

The gateway owns permission resolution, enforcement, secret resolution, audit log, approval gating, trigger dispatch, and registry management.

Never write permission enforcement in pipeline or step code. Pipelines are the user layer. The gateway is the trust layer.

skelm gateway start
skelm gateway status
skelm gateway install --systemd   # systemd unit at ~/.config/systemd/user/skelm-gateway.service

Gateway reference: {baseDir}/references/gateway.md


Common pitfalls

  • Widening at step levelnetworkEgress: 'allow' in a step when the project default is deny has no effect. Intersection always wins.
  • Missing Zod schemainput/output are validated at run boundaries; omitting them skips validation silently.
  • agent() with an unregistered backend — step fails at runtime if backend references an id with no matching entry in config backends: or instances:. The pi SDK backend must be in instances:.
  • Step id collisions inside parallel() — sibling ids must be unique within the parallel block.
  • Editing dist/ — never edit generated files. Run pnpm build to regenerate.

Full references

  • {baseDir}/references/pipeline-authoring.md — all builders, control flow, context shape, retry
  • {baseDir}/references/agent-step.mdagent() signature, backends, workspace modes, MCP
  • {baseDir}/references/permissions.md — full permission model, TrustEnforcer, testing
  • {baseDir}/references/config.mdskelm.config.ts shape, backends, MCP entries
  • {baseDir}/references/gateway.md — gateway lifecycle, HTTP surface, audit log, systemd
  • {baseDir}/references/cli.md — complete CLI reference with all flags and exit codes

skelm v0.3.7 · MIT · npm

安全使用建议
Install this only if you intend to use skelm to build or operate agentic workflows. Review generated TypeScript before running it, keep gateway access local or protected with bearer auth for remote use, grant agent permissions narrowly, avoid broad bash/filesystem/network access, and protect any provider API keys or skelm secrets.
功能分析
Type: OpenClaw Skill Name: skelm Version: 0.3.8 The skelm skill bundle provides a framework for authoring and orchestrating secure, agentic TypeScript workflows. The bundle consists of documentation, scaffolding scripts (new-pipeline.sh), and templates (skelm.config.template.ts) that align with its stated purpose of providing a 'default-deny' permission model for AI agents. While the skill requests broad Bash permissions for package managers and development tools, this is consistent with its role as a workflow engine, and the framework's design emphasizes security boundaries, audit logging, and human-in-the-loop approvals.
能力标签
requires-sensitive-credentials
能力评估
Purpose & Capability
The documented purpose—authoring, running, and operating skelm TypeScript pipelines—matches the templates, CLI references, gateway documentation, and permission model references.
Instruction Scope
The skill gives the agent file editing plus npm/pnpm/skelm/node/git command access, which is purpose-aligned for pipeline development but can materially affect the local project.
Install Mechanism
Installation uses a global npm package that creates the skelm binary. This is normal for a CLI skill, but users are trusting the npm package implementation, which is not included in the supplied artifacts.
Credentials
Templates and references emphasize default-deny permissions, ephemeral workspaces, localhost gateway binding, and network denial by default, but user-configured backends, MCP servers, filesystem grants, and secrets can expand authority.
Persistence & Privilege
Long-running gateway, scheduling, systemd installation, session persistence, and SQLite run/state storage are disclosed and purpose-aligned, but should be enabled intentionally.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install skelm
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /skelm 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.3.8
Set official gateway port to 14738 throughout source, docs, templates, and references.
v0.3.7
Initial release — typed TypeScript workflow framework with default-deny agent permissions, multi-backend support (OpenAI, Anthropic, pi, ACP, Opencode), MCP-native gateway, scheduling, and a tamper-evident audit log. Full reference docs included.
元数据
Slug skelm
版本 0.3.8
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 2
常见问题

skelm 是什么?

Author, run, and operate skelm pipelines — typed TypeScript orchestrations that mix deterministic code, LLM inference, and full agent loops behind a default-... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 55 次。

如何安装 skelm?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install skelm」即可一键安装,无需额外配置。

skelm 是免费的吗?

是的,skelm 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

skelm 支持哪些平台?

skelm 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 skelm?

由 Scott Glover(@scottgl9)开发并维护,当前版本 v0.3.8。

💬 留言讨论