Logo Carnet

Carnet

Tổ chứcPhổ biến
Atmosphere
carnet

Work the private register (Atmosphere/atmosphere-carnet) from a session — claim an issue before touching it so peers see who holds it and which session, release or close it when done, file new issues in the one canonical shape. Use whenever a carnet#N or registre#N issue is mentioned, when you start or stop work that an issue tracks, or when you are about to run gh issue against the tracker.

Tổng quan

Nhà phát hànhAtmosphere
Kho mãatmosphere
Tên kỹ năngcarnet
Sao
3.8K
Bản fork
764
Tệp đi kèm
5
Giấy phépApache-2.0
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI là Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • 5 tệp đi kèm

    Các tập lệnh, mẫu và tài liệu tham khảo mà mô hình có thể đọc khi làm việc. Các tệp chỉ cho phép đọc và không bao giờ được thực thi.

  • Mã nguồn mở

    Được Atmosphere công bố trên GitHub. Hãy đọc nội dung nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Carnet trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL thư mục kỹ năng bên dưới và xác nhận.
    https://github.com/Atmosphere/atmosphere/tree/main/.agents/skills/carnet
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Atmosphere/atmosphere.git /tmp/atmosphere
mkdir -p .claude/skills
cp -r /tmp/atmosphere/.agents/skills/carnet .claude/skills/carnet
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Carnet trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự tải Carnet ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên Carnet không bị giới hạn ở mô hình mà kỹ năng này được viết cho. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên kỹ năng chưa dùng không tốn chi phí.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

Carnet

The register is Atmosphere/atmosphere-carnet, named by registre.toml. It is private because this repo is public and an entry states precisely where a defence or a capability is incomplete. Many Claude Code sessions work it at once, and nothing on a GitHub issue says a session is on it, so peers collide: two sessions pick up the same issue and build the same fix twice, or find the same gap and write it up twice. A claim fixes that. It is three native GitHub facts that move together:

CarrierMeaning
assigneethe human accountable (gh login)
label in-progressa live session holds the issue
newest carnet-claim marker commentwhich session — id, name, user, host, pid, repo, branch, time

One script does everything: .agents/skills/carnet/carnet.sh (also reachable through the .claude/skills/carnet link). Never run gh issue against the tracker by hand — the script is the one path that keeps the three carriers consistent and the title shape uniform.

The rules

  1. Claim before the first edit — and it happens without you. The PreToolUse hook claims every issue the prompt named as soon as you touch a write tool, so an issue you were told about is held before your first edit lands, and the hook tells you so. Run claim <n> yourself when the number never appeared in a prompt (you found the issue by searching, or you are picking up work mid-session), and when the hook tells you it could NOT claim an issue — gh logged out, the tracker unreachable: it is not held, and peers see it unclaimed. Not after the commit: a claim made after the work is done protects nobody.
  2. A refusal is a peer, not an obstacle. Exit code 2 means another live session holds the issue, or a session on another host does. Tell the user who and which session, and stop. The auto-claim hook enforces this once: it blocks your first edit and names the holder. It does not block again — after that you are accountable, not the hook. Do not --steal on your own judgement — stealing is the user's call, and the stolen-from session is warned on the issue. A claim whose session has ended is not a refusal: release and close exit 1 on it and say so, and a plain claim takes it over.
  3. Release when you stop, close when it is fixed. release <n> when you abandon or hand off; close <n> --why "…" --commit <sha> when the work landed. Both drop the label and the assignee and post a marker. If another session took the issue over, release posts nothing and only drops it from this session's ledger. A session that ends still holding claims is released by the SessionEnd hook, so a forgotten release is not fatal — but do not rely on it.
  4. Unreadable is not unclaimed. When the issue's comments cannot be read in full, claim, release, close and status exit 1 and change nothing: the newest marker is the only record of who holds the issue, and deciding without it is how two sessions end up on one.
  5. Every close says why. --why is mandatory and is what the next reader sees first. Add --commit <sha> whenever a commit resolved it: the tracker is a different repository, so carnet#N in a commit message is plain text to GitHub and never closes anything there. --commit posts the commit's URL on origin.
  6. File through create. It reads the tracker from registre.toml, refuses a tracker that is not private (or whose visibility it cannot read), prefixes the title with the project — [atmosphere] — unless the title already starts with [, and always adds the atmosphere label. Titles are [<project>] <Thing> — one shape, no variants, capitalised first word unless it is an identifier. The body says where it is (file + symbol), what is incomplete, and what the fix looks like. The limitation label goes only on an issue that a LIMITATION(registre#n) marker in source will point at; plain findings get the project label alone.

Commands

bash
C=.agents/skills/carnet/carnet.sh

$C claim 12                       # hold it: assign me, label, marker comment, local ledger
$C claim 12 --steal               # take it from a live or remote session — the user's decision only
$C release 12 --reason "handed to the transport session"
$C status 12                      # who holds it, is that session alive, which branch
$C status                         # every in-progress issue in the tracker
$C mine                           # what this session holds (no API call, works with gh logged out); --verify to check the tracker
$C create --title "<Thing that is incomplete>" --label bug --body-file /tmp/body.md --claim
$C close 12 --why "<what resolved it>" --commit <sha>
$C label 12 +critical -bug
$C tracker                        # the register this checkout files into (no API call)

Add --dry-run to any of them to see the gh calls without making them.

Read the thread before you implement — comments carry requirements the body does not: gh api "repos/$($C tracker)/issues/12/comments" --paginate -q '.[].body'. The script reaches the tracker through gh api (REST) only, because gh issue is GraphQL and a cloud session's agent proxy refuses every GraphQL query outside a pinned set of PR-review operations.

What the hooks do for you

  • UserPromptSubmit (hooks/prompt-status.sh): when a prompt names carnet#N, registre#N, or this register's own name or issue URL (atmosphere-carnet#N, Atmosphere/atmosphere-carnet#N, …/Atmosphere/atmosphere-carnet/issues/N), one status line per issue lands in your context before you answer — carnet#12 · held by @alice · session Wiring (a3f9c2d1) on build-host [running] · feature/wiring · since …. Read it. If it says unclaimed, claim before editing. If it says [session ended — stale], a plain claim takes it over. Another register's issue — dravr-carnet#31, llm-registre#5, its URL — is not this register's and arms nothing: the numbers overlap. A peer message or a background task result gets the status line plus a note saying it armed nothing — see A peer naming an issue is not assigning it below. Lines are cached for a minute under the tracker's name, so a checkout that files into another register never reads this one's, and a cached line naming your own session is never served to you.
  • PreToolUse (hooks/auto-claim.sh): claims those issues for you, on the first write-shaped tool call after the prompt that named them, and tells you what it claimed. Reading is not working — a question about an issue never reaches a write tool and never claims. A Bash call counts as an edit only when the command looks like one (a redirect into a file, sed -i, mv, git commit, …), because a session that edits through bash would otherwise never claim; what sits inside quotes is data, so jq 'select(.n > 5)' or grep -n '<version>' is still a read. If a live peer holds the issue it blocks that one tool call and names them — and names anything it claimed for you in the same step. A claim that fails blocks nothing: you are told carnet: could NOT claim …, and the hook tries again on your next edits (three attempts within the hour). Whether you hold an issue already is the newest claim marker's to say, never the ledger's: a claim cut off half-way — by the hook's timeout, or a failed marker POST — is in the ledger and still not held, and the next attempt finishes it. Subagents share the session's id, so one hook run at a time works the list; a write made meanwhile goes through and leaves it to that run. Before claiming it asks the transcript who wrote the prompt that named the issue: a /loop or ScheduleWakeup re-fire is text the model wrote for itself, and a peer message or task result is text no human wrote, so a list armed by any of those claims nothing and tells you carnet: NOT claimed — carnet#N came from a scheduled wakeup … instead. Take it deliberately if it is yours: carnet.sh claim <n>.
  • SessionEnd (hooks/session-end-release.sh): releases everything this session still holds, from its ledger under $CLAUDE_CONFIG_DIR/carnet-claims/ — each claim in the register its ledger line names — and drops its pending list. Zero calls when nothing is held.

All three are wired in .claude/settings.json; the exact entry is at the top of each hook file, and test.sh fails when one is missing or when the PreToolUse wiring would swallow the hook's exit code. They act on the checkout the session started in ($CLAUDE_PROJECT_DIR), not on wherever it has cd'd since. What the PreToolUse hook tells you arrives as hook context (additionalContext): Claude Code does not show the model a PreToolUse hook's plain output. The auto-claim hook costs one stat when nothing is pending, which is almost always — it runs before every edit in every session, and a list nobody consumed is removed at session end, or by any session once it is an hour old.

What it deliberately does not do. It never claims from a prompt alone, so asking about an issue is free. It never steals. It forgets a pending list an hour old, so an issue mentioned long ago is not claimed by an unrelated edit. It never claims from a peer message, a background task result, a wakeup prompt the session scheduled for itself, or terminal output pasted into the prompt. And it never blocks twice for the same issue: a permanent block would deadlock a session over an issue that was only mentioned in passing.

A wakeup you write is not an assignment you received. When you schedule a wakeup (/loop, ScheduleWakeup), the prompt that comes back is yours, and the hooks know it: the prompt hook cannot tell at submit time (as of Claude Code 2.1.276 the payload carries no source yet, and the transcript entry is written after the hook runs), so it records the prompt id, and the claim hook reads that entry — promptSource: "system", isMeta: true, scheduledTaskId — before claiming. Without that, a session that wrote "comment on carnet#N" into its own wakeup would hold #N for as long as it ran, the user never having typed the number. Do not put issue numbers into a wakeup prompt as a to-do list for yourself; and if you are told a claim was refused because the prompt was a wakeup, that is the hook working.

A peer naming an issue is not assigning it

Sessions message each other, and many of them are working on something else entirely — another repo, another product, a goal that has nothing to do with the register. When one of those is asked a question, the whole correct answer is to answer it. Do not claim the issue the sender mentioned, do not assign it to yourself, do not comment on it, do not start fixing it. If the message does not concern you, one line saying so is a complete reply.

That is enforced, not just asked for. A peer message arrives in the prompt hook as <cross-session-message from="…">, and a background result as <task-notification> — both byte-identical to something the user typed. Arming the claim list from them goes wrong in both directions:

what goes wrong
false claima peer writes "do not put this in carnet#N", or replies "not mine", and the recipient's next edit claims #N — label, assignee and marker comment all assigned to a session that was never going to work it.
false blockone FYI ("I hold carnet#N, stay off these files") blocks a tool call in every session it reaches, each told "Do not do this work twice" about work it never started — some of them in another repo entirely.

Both vectors print the status line and arm nothing: knowing who holds #N is exactly what you need in order to answer the sender, and a peer cannot redirect your session's claim onto an issue it happened to mention. The same goes for a peer's terminal output the user pastes: if the prompt carries transcript glyphs (⏺ ⎿ ✻ ✢ ⏵ ❯ ───) anywhere, nothing arms. Taking work a peer hands over is still fine — it is just explicit: carnet.sh claim <n>.

When you are the sender, say which of the three you mean, in the first line:

IntentWrite it as
FYI, no actionFYI only — I hold carnet#N and am editing <files>. Nothing for you to do; ignore if you are in another repo.
A questionQuestion, no action on the issue: <question>. carnet#N is mine and stays mine.
A real handoffHanding off carnet#N — I have released it. If you take it, claim it first.

The first line is all the recipient's human sees as a preview, and it is what stops an unrelated session from adopting your work out of helpfulness.

How liveness is decided

Claude Code writes sessions/<pid>.json under the config dir for every running session and removes it on exit. A claim on this host is running when that file exists with the same session id and the pid answers kill -0; otherwise it ended and claim takes it over with a "took over" line. A claim from another host cannot be checked, so it is refused without --steal. Outside Claude Code (session=manual) a claim is advisory: it records the human, and nothing auto-releases it. It is that human's alone — every shell outside Claude Code records the same manual session, so a manual claim counts as the caller's own only when it also names the caller's gh login.

Where things are

Trackerregistre.toml → tracker = Atmosphere/atmosphere-carnet (PRIVATE); REGISTRE_TRACKER overrides it, as it does for the limitation gates
Title prefix + labelthe repo name from origin — [atmosphere] and atmosphere — never the checkout's basename, which in a worktree is the branch or agent name
Ledger${CLAUDE_CONFIG_DIR:-~/.claude}/carnet-claims/<session-id>.jsonl; every line names its tracker. Subagents share their session's ledger, so every change to it holds <session-id>.jsonl.lock (a directory naming its holder's pid) while it is written. The lock is broken only when that process is gone; a live holder is waited on for CARNET_LOCK_WAIT seconds (30 unless set, 5 from the hooks), and a mkdir the directory refuses fails at once — an error either way, never a hang. carnet-claims/ is kept at 0700: its cache holds private titles
Status cache${CLAUDE_CONFIG_DIR:-~/.claude}/carnet-claims/cache/<tracker>/<n>, one minute
Tests.agents/skills/carnet/test.sh — stub gh, every refusal path fires; CI runs it from .github/workflows/carnet.yml

Related

  • Limitation markers. The limitation register gates (.registre/limitation-gates.sh, run at pre-push and by .github/workflows/limitation-register.yml) ban deferral prose unless the line carries a LIMITATION(registre#n) marker naming the limited item and pointing at an issue in this tracker. File that issue with create --label limitation first — it prints the marker line to fill in — then write the marker.
  • An open decision in a plan or audit is filed the same way — one issue per decision, so each gets its own close.
  • bilan (.agents/skills/bilan/) reads this skill's ledger: a claim still held, or an issue filed this session and still open (unless it is a registered limitation), caps the session's completion score at 6.

Tệp đi kèm

Mô hình đọc các tệp này khi cần trong lúc kỹ năng được tải. Các tệp được cung cấp ở dạng có thể đọc và không bao giờ được thực thi.

Câu hỏi thường gặp

Kỹ năng AI Carnet làm được gì?

Work the private register (Atmosphere/atmosphere-carnet) from a session — claim an issue before touching it so peers see who holds it and which session, release or close it when done, file new issues in the one canonical shape. Use whenever a carnet#N or registre#N issue is mentioned, when you start or stop work that an issue tracks, or when you are about to run gh issue against the tracker.

Vì sao nên dùng Carnet trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Carnet là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Carnet trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/Atmosphere/atmosphere/tree/main/.agents/skills/carnet. TypingMind đọc tệp SKILL.md, đóng gói các tệp đi kèm và cài đặt thành một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Carnet?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Bạn có thể dùng Carnet với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Carnet với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Carnet có miễn phí không?

Có. Kỹ năng này được Atmosphere phát hành trên GitHub theo giấy phép Apache-2.0. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp cho mô hình các công cụ mới để gọi — mã được chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và tiêu chí của đầu ra tốt. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇