Skip to main content

Skills Library - AI Tooling

@n8n-as-code/skills is an internal library in packages/skills. It is the source of truth for AI-facing tooling in this monorepo, but it is not the primary public entrypoint. Users and agents are expected to go through n8nac skills.

๐ŸŽฏ What This Package Actually Ownsโ€‹

The current package is responsible for four things:

  1. Exposing the full n8nac skills command group used by agents and developers.
  2. Providing programmatic services such as AiContextGenerator and node/documentation lookup.
  3. Generating AI context files such as AGENTS.md and editor snippets.
  4. Building Claude-specific adapter artifacts from the same shared instruction source.

There is no separate packages/claude-skill/ package anymore. Claude distribution is generated from this package.

๐Ÿ—๏ธ Package Layoutโ€‹

packages/skills/
โ”œโ”€โ”€ src/
โ”‚ โ”œโ”€โ”€ commands/ # n8nac skills subcommand registration
โ”‚ โ”œโ”€โ”€ services/ # AiContextGenerator and related services
โ”‚ โ””โ”€โ”€ assets/ # Generated node/doc indexes copied to dist/
โ”œโ”€โ”€ scripts/
โ”‚ โ””โ”€โ”€ build-skill-adapters.js # Builds generated skill adapter artifacts
โ”œโ”€โ”€ tests/
โ”œโ”€โ”€ dist/
โ”‚ โ”œโ”€โ”€ assets/
โ”‚ โ””โ”€โ”€ adapters/claude/ # Built Claude adapter output
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ package.json

๐Ÿ”Œ Public vs Internal Entry Pointsโ€‹

Public entry pointโ€‹

The supported interface for humans and agents is:

npx --yes n8nac skills --help

Typical commands include:

npx --yes n8nac skills search "google sheets"
npx --yes n8nac skills node-info googleSheets
npx --yes n8nac skills node-schema httpRequest
npx --yes n8nac skills examples search "slack notification"
npx --yes n8nac skills validate my-workflow.workflow.ts
npx --yes n8nac skills update-ai

Internal APIโ€‹

@n8n-as-code/skills is still consumable as a TypeScript dependency inside the monorepo:

import { AiContextGenerator, SnippetGenerator } from '@n8n-as-code/skills';

const aiGenerator = new AiContextGenerator();
await aiGenerator.generate('./project-root', '2.2.6');

const snippetGenerator = new SnippetGenerator();
await snippetGenerator.generate('./project-root');

Use the library API only from packages in this repository or tightly controlled integrations. User-facing documentation should prefer n8nac skills.

๐Ÿง  Core Servicesโ€‹

Command registrationโ€‹

The package registers the n8nac skills subcommand tree consumed by the CLI package. This is the main operational surface for node search, technical schemas, docs lookup, guide discovery, workflow examples, validation, and AI context refresh.

AiContextGeneratorโ€‹

AiContextGenerator materializes the canonical skill and lightweight context-root bootstrap reused across AI surfaces. Its responsibilities now include:

  • Generating and updating AGENTS.md
  • Generating .agents/skills/n8n-architect/SKILL.md
  • Applying local dev command overrides to the generated files

The canonical skill content lives in packages/skills/src/agent-skills/n8n-architect/SKILL.md. AGENTS.md is not the source of truth for effective config.

SnippetGeneratorโ€‹

SnippetGenerator writes .vscode/n8n.code-snippets from the node index and fallback templates.

Indexed data assetsโ€‹

The build copies generated indexes into dist/assets/, including technical schemas, documentation, and the unified search index used by search, node-info, docs, guides, related, and validate.

๐Ÿ“ Generated Outputsโ€‹

AI context filesโ€‹

n8nac skills update-ai generates or refreshes:

  • AGENTS.md
  • .agents/skills/n8n-architect/SKILL.md

AGENTS.md is updated in-place using markers so user-authored content outside the managed block is preserved.

Agent skill adapter artifactsโ€‹

The same package mirrors the canonical skill under packages/skills/dist/adapters/agent-skills/, including:

  • n8n-architect/SKILL.md

The build script also mirrors generated skill files into the plugin distribution trees under plugins/claude/..., plugins/openclaw/..., and plugins/cursor/....

๐Ÿ”„ Integration With Other Packagesโ€‹

n8nacโ€‹

n8nac depends on @n8n-as-code/skills and forwards its command surface under n8nac skills.

VS Code extensionโ€‹

The VS Code extension depends on the same package for AI context generation and node-aware assistance.

Agent skill adaptersโ€‹

Facade-specific distribution is not an independent source of truth. It is a build artifact generated from packages/skills/scripts/build-skill-adapters.js and the canonical src/agent-skills files.

๐Ÿงช Build And Testโ€‹

Build the packageโ€‹

cd packages/skills
npm run build

This compiles TypeScript and copies JSON assets into dist/assets/.

Build the Claude adapterโ€‹

cd packages/skills
npm run build:adapters

At the workspace root, the compatibility script is:

npm run build:claude-plugin

Run testsโ€‹

cd packages/skills
npm test

Key coverage includes AiContextGenerator behavior, .agents/skills generation, lightweight AGENTS.md, and parity between canonical and packaged plugin skills.

๐Ÿ“Œ Contribution Notesโ€‹

  • Do not document @n8n-as-code/skills as a standalone end-user CLI.
  • Do not reintroduce references to get if the real command is node-info or node-schema.
  • Keep AI guidance centered on TypeScript workflows, not legacy JSON-only examples.
  • Treat packaged Claude/OpenClaw/Cursor skill content as derived from the canonical src/agent-skills files, not as hand-maintained standalone instructions.

The Skills CLI enables AI assistants to work effectively with n8n workflows by providing comprehensive context, validation, and code generation capabilities.