-
Notifications
You must be signed in to change notification settings - Fork 129
Fix classification fallback bug and enhance all prompts (Issue #93) #191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
LinKon12
wants to merge
5
commits into
AOSSIE-Org:main
Choose a base branch
from
LinKon12:fix-classification-prompt-93
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
2233f29
Fix classification fallback bug and enhance all prompts (Issue #93)
LinKon12 3f8a42f
Fix: Catch all extension errors and use logger.exception
LinKon12 e47abca
Fix: Remove formatting inconsistencies in response prompt
LinKon12 77e64ab
Fix: Remove redundant exception argument from logger.exception
LinKon12 b40cd7a
Fix: Add backticks to command example to match formatting guidelines
LinKon12 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,48 @@ | ||
| EXTRACT_SEARCH_QUERY_PROMPT = """Extract the core search query from the following user message. | ||
| EXTRACT_SEARCH_QUERY_PROMPT = """Extract a clean, concise search query from the user's message. | ||
|
|
||
| User Message: "{message}" | ||
| Focus on the main topic or question. Be concise. | ||
| Search Query: """ | ||
|
|
||
| INSTRUCTIONS: | ||
| 1. Identify the core topic or question the user is asking about | ||
| 2. Remove filler words: "I was wondering", "could you", "maybe", "please", "just", etc. | ||
| 3. Remove conversational elements: greetings, politeness, context-setting phrases | ||
| 4. Keep essential keywords: technical terms, specific features, error messages, action verbs | ||
| 5. Preserve important context: version numbers, platform names, specific tools | ||
| 6. If multiple topics, focus on the PRIMARY question/need | ||
| 7. Keep it concise: 2-6 words ideal, maximum 10 words | ||
| 8. Use natural search language, not full sentences | ||
|
|
||
| EXAMPLES: | ||
|
|
||
| Input: "Hey everyone! I was wondering if someone could help me understand how to set up the development environment for this project?" | ||
| Output: setup development environment | ||
|
|
||
| Input: "I'm getting a really weird error that says 'module not found' when I try to run npm install. Any ideas?" | ||
| Output: npm install module not found error | ||
|
|
||
| Input: "Could you please tell me where I can find the contribution guidelines? I'd love to help out!" | ||
| Output: contribution guidelines | ||
|
|
||
| Input: "What's the best way to configure the API authentication? I'm using version 2.0 and need JWT support" | ||
| Output: configure API authentication JWT version 2.0 | ||
|
|
||
| Input: "The GitHub Actions workflow is failing on the build step. It worked yesterday but now throws a syntax error" | ||
| Output: GitHub Actions build failing syntax error | ||
|
|
||
| Input: "I'm new here! How do I get started with contributing to this project? What should I work on first?" | ||
| Output: getting started contributing | ||
|
|
||
| Input: "Is there documentation for the REST API endpoints? Specifically looking for user authentication endpoints" | ||
| Output: REST API documentation user authentication | ||
|
|
||
| Input: "My code review has been pending for 3 days. How long do PRs usually take to get reviewed here?" | ||
| Output: PR review timeline | ||
|
|
||
| EDGE CASES: | ||
| - If message is just a greeting β extract any implicit topic or return "general inquiry" | ||
| - If multiple questions β prioritize the first actionable question | ||
| - If very technical error message β keep the specific error text | ||
| - If asking about specific issue/PR number β include the number | ||
|
|
||
| Extract the search query now: | ||
| Search Query:""" |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.