Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: reorganize PR description prompt fields and improve clarity #1432

Merged
merged 1 commit into from
Jan 2, 2025

Conversation

mrT23
Copy link
Collaborator

@mrT23 mrT23 commented Jan 2, 2025

PR Type

Enhancement


Description

  • Refined PR description prompt for clarity and conciseness.

  • Removed redundant fields and improved formatting instructions.

  • Adjusted field descriptions for better alignment with functionality.

  • Updated example output to match new structure.


Changes walkthrough 📝

Relevant files
Enhancement
pr_description_prompts.toml
Refined PR description prompt and examples                             

pr_agent/settings/pr_description_prompts.toml

  • Simplified and clarified the PR description prompt instructions.
  • Removed unnecessary fields like language and redundant descriptions.
  • Adjusted YAML output examples to align with updated structure.
  • Improved formatting and consistency in field descriptions.
  • +10/-17 

    💡 PR-Agent usage: Comment /help "your question" on any pull request to receive relevant information

    Copy link
    Contributor

    PR Reviewer Guide 🔍

    Here are some key observations to aid the review process:

    ⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
    🏅 Score: 92
    🧪 No relevant tests
    🔒 No security concerns identified
    ⚡ Recommended focus areas for review

    Code Organization

    Verify that reordering PR description fields (type, description, title, files) improves readability and maintains logical flow

        type: List[PRType] = Field(description="one or more types that describe the PR content. Return the label member value (e.g. 'Bug fix', not 'bug_fix')")
        description: str = Field(description="summarize the PR changes in up to four bullet points, each up to 8 words. For large PRs, add sub-bullets if needed. Order bullets by importance, with each bullet highlighting a key change group.")
        title: str = Field(description="a concise and descriptive title that captures the PR's main theme")
    {%- if enable_semantic_files_types %}
        pr_files: List[FileDescription] = Field(max_items=20, description="a list of all the files that were changed in the PR, and summary of their changes. Each file must be analyzed regardless of change size.")
    {%- endif %}

    Copy link
    Contributor

    PR Code Suggestions ✨

    Explore these optional code suggestions:

    CategorySuggestion                                                                                                                                    Score
    General
    Ensure consistency in block scalar indicator requirements

    The block scalar indicator example in the system prompt should be consistent with
    the actual requirement ('|' vs '|-').

    pr_agent/settings/pr_description_prompts.toml [7]

    -- If needed, each YAML output should be in block scalar indicator ('|')
    +- Each YAML output MUST be in block scalar indicator ('|')
    • Apply this suggestion
    Suggestion importance[1-10]: 5

    Why: The suggestion correctly identifies an inconsistency between "If needed" vs "MUST" in the block scalar indicator requirements, which would improve clarity and consistency in the documentation.

    5
    • Author self-review: I have reviewed the PR code suggestions, and addressed the relevant ones.

    @mrT23
    Copy link
    Collaborator Author

    mrT23 commented Jan 2, 2025

    PR Description updated to latest commit (f6b470b)

    @mrT23 mrT23 merged commit aa95d5f into main Jan 2, 2025
    2 checks passed
    @mrT23 mrT23 deleted the tr/describe branch January 2, 2025 06:46
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    2 participants