collectlisted
Install: claude install-skill apache/skywalking-ai-sessionizer
# Collect local Claude Code data
Runs the `claude-code-local` adapter over this machine's own Claude Code files.
It reads only what is already on disk — nothing needs to be enabled in Claude
Code, and it works on history that predates the collector.
## 1. Resolve the source directory
The location is **not** fixed. Resolve in this order and report which one won:
```sh
if [ -n "$CLAUDE_CONFIG_DIR" ]; then SRC="$CLAUDE_CONFIG_DIR/projects"
elif [ -n "$XDG_CONFIG_HOME" ]; then SRC="$XDG_CONFIG_HOME/claude/projects"
else SRC="$HOME/.claude/projects"
fi
ls -d "$SRC" && du -sh "$SRC"
```
`asz` performs the same resolution internally, so normally you do not pass
`source_root` at all. Set it only when collecting from a copy or a mounted corpus.
## 2. Build
```sh
make build # -> ./bin/asz
```
## 3. See what is discoverable before collecting
```sh
./bin/asz sources
```
Reports one row per session with its stream, meta, journal and manifest counts,
then a footer naming any session whose files span more than one source
directory. Read it for two things:
- **`filtered: N session(s) excluded by config`** — the default config excludes
`/private/tmp/**` (Claude Code's own agent scratchpads). If a session you
expect is missing, this is why.
- **sessions spanning several directories** — normal. A child agent that ran in
a different working directory is filed under that directory instead.
## 4. Collect
Default storage root is `