Skip to content

Commit

Permalink
Merge branch 'main' into of/issue_template
Browse files Browse the repository at this point in the history
  • Loading branch information
ofir-frd committed Jan 26, 2025
2 parents c4a70f4 + 3f6fa5c commit 84d81de
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 7 deletions.
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ PR-Agent aims to help efficiently review and handle pull requests, by providing
</div>

### [Documentation](https://qodo-merge-docs.qodo.ai/)

- See the [Installation Guide](https://qodo-merge-docs.qodo.ai/installation/) for instructions on installing PR-Agent on different platforms.

- See the [Usage Guide](https://qodo-merge-docs.qodo.ai/usage-guide/) for instructions on running PR-Agent tools via different interfaces, such as CLI, PR Comments, or by automatically triggering them when a new PR is opened.
Expand All @@ -31,6 +32,7 @@ PR-Agent aims to help efficiently review and handle pull requests, by providing


## Table of Contents

- [News and Updates](#news-and-updates)
- [Overview](#overview)
- [Example results](#example-results)
Expand All @@ -41,6 +43,19 @@ PR-Agent aims to help efficiently review and handle pull requests, by providing

## News and Updates

### Jan 25, 2025

The open-source GitHub organization was updated:
`https://github.com/codium-ai/pr-agent`
`https://github.com/qodo-ai/pr-agent`

The docker should be redirected automatically to the new location.
However, if you have any issues, please update the GitHub action docker image from
`uses: Codium-ai/pr-agent@main`
to
`uses: qodo-ai/pr-agent@main`


### Jan 2, 2025

New tool [/Implement](https://qodo-merge-docs.qodo.ai/tools/implement/) (💎), which converts human code review discussions and feedback into ready-to-commit code changes.
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/installation/github.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
steps:
- name: PR Agent action step
id: pragent
uses: Codium-ai/pr-agent@main
uses: qodo-ai/pr-agent@main
env:
OPENAI_KEY: ${{ secrets.OPENAI_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion pr_agent/settings/pr_code_suggestions_prompts.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ Specific guidelines for generating code suggestions:
- Do not suggest to change packages version, add missing import statement, or declare undefined variable.
{%- endif %}
- When mentioning code elements (variables, names, or files) in your response, surround them with backticks (`). For example: "verify that `user_id` is..."
- Note that you only see changed code segments (diff hunks in a PR), not the entire codebase. Avoid suggestions that might duplicate existing functionality or questioning code elements (like variables declerations or import statements) that may be defined elsewhere in the codebase.
- Note that you only see changed code segments (diff hunks in a PR), not the entire codebase. Avoid suggestions that might duplicate existing functionality or questioning code elements (like variables declarations or import statements) that may be defined elsewhere in the codebase.
{%- if extra_instructions %}
Expand Down
10 changes: 7 additions & 3 deletions pr_agent/tools/pr_help_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,10 +174,11 @@ async def run(self):
tool_names.append(f"[IMPROVE COMPONENT]({base_path}/improve_component/) 💎")
tool_names.append(f"[ANALYZE]({base_path}/analyze/) 💎")
tool_names.append(f"[ASK]({base_path}/ask/)")
tool_names.append(f"[SIMILAR ISSUE]({base_path}/similar_issues/)")
tool_names.append(f"[GENERATE CUSTOM LABELS]({base_path}/custom_labels/) 💎")
tool_names.append(f"[CI FEEDBACK]({base_path}/ci_feedback/) 💎")
tool_names.append(f"[CUSTOM PROMPT]({base_path}/custom_prompt/) 💎")
tool_names.append(f"[SIMILAR ISSUE]({base_path}/similar_issues/)")
tool_names.append(f"[IMPLEMENT]({base_path}/implement/) 💎")

descriptions = []
descriptions.append("Generates PR description - title, type, summary, code walkthrough and labels")
Expand All @@ -189,10 +190,11 @@ async def run(self):
descriptions.append("Code suggestions for a specific component that changed in the PR")
descriptions.append("Identifies code components that changed in the PR, and enables to interactively generate tests, docs, and code suggestions for each component")
descriptions.append("Answering free-text questions about the PR")
descriptions.append("Automatically retrieves and presents similar issues")
descriptions.append("Generates custom labels for the PR, based on specific guidelines defined by the user")
descriptions.append("Generates feedback and analysis for a failed CI job")
descriptions.append("Generates custom suggestions for improving the PR code, derived only from a specific guidelines prompt defined by the user")
descriptions.append("Automatically retrieves and presents similar issues")
descriptions.append("Generates implementation code from review suggestions")

commands =[]
commands.append("`/describe`")
Expand All @@ -204,10 +206,11 @@ async def run(self):
commands.append("`/improve_component`")
commands.append("`/analyze`")
commands.append("`/ask`")
commands.append("`/similar_issue`")
commands.append("`/generate_labels`")
commands.append("`/checks`")
commands.append("`/custom_prompt`")
commands.append("`/similar_issue`")
commands.append("`/implement`")

checkbox_list = []
checkbox_list.append(" - [ ] Run <!-- /describe -->")
Expand All @@ -226,6 +229,7 @@ async def run(self):
checkbox_list.append("[*]")
checkbox_list.append("[*]")
checkbox_list.append("[*]")
checkbox_list.append("[*]")

if isinstance(self.git_provider, GithubProvider) and not get_settings().config.get('disable_checkboxes', False):
pr_comment += f"<table><tr align='left'><th align='left'>Tool</th><th align='left'>Description</th><th align='left'>Trigger Interactively :gem:</th></tr>"
Expand Down
2 changes: 1 addition & 1 deletion pr_agent/tools/pr_reviewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ def set_review_labels(self, data):
else:
get_logger().warning(f"Unexpected type for estimated_effort: {type(estimated_effort)}")
if 1 <= estimated_effort_number <= 5: # 1, because ...
review_labels.append(f'Review effort: {estimated_effort_number}/5')
review_labels.append(f'Review effort [1-5]: {estimated_effort_number}')
if get_settings().pr_reviewer.enable_review_labels_security and get_settings().pr_reviewer.require_security_review:
security_concerns = data['review']['security_concerns'] # yes, because ...
security_concerns_bool = 'yes' in security_concerns.lower() or 'true' in security_concerns.lower()
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ dynamic = ["dependencies"]
dependencies = { file = ["requirements.txt"] }

[project.urls]
"Homepage" = "https://github.com/Codium-ai/pr-agent"
"Homepage" = "https://github.com/qodo-ai/pr-agent"
"Documentation" = "https://pr-agent-docs.codium.ai/"

[tool.setuptools]
Expand Down

0 comments on commit 84d81de

Please sign in to comment.