본문으로 건너뛰기
cccskills
무료GitHub에 공개

kiln-conventions

Apply Kiln’s coding rules when editing or reviewing Python, TypeScript, and Svelte. The skill combines area-specific guidance with a script that checks changed lines, plus manual checks for architecture, configuration handling, shared state, and asynchronous operations.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Kiln's code conventions and per-area gotchas, plus a diff gate that enforces the mechanical ones. Invoke before writing or changing any Python, TypeScript or Svelte code in the Kiln repo (libs/core, libs/server, app/desktop, app/web_ui), and when reviewing such a change. Covers comments, startup and entry points, globals and module state, config reads, module layering, library-vs-app rules and async I/O.

실행 점수 미검증

설치 방법 보기

이럴 때 유용합니다

  • Checking coding rules before changing Kiln
  • Checking uncommitted changes for convention violations
  • Reviewing a branch or pull request against shared rules
  • Auditing existing files or directories for violations

포함된 파일(9)

  • SKILL.md6.5 KB
  • references/core.md6.9 KB
  • references/rules.md13.8 KB
  • references/server_desktop.md8.0 KB
  • references/web_ui.md5.3 KB
  • scripts/conventions_gate.py22.2 KB
  • scripts/gate_allow.txt657 B
  • scripts/gate_config.json1.8 KB
  • scripts/test_conventions_gate.py18.2 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

kiln-conventions

One set of rules for how code is written in Kiln, the facts about the current code that are easy to get wrong, and a cheap check on the lines you add. Existing code is grandfathered: the rules apply to what your change adds or modifies.

Docs-only and spec-only changes don't need this skill.

1. Read the rules

Read references/rules.md in full. It is short, and every rule has a ❌/✅ example.

2. Read the reference for each area you touch

Pick the references from the paths you are editing. Read only those.

PathsReference
libs/core/**references/core.md
libs/server/**, app/desktop/**references/server_desktop.md
app/web_ui/**references/web_ui.md

UI changes (anything under app/web_ui that renders) also need the kiln-ui skill (.agents/skills/kiln-ui/SKILL.md) for visual design and house controls. This skill covers code structure only.

3. Write the code

Follow the rules even where the surrounding code doesn't (rules.md H24). Don't copy a nearby pattern that breaks a rule, and don't rewrite neighbouring code to comply unless your change already touches it.

4. Run the gate on your change

From the repo root:

uv run python .agents/skills/kiln-conventions/scripts/conventions_gate.py --worktree               # uncommitted changes + untracked files
uv run python .agents/skills/kiln-conventions/scripts/conventions_gate.py --range origin/main...HEAD  # a branch or PR
uv run python .agents/skills/kiln-conventions/scripts/conventions_gate.py --files <path>...          # whole files or directories (audits)

It prints one line per hit, SEV<TAB>RULE<TAB>path:line<TAB>snippet, then a summary. Exit 1 means at least one FAIL.

  • FAIL: fix it. If the hit is not a violation, add an entry to scripts/gate_allow.txt with a # reason line above it. Don't allowlist a real violation.
  • FAIL you can't fix without an out-of-scope refactor (rules.md H24): leave it, and don't allowlist it. List it in your end-of-task summary and the PR description with the rule id, path:line, and the refactor it waits on. The gate isn't in CI, so a FAIL reported this way blocks nothing.
  • WARN: fix it, or name it in your end-of-task summary with a one-line justification (for example "module-level-call app.command(...)(...) in cli/cli.py: Typer command registration at the CLI's composition root").

Only added lines are checked in --worktree and --range mode, so a hit is always on a line you wrote. --files reports existing code too; it's for audits, not for gating.

5. Self-check what the gate can't see

The gate catches history comments, global, bool(os.getenv…), env reads outside the allowed paths, new Config.shared() in libs/core, lib/ → routes/ imports, and module-level calls, constructions and subscriptions. Before you finish, check the review-only rules yourself against your diff:

  • A2/A3: no comment restates the code; each remaining comment is a 1–3 line why.
  • B4/B6: startup work is in the entry point or lifespan, not in an app factory or a module.
  • C7: no new module-level dict, list or set that gets mutated, and no ClassVar registries (the gate only catches global).
  • C8–C10: no reset hooks for tests, no asyncio primitives in singletons, every cache has an owner, a bound and invalidation.
  • D11/D14/D15: config is read at the edge; validators and default_factory are pure; no branching on the environment name to pick an implementation.
  • E16–E21: thin handlers and pages, no router-to-router imports, no HTTPException in services, no catch-all modules, no test helpers in production packages, no near-copies.
  • F22: library code doesn't touch host-process globals.
  • G23: no blocking I/O in async def; every outbound call has a timeout.

If a rule couldn't be followed without a refactor, say so in your summary (H24); for a gate FAIL, report it as in step 4.

For reviewers

Apply references/rules.md and the area references for the changed paths. Run the gate with --range <base>...<head> on the PR and report every FAIL and every WARN that the author didn't justify. Accept a FAIL the author reported with its rule id, path:line and the refactor it waits on (rules.md H24); an allowlist entry for a real violation is a finding. Rule violations in added code are findings, not nits.

Maintaining the gate

Files in this skill:

  • references/rules.md, scripts/conventions_gate.py and scripts/test_conventions_gate.py: each repo keeps its own copy, and kiln_server's started from Kiln's.
  • scripts/gate_config.json (skipped paths, which checks run where, allowed env-access paths, module-level patterns) and scripts/gate_allow.txt are Kiln-only. The gate reads both from its own directory.

Run the gate's tests (stdlib + pytest only; the default repo test run doesn't collect dot-directories):

uv run python -m pytest .agents/skills/kiln-conventions/scripts/test_conventions_gate.py

Config notes: a check missing from checks is disabled; an unknown check id or an invalid regex exits 2. Globs support * and ? (within one path segment) and **/ (zero or more directories); brackets are literal, so routes/[project_id]/** works. Allowlist lines are Python regexes searched in path<TAB>stripped line, optionally prefixed rule-id:.

Known limitations:

  • Python docstrings aren't scanned for history phrases; only # comments are.
  • Comment detection is per line. A multi-line /* */ or <!-- --> block is scanned only on its first line and on lines that start with *.
  • Quote tracking is per line too: an apostrophe earlier on the line (Svelte markup text like <p>Don't</p> <!-- … -->, or a ' in a regex literal) hides a comment that follows it.
  • The module-level-* checks are heuristics, which is why they are WARN. A module-level call written as an assignment is caught only when the right-hand side matches module_level_construct_patterns.
  • The history-comment phrase list skips common runtime-state phrasings ("no longer matches", "previously selected"), so some history phrased that way slips through. Review still applies rules.md A1.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Add AI models to Kiln or find available models missing from its list. The skill checks provider model identifiers and capabilities, updates model settings, runs tests against real APIs, and drafts a Discord announcement.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Adding a newly released model to Kiln
  • Finding available models missing from Kiln
  • Checking provider support for recently added models
Kiln-AI/Kiln5.2천2026년 10월 23일 업데이트

docs-sync

무료

Find documentation and agent instructions made outdated by a branch’s code changes. Update affected paths, commands, settings, and behavior descriptions in place, then commit the documentation fixes alongside the code in the same pull request.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Update documentation before opening a pull request
  • Review documentation before pushing more commits to an open pull request
  • Fix references after renaming scripts or public functions
Kiln-AI/Kiln5.2천2026년 10월 23일 업데이트

Draft first replies to customers and identify tickets that require human review before sending. The skill defines sensitive cases to escalate and guides replies that explain the next action, name who handles it, and match the customer's tone.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Drafting a first reply to a customer
  • Identifying tickets that need human review
  • Explaining next steps and who handles them
Kiln-AI/Kiln5.2천2026년 10월 23일 업데이트

Audit Kiln’s model list against provider APIs and catalogs to identify removed models and upcoming retirements. Get findings organized by provider, then mark affected entries as deprecated after reviewing and approving the proposed changes.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Audit Kiln’s model list for retired entries
  • Identify models approaching their retirement dates
  • Check model availability for a single provider
Kiln-AI/Kiln5.2천2026년 10월 23일 업데이트

Check whether Kiln’s base models still support fine-tuning, the process of adapting a model with additional training. Compare configured identifiers and Fireworks’ allowlist with provider information, then report unsupported entries and recommend specific updates.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Audit support for fine-tuning base models in Kiln
  • Check whether configured fine-tuning identifiers remain valid
  • Find stale entries in the Fireworks allowlist
Kiln-AI/Kiln5.2천2026년 10월 23일 업데이트

Maintain Kiln’s list of large language models by discovering new releases, testing provider access, and marking unavailable entries as deprecated. Prepare pull requests, report unresolved issues, and check whether the updated list needs publication.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Run the scheduled model sweep manually
  • Add new models and test provider access
  • Mark unavailable model entries as deprecated
Kiln-AI/Kiln5.2천2026년 10월 23일 업데이트

Kiln-AI의 스킬 모두 보기

이 스킬의 문제 신고