Skip to content

Conversation

litt3
Copy link
Contributor

@litt3 litt3 commented Jul 21, 2025

Makes some small improvements to the batch preprocessing claude command:

  • additional search patterns
  • usage help if user doesn't specify log directory
  • formatting + cleanup

@litt3 litt3 self-assigned this Jul 21, 2025
Signed-off-by: litt3 <[email protected]>
@litt3 litt3 changed the title feat: Improve claude preprocessing command feat: Improve claude log preprocessing command Jul 21, 2025
@litt3 litt3 marked this pull request as ready for review July 21, 2025 19:41
Copy link
Collaborator

@samlaf samlaf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I feel like every claude command should be accompanied by a 5 min loom video where its author shows how to use it and explains the reasoning behind the command.

#### Profile 1: Test Failures
For standard test output failures:
```bash
rg --line-number --ignore-case --json -C 5 -- "^[-]{3} FAIL:|\\s+FAIL\$|\\s+FAIL\\t|\\[FAILED\\]|panic: test timed out" "<original_log_directory>/analysis/shards/" > "<original_log_directory>/analysis/search_results/test_failures_search.jsonl"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one question I have is how do we make these files more readable for humans. I would want to request comments that explain what this is doing so that a human can improve on it in the future, but I'm assuming if we put comments here they will be ingested by the LLM, and potentially take some context needlessly, or worse confuse it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I intentionally didn't leave comments on what these commands are specifically doing. It ends up looking like a regurgitation of the rg docs, which generally isn't very helpful to claude, and it introduces content duplication.

Is it just these explicit rg commands that you find unreadable, or do you think the document in general suffers from poor readability? IMO the document itself ought to be digestible (and if it isn't, then this needs more work), but it's not the end of the world if a specific command like this is tailored for an agent. While not as easily accessible as a comment, it's also not too hard to just ask claude to summarize what such a command is doing, if an engineer wants to understand specifics.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that's a good point actually. Makes it even more explicit now that comments should almost exclusively be targetted for expressing the author's intentions. "explanation" docs can be generated automatically by llms at read time.

@samlaf
Copy link
Collaborator

samlaf commented Jul 28, 2025

image You might need to close adn reopen the PR to get these checks to run. Or maybe you can just "merge when ready" and it'll send it automatically to the merge queue. Not sure...

@litt3 litt3 enabled auto-merge July 28, 2025 19:17
Copy link

The latest Buf updates on your PR. Results from workflow Buf Proto / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedJul 28, 2025, 7:17 PM

@litt3 litt3 added this pull request to the merge queue Jul 28, 2025
Merged via the queue into master with commit 221acc6 Jul 28, 2025
27 checks passed
@litt3 litt3 deleted the better-preprocessing branch July 28, 2025 19:36
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.

2 participants