[BUG]: Issue-creation intent is missed when the article is omitted (create issue for this)

Open Beginner friendly
#65 2 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

  • #66 by @Ankitavasudev — closed without merging

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
82/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
ollama, python
Domain
backend

Research direction

Start with ISSUE_TRIGGER_PATTERN and is_issue_creation_request() in bot.py, then read the existing issue intent coverage in scripts/test_link_and_issue_features.py. Reproduce the listed phrasings and extend the pattern and coverage so article-free requests and an optional “github” qualifier are recognized. Done when the listed cases pass and the documented negation limitation remains unchanged.

Written by the indexing model from the issue text.

Description

bug enhancement
Bug Description

is_issue_creation_request() only fires when the verb is followed by an explicit article (an?):

# bot.py:312
ISSUE_TRIGGER_PATTERN = re.compile(r"\b(create|open|file|raise|make)\s+an?\s+issue\b", re.IGNORECASE)

The article is optional in normal English, and dropping it is common in short Discord messages. When the pattern misses, execution falls through to the normal Ollama answer path (bot.py:563-567), so the bot replies to the request conversationally instead of drafting and opening the issue. The user gets no error and no indication that their explicit request was ignored.

Steps to Reproduce

In a thread mapped to a repo, send any of these:

Message is_issue_creation_request()
create an issue for this True
create issue for this False
open issue False
make issue False
file an issue True

Or directly:

from bot import is_issue_creation_request

for q in ["create an issue", "create issue for this", "open issue", "make issue"]:
    print(repr(q), is_issue_creation_request(q))

Output:

'create an issue' True
'create issue for this' False
'open issue' False
'make issue' False
Logs and Screenshots

For the failing phrasings the log shows the normal path (MAPPED PROJECT followed by the Ollama request) and never reaches EXPLICIT ISSUE-CREATION REQUEST detected, which is logged at bot.py:564 when the check succeeds.

Environment Details
  • OS: Windows 11
  • Python: 3.14.0
  • Repository HEAD at time of filing
Impact

Medium - an explicitly requested feature silently does nothing for a common phrasing.

Suggested fix

Make the article optional and allow an optional "github" qualifier:

ISSUE_TRIGGER_PATTERN = re.compile(
    r"\b(?:create|open|file|raise|make)\s+(?:an?\s+)?(?:github\s+)?issue\b",
    re.IGNORECASE,
)

Then extend the existing coverage in scripts/test_link_and_issue_features.py, which currently only tests "an issue" / "a issue" variants. The documented negation limitation ("please don't create an issue") is separate and would remain unchanged.

Code of Conduct
  • I have joined the Discord server and will post updates there
  • I have searched existing issues to avoid duplicates
Dominant language
Python
Stars
10
Forks
12
Avg merge
3m
Merged PRs (30d)
1

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from AOSSIE-Org/SkillBot

All issues in AOSSIE-Org/SkillBot

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.