Skip to content

Provide an AGENTS.md file that explains Blacklight#3880

Open
jcoyne wants to merge 1 commit into
mainfrom
agents
Open

Provide an AGENTS.md file that explains Blacklight#3880
jcoyne wants to merge 1 commit into
mainfrom
agents

Conversation

@jcoyne

@jcoyne jcoyne commented Jun 25, 2026

Copy link
Copy Markdown
Member

This cuts down on some of the research an agent would have to do before getting down to work.

@sandbergja sandbergja left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks, @jcoyne ! Two thoughts, neither of them are blockers.

Comment thread AGENTS.md

## What this is

Blacklight is a **Ruby on Rails engine gem** (the `blacklight` rubygem) **plus an npm package** (`blacklight-frontend`) providing the Solr discovery UI. The two ship together. Active development for 9.x is on `main`; older series live on `release-8.x` / `release-7.x` branches. Ruby >= 3.3, Rails >= 7.2 and < 9.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It's nice to give the agent these specifics, but I'm wondering if we'll forget to update the branches when we set up Blacklight 10, and the minimum versions whenver these change. And it strikes me that the minimum versions at least are quite simple for an agent to figure out -- maybe not worth the maintenance burden to include them here?

Comment thread AGENTS.md
Comment on lines +24 to +36
## Testing prerequisites (the main gotchas)

- The suite runs **inside a generated Rails app** at `.internal_test_app/` (gitignored), produced by `engine_cart`; `spec/spec_helper.rb` calls `EngineCart.load_application!`. If it doesn't exist, generate it first: `bundle exec rake engine_cart:generate`.
- Specs need **Solr running** with the `analysis-extras` module. `rake ci` / `rake server` start it via docker compose (preferred) or `solr_wrapper`. To point the suite at an already-running Solr, set `SOLR_ENV=docker-compose` (used by `compose.yaml`).
- Feature specs use **Capybara headless Chrome** (`selenium-webdriver`) — Chrome must be installed.
- Seed data is indexed by `rake blacklight:internal:seed` (source: `spec/fixtures/sample_solr_documents.yml`).

### Environment variables that change behavior

- `RAILS_VERSION`, `SOLR_VERSION`, `VIEW_COMPONENT_VERSION`, `BOOTSTRAP_VERSION`, `BUNDLER_VERSION` — select dependency versions (see `.github/matrix.json`).
- `BLACKLIGHT_API_TEST=1` — run only API-mode tests (tagged `:api`).
- `ENGINE_CART_RAILS_OPTIONS` — flags passed to the generated test app (e.g. `--api`, `--css=bootstrap`).
- `COVERAGE=true` — enable SimpleCov (set by `rake blacklight:coverage`).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I'm glad that we are documenting these in the repo, seems nice for a 🤖 or a human!

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.

I agree, can't we document these in the README?

@tpendragon tpendragon left a comment

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.

Do we need this? Doesn't it work well enough that we don't have to explicitly encourage agent usage? Or at least, can we think about some policy that may hit this file which requires being transparent about it?

@tpendragon tpendragon left a comment

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.

Also there's recent research that shows agents.md may actually make agents worse.

Why would we even want to give better documentation to claude than to humans?

https://arxiv.org/pdf/2602.11988

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.

3 participants