Devr.AI icon indicating copy to clipboard operation
Devr.AI copied to clipboard

FEATURE REQUEST: Enhance Classification Prompt for Stricter DevRel Query Handling

Open smokeyScraper opened this issue 1 year ago • 18 comments

Is your feature request related to a problem?

  • [x] Yes, it is related to a problem

Describe the feature you'd like

🌟 Feature Description

This feature focuses on a critical enhancement of the initial Classification Prompt. The goal is to refine the prompt's logic to be much stricter and more precise, ensuring that the DevRel agent is only triggered for queries that are explicitly its responsibility. This involves improving the instructions the LLM uses to decide whether a message requires agent intervention.

Additionally, this task includes a secondary objective to review all other existing prompts (agent_prompt, summarization_prompt, etc.) for clarity, efficiency, and alignment with the latest system architecture.

🔍 Problem Statement

Currently, the classification prompt may be too broad, leading to the DevRel agent responding to general conversations or messages where it's not needed. This can create several issues:

  1. Unnecessary Invocations: The agent wastes resources processing irrelevant messages.
  2. User Annoyance: An AI assistant that injects itself into every conversation can be perceived as intrusive or unhelpful.
  3. Lack of Precision: The agent may misinterpret context and provide answers when it should remain silent, degrading the quality of the user experience.

The core problem is a lack of strict activation boundaries for the agent.

🎯 Expected Outcome

  1. Modified Classification Prompt: The Classification Prompt will be rewritten to include new, strict rules. The agent should only be activated if one of the following conditions is met:
    • The user explicitly tags or mentions the DevRel AI bot (e.g., @Devr.AI, can you help?).
    • The user's query is a direct question about the project, community, contribution process, or a technical issue clearly related to the repository (e.g., "How do I set up the development environment?", "I'm getting a build error.").
    • The prompt will explicitly instruct the model to ignore general chatter, greetings, and conversations between other users unless the bot is tagged.
  2. Reduced False Positives: After implementation, there should be a measurable decrease in the number of times the agent responds to irrelevant conversations.
  3. Improved Prompt Suite: A brief review of all other system prompts will be conducted, with minor enhancements made for clarity and conciseness.

Record

  • [x] I agree to follow this project's Code of Conduct
  • [ ] I want to work on implementing this feature

smokeyScraper avatar Jul 09 '25 21:07 smokeyScraper

@smokeyScraper would like to try this out. Can u assign this to me so that I can start working on it?

HarK-github avatar Jul 23 '25 05:07 HarK-github

yep @HarK-github, you can give it a try.

smokeyScraper avatar Jul 23 '25 06:07 smokeyScraper

Hey @PrithvijitBose, I'm preferring to assign one issue at a time. Please clarify which one you are willing to work on.

PS: @HarK-github are you working on this issue? I'm not very explicitly assigning issues prior a discussion. Please let me know.

smokeyScraper avatar Jul 26 '25 23:07 smokeyScraper

Heyy @smokeyScraper I would like to work on this issue, also thinking to improve the logging as it is taking time to check agent status.

DhruvK278 avatar Jul 30 '25 09:07 DhruvK278

@smokeyScraper Heyy!!!!! I would love to work on this issue. Could you please assign it to me ?

aditi25srivastava avatar Sep 24 '25 13:09 aditi25srivastava

any updates @aditi25srivastava ? Are you still working on the issue?

smokeyScraper avatar Oct 11 '25 08:10 smokeyScraper

heyyy !!! @smokeyScraper I'm sorry for this actually, I am currently preparing for my exams, so I may need a little extra time to updates as soon as possible after my exams are completed.......

aditi25srivastava avatar Oct 11 '25 08:10 aditi25srivastava

Hey @smokeyScraper , I would like to work and solve this issue. If there is nobody assigned, can I solve this?

aryanc381 avatar Oct 16 '25 09:10 aryanc381

I am not assigning any issues as of now @aryanc381. However, you can give it a shot and raise a PR.

smokeyScraper avatar Oct 16 '25 09:10 smokeyScraper

Can I contribute to his problem

g-k-s-03 avatar Oct 18 '25 08:10 g-k-s-03

Okay @aditi25srivastava , excited to raise a PR soon!

aryanc381 avatar Oct 18 '25 13:10 aryanc381

Hi @smokeyScraper ! I’d like to work on this feature and implement the stricter classification prompt logic. Could you please assign this issue to me? Thanks!

cooldeba-21 avatar Oct 22 '25 15:10 cooldeba-21

Hi @smokeyScraper ! I hope you’re doing well!

I noticed that this issue (#93) is still open and currently unassigned.

I’m very interested in working on this enhancement and contributing a clean, well-reviewed PR. My background includes Full Stack (MERN) and Android (Jetpack Compose), and I’m also preparing for GSoC 2026, so this aligns perfectly with the kind of contributor experience I’m building toward.

--> Proposed approach for the fix:

  1. Refine classification_prompt.txt to enforce strict activation boundaries (trigger only on bot tags or clearly scoped technical queries)
  2. Add explicit rules to ignore general chatter/greetings unless tagged
  3. Validate with real test cases to reduce false positives

Keeping commit history clean and meaningful per CONTRIBUTING guidelines

If this direction works, could you please assign this issue to me so I can start working on it?

Looking forward to your guidance. Thanks a lot! 🙌

GitHub: @sanskriti10247

Sanskriti10247 avatar Jan 01 '26 06:01 Sanskriti10247

Hi @smokeyScraper, I’ve reviewed the issue on refining the Classification Prompt to reduce unnecessary DevRel agent activations, and I’d like to take this up as my first contribution, if you feel it’s suitable.

Relevant background: Python, LLM prompt engineering, intent classification logic, and Git-based open-source workflows.

--> Proposed technical approach for this fix:

  1. Rewrite the Classification Prompt to enforce explicit boolean-style activation rules (bot mention OR repository-specific question).
  2. Introduce negative constraints and guard clauses in the prompt to suppress activation on greetings, chatter, and non-actionable messages.
  3. Add structured examples (positive and negative) to anchor model behavior and reduce ambiguity.

Validate changes by testing against real conversation samples and measuring false-positive activation reduction.

Please let me know if I can be assigned to this issue . Thanks for your Guidance !!

swarneshkunden avatar Jan 07 '26 09:01 swarneshkunden

hey @smokeyScraper would it be okay if i start working on this again form the beginning???

aditi25srivastava avatar Jan 18 '26 08:01 aditi25srivastava

Hi @smokeyScraper, I’d like to start working on #93 again from the beginning and implement a clean, stricter classification prompt. Could you please assign this issue to me? Thanks!

Harshi-max avatar Jan 29 '26 08:01 Harshi-max