Skip to content

Added: Agent guidelines documentation#24

Merged
fronzec merged 2 commits intomainfrom
ai-features
Feb 9, 2026
Merged

Added: Agent guidelines documentation#24
fronzec merged 2 commits intomainfrom
ai-features

Conversation

@fronzec
Copy link
Owner

@fronzec fronzec commented Feb 9, 2026

Introduced AGENTS.md to standardize coding standards and practices for AI agents in fr-batch-service. Includes build, lint, and test commands, code style conventions, and best practices to ensure consistency and maintainability.

Summary by CodeRabbit

  • Documentation
    • Added comprehensive agent guidelines documenting Maven build/test/lint commands, formatting tooling usage, and detailed Java coding standards (formatting, imports, naming, types, error handling, comments, and general best practices) to help maintain consistent development and contribution workflows.

Introduced `AGENTS.md` to standardize coding standards and practices for AI agents in `fr-batch-service`. Includes build, lint, and test commands, code style conventions, and best practices to ensure consistency and maintainability.
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 9, 2026

📝 Walkthrough

Walkthrough

A new documentation file, fr-batch-service/AGENTS.md, was added containing agent guidelines: Maven build/test/lint commands, formatting tooling notes, and comprehensive Java coding standards (formatting, imports, naming, types, error handling, comments, and best practices).

Changes

Cohort / File(s) Summary
Documentation
fr-batch-service/AGENTS.md
Added new agent guidelines (≈115 lines) describing Maven commands, spotless/Prettier formatting setup, plugin notes, and detailed Java coding conventions (imports, naming, types, generics, exceptions, Javadoc, and best practices).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐇 I hopped in to leave a tiny sign,

Rules for code, and lines that shine.
Spotless paws and tidy imports near,
Agents build batches with nothing to fear.
A little rabbit cheers — well done, sincere!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Added: Agent guidelines documentation' clearly and directly summarizes the main change: adding documentation for agent guidelines to the fr-batch-service repository.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch ai-features

No actionable comments were generated in the recent review. 🎉


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 and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 3

🤖 Fix all issues with AI agents
In `@fr-batch-service/AGENTS.md`:
- Line 67: The sentence in AGENTS.md incorrectly states wildcard imports appear
"after" specific imports when the setting wildcardsLast is false; update the
text to say wildcards appear FIRST when wildcardsLast is false (or note that to
place wildcards after specific imports you must set wildcardsLast to true), and
adjust the example phrasing around "Wildcards:" so it correctly references the
wildcardsLast boolean behavior.
- Line 61: Replace the ambiguous phrase "indicated by commented Prettier plugin"
in the indentation bullet with an explicit statement that the project uses the
prettier-maven-plugin (prettier-java) configured in pom.xml; e.g., say that
Prettier is enforced via the prettier-maven-plugin (prettier-java) in pom.xml
and that any comment in this file merely references that configuration, rather
than implying an optional or commented-out plugin.
- Line 40: Update the wording in AGENTS.md about the spotless-maven-plugin
status: replace "currently temporarily disabled" with a more accurate phrase
(e.g., "disabled as of Dec 2024" or "disabled (no near-term plan to re-enable)")
to match the pam.xml comment; mention the configured formatter (googleJavaFormat
with AOSP style) remains in the config so readers know what would be applied if
re-enabled, and ensure the change references the spotless-maven-plugin and
googleJavaFormat/AOSP wording so it’s clear which plugin and style the status
refers to.
🧹 Nitpick comments (1)
fr-batch-service/AGENTS.md (1)

66-66: Simplify the technical import ordering syntax for better readability.

The import ordering string java|javax,org,com,com.diffplug,,\#com.diffplug,\# appears to be copied directly from a Spotless configuration file. While technically accurate, this syntax may be confusing for readers unfamiliar with Spotless configuration format.

📝 Suggested simplification

Consider rewriting this in plain language:

-*   **Ordering:** Imports are organized as `java|javax,org,com,com.diffplug,,\#com.diffplug,\#`. Static imports are grouped separately after regular imports.
+*   **Ordering:** Imports are organized in the following groups:
+    1. `java` and `javax` packages
+    2. Third-party packages (`org`, `com`)
+    3. Project-specific packages
+    4. Static imports (grouped separately after regular imports)


### Linting and Formatting

The project uses `spotless-maven-plugin` for code formatting, although it is currently temporarily disabled. When enabled, it enforces `googleJavaFormat` with AOSP style.
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Find and examine pom.xml files for spotless-maven-plugin configuration
fd -t f '^pom\.xml$' | head -5

Repository: fronzec/spring-batch-projects

Length of output: 97


🏁 Script executed:

#!/bin/bash
# Read pom.xml and find spotless-maven-plugin configuration
cat fr-batch-service/pom.xml | grep -A 15 -B 2 'spotless-maven-plugin'

Repository: fronzec/spring-batch-projects

Length of output: 793


🏁 Script executed:

#!/bin/bash
# Get more context around spotless configuration
grep -A 30 '<groupId>com.diffplug.spotless</groupId>' fr-batch-service/pom.xml

Repository: fronzec/spring-batch-projects

Length of output: 1592


🏁 Script executed:

#!/bin/bash
# Search for java formatting configuration (googleJavaFormat) in spotless config
grep -A 50 '<groupId>com.diffplug.spotless</groupId>' fr-batch-service/pom.xml | grep -A 20 'java\|google'

Repository: fronzec/spring-batch-projects

Length of output: 1078


🏁 Script executed:

#!/bin/bash
# Search for googleJavaFormat style configuration in pom.xml
grep -i 'googleJavaFormat\|aosp' fr-batch-service/pom.xml

Repository: fronzec/spring-batch-projects

Length of output: 264


Update "temporarily disabled" to reflect current status.

The documentation correctly states that spotless-maven-plugin is disabled with googleJavaFormat AOSP style configured. However, the pom.xml comment shows it has been disabled since December 2024 (14+ months). If re-enabling is no longer planned for the near term, update the language from "currently temporarily disabled" to more accurately reflect the actual status—either a specific timeline or simply "disabled" without the "temporarily" qualifier.

🤖 Prompt for AI Agents
In `@fr-batch-service/AGENTS.md` at line 40, Update the wording in AGENTS.md about
the spotless-maven-plugin status: replace "currently temporarily disabled" with
a more accurate phrase (e.g., "disabled as of Dec 2024" or "disabled (no
near-term plan to re-enable)") to match the pam.xml comment; mention the
configured formatter (googleJavaFormat with AOSP style) remains in the config so
readers know what would be applied if re-enabled, and ensure the change
references the spotless-maven-plugin and googleJavaFormat/AOSP wording so it’s
clear which plugin and style the status refers to.

### Imports

* **Ordering:** Imports are organized as `java|javax,org,com,com.diffplug,,\#com.diffplug,\#`. Static imports are grouped separately after regular imports.
* **Wildcards:** Wildcard imports (`import com.example.*`) are generally discouraged; prefer explicit imports. If used, they will appear *after* specific imports as `wildcardsLast` is `false`.
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Correct the factual error about wildcard import ordering.

The statement claims that wildcards will appear "after" specific imports when wildcardsLast is false, but this is incorrect. When wildcardsLast is set to false, wildcard imports actually appear FIRST (before specific imports), not after.

🔧 Proposed correction
-*   **Wildcards:** Wildcard imports (`import com.example.*`) are generally discouraged; prefer explicit imports. If used, they will appear *after* specific imports as `wildcardsLast` is `false`.
+*   **Wildcards:** Wildcard imports (`import com.example.*`) are generally discouraged; prefer explicit imports. If used, they will appear *before* specific imports as `wildcardsLast` is `false`.

Or, if wildcards should appear after specific imports, the configuration should be wildcardsLast set to true.

📝 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
* **Wildcards:** Wildcard imports (`import com.example.*`) are generally discouraged; prefer explicit imports. If used, they will appear *after* specific imports as `wildcardsLast` is `false`.
* **Wildcards:** Wildcard imports (`import com.example.*`) are generally discouraged; prefer explicit imports. If used, they will appear *before* specific imports as `wildcardsLast` is `false`.
🤖 Prompt for AI Agents
In `@fr-batch-service/AGENTS.md` at line 67, The sentence in AGENTS.md incorrectly
states wildcard imports appear "after" specific imports when the setting
wildcardsLast is false; update the text to say wildcards appear FIRST when
wildcardsLast is false (or note that to place wildcards after specific imports
you must set wildcardsLast to true), and adjust the example phrasing around
"Wildcards:" so it correctly references the wildcardsLast boolean behavior.

@fronzec fronzec merged commit dd3cdaf into main Feb 9, 2026
3 checks passed
@fronzec fronzec deleted the ai-features branch February 9, 2026 03:53
@coderabbitai coderabbitai bot mentioned this pull request Feb 15, 2026
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