-
Notifications
You must be signed in to change notification settings - Fork 9
APPENG-3801-B - Agent performance fixes - all agent stages #134
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
APPENG-3801-B - Agent performance fixes - all agent stages #134
Conversation
… better clarity and quality
…l descriptions to both checklist and agent prompts
|
/ok-to-test |
adding in constants during the vdb generation check
|
bugfix pushed for the vdb tool issue |
zvigrinberg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @etsien
The agent is not being started with these changes.
Please see my comment for a quick fix and will continue from there...
anyway we fixed it manually and continued with the confusion matrix second batch run...
Thanks.
|
/retest |
|
/retest vulnerability-analysis-on-pr |
… better clarity and quality
…l descriptions to both checklist and agent prompts
adding in constants during the vdb generation check
…cution-stages' of https://github.com/etsien/vulnerability-analysis into APPENG-3801-B-Agent-performance-fixes-checklist-and-execution-stages
|
Just rebased to |
|
/retest vulnerability-analysis-on-pr |
|
Hi @etsien , Thank you. |
patched, forgot to bring over the bugfix from the other branch |
|
/retest vulnerability-analysis-on-pr |
|
@etsien Please rebase and resolve conflicts, and we'll merge it ( that one improved the consistency and the results significantly). |
…-checklist-and-execution-stages
|
/retest vulnerability-analysis-on-pr |
|
LGTM Approved. |
…emAppEng#134) * bugfix in the testing env * update tool descriptions for clarity * refactor tool names to be class constants instead of disparate strings * add initial unit tests * rename tool names to be more consistent and distinct * update unit tests with tool names and tool constants * cleanup startup guide notebook * rework intel source score section * update agent execution stage prompts and make tool descriptions dynamic * add tests for dynamic tool descriptions * revamp the tool description list, as well as the checklist prompt for better clarity and quality * revamp checklist prompt implementation, as well as add in dynamic tool descriptions to both checklist and agent prompts * update tests for tool descriptions * add more detailed agent examples with more useful MRKL-formatted steps * update for summary prompt * update justification prompt with more logic and explanations on how to pick the class * update CVSS prompts and cleanup examples and guidance * bugfix on intel source * bug patch for vdb generation adding in constants during the vdb generation check * bugfix by Tamar * update register_function() and transitive_search() descriptions * bugfix in the testing env * update tool descriptions for clarity * refactor tool names to be class constants instead of disparate strings * add initial unit tests * rename tool names to be more consistent and distinct * update unit tests with tool names and tool constants * cleanup startup guide notebook * rework intel source score section * update agent execution stage prompts and make tool descriptions dynamic * add tests for dynamic tool descriptions * revamp the tool description list, as well as the checklist prompt for better clarity and quality * revamp checklist prompt implementation, as well as add in dynamic tool descriptions to both checklist and agent prompts * update tests for tool descriptions * add more detailed agent examples with more useful MRKL-formatted steps * update for summary prompt * update justification prompt with more logic and explanations on how to pick the class * update CVSS prompts and cleanup examples and guidance * bugfix on intel source * bug patch for vdb generation adding in constants during the vdb generation check * bugfix by Tamar * update register_function() and transitive_search() descriptions * add function locator descriptions * add names to configs * add local output for local testing * bugfix * Update tool_names.py


Comprehensive Prompting Improvements Across Vulnerability Analysis Pipeline
This PR implements systematic improvements to all prompting stages of the vulnerability analysis pipeline, focusing on consistency, clarity, reduced verbosity, and reduced LLM hallucinations. Also incorporates tool improvements from prior PR (APPENG-3801-A).
Edit:
Also rebased to incorporate the latest PRs that were merged upstream to branch
rh-aiq-main.Summary of Changes
All 7 stages of the vulnerability analysis pipeline have been improved with:
<TASK>,<INSTRUCTIONS>,<EXAMPLES>, etc.)Files Modified
Core Prompting and Utilities
src/vuln_analysis/utils/prompting.py - Major restructuring
build_tool_descriptions()consolidated base functionget_agent_prompt()andget_cvss_prompt()functionssrc/vuln_analysis/utils/intel_source_score.py
src/vuln_analysis/utils/checklist_prompt_generator.py
tool_namesparameter togenerate_checklist()src/vuln_analysis/utils/justification_parser.py
JUSTIFICATION_PROMPTwith clear sectionsFunction Implementations
src/vuln_analysis/functions/cve_agent.py
_create_agent()to usebuild_tool_descriptions()partial_variablesfortool_selection_strategysrc/vuln_analysis/functions/cve_checklist.py
agent_namefield toCVEChecklistToolConfigsrc/vuln_analysis/functions/cve_generate_cvss.py
_create_agent()functionTests
build_tool_descriptions()function