ctx-convention-add

Record a coding convention. Use when a repeated pattern should be codified so all sessions follow it consistently.

41 stars

Best use case

ctx-convention-add is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Record a coding convention. Use when a repeated pattern should be codified so all sessions follow it consistently.

Teams using ctx-convention-add should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/ctx-convention-add/SKILL.md --create-dirs "https://raw.githubusercontent.com/ActiveMemory/ctx/main/internal/assets/claude/skills/ctx-convention-add/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/ctx-convention-add/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How ctx-convention-add Compares

Feature / Agentctx-convention-addStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Record a coding convention. Use when a repeated pattern should be codified so all sessions follow it consistently.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

Record a coding convention in CONVENTIONS.md.

## When to Use

- When a pattern has been used 2-3 times and should be standardized
- When establishing a naming, formatting, or structural rule
- When a new contributor would need to know "how we do things here"
- When the user says "codify that" or "make that a convention"

## When NOT to Use

- One-off implementation details (use code comments instead)
- Architectural decisions with trade-offs (use `/ctx-decision-add`)
- Debugging insights or gotchas (use `/ctx-learning-add`)
- Rules that are already enforced by linters or formatters

## Gathering Information

Conventions are simpler than decisions or learnings. You need:

1. **Name**: What is the convention called? (e.g., "kebab-case CLI flags")
2. **Rule**: What is the rule? One clear sentence.
3. **Section**: Where does it belong in CONVENTIONS.md? (e.g., "Naming",
   "Output", "Testing")

If the user provides only a description, infer the section from the
topic. Check existing sections in CONVENTIONS.md first to place it
correctly: don't create a new section if an existing one fits.

If the convention overlaps with an existing one, mention it:
*"There's already a naming convention for functions. Want me to add
this alongside it or update the existing one?"*

## Execution

```bash
ctx add convention "Use kebab-case for all CLI flag names" --section "Naming"
```

```bash
ctx add convention "Use cmd.Printf/cmd.Println for CLI output, never fmt.Printf/fmt.Println" --section "Output"
```

```bash
ctx add convention "Colocate test files with implementation (*_test.go next to *.go)" --section "Testing"
```

If no `--section` is provided, the convention is appended to the end
of the file. Prefer specifying a section for organization.

## Quality Checklist

Before recording, verify:
- [ ] The rule is clear enough that someone unfamiliar could follow it
- [ ] It is specific to this project (not a general Go/JS/etc. rule)
- [ ] It is not already in CONVENTIONS.md (check first)
- [ ] The section matches an existing section, or a new section is
      genuinely needed
- [ ] It describes a pattern, not a one-time choice (that's a decision)

Confirm the convention was added.

Related Skills

ctx-add-convention

41
from ActiveMemory/ctx

Record a coding convention. Use when a repeated pattern should be codified so all sessions follow it consistently.

ctx-verify

41
from ActiveMemory/ctx

Verify before claiming completion. Use before saying work is done, tests pass, or builds succeed.

ctx-skill-creator

41
from ActiveMemory/ctx

Create, improve, test, and deploy skills. Full skill lifecycle from intent to working skill file.

ctx-sanitize-permissions

41
from ActiveMemory/ctx

Audit tool permissions for dangerous or overly broad entries. Use to ensure safe agent configuration.

ctx-recall

41
from ActiveMemory/ctx

Browse session history. Use when referencing past discussions or finding context from previous work.

ctx-prompt

41
from ActiveMemory/ctx

Apply, list, and manage saved prompt templates from .context/prompts/. Use when the user asks to apply, list, or create a reusable template like code-review or refactor.

ctx-journal-normalize

41
from ActiveMemory/ctx

Normalize journal source markdown for clean rendering. Use after journal site shows rendering issues: fence nesting, metadata formatting, broken lists.

ctx-import-plans

41
from ActiveMemory/ctx

Import plan files into project specs directory. Use to convert external plans into project-tracked specs.

ctx-compact

41
from ActiveMemory/ctx

Archive completed tasks and trim context. Use when context files are growing large.

ctx-check-links

41
from ActiveMemory/ctx

Audit docs for dead links. Use before releases, after restructuring docs, or when running a documentation audit.

ctx-add-task

41
from ActiveMemory/ctx

Add a task. Use when follow-up work is identified or when breaking down complex work into subtasks.

ctx-add-learning

41
from ActiveMemory/ctx

Record a learning. Use when discovering gotchas, bugs, or unexpected behavior that future sessions should know about.