# Build a Custom AI Skill in 37 Lines (with working code)

> Source: <https://blog.stackademic.com/build-a-custom-ai-skill-in-37-lines-with-working-code-0c7a699f512a?source=rss----d1baaa8417a4---4>
> Published: 2026-07-22 07:41:11+00:00

Member-only story

# Build a Custom AI Skill in 37 Lines (with working code)

Most teams I work with have already adopted an AI coding assistant. Few of them have taught it anything specific to their codebase. That is the gap custom skills fill.

A skill is a small, named bundle of instructions, usually 20 to 40 lines, that an AI agent loads on demand. It does not sit in the system prompt burning tokens. It lives in a folder, has a name, and gets invoked when the task matches.

In this post we will build one. The whole thing: 30 lines, two files, one bash command to install. The skill reviews a `git diff`

and returns a structured critique covering bugs, security, style, and performance. The output is formatted so you can paste it straight into a PR comment.

By the end, you will have a working pattern. I will give you three more skill ideas at the bottom that you can ship in an afternoon each.

*By the way, if you are not Medium member, please click **here** to read.*

Why this matters: a vanilla AI assistant knows JavaScript. It does not know your team’s rule against console.log in production. A skill encodes that rule once, and every future session follows it. That is the difference between an assistant you use and an assistant that fits.
