agentleFS
OpenAIKnown publisheropenai/openai-java/AGENTS.md

openai-java

AGENTS.md1.5k starsChanged 3 months agoApache-2.0View on GitHub

Read CONTRIBUTING.md and SECURITY.md before making changes. Most SDK sources are generated; .castiron.stats.yml records generation metadata. Check whether the generator owns the code you are changing, preserve existing generated behavior, and update the authoritative source when it is available. The openai-java-example/ directory is not modified by the generator. Follow the custom-code guidance. Budget changes belong in a separate PR containing only .castiron-ratchet.json, with an explicit justification in the PR description. Increases require a human approving review before merging. Agents may…

  • Reads credentials

Trending

Less talk lately.about the whole repository

Dec 2025: 3 mentionsJan 2026: 4 mentionsFeb 2026: 0 mentionsMar 2026: 1 mentionApr 2026: 0 mentionsMay 2026: 1 mentionJun 2026: 2 mentionsJul 2026: 1 mentionAug 2026: 3 mentionsSep 2026: 2 mentionsOct 2026: 1 mentionNov 2026: 0 mentions
Dec 2025Jun 2026Nov 2026
Mentions a month of the openai/openai-java repository that our weekly crawl found. There is no adoption data for this file yet.

Who's talking about openai/openai-java

The biggest 5 of 45 mentions linking to the repository that our crawl found. Each line is their own headline.

See all 45

Talked about on GitHub, Bluesky and Hacker News (45 times).

On GitHub · 40

35 more on GitHub

On Bluesky · 4

On Hacker News · 1

  • Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.

    Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.

The file

We split this AGENTS.md into the rules it gives an agent

6 rules. About 1 is common, 2 are distinctive, and 3 are very specific to this project.

  • ≈1

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Distinctive:

    Read CONTRIBUTING.md and SECURITY.md before making changes.

    line 3
  2. Very specific:

    Follow the custom-code guidance.

    line 12
  3. Very specific:

    Never commit OpenAI API keys, bearer tokens, AWS/Bedrock credentials, Sonatype tokens, GPG private keys or passphrases, or any other …

    line 22
  4. Common:

    Keep credentials, authorization or cookie headers, signed requests, and real customer data out of default or uncontrolled logs, errors, …

    line 29
  5. Very specific:

    Treat large payloads as a normal API contract, not evidence of malformed or hostile input.

    line 51
  6. Distinctive:

    Prefer incremental processing, amortized-linear buffering, timely cleanup, and caller cancellation.

    line 55

≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

Agent instructions

Read CONTRIBUTING.md and SECURITY.md before making changes.

Most SDK sources are generated; .castiron.stats.yml records generation metadata. Check whether the generator owns the code you are changing, preserve existing generated behavior, and update the authoritative source when it is available. The openai-java-example/ directory is not modified by the generator.

Custom-code budget

Follow the custom-code guidance. Budget changes belong in a separate PR containing only .castiron-ratchet.json, with an explicit justification in the PR description. Increases require a human approving review before merging. Agents may investigate and draft proposals, but must not approve budget increases (including through a human's credentials) or bypass the gate. Do not weaken counting, broaden exclusions, or alter generation metadata to make a change pass. The checker and effective budget come from main, not the PR. Keep default CODEOWNERS.

Security requirements

  • Never commit OpenAI API keys, bearer tokens, AWS/Bedrock credentials, Sonatype tokens, GPG private keys or passphrases, or any other secrets. Read credentials from environment variables such as OPENAI_API_KEY; use obviously fake values in examples, JUnit/WireMock fixtures, recordings, and snapshots. Keep ordinary unit and pull-request tests offline and free of real credentials. Purpose-built, explicitly opt-in live integration tests such as BedrockRuntimeLiveTest may use dedicated, least-privilege credentials and synthetic inputs; never log credentials or customer data.
  • Keep credentials, authorization or cookie headers, signed requests, and real customer data out of default or uncontrolled logs, errors, traces, and test output. Preserve documented diagnostics, including OpenAIServiceException.body(), API-error and validation messages, and explicitly enabled DEBUG request/response body logging. Warn before enabling sensitive diagnostics, use sanitized fixtures, and redact before forwarding data to untrusted sinks.
  • Review direct and transitive Maven dependencies, Gradle plugins and repositories, the Gradle wrapper and distribution integrity, dependency locks, and build/install/download scripts before changing them. Avoid untrusted artifacts, repositories, and executable installation hooks.
  • Pin third-party GitHub Actions to full immutable commit SHAs and review updates. Keep workflow and publishing permissions minimal, disable persisted checkout credentials, never expose secrets to untrusted pull requests, and keep GitHub App tokens, Sonatype credentials, and GPG signing material within their protected release or publishing environments.
  • Require security-focused review for changes to API-key or Bedrock/AWS authentication; OkHttp transport, base URLs, redirects, proxies, TLS, or header forwarding; file uploads and path handling; Jackson serialization/deserialization or polymorphic types; and signing, release, or publication logic. Add focused, boundary-appropriate regression coverage: JUnit/WireMock tests for SDK behavior and workflow, Gradle, or shell checks for signing, release, and publication logic.
  • Report suspected vulnerabilities privately through SECURITY.md. Do not open public issues, discussions, or pull requests containing vulnerability details or secrets.

Large-payload compatibility

Treat large payloads as a normal API contract, not evidence of malformed or hostile input. Responses, Chat Completions, and other APIs can legitimately return large application/json bodies and streaming events. Do not introduce new arbitrary fixed limits on bodies, events, or lines as a security or efficiency fix. Prefer incremental processing, amortized-linear buffering, timely cleanup, and caller cancellation. Any new rejection limit needs an explicit, owner-approved API contract and a review of existing supported payloads and transports. Preserve longstanding dependency limits unless changing them is explicitly in scope; regression fixtures should exercise payloads supported by recent SDK releases.

Protect this behavior with focused, deterministic public-entrypoint tests using large synthetic payloads generated in memory, not committed captures or live image generation. Their high memory use is intentional: do not shrink the payloads or raise client limits to make the tests pass. Keep coverage to the main JSON and streaming categories, and run large cases sequentially to keep peak memory reasonable. The fixture size is a regression probe, not a new API maximum.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.