Skip to content

docs(agents): add setup, checks, and agent gotchas to AGENTS.md#6543

Open
Zandereins wants to merge 1 commit into
crewAIInc:mainfrom
Zandereins:docs/agents-md-operational-info
Open

docs(agents): add setup, checks, and agent gotchas to AGENTS.md#6543
Zandereins wants to merge 1 commit into
crewAIInc:mainfrom
Zandereins:docs/agents-md-operational-info

Conversation

@Zandereins

Copy link
Copy Markdown

What

Adds the operational information an agent needs to work in this repo to AGENTS.md: setup, the CI-enforced checks, and three gotchas that are easy to hit blind.

Why

AGENTS.md is the file coding agents load on startup, but today it carries only style guidance — the commands and constraints live in .github/CONTRIBUTING.md, which an agent doesn't read by default.

The sharpest example: the llm-generated label requirement is a rule aimed specifically at AI agents, and it is currently invisible to them. An agent following only AGENTS.md today cannot install the workspace, cannot run the tests, and will open a PR that gets closed unlabeled.

Everything added is taken from this repo's own sources, not invented:

  • setup + checks — .github/CONTRIBUTING.md and the tests, linter, type-checker workflows
  • --block-network / VCR cassettes — [tool.pytest.ini_options] addopts in pyproject.toml
  • PR-title rules — .github/workflows/pr-title.yml
  • label requirement — .github/CONTRIBUTING.md

Additive only: nothing existing was removed or reworded, and no build command was invented (this workspace doesn't have one).

Note

This PR was authored by an AI agent (Claude Code). Per CONTRIBUTING it needs the llm-generated label; outside contributors can't apply labels, so flagging it here for a maintainer.


Context: I found this while running a deterministic quality survey of AGENTS.md files across major agent repos — crewAI scored 55/100, almost entirely for missing operational content. Happy to share the method if it's useful.

@coderabbitai

coderabbitai Bot commented Jul 14, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

AGENTS.md adds contributor guidance for AI-generated changes, local environment setup, required validation commands, network-blocked tests, Conventional Commits titles, and branch naming.

Changes

Contributor Guidance

Layer / File(s) Summary
Contribution instructions
AGENTS.md
Adds requirements for llm-generated labels, uv setup, pre-commit installation, pytest/ruff/mypy checks, network-blocked tests, Conventional Commits titles, and branch naming.

Suggested reviewers: vinibrsl, lorenzejay

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the AGENTS.md update and its main additions.
Description check ✅ Passed The description matches the changeset and explains the added setup, checks, and gotchas.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@AGENTS.md`:
- Around line 27-32: Update the documented ruff formatting command in the
command list to use check-only mode, matching CI, while leaving the pytest,
lint, and mypy commands unchanged.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: a7c558b8-8959-4f0c-bbed-80ab1034ad7c

📥 Commits

Reviewing files that changed from the base of the PR and between 9d72e26 and c4dd5f8.

📒 Files selected for processing (1)
  • AGENTS.md

Comment thread AGENTS.md
Comment on lines +27 to +32
```bash
uv run pytest lib/crewai/tests/ -x -q # tests for the core package
uv run ruff check lib/ # lint
uv run ruff format lib/ # format (CI runs it with --check)
uv run mypy lib/ # type check, strict mode
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Use the CI-equivalent format check.

Line 30 runs formatting in write mode, while CI validates with ruff format --check lib/. Replace it with the check-only command to avoid modifying files during validation.

-uv run ruff format lib/                 # format (CI runs it with --check)
+uv run ruff format --check lib/         # format check
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
```bash
uv run pytest lib/crewai/tests/ -x -q # tests for the core package
uv run ruff check lib/ # lint
uv run ruff format lib/ # format (CI runs it with --check)
uv run mypy lib/ # type check, strict mode
```
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@AGENTS.md` around lines 27 - 32, Update the documented ruff formatting
command in the command list to use check-only mode, matching CI, while leaving
the pytest, lint, and mypy commands unchanged.

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.

1 participant