Agent skill

Chaibuilder

by chaibuilder in chaibuilder/core

ChaiBuilder Core extension patterns for Next.js. An agent skill from chaibuilder/core.

BSD-3-ClauseAuto-check passedFrontend & Design

Install Chaibuilder

skills CLI
$ npx skills add chaibuilder/core --skill chaibuilder -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install chaibuilder/core chaibuilder --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/chaibuilder/core.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/chaibuilder .claude/skills/chaibuilder && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
chaibuilder
GitHub stars
483
Token cost
~2.2k tokens
SKILL.md length
362 words
Files
33
Skills in repo
1
Repo updated
First seen
Licence
BSD-3-Clause

At a glance

ChaiBuilder Core extension patterns for Next.js. An agent skill from chaibuilder/core.

  • Extending the builder UI (custom sidebar panels
  • SKILL.md covers Skill Sections, Quick Reference: Page Rendering, Quick Reference: Server Setup and Quick Reference: Custom Blocks, plus 1 more section
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Lifecycle hooks

What it does

Chaibuilder is an agent skill from chaibuilder/core. ChaiBuilder Core extension patterns for Next.js. Use when extending the builder UI (custom sidebar panels, slots, lifecycle hooks, feature flags, block tabs, libraries), creating custom blocks, configuring the server, or implementing page rendering. Covers all top-level chaicore APIs.

Its SKILL.md is about 2.2k tokens, which your agent loads only when the skill is triggered. The skill folder holds 33 other files (for example `AGENTS.md`, `README.md` and `SKILLS.md`).

It sits in Frontend & Design. It works with Next.js, Tailwind CSS and React. The repository describes itself as: chaicore - open-source AI-enabled visual website builder for Next.js. The licence is BSD-3-Clause.

When your agent uses it

  • Extending the builder UI (custom sidebar panels
  • Lifecycle hooks
  • Creating custom blocks
  • Configuring the server

Example prompts

  • “/chaibuilder”

What it can do on your machine

Read from SKILL.md and the folder at commit 56a002f. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are typescript).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Chaibuilder loads about 2.2k tokens when it runs. Until then it costs about 74 tokens; SKILL.md has 362 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~74
When it runs · the whole SKILL.md, loaded when a task matches
~2.2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from chaibuilder/core at commit 56a002f, republished under its BSD-3-Clause licence (© chaibuilder). 362 words, ~2,202 tokens.

Download SKILL.mdSave it as .claude/skills/chaibuilder/SKILL.md (or your agent's skills folder). This skill also uses 32 other files; get the full folder from GitHub.
name
chaibuilder
description
ChaiBuilder Core extension patterns for Next.js. Use when extending the builder UI (custom sidebar panels, slots, lifecycle hooks, feature flags, block tabs, libraries), creating custom blocks, configuring the server, or implementing page rendering. Covers all top-level chaicore APIs.

ChaiBuilder Core — Extension Patterns

Skill Sections

SectionPrefixWhen to Use
Extend UIextend-ui-Add panels, slots, hooks, flags, tabs, libraries to the builder
Custom Blocksblocks-Define and register custom blocks with props schema
Server Setupserver-buildChaiBuilderConfig, server actions, withChaiBuilder
Renderrender-RenderChaiBlocks, ChaiPageCSS, getStylesForBlocks

See AGENTS.md for full examples per section.


Quick Reference: Page Rendering

All render imports from chaicore/render.

APIWhereDescription
RenderChaiBlocksPage bodyRenders all blocks (async RSC)
ChaiPageCSS<head>Tailwind CSS + theme vars + fonts
ChaiPageJSONLD<head>Structured data JSON-LD
PreviewBannerPage bodyDraft mode indicator (client)
getStylesForBlocks(blocks, includeBase?)Custom pipelinesGenerate Tailwind CSS from blocks
getChaiThemeCssVariables({ theme })Custom pipelinesCSS vars string from theme object
getMergedPartialBlocks(blocks, partials)Custom pipelinesInline partial block references

Minimal page:

tsx
// app/(public)/[[...slug]]/page.tsx
import { getChaiBuilder } from "@/chaibuilder.server";
import { RenderChaiBlocks, ChaiPageCSS, PreviewBanner } from "chaicore/render";

export default async function Page(props) {
  const slug = "/" + ((await props.params).slug?.join("/") ?? "");
  const cb = await getChaiBuilder(props);
  const { page, pageData, settings } = await cb.getPagePayload(slug);
  return (
    <>
      <ChaiPageCSS page={page} />
      <RenderChaiBlocks page={page} pageData={pageData} settings={settings} pageProps={{ slug }} />
      <PreviewBanner show={page.draft ?? false} />
    </>
  );
}

Quick Reference: Server Setup

All server imports from chaicore/server or chaicore/next. Never import in client components.

StepFileAPI
1. Wrap Next.js confignext.config.tswithChaiBuilder(nextConfig)
2. Build server configchaibuilder.config.tsbuildChaiBuilderConfig({ db, ... })
3. Create server handlechaibuilder.server.tscreateChaiBuilder(config, { context })
4. Use in pages/layoutsapp/**/page.tsxgetChaiBuilder(props)
5. Route handlerapp/.../api/chai/route.tshandleChaiActionRequest(req, cb.handleHttpAction)

Minimal setup:

ts
// next.config.ts
import { withChaiBuilder } from "chaicore/next";
export default withChaiBuilder({});

// chaibuilder.config.ts — plain data, no framework imports
import { buildChaiBuilderConfig } from "chaicore/server";
export const chaiConfig = buildChaiBuilderConfig({ db });

// chaibuilder.server.ts — owns auth/tenancy/draft; exports the handle entry points import
import { chaiConfig } from "@/chaibuilder.config";
import { createChaiBuilder } from "chaicore/server";
export const { getChaiBuilder } = createChaiBuilder(chaiConfig, {
  context: async ({ request }) => ({
    userId: await getUserIdFromCookies(request),
    role: "admin",
    permissions: ["*"], // omit to resolve membership from app_users instead
    draft: false,
  }),
});

// app/(builder)/api/chai/route.ts
import { getChaiBuilder } from "@/chaibuilder.server";
import { handleChaiActionRequest } from "chaicore/nextjs/server";
export async function POST(req, props) {
  const cb = await getChaiBuilder(props, req);
  return handleChaiActionRequest(req, cb.handleHttpAction);
}

Quick Reference: Custom Blocks

All block imports from chaicore/registry. Register at module level.

APIPurpose
registerChaiBlock(Component, Config)Register a block component + config
registerChaiBlockProps(schema)Build RJSF props schema; returns { schema, uiSchema }
stylesProp(defaultClasses)Create the Tailwind styles prop
builderProp(options)Editor-only prop (hidden in rendered output)
closestBlockProp(blockType, prop)Read prop from nearest ancestor block
registerChaiServerBlock(Component, opts)Override server-side data provider only

Minimal block example:

tsx
import { registerChaiBlock, registerChaiBlockProps, stylesProp } from "chaicore/registry";
import type { ChaiBlockComponentProps, ChaiStyles } from "chaicore/types";

const MyBlock = ({ blockProps, styles, label }: ChaiBlockComponentProps<{ label: string; styles: ChaiStyles }>) => (
  <div {...blockProps} {...styles}>
    {label}
  </div>
);

registerChaiBlock(MyBlock, {
  type: "MyBlock",
  label: "My Block",
  group: "basic",
  props: registerChaiBlockProps({
    properties: {
      styles: stylesProp("p-4"),
      label: { type: "string", title: "Label", default: "Hello" },
    },
  }),
  i18nProps: ["label"],
  aiProps: ["label"],
});

Show full SKILL.md (126 more words)Show less

Quick Reference: Extend UI

All register calls are client-only — call at module level before ChaiWebsiteBuilder mounts.

APIImportPurpose
registerChaiSidebarPanel(id, opts)chaicoreAdd panel to builder sidebar
registerChaiSlot(slotId, Component)chaicoreInject component at a UI location
CHAI_SLOT_IDSchaicoreEnum of all valid slot IDs
registerChaiHook(hookName, fn)chaicoreLifecycle hook (pipeline)
CHAI_HOOKSchaicoreEnum of all valid hook names
registerChaiFeatureFlag(key, opts)chaicoreRegister toggleable flag
registerChaiFeatureFlags(map)chaicoreRegister multiple flags at once
registerChaiAddBlockTab(id, opts)chaicoreAdd tab to "Add Block" panel
registerChaiLibrary(id, config)chaicoreRegister custom block library
registerChaiBlockSettingWidget(id, C)chaicoreCustom RJSF widget for block settings
registerChaiBlockSettingField(id, C)chaicoreCustom RJSF field
registerChaiBlockSettingTemplate(id, C)chaicoreCustom RJSF template
registerChaiSaveToLibrary(Component)chaicoreReplace "Save to Library" dialog
registerChaiPreImportHTMLHook(fn)chaicoreTransform HTML before block import
Extend UI Setup Pattern
ts
// chai-setup.ts  ← module-level, imported once before builder mounts
import { registerChaiSlot, CHAI_SLOT_IDS, registerChaiHook, CHAI_HOOKS } from "chaicore";

registerChaiSlot(CHAI_SLOT_IDS.TOPBAR_RIGHT, MyButton);
registerChaiHook(CHAI_HOOKS.BEFORE_SAVE_PAGE, myHook);
tsx
// editor/page.tsx
"use client";
import "../chai-setup";
import { ChaiWebsiteBuilder } from "chaicore";
export default function EditorPage() {
  return <ChaiWebsiteBuilder {...props} />;
}

© chaibuilder, BSD-3-Clause. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 32 other files in .agents/skills/chaibuilder of chaibuilder/core.

  • SKILL.md
  • AGENTS.md
  • README.md
  • SKILLS.md
  • metadata.json
  • rules/_sections.md
  • rules/_template.md
  • rules/blocks-component-props.md
  • rules/blocks-data-provider.md
  • rules/blocks-i18n-ai.md
  • rules/blocks-nesting-wrapper.md
  • rules/blocks-props-schema.md
  • rules/blocks-register.md
  • rules/extend-ui-add-block-tab.md
  • rules/extend-ui-block-settings.md
  • rules/extend-ui-feature-flags.md
  • rules/extend-ui-hooks.md
  • rules/extend-ui-library.md
  • rules/extend-ui-pre-import-html.md
  • rules/extend-ui-save-to-library.md
  • … and 13 more

Open the folder on GitHubat commit 56a002f

Compare with similar skills

Chaibuilder next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Chaibuilder compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Chaibuilder this skillchaibuilder/core483—~2.2kAutomated safety check: PassBSD-3-Clause
Website ClonerJCodesMore/ai-website-cloner-template36k—~1.7kAutomated safety check: PassMIT
Creative Tim UI Blockscreativetimofficial/ui12k—~2.1kAutomated safety check: NotesMIT
Chakra UI v3 Refactor and Reviewchakra-ui/chakra-ui41k—~2.8kAutomated safety check: PassMIT
Cosscrafter-station/petdex4.2k—~1.4kAutomated safety check: PassMIT
Ss Learnbitjaru/styleseed972—~1.3kAutomated safety check: PassMIT

Similar skills

  • Website Cloner

    JCodesMore/ai-website-cloner-template

    Rebuilds existing web pages as editable local code that matches their content, assets, responsive layout and interactions, including Framer sites and animated pages.

    36k GitHub stars~1.7k tokensUpdated 2 days ago
    Frontend & DesignAuto-check passed
  • Creative Tim UI Blocks

    creativetimofficial/ui

    Helps install, generate and review Creative Tim UI blocks: shadcn/ui-based React and Tailwind sections that follow a restrained, production-minded design philosophy.

    12k GitHub stars~2.1k tokensUpdated 6 mo ago
    Frontend & DesignAuto-check: notes
  • Reviews and converts UI code to Chakra UI v3, producing a critique, rewritten code or both, from plain HTML, Tailwind, CSS Modules or styled-components.

    41k GitHub stars~2.8k tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Coss

    crafter-station/petdex

    Helps implement coss UI components correctly. An agent skill from crafter-station/petdex.

    4.2k GitHub stars~1.4k tokensUpdated 9 days ago
    Frontend & DesignAuto-check passed
  • Ss Learn

    bitjaru/styleseed

    Capture a human-approved UI design lesson as a privacy-minimized local StyleSeed candidate, review it, and prepare an opt-in share package without transmitting project code, prompts, screenshots, or…

    972 GitHub stars~1.3k tokensUpdated 7 days ago
    Frontend & DesignAuto-check passed
  • UI/UX Design System Advisor

    Galaxy-Dawn/claude-scholar

    Turns a vague UI request into a concrete design system with style, palette, typography and layout guidance from a search script, plus stack-specific implementation advice.

    5.7k GitHub starsUsed in 1 repo~1.1k tokens
    Frontend & DesignAuto-check passed

Questions about Chaibuilder

What does Chaibuilder do?

ChaiBuilder Core extension patterns for Next.js. An agent skill from chaibuilder/core. Chaibuilder is an agent skill from chaibuilder/core.js.

When should I use Chaibuilder?

Chaibuilder fits situations like: extending the builder UI (custom sidebar panels; lifecycle hooks; creating custom blocks; configuring the server.

How do I install Chaibuilder in Claude Code?

Run `npx skills add chaibuilder/core --skill chaibuilder -a claude-code`. Or copy the skill folder (.agents/skills/chaibuilder in chaibuilder/core) into .claude/skills/chaibuilder in your project. Claude Code loads it when a task matches its description.

How do I install Chaibuilder in Codex?

Run `npx skills add chaibuilder/core --skill chaibuilder -a codex`. Or copy the skill folder (.agents/skills/chaibuilder in chaibuilder/core) into .agents/skills/chaibuilder in your project. Codex loads it when a task matches its description.

Can I use Chaibuilder in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add chaibuilder/core --skill chaibuilder -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/chaibuilder, .gemini/skills/chaibuilder, .github/skills/chaibuilder and .opencode/skills/chaibuilder in your project.

What does Chaibuilder need to run?

SKILL.md names no scripts, command-line tools or credentials: Chaibuilder is instructions for the agent only.

Does Chaibuilder access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Chaibuilder safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Chaibuilder use?

Chaibuilder is published under the BSD-3-Clause licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Chaibuilder use?

About 2.2k tokens (SKILL.md is roughly 8.8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Chaibuilder?

Skills that share tags, products or a category with Chaibuilder: Website Cloner (JCodesMore/ai-website-cloner-template, 36k stars), Creative Tim UI Blocks (creativetimofficial/ui, 12k stars), Chakra UI v3 Refactor and Review (chakra-ui/chakra-ui, 41k stars) and Coss (crafter-station/petdex, 4.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Chaibuilder?

chaibuilder (a GitHub organization) maintains it in chaibuilder/core, which has 483 GitHub stars. The repository was last updated on October 5, 2026.

Source: chaibuilder/core on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.