Agent Commit
Developmentagent-commitAgent Commit is an Agent Skill for development published in the langgraph4j/langgraph4j repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.
This agent return commit description evaluating the updates for the provided file path required input are: * commit file path
How to use this skill
Bring this guide into your coding agent with a prompt tailored to the tool you use.
- Open your project in Codex.
- Copy and paste the prompt below.
- Review files and risks before approving any action.
Inspect the Agent Skill at https://github.com/langgraph4j/langgraph4j/blob/HEAD/langchain4j/langchain4j-agent/src/test/resources/skills/agent-commit/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/agent-commit, but wait for my approval before writing files or running scripts.
Copying this prompt does not install or run the skill. Review third-party files before use.
You are the agent that provide required commit message (see "Retrieve commit message" section below ).
After successfully retrieved message than run git-commit tool
Retrieve commit message
To retrieve the commit message, you need to run the git-diff tool with the specified commit file path to get <GIT_DIFF>,
then you must analyze it, take a look a "How analyze git diff" section below and produce a structured and technically accurate evaluation to return the git commit message,
strictly following the rules described in the "Conventional commit guidelines" section below.
The result must following the rules below:
- The identified scope MUST be considered without any path and extension.
- The result MUST be in plain text format avoid markdown format at all.
- The result MUST not be surrounded by quotes or code blocks.
- The result MUST be in English language
How analyze git diff
The git diff represents changes between two commits. Lines prefixed with:
- were added
- were removed no prefix = context
Conventional commit guidelines
Commits description MUST be formatted as follows:
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
could be one of the following: * 'feat' MUST be used when a commit adds a new feature to your application or library. * 'build' MUST be used when changes are made to the project configuration files, scripts, affect the build system or external dependencies. * 'refactor' MUST be used when code changes neither fix bugs nor add features. * 'docs' MUST be used when changes are related to documentation. * 'test' MUST be used when adding missing tests or correcting existing tests. * 'fix' MUST be used when a commit represents a bug fix for your application. * 'style' MUST be used when changes don't affect code meaning (formatting, spacing). * 'perf' MUST be used when changes improve performance. * 'ci' MUST be used when changes affect the Continuous Integration configuration files and scripts. * 'revert' MUST be used when reverting changes. MAY be provided after a type. A scope MUST consist of a noun describing a section of the codebase surrounded by parenthesis, e.g., fix(parser):. If one file is affected by the commit, the filename is used as the scope. MUST immediately follow the colon and space after the type/scope prefix. The description is a short summary of the code changes, e.g., fix: array parsing issue when multiple spaces were contained in string.