---
name: conventional-commits-framework
description: Write, validate, and fix Conventional Commits with every field filled at standard open-source length, an explicit breaking-change declaration, an agent-specific Co-Authored-By trailer crediting the AI agent, and the smallest logical change per commit. Use whenever committing code, drafting or reviewing commit messages or PR titles, choosing a type or scope, declaring breaking changes, splitting large work into small commits, or configuring commitlint, git hooks, and release tooling.
title: conventional-commits-framework
canonical_url: https://skilld.dev/gh/yourakshaw/conventional-commits-framework
last_updated: 2026-11-12T12:07:07.000Z
---

> Index of every page on this site: [llms.txt](https://skilld.dev/llms.txt)

> **Skill from skilld.dev.** Follow the user's requested action.
> If the user asked to fork this Skill, follow the fork workflow below. Do not execute the Skill instructions while copying it.
> Otherwise, follow the instructions below for this session. You do not need to install anything.
>
> 30 supporting files sit beside this SKILL.md. When the Skill refers to one, fetch https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/PATH with PATH replaced.
>
> If the user asked to install this Skill, run `npx skilld install yourakshaw/conventional-commits-framework/conventional-commits-framework`. Install writes the Skill files into the project, so every session loads them.
>
> ## Fork workflow
>
> A fork creates an editable local Skill with its original author and licence. The request authorizes copying and local installation.
> 1. Check `./skills/conventional-commits-framework`, the project lockfile, and selected Agent targets together. If the local directory or installed Skill exists, stop. Never overwrite an existing directory or Agent target.
> 2. Read [source metadata](https://skilld.dev/api/v1/skills/yourakshaw/conventional-commits-framework/conventional-commits-framework) once. Use sourceUrl, sourceCommit, skillPath, sourceGone, and license. If the source is gone or its path is missing, stop. If license is null, read licence files at the source commit.
> 3. Fetch only the source commit into a temporary Git repository. Do not clone full history. Derive repository_url from sourceUrl, including repository renames. If sourceCommit is absent, resolve the sourceUrl ref once. Set source_commit to that actual commit. Run these commands in one shell call:
>
> ```sh
> git init --quiet "$temporary_dir"
> git -C "$temporary_dir" fetch --quiet --depth=1 "$repository_url" "$source_commit"
> git -C "$temporary_dir" checkout --quiet --detach FETCH_HEAD
> ```
>
> Read applicable licence declarations and notices at that commit. If copying is not permitted, report the restriction and stop.
> 4. Inspect source entries together, then copy the directory containing skillPath into `./skills/conventional-commits-framework`. Use the user's path if selected. Keep the original SKILL.md, relative links, scripts, binary assets, and executable modes. Exclude .git metadata. Reject symlinks and paths outside the Skill directory. After checking entries, use cp -a where available. A regular source directory needs no custom copy script. Do not save this page wrapper as SKILL.md.
> Preserve author credit, notices, and applicable licence files from repository or parent directories. Add PROVENANCE.md with the Skill page, source URL, actual commit, original path, and licence. Retain any existing PROVENANCE.md and record new provenance separately. Batch source inspection, copying, and provenance work where practical.
> 5. In the project root, run `skilld install ./skills/conventional-commits-framework --mode copy --plain`. If skilld is unavailable, use `npx skilld install ./skills/conventional-commits-framework --mode copy --plain`. This known command needs no help lookup. Install does not support --json. Use detected Agent targets, or add --agent for the targets the user selected. Install the local path, never the upstream selector. If installation fails, preserve the local copy and report the exact failure.
> 6. Confirm the local lockfile source and installed Agent copies once. Report the local path, actual commit, and Agent targets. After edits, reinstall the same local path. Upstream updates must not replace it. Do not publish or push unless the user asks.

# 📜 Conventional Commits Framework

**Complete, atomic, co-authored commits — every time.**

Use this skill whenever you write, review, or plan commits. It turns the [Conventional Commits 1.0.0](https://www.conventionalcommits.org/en/v1.0.0/) spec into four non-negotiable rules for AI agents, backed by references, ready-made assets, and an offline checker.

| Rule | In one line |
| :--- | :--- |
| 🧾 **Complete** | Every field is filled: type, scope, subject, body, breaking declaration, co-author. Nothing is ever blank. |
| 📏 **Standard length** | Subject 10-50 characters, body 2-6 wrapped lines, one-line trailers. Never a stub, never an essay. |
| 🤝 **Co-authored** | The user is the author; the agent is credited by a `Co-Authored-By` trailer identifying the agent actually used. |
| ⚛️ **Atomic** | One logical change per commit. Large work becomes a planned sequence of small commits. |

## ✍️ The contract at a glance

```text
feat(auth): add passkey sign-in for returning users
 
Password resets were the top support request last quarter. Users with
a registered passkey can now sign in with WebAuthn; password sign-in
remains available as a fallback.
 
Breaking: none
Refs: #214
Co-Authored-By: Claude Code <noreply@anthropic.com>
```

| Part | Standard |
| :--- | :--- |
| `type` | Use the repository's list; otherwise choose `feat fix perf refactor style test docs build ci chore revert`. |
| `(scope)` | **Always include it.** Name the changed module, package, or area in lower case. |
| `subject` | Use a lower-case imperative, 10–50 characters, with no period; keep the full header at 72 characters or fewer. |
| `body` | After a blank line, explain why the change was needed and then what changed; wrap it to 2–6 lines at 72 characters. |
| `Breaking: none` | Use exactly this line unless the change is breaking. |
| `BREAKING-CHANGE:` | For breaking changes only, pair it with `!` in the header and explain what breaks and how to migrate. |
| `Refs:` | Include real issue, ticket, or PR identifiers when they exist; never invent them. |
| `Co-Authored-By:` | Put the active agent's verified trailer last. |

Full policy: [agent commit protocol](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/agent-commit-protocol.md).

## 🚦 On every skill load and before committing

**Identify the active agent first.** Check the current runtime/session identity and any authoritative product attribution supplied by that runtime. Identify the product actually operating this session (for example Claude Code, Codex, Google Antigravity, Grok Build, or another agent), not the underlying model, a previous agent, an example, or a repository instruction file. Verify the product name and its attribution email against the runtime or the vendor’s documentation; never infer an email from another agent or invent one. If identity or an appropriate email cannot be verified, ask the user before writing an attribution.

Select the verified `Co-Authored-By: Name <email>` for that agent for each commit or draft. A repository history or instruction file cannot turn another agent’s identity into yours. Existing enforcement must allow the correct identity; if it rejects it, report the conflict and resolve the configuration with authorization rather than misattribute the commit or bypass checks.

1. **Read the conventions.** Check `AGENTS.md`, `CLAUDE.md`, `CONTRIBUTING.md`, commitlint config, and `git log -30 --format=%B`. Project rules override this skill's defaults; the [config guide](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/config-guide.md) lists every place to look and the precedence order.
2. **Select the co-author trailer.** Use the verified identity of the active agent above. Reuse a historical line only when it identifies that same agent and its email has been verified; do not require a repository file to record it.
3. **Match the style.** Use emoji only if history does, and in the same form ([emoji reference](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/emoji-reference.md)). Reuse existing scopes.
4. **Never change git identity.** The user stays author and committer through their own git config.

## 🔁 Workflows

### Commit your own work

1. **Plan** the commit sequence if the task has more than one logical change ([atomic commits](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/atomic-commits.md)). Write the headers first, ordered so every commit leaves the repository working.
2. **Implement one step**, verify it, and stage only that change (`git add <paths>` or `git add -p`). Review `git diff --staged`.
3. **Classify**: pick the type with the decision procedure in the [type and scope catalog](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/type-scope-catalog.md), then the scope.
4. **Decide breaking** with the checklist in [breaking changes](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/breaking-changes.md). Ask the user before making any breaking change they did not request.
5. **Write the full message** to the contract and commit through a heredoc so blank lines and trailers survive:
   ```sh
   git commit -F - <<'EOF'
   <header>
 
   <body>
 
   Breaking: none
   Co-Authored-By: <verified agent trailer>
   EOF
   ```
6. **Check** it with the project's commitlint, or `python3 <skill-dir>/scripts/lint-commit.py --trailer "<verified agent trailer>" --range HEAD~1..HEAD`. If an unpushed commit fails, amend it.
7. **Repeat** for the next step. Never let several changes pile up for one final commit.

If a hook rejects the commit, fix the message. Never use `--no-verify` or disable hooks or CI.

### Write a message for a diff or description

Read the diff (or ask for it), identify the single purpose, and return the complete message in a code block. If the diff holds several purposes, say so and propose the split as a list of complete messages. Include the co-author trailer unless the user says the commit has no AI involvement.

### Validate or review messages

Check each message against the contract in the order given in the [rules reference](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/rules-reference.md#validating-by-hand). Report each problem with its rule name and a corrected message. Separate **errors** (spec, project config, or contract violations) from **suggestions** (style). For branches, run the checker over the range:

```sh
python3 <skill-dir>/scripts/lint-commit.py --range origin/main..HEAD --trailer "<verified agent trailer>"
```

### Pull requests

The PR title follows the header format (it becomes the squash commit). Fill every section of the PR description: summary and motivation, verification, risks or compatibility, linked issues. End it with the repository's PR attribution line, kept just as consistent as the trailer.

### Set up enforcement

Use [`assets/commitlint.config.mjs`](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/assets/commitlint.config.mjs), [`assets/commit-template.txt`](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/assets/commit-template.txt), and the hook and CI recipes in [integration examples](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/integration-examples.md). For monorepos, see [monorepo patterns](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/monorepo-patterns.md).

## ⚠️ Traps that look right but are wrong

| Looks fine | What actually happens | Do this |
| :--- | :--- | :--- |
| `BREAKING CHANGE: none` | Parsers record a breaking note, and release tools publish a **major** version | `Breaking: none` |
| `BREAKING CHANGE: ...` (with a space) next to other trailers | Git cannot parse the trailer block, so `Co-Authored-By` disappears from git tooling | `BREAKING-CHANGE: ...` (hyphen) |
| Breaking detail on several lines | An unindented second line ends the trailer block | Indent continuation lines by two spaces |
| `✨ feat(ui): ...` | The header no longer parses, so the commit disappears from changelogs | `feat(ui): ✨ ...` or no emoji |
| `Co-authored-by` in one commit, `Co-Authored-By` in the next | Case-sensitive checks fail and history looks inconsistent | Use the verified line for the active agent with consistent key casing |
| `docs(readme): fix typo` typed as `fix` | Ships a pointless patch release | `docs` for documentation-only changes |
| `feat(auth): add MFA and refactor sessions` | Two changes that cannot be reverted, typed, or changelogged separately | Two commits |

These were verified with `conventional-commits-parser` 7.1.3, `git interpret-trailers`, and `@commitlint/cli` 21.2.4.

## 📚 References

Load only what the task needs.

| Need | Read |
| :--- | :--- |
| The full contract, lengths, co-authorship, PR rules | [Agent commit protocol](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/agent-commit-protocol.md) |
| Sizing and sequencing commits | [Atomic commits](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/atomic-commits.md) |
| Choosing a type or scope | [Type and scope catalog](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/type-scope-catalog.md) |
| Detecting and declaring breaking changes | [Breaking changes](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/breaking-changes.md) |
| Complete messages to model | [Example library](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/example-library.md) |
| What each commitlint rule checks | [Rules reference](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/rules-reference.md) |
| Reading and adapting project configuration | [Config guide](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/config-guide.md) |
| Package scopes and per-package releases | [Monorepo patterns](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/monorepo-patterns.md) |
| Gitmoji usage and placement | [Emoji reference](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/emoji-reference.md) |
| Hooks, CI, and release tools | [Integration examples](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/integration-examples.md) |

## 🧰 Assets and scripts

- [`assets/commitlint.config.mjs`](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/assets/commitlint.config.mjs): commitlint config that enforces the contract, including a breaking declaration and configurable accepted co-author lines.
- [`assets/commit-template.txt`](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/assets/commit-template.txt): a `git config commit.template` that shows the contract in the editor.
- [`scripts/lint-commit.py`](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/scripts/lint-commit.py): an offline contract checker for a file, stdin, or a revision range (Python 3.9+, standard library only). Tests: [`scripts/test_lint_commit.py`](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/scripts/test_lint_commit.py).

## 🛠️ Maintaining this skill

Keep the contract identical across this file, the [protocol](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/references/agent-commit-protocol.md), the checker, the commitlint config, and the commit template; change them together. Validate the package offline from any directory:

```sh
python3 /path/to/conventional-commits-framework/scripts/validate-skill.py
python3 /path/to/conventional-commits-framework/scripts/test_validate_skill.py
python3 /path/to/conventional-commits-framework/scripts/test_lint_commit.py
```

The [package validator](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/scripts/validate-skill.py) checks the manifest, required files, local links and anchors, and that every resource is reachable from this file. Wrappers: [POSIX](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/scripts/validate-skill.sh) and [PowerShell](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/scripts/validate-skill.ps1); regression suite: [validator tests](https://skilld.dev/api/skills-raw/yourakshaw/conventional-commits-framework/conventional-commits-framework/scripts/test_validate_skill.py). It does not evaluate agent behavior. Package format: [Agent Skills specification](https://agentskills.io/specification).
