anthropics / anthropics/claude-code

Project session JSONL: 13+ record types, variable type placement, no schema/version marker — request for a documented record-type enum

Offen
#92,735 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
documentation enhancement
Vorherrschende Sprache
Python
Sterne
145k
Forks
23.1k
PR-Merge-Kennzahlen
PR-Kennzahlen ausstehend

Beschreibung

## Summary
We built fail-closed analytics over Claude Code project session files (`~/.claude/projects//.jsonl`; 128 sessions / 7 days in a multi-vendor orchestration). Observations from a tokenized structural specimen (all values replaced with type tokens; key sets and `type` placement preserved exactly):

https://github.com/oguzhanpisgin/ai-session-analytics/tree/main/specimens/claude

## Findings
1. **13+ record types** beyond `user`/`assistant`: `ai-title`, `atis-latch`, `last-prompt`, `queue-operation`, `custom-title`, `mode`, `frame-link`, `bridge-session`, `pr-link`, `artifact-comment-monitor`, `artifact-autoreact-ledger`, `agent-setting`, `attachment` (counts from a 7-day sample in the linked specimen README).
2. **`type` placement varies**: message lines carry `type` mid-object (after `parentUuid`, `isSidechain`, ...), while metadata lines carry it first. Type-first regex parsing silently misses all message lines — micro-benchmark here:
https://github.com/anthropics/claude-code — see benchmarks/claude-record-mix in the analytics repo above (2/4 lines recognized on a 4-line file).
3. **No schema/version marker** anywhere in the file.

## Request
A **documented, versioned record-type enum** for the project JSONL format (type names + key sets + placement rules, with a version field). This would let third-party analytics detect format evolution instead of silently mis-parsing.

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Rechercherichtung

Start with the linked specimens/claude README and the claude-record-mix benchmark to verify the listed record types, key sets, and type placement. Then locate the project session JSONL documentation in Claude Code and determine where a version field and record-type enum could be documented. Done means the format has a documented version, complete record-type coverage, key sets, and placement rules.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
json
Bereich
documentation
Issue-Typ
Dokumentation
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Aktiv
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
38/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.