mirror of
https://github.com/tiennm99/litellm.git
synced 2026-06-18 00:48:01 +00:00
cd9b71093a
- Replace "ML Ops Team" dropdown with "What part of LiteLLM is this about?" with options: SDK, Proxy, UI Dashboard, Docs, Other - Add component dropdown to feature_request.yml template - Rename label-mlops.yml to label-component.yml and update to auto-label issues with sdk, proxy, ui-dashboard, or docs based on selection - Add more provider keywords to issue-keyword-labeler: gemini, cohere, mistral, groq, ollama, deepseek
145 lines
4.7 KiB
YAML
145 lines
4.7 KiB
YAML
name: Label Component Issues
|
|
|
|
on:
|
|
issues:
|
|
types:
|
|
- opened
|
|
|
|
jobs:
|
|
add-component-label:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
issues: write
|
|
steps:
|
|
- name: Add SDK label
|
|
if: contains(github.event.issue.body, 'SDK (litellm Python package)')
|
|
uses: actions/github-script@v7
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
script: |
|
|
const labelName = 'sdk';
|
|
try {
|
|
await github.rest.issues.getLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName
|
|
});
|
|
} catch (error) {
|
|
if (error.status === 404) {
|
|
await github.rest.issues.createLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName,
|
|
color: '0E7C86',
|
|
description: 'Issues related to the litellm Python SDK'
|
|
});
|
|
} else {
|
|
throw error;
|
|
}
|
|
}
|
|
await github.rest.issues.addLabels({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
issue_number: context.issue.number,
|
|
labels: [labelName]
|
|
});
|
|
|
|
- name: Add Proxy label
|
|
if: contains(github.event.issue.body, 'Proxy')
|
|
uses: actions/github-script@v7
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
script: |
|
|
const labelName = 'proxy';
|
|
try {
|
|
await github.rest.issues.getLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName
|
|
});
|
|
} catch (error) {
|
|
if (error.status === 404) {
|
|
await github.rest.issues.createLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName,
|
|
color: '5319E7',
|
|
description: 'Issues related to the LiteLLM Proxy'
|
|
});
|
|
} else {
|
|
throw error;
|
|
}
|
|
}
|
|
await github.rest.issues.addLabels({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
issue_number: context.issue.number,
|
|
labels: [labelName]
|
|
});
|
|
|
|
- name: Add UI Dashboard label
|
|
if: contains(github.event.issue.body, 'UI Dashboard')
|
|
uses: actions/github-script@v7
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
script: |
|
|
const labelName = 'ui-dashboard';
|
|
try {
|
|
await github.rest.issues.getLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName
|
|
});
|
|
} catch (error) {
|
|
if (error.status === 404) {
|
|
await github.rest.issues.createLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName,
|
|
color: 'D876E3',
|
|
description: 'Issues related to the LiteLLM UI Dashboard'
|
|
});
|
|
} else {
|
|
throw error;
|
|
}
|
|
}
|
|
await github.rest.issues.addLabels({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
issue_number: context.issue.number,
|
|
labels: [labelName]
|
|
});
|
|
|
|
- name: Add Docs label
|
|
if: contains(github.event.issue.body, 'Docs')
|
|
uses: actions/github-script@v7
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
script: |
|
|
const labelName = 'docs';
|
|
try {
|
|
await github.rest.issues.getLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName
|
|
});
|
|
} catch (error) {
|
|
if (error.status === 404) {
|
|
await github.rest.issues.createLabel({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
name: labelName,
|
|
color: 'FBCA04',
|
|
description: 'Issues related to LiteLLM documentation'
|
|
});
|
|
} else {
|
|
throw error;
|
|
}
|
|
}
|
|
await github.rest.issues.addLabels({
|
|
owner: context.repo.owner,
|
|
repo: context.repo.repo,
|
|
issue_number: context.issue.number,
|
|
labels: [labelName]
|
|
});
|