Skip to content

feat: session-analysis improvements — az JSON, vite noise, prisma generate, hook health check#90

Merged
claudioemmanuel merged 1 commit intomainfrom
feat/89-session-analysis-improvements
Apr 28, 2026
Merged

feat: session-analysis improvements — az JSON, vite noise, prisma generate, hook health check#90
claudioemmanuel merged 1 commit intomainfrom
feat/89-session-analysis-improvements

Conversation

@claudioemmanuel
Copy link
Copy Markdown
Owner

Closes #89

Summary

Four targeted compression improvements identified by analyzing a real Claude Code session that ran for ~4 hours and hit context-compaction twice without squeez active.

Change File Effect
Strip vite-tsconfig-paths + next-lint deprecation warnings src/strategies/smart_filter.rs Cuts ~27KB of repeated noise per typical vitest session (6 runs × ~3KB each)
az boards/az repos JSON field extraction src/commands/cloud.rs Drops _links, relations, extensions; keeps System.* + id/rev/url
prisma generate fast-path src/commands/database.rs Reduces ~5-line boilerplate to single result line
Hook health check on SessionStart hooks/session-start.sh Warns when squeez hooks are missing from settings.json (e.g. wiped by another tool's setup)

Test plan

  • cargo test — all suites green (50+ binaries, 0 failures)
  • New tests added: 2 cloud (az JSON), 3 database (prisma generate), 2 smart_filter (vite noise, next lint)
  • Existing tests unaffected (kubectl, psql, etc.)

Why this matters

A 4-hour transcript analysis captured 142 tool calls / 149KB of raw output flowing uncompressed to the model — and the user had no way to know squeez wasn't active. The health check addresses the silent-failure mode; the other three handlers cut the highest-volume noise patterns observed in the session.

…erate, hook health check

Closes #89

- smart_filter: strip vite-tsconfig-paths and next-lint deprecation warnings
  (one session captured 6 identical copies = 27KB of noise)
- cloud: extract System.* fields from `az boards`/`az repos` JSON, drop
  _links/relations/extensions blocks
- database: fast-path for `prisma generate` — keep only the result line
- session-start: warn when squeez hooks are missing from settings.json
  (e.g. when another tool overwrote the file on its setup)

Signed-off-by: claudioemmanuel <42774167+claudioemmanuel@users.noreply.github.com>
@claudioemmanuel claudioemmanuel force-pushed the feat/89-session-analysis-improvements branch from 0f35e4d to 935cf4a Compare April 28, 2026 18:41
@claudioemmanuel claudioemmanuel merged commit 6e58570 into main Apr 28, 2026
5 checks passed
@claudioemmanuel claudioemmanuel deleted the feat/89-session-analysis-improvements branch April 28, 2026 18:48
claudioemmanuel added a commit that referenced this pull request Apr 28, 2026
The squeez install patches `~/.claude/settings.json` by writing hook
arrays at top-level event keys (settings.PreToolUse, settings.SessionStart,
settings.PostToolUse). Other tools nest under settings.hooks.* — Claude
Code reads both shapes for backwards compat.

The G0 health check shipped in #90 only inspected settings.hooks.* and
falsely reported "missing" on installs where squeez hooks live at the
top level. Now scans both buckets plus the statusLine slot.

Signed-off-by: claudioemmanuel <42774167+claudioemmanuel@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: session-analysis improvements — az JSON, tsconfig noise, prisma generate, hook health check

1 participant