Apply labels automatically at issue creation

I have seen the documentation on how to write custom templates for issues, and that is great. Tried the feature and it works perfectly. Now I am wondering if there’s a way to tune each template to perform specific queries automatically. 

What I am specifically looking for is a way to encode the information to auto-label a new issues in the appropriate template. For instance if a user opens a bug report I want the tag “bug” to be automatically applied (given he has sufficient permissions to apply a label).

I have seen that I can do something like this using queries but the bit I am missing is if it is possible to generate those queries from the issue template.

Thanks in advance for any reply!

10 Likes

Hi @alalazo,

This isn’t currently possible, but we’re always working to improve GitHub and consider every suggestion we receive. I’ve logged your feature request in our internal feature request list. Though I can’t guarantee anything or share a timeline for this, I can tell you that it’s been shared with the appropriate teams for consideration.

Please let me know if you have any other questions.

Cheers!

8 Likes

Hey @alalazo,

have a look at https://defects.ai
It is a service to predict labels for GitHub Issues fully automated, with machine learning models.
I am the creator of Defects AI, reach out to me if you have any questions ✌️

labeling.png

Cheers
Sascha

1 Like

Started using the Issues Template. It is so cool.

Would be really happy to have labels attached along with templates.

3 Likes

I see the issue template now support labels, but not projects, will project tag be added?

https://help.github.com/articles/manually-creating-a-single-issue-template-for-your-repository/

7 Likes

Hi @jasonycw,

We’re always working to improve GitHub, and we consider every suggestion we receive. I don’t know of any set plans to implement this, but I’ve logged your feature request in our internal feature request list. Though I can’t guarantee anything or share a timeline for this, I can tell you that it’s been shared with the appropriate teams for consideration.

Please let me know if you have any other questions.

Cheers!

3 Likes

@nadiajoyce Thank you for implementing the feature! One question: is there any way to apply multiple labels? For instance can I e.g. apply the labels “bug” and “help wanted” simultaneously to a type of report?

1 Like

Hi @alalazo,

Yes, indeed! You just need to list them, and separate with commas. Example: 

labels: bug, feedback

^ That will produce an issue with the labels bug and feedback both applied.

Cheers!

8 Likes

Hi

I’m trying to add title: and labels: as YAML frontmatter but the feature just isn’t working for me. Can someone tell me what is wrong with the following please?:


name: Release_A_Deliver
title: “Deliver Release x.x”
about: Epic for delivering next release
labels: “jester:userdoc”, “jester:website”, “jester:other”

2 Likes

Have to add to this thread too that adding labels automatically to a template would be very very useful! :smiley:

Oh! It’s done! Perfect!

Hi,

I am using a corporate account and the fields Title and Labels are filled. If I try in my private github account, it works fine.

Is there a limitation related to versioning?

Hugs,

Cláudio Ramos

3 Likes

I have the same issue/need and we are using GitHub Enterprise 2.15.4

2 Likes

What about the projects … ? automatic assigning a project in an issue template

It does not work for me on GitHub.com 

Please help … Thanks, Ralf

3 Likes

@jasonycw wrote:

I see the issue template now support labels, but not projects, will project tag be added?

https://help.github.com/articles/manually-creating-a-single-issue-template-for-your-repository/

 

Fyi, for labels with spaces or characters that are not working with markdown or yaml formats you just need to wrap the value in quotes.

labels: "jester:userdoc, jester:website, jester:other"