Skip to content

Making PCP a bit friendlier to AI agents#2583

Open
wcohen wants to merge 6 commits into
performancecopilot:mainfrom
wcohen:wcohen/agentready
Open

Making PCP a bit friendlier to AI agents#2583
wcohen wants to merge 6 commits into
performancecopilot:mainfrom
wcohen:wcohen/agentready

Conversation

@wcohen
Copy link
Copy Markdown
Contributor

@wcohen wcohen commented May 4, 2026

The AgentReady tooling reviews a git repository and suggest changes to make it easier for AI agents to navigate and improve the overall processes for development for the code in the git repository. AgentReady scores the results. The initial assessment of PCP was towards the bottom of the Bronze (42.5). The patches in this merge request provides:

  • A symbolic link for tests to qa to make it easier for AI to determine where the tests are (standard project layout)
  • Headers in the README.md to address (concise documentation)
  • github issue templates and pull request checklist (Issue & Pull Request Templates)

These changes moves PCP's accessment to the middle of the Bronze (51.8). There are some other areas for improvement flagged by AgentReady that are not yet addressed:

  • type annotations of the python code as PCP has now moved to python 3 as requirement. This is going to take some work as there is less than 5% of the python code that currently has annotations
  • pre-commit hooks & ci/cd linting to automate those check
  • additional linting configuration ("Code Smell Elimination") to catch python and markdown issues.

@kurik
Copy link
Copy Markdown
Contributor

kurik commented May 4, 2026

Would it make sense, as part of this PR, to rename CLAUDE.md to AGENTS.md ?
Both files serve the same purpose, however CLAUDE.md is used just by the Claude agent, while AGENTS.md is consumed by most of the AI tools.

@natoscott
Copy link
Copy Markdown
Member

@kurik yes it would IMO - Claude doesn't read that though, so what I see other projects doing (e.g. vllm) is to create a CLAUDE.md that contains:

@AGENTS.md

@wcohen
Copy link
Copy Markdown
Contributor Author

wcohen commented May 5, 2026

@kurik and @natoscott, the AgentReady CLAUDEmdAssessor class does accept a @ reference or a symbolic link to the AGENTS.md file, so the suggested changes would both pass the tests. I don't know which would be "better." However, having the PCP codebase widening the acceptable AI agents with that type of change would be be an improvement.

@kurik
Copy link
Copy Markdown
Contributor

kurik commented May 6, 2026

the AgentReady CLAUDEmdAssessor class does accept a @ reference or a symbolic link to the AGENTS.md file, so the suggested changes would both pass the tests. I don't know which would be "better."

I do not have any strong opinion, not even experience, here. My personal preference would be to have only the AGENTS.md file and no CLAUDE.md. However as @natoscott mentioned above, other project are referencing the AGENTS.md via @ operator in the CLAUDE.md file. So, perhaps we can follow this pattern as well.

@wcohen wcohen requested a review from natoscott May 6, 2026 15:24
@@ -0,0 +1,60 @@
name: Performance Co-Pilot Issue Report
description: Create a report for a PCP related issues on Linux
title: "[Issue] "
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Does adding "[Issue]" to every non-RFE issue really help in any way? I'd prefer to leave the title string as was originally provided if not.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, "[Issue]" is too generic. Looking at how the papi issues which this was based on there are two templates described it .github/ISSUE_TEMPLATE but there is a third "Blank issue" choice when filing a new issue. Maybe it would be better to this called a bug template for PCP.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I did some fixup to make the issue template a more descriptive bug template. I also collected up the patches and put them on an updated checkout of pcp git repo branch.

@natoscott natoscott requested a review from tallpsmith May 9, 2026 12:58
kurik and others added 6 commits May 11, 2026 11:43
  When LC_ALL is set in the caller's environment (e.g. LC_ALL=en_US.utf8),
  it overrides any per-command LC_COLLATE=POSIX setting used inside
  individual QA tests, causing locale-sensitive sort ordering instead of
  the expected POSIX byte-value ordering.  This manifests as spurious
  output mismatches in tests such as 821/1663 where metric names are
  enumerated via "LC_COLLATE=POSIX sort".
  Unsetting LC_ALL at the start of the check script removes the inherited
  override while still allowing individual tests to apply their own
  per-command locale settings (e.g. "LC_COLLATE=en_US.utf8 sort") as
  intended by their authors.
…al docs

Make it a bit simpler for people (and AI) directly looking at the
git repository README.md to get started installing and building PCP
and locating the documentation.
Some times people forget to include details when filing issues on
github. The template should encourage people to include additional
pieces of information that would be useful in addressing the issues.
@wcohen wcohen force-pushed the wcohen/agentready branch from bc20afe to 3d78a48 Compare May 11, 2026 15:49
@tallpsmith
Copy link
Copy Markdown
Contributor

the AgentReady CLAUDEmdAssessor class does accept a @ reference or a symbolic link to the AGENTS.md file, so the suggested changes would both pass the tests. I don't know which would be "better."

I do not have any strong opinion, not even experience, here. My personal preference would be to have only the AGENTS.md file and no CLAUDE.md. However as @natoscott mentioned above, other project are referencing the AGENTS.md via @ operator in the CLAUDE.md file. So, perhaps we can follow this pattern as well.

The @AGENTS.md pattern seems to be the best option. Annoying that Claude Code doesn't natively support it, because the extra CLAUDE.md files are clutter, but I'd personally be screwed without them now, so thanks for taking the time to migrate but maintain Claude support. I agree for an open-source project that being agnostic and aligned on AGENTS.md makes sense though.

@wcohen
Copy link
Copy Markdown
Contributor Author

wcohen commented May 15, 2026

@tallpsmith Any suggested changes to the patches? Or is this good to be merged into upstream?

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.

4 participants