mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Chore: Use auto-triager github action directly and pass labels and prompts files (#98602)
* Add auto triager files and use them in the auto-triager github action * add auto-triager file to codeowners
This commit is contained in:
parent
976cfcbf4f
commit
92fb6e765f
1
.github/CODEOWNERS
vendored
1
.github/CODEOWNERS
vendored
@ -746,6 +746,7 @@ embed.go @grafana/grafana-as-code
|
||||
/.github/pr-checks.json @tolzhabayev
|
||||
/.github/pr-commands.json @tolzhabayev
|
||||
/.github/renovate.json5 @grafana/frontend-ops
|
||||
/.github/workflows/auto-triager/ @grafana/plugins-platform-frontend
|
||||
/.github/workflows/alerting-swagger-gen.yml @grafana/alerting-backend
|
||||
/.github/workflows/auto-milestone.yml @grafana/grafana-developer-enablement-squad
|
||||
/.github/workflows/backport.yml @grafana/grafana-developer-enablement-squad
|
||||
|
125
.github/workflows/auto-triager/labels.txt
vendored
Normal file
125
.github/workflows/auto-triager/labels.txt
vendored
Normal file
@ -0,0 +1,125 @@
|
||||
area/admin/user
|
||||
area/alerting
|
||||
area/annotations
|
||||
area/auth
|
||||
area/auth/ldap
|
||||
area/auth/oauth
|
||||
area/auth/rbac
|
||||
area/auth/serviceaccount
|
||||
area/backend
|
||||
area/backend/api
|
||||
area/backend/db
|
||||
area/backend/db/migration
|
||||
area/backend/db/mysql
|
||||
area/backend/db/postgres
|
||||
area/backend/db/sql
|
||||
area/backend/db/sqlite
|
||||
area/configuration
|
||||
area/dashboard/annotations
|
||||
area/dashboard/data-links
|
||||
area/dashboard/edit
|
||||
area/dashboard/folders
|
||||
area/dashboard/import
|
||||
area/dashboard/kiosk
|
||||
area/dashboard/links
|
||||
area/dashboard/rows
|
||||
area/dashboard/scenes
|
||||
area/dashboard/settings
|
||||
area/dashboard/snapshot
|
||||
area/dashboard/templating
|
||||
area/dashboard/timerange
|
||||
area/dashboard/tv
|
||||
area/dashboard/variable
|
||||
area/dashboards/panel
|
||||
area/data/export
|
||||
area/editor
|
||||
area/explore
|
||||
area/exploremetrics
|
||||
area/expressions
|
||||
area/field/overrides
|
||||
area/frontend/library-panels
|
||||
area/frontend/login
|
||||
area/image-rendering
|
||||
area/internationalization
|
||||
area/legend
|
||||
area/library-panel
|
||||
area/navigation
|
||||
area/panel/annotation-list
|
||||
area/panel/barchart
|
||||
area/panel/bargauge
|
||||
area/panel/candlestick
|
||||
area/panel/canvas
|
||||
area/panel/dashboard-list
|
||||
area/panel/edit
|
||||
area/panel/edit
|
||||
area/panel/field-override
|
||||
area/panel/flame-graph
|
||||
area/panel/gauge
|
||||
area/panel/geomap
|
||||
area/panel/heatmap
|
||||
area/panel/histogram
|
||||
area/panel/logs
|
||||
area/panel/node-graph
|
||||
area/panel/node-graph
|
||||
area/panel/piechart
|
||||
area/panel/repeat
|
||||
area/panel/singlestat
|
||||
area/panel/stat
|
||||
area/panel/state-timeline
|
||||
area/panel/status-history
|
||||
area/panel/table
|
||||
area/panel/timeseries
|
||||
area/panel/traceview
|
||||
area/panel/trend
|
||||
area/panel/xychart
|
||||
area/permissions
|
||||
area/playlist
|
||||
area/plugins
|
||||
area/plugins-catalog
|
||||
area/provisioning
|
||||
area/provisioning/datasources
|
||||
area/public-dashboards
|
||||
area/query-library
|
||||
area/recorded-queries
|
||||
area/scenes
|
||||
area/search
|
||||
area/security
|
||||
area/streaming
|
||||
area/templating/repeating
|
||||
area/tooltip
|
||||
area/transformations
|
||||
datagrid
|
||||
datasource/Alertmanager
|
||||
datasource/Azure
|
||||
datasource/azure-cosmosdb
|
||||
datasource/BigQuery
|
||||
datasource/CloudWatch
|
||||
datasource/CloudWatch Logs
|
||||
datasource/CSV
|
||||
datasource/Elasticsearch
|
||||
datasource/GitHub
|
||||
datasource/GoogleCloudMonitoring
|
||||
datasource/GoogleSheets
|
||||
datasource/grafana-pyroscope
|
||||
datasource/Graphite
|
||||
datasource/InfluxDB
|
||||
datasource/Jaeger
|
||||
datasource/JSON
|
||||
datasource/Loki
|
||||
datasource/MSSQL
|
||||
datasource/MySQL
|
||||
datasource/OpenSearch
|
||||
datasource/OpenTSDB
|
||||
datasource/Parca
|
||||
datasource/Phlare
|
||||
datasource/Postgres
|
||||
datasource/Prometheus
|
||||
datasource/SiteWIse
|
||||
datasource/Splunk
|
||||
datasource/Tempo
|
||||
datasource/TestDataDB
|
||||
datasource/Timestream
|
||||
datasource/X-Ray
|
||||
datasource/Zabbix
|
||||
datasource/Zipkin
|
||||
team/grafana-aws-datasources
|
25
.github/workflows/auto-triager/prompt.txt
vendored
Normal file
25
.github/workflows/auto-triager/prompt.txt
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
You are an expert Grafana issues categorizer.
|
||||
|
||||
You are provided with a Grafana issue. Your task is to categorize the issue by analyzing the issue title and description to determine the most relevant category and type from the provided lists. Focus on precision and clarity, selecting only the most pertinent labels based on the issue details. Ensure that your selections reflect the core problem or functionality affected.
|
||||
|
||||
The output should be a valid JSON object with the following fields:
|
||||
* id (string): The ID of the current issue.
|
||||
* categoryLabel (array of strings): The category labels for the current issue, emphasizing key terms and context.
|
||||
* typeLabel (array of strings): The type of the current issue, emphasizing clarity and relevance.
|
||||
|
||||
**Instructions**:
|
||||
1. **Contextual Analysis**: Understand the context and intent behind the issue description. Analyze the overall narrative and relationships between different components within Grafana. Consider dependencies and related components to inform your decision.
|
||||
2. **Category and Type Differentiation**: Use language cues and patterns to differentiate between similar categories and types. Provide examples and counterexamples to clarify distinctions. Prioritize primary components over secondary ones unless they are critical to the issue.
|
||||
3. **Historical Data Utilization**: Compare current issues with past resolved issues by analyzing similarities in problem descriptions, leveraging patterns to inform categorization. Use historical data to recognize patterns and inform your decision-making.
|
||||
4. **Confidence Scoring**: Implement a confidence scoring mechanism to flag issues for review if the confidence is below a predefined threshold. Clearly indicate thresholds for high and low confidence predictions. Provide clarifying questions if data is ambiguous.
|
||||
5. **Feedback Loop Integration**: Integrate feedback from incorrect predictions to refine understanding and improve future predictions. Conduct error analysis to identify patterns in misclassifications and adapt your approach accordingly.
|
||||
6. **Semantic Analysis**: Evaluate the underlying intent of the issue using semantic analysis, considering broader implications and context. Leverage metadata or historical patterns to improve accuracy.
|
||||
7. **Avoid Over-Specification**: Maintain precision and conciseness, avoiding unnecessary details. Prioritize clarity and flag for further review if uncertain.
|
||||
8. **Consistent JSON Formatting**: Ensure the output maintains a consistent JSON structure with uniform formatting for readability and scalability.
|
||||
|
||||
**Next Steps and Insights**:
|
||||
- Suggest potential next steps or resources that could help address the issue, providing actionable insights to enhance user engagement.
|
||||
- Regularly test responses against edge cases to ensure robustness and adaptability.
|
||||
- Stay updated with changes in category and type lists to remain current.
|
||||
|
||||
Provide a brief explanation of the categorization decision, highlighting key terms or context that influenced the choice. Use user-centric language and technical details to ensure the explanation is comprehensive and insightful.
|
30
.github/workflows/auto-triager/types.txt
vendored
Normal file
30
.github/workflows/auto-triager/types.txt
vendored
Normal file
@ -0,0 +1,30 @@
|
||||
type/accessibility
|
||||
type/angular-2-react
|
||||
type/browser-compatibility
|
||||
type/bug
|
||||
type/build-packaging
|
||||
type/chore
|
||||
type/ci
|
||||
type/cleanup
|
||||
type/codegen
|
||||
type/community
|
||||
type/debt
|
||||
type/design
|
||||
type/discussion
|
||||
type/docs
|
||||
type/duplicate
|
||||
type/e2e
|
||||
type/epic
|
||||
type/feature-request
|
||||
type/feature-toggle-enable
|
||||
type/feature-toggle-removal
|
||||
type/performance
|
||||
type/poc
|
||||
type/project
|
||||
type/proposal
|
||||
type/question
|
||||
type/refactor
|
||||
type/regression
|
||||
type/roadmap
|
||||
type/tech
|
||||
type/ux
|
13
.github/workflows/issue-opened.yml
vendored
13
.github/workflows/issue-opened.yml
vendored
@ -82,23 +82,20 @@ jobs:
|
||||
app_id: ${{ env.GH_APP_ID }}
|
||||
private_key: ${{ env.GH_APP_PEM }}
|
||||
|
||||
- name: Checkout auto-triager repository
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: grafana/auto-triager
|
||||
path: auto-triager
|
||||
token: ${{ steps.generate_token.outputs.token }}
|
||||
|
||||
- name: Send issue to the auto triager action
|
||||
id: auto_triage
|
||||
# https://github.com/grafana/auto-triager/blob/main/action.yml
|
||||
#uses: grafana/auto-triager@main
|
||||
uses: ./auto-triager
|
||||
uses: grafana/auto-triager@main
|
||||
with:
|
||||
token: ${{ steps.generate_token.outputs.token }}
|
||||
issue_number: ${{ github.event.issue.number }}
|
||||
openai_api_key: ${{ env.AUTOTRIAGER_OPENAI_API_KEY }}
|
||||
add_labels: true
|
||||
labels_file: ${{ github.workspace }}/.github/auto-triager/labels.txt
|
||||
types_file: ${{ github.workspace }}/.github/auto-triager/types.txt
|
||||
prompt_file: ${{ github.workspace }}/.github/auto-triager/prompt.txt
|
||||
|
||||
- name: Labels from auto triage
|
||||
run: |
|
||||
|
Loading…
Reference in New Issue
Block a user