brainstorming
brainstorming
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation).
japanese-writing-drafterDetect when the operator corrects the agent's Japanese phrasing mid-conversation (rewrites a sentence, calls out a style problem, says 'this wording is bad, say it like X instead') and draft a pending writing-rule proposal into ~/.claude/writing-lint/proposals.jsonl for later human review. This skill is the ONLY writer of proposals.jsonl — it never edits ru…
Independent GitHub snapshot · Automated classification · Original documentation governs
会話内で operator が agent の日本語表現を直したときだけ、その指摘を pending の writing-rule 提案として ~/.claude/writing-lint/proposals.jsonl に追記する。提案の追記のみを行い、承認・却下・rules.jsonl への昇格は一切行わない。
proposals.jsonl に status: pending の行を追記できるのはこの skill だけ。他のどのスクリプト・hook もこのファイルに書き込まない。rules.jsonl を更新できるのは人間が手で実行する scripts/writing-rule-approve.sh --id <id> だけ。この skill からも、他のどの hook からも writing-rule-approve.sh を自動起動しない。"pending" で書く。会話の中で、次のいずれかが起きたときだけ発動する(雑談・通常の作業指示では発動しない)。
writing-rule.v1 の pattern は文全体ではなく該当箇所のみでよい)。["external"] / ["chat"] / ["docs"] 等を付ける。不明なら省略する(省略は「全シーン適用」の意味になる。無理に推測しない)。no-meta-narration-a1b2c3d4)。templates/schemas/writing-rule-proposal.v1.json に対する手書きバリデーション(必須キー + additionalProperties: false)を通してから 1 行追記する。CLAUDE_WRITING_LINT_PROPOSALS が設定されていればそのパスを、無ければ ~/.claude/writing-lint/proposals.jsonl を使う。python3 - <<'PY'
import json, os, sys, uuid
from datetime import datetime, timezone
repo_root = "REPO_ROOT" # 呼び出し時に実際のリポジトリルートへ置き換える
schema_path = os.path.join(repo_root, "templates/schemas/writing-rule-proposal.v1.json")
proposals_path = os.environ.get("CLAUDE_WRITING_LINT_PROPOSALS") or os.path.join(
os.path.expanduser("~"), ".claude/writing-lint/proposals.jsonl"
)
with open(schema_path, encoding="utf-8") as f:
schema = json.load(f)
record = {
"id": "SLUG-" + uuid.uuid4().hex[:8],
"pattern": "PATTERN_HERE",
"good": "GOOD_HERE",
"status": "pending",
"evidence": "EVIDENCE_HERE",
"created_at": datetime.now(timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ"),
}
# scenes / severity は分かるときだけ足す:
# record["scenes"] = ["external"]
# record["severity"] = "warning"
def validate(data, sch):
required = set(sch.get("required", []))
props = sch.get("properties", {})
if sch.get("additionalProperties") is False:
extra = set(data.keys()) - set(props.keys())
if extra:
raise ValueError(f"additional properties not allowed: {sorted(extra)}")
for key in required:
if key not in data:
raise ValueError(f"missing required property: {key}")
validate(record, schema)
os.makedirs(os.path.dirname(proposals_path) or ".", exist_ok=True)
with open(proposals_path, "a", encoding="utf-8") as f:
f.write(json.dumps(record, ensure_ascii=False) + "\n")
print(f"drafted pending proposal: {record['id']}")
PY
id と、確認・承認コマンド (scripts/writing-rule-list.sh / scripts/writing-rule-approve.sh --id <id>) を短く伝える。承認するかどうかは operator の判断であり、この skill は待たない。scripts/writing-rule-approve.sh --id <id> (--reject で却下)scripts/writing-rule-list.shtemplates/schemas/writing-rule-proposal.v1.json (提案) / templates/schemas/writing-rule.v1.json (承認後のルール)go/internal/writinglint/ (Phase 135.1)