Skip to content

feat: improve maintainers analysis prompt [CM-1049]#3919

Merged
mbani01 merged 2 commits intomainfrom
feat/improve-haiku-extraction-prompt
Mar 13, 2026
Merged

feat: improve maintainers analysis prompt [CM-1049]#3919
mbani01 merged 2 commits intomainfrom
feat/improve-haiku-extraction-prompt

Conversation

@mbani01
Copy link
Contributor

@mbani01 mbani01 commented Mar 13, 2026

This pull request updates the maintainer extraction prompt logic to ensure more comprehensive and accurate extraction of individual contributors from repository files. The changes expand the scope of extraction, clarify role mapping, and improve instructions for identifying GitHub usernames and emails.

Enhancements to extraction scope and instructions:

  • The extraction prompt now instructs to scan the entire file and extract every person listed, regardless of section or role, ensuring no individuals are missed.
  • Added a critical directive to include every person found in any role, without filtering by role importance.

Improvements to role mapping and identification:

  • Clarified that reviewers and designated reviewers should be mapped to the "maintainer" normalized title.
  • Expanded patterns for identifying GitHub usernames to include markdown links and additional email formats.

Note

Medium Risk
Changes the LLM prompt that drives maintainer ingestion, which can materially alter who gets extracted and persisted (including role classification) and may increase false positives/DB churn. No runtime logic changes beyond prompt text, but output variance can affect downstream maintainer updates.

Overview
Improves the maintainer-extraction LLM prompt to scan the entire file and return every listed individual (across maintainers/contributors/reviewers/etc.) instead of implicitly focusing on a single section.

Clarifies parsing rules by expanding GitHub username detection (markdown links and more users.noreply.github.com email formats) and explicitly mapping reviewers to normalized_title: "maintainer", while keeping the same JSON output contract and not_found behavior.

Written by Cursor Bugbot for commit 3f21068. This will update automatically on new commits. Configure here.

Signed-off-by: Mouad BANI <mouad-mb@outlook.com>
@mbani01 mbani01 self-assigned this Mar 13, 2026
Copilot AI review requested due to automatic review settings March 13, 2026 15:27
@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

2 similar comments
@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

@mbani01 mbani01 changed the title feat: improve maintainers analysis prompt feat: improve maintainers analysis prompt [CM-1049] Mar 13, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the LLM extraction prompt used by the maintainer analysis service to broaden extraction beyond just “maintainers” and improve identification/mapping guidance.

Changes:

  • Expands prompt scope to scan the entire file and include every listed individual (across roles/sections).
  • Clarifies role normalization (e.g., reviewers → maintainer) and strengthens “don’t filter” instructions.
  • Expands GitHub username detection patterns (markdown profile links and noreply email variants).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment on lines 208 to +210
- Your final output MUST be a single JSON object.
- If maintainers are found, the JSON format must be: `{{"info": [list_of_maintainer_objects]}}`
- If no individual maintainers are found, or only teams/groups are mentioned, the JSON format must be: `{{"error": "not_found"}}`
- If no individual maintainers are found, the JSON format must be: `{{"error": "not_found"}}`
Your task is to extract every person listed in the file content provided below, regardless of which section they appear in. Follow these rules precisely:

- **Primary Directive**: First, check if the content itself contains a legend or instructions on how to parse it (e.g., "M: Maintainer, R: Reviewer"). If it does, use that legend to guide your extraction.
- **Scope**: Process the entire file. Do not stop after the first section. Every section (Maintainers, Contributors, Authors, Previous Maintainers, Reviewers, etc.) must be scanned and all listed individuals extracted.
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Signed-off-by: Mouad BANI <mouad-mb@outlook.com>
@mbani01 mbani01 merged commit 255fd66 into main Mar 13, 2026
9 checks passed
@mbani01 mbani01 deleted the feat/improve-haiku-extraction-prompt branch March 13, 2026 15:34
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.

2 participants