-
Notifications
You must be signed in to change notification settings - Fork 22
GEval Integration #97
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
Merged
tisnik
merged 9 commits into
lightspeed-core:main
from
arin-deloatch:feature/geval-config
Nov 20, 2025
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
cc0dc60
feat: added GEval handler; integrated component into DeepEvalMetrics
arin-deloatch 6dc7b04
bug:small fix for undefined registry paths
arin-deloatch 0b51087
fix: resolving pylint and pydocstyle conflicts
arin-deloatch 0a9f693
fix: unbound errors with registry loading function
arin-deloatch e7dc73b
removing backward compatibility for turn data + coderabbit fixes
arin-deloatch 13b60b5
additional configuration needed for Geval support + metric registry a…
arin-deloatch e0a5bcc
fix: pylint and pyright conflicts; corrected default directory for GE…
arin-deloatch 205c03c
refactor: addressed PR feedback; alignment with pre-existing structure
arin-deloatch 0e330ef
geval unit tests; general geval testing support
arin-deloatch 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -6,7 +6,7 @@ core: | |
|
|
||
| # LLM as a judge configuration | ||
| llm: | ||
| provider: "openai" # LLM Provider (openai, watsonx, gemini, hosted_vllm etc..) | ||
| provider: "openai" # LLM Provider (openai, watsonx, gemini, hosted_vllm etc..) | ||
| model: "gpt-4o-mini" # Model name for the provider | ||
| temperature: 0.0 # Generation temperature | ||
| max_tokens: 512 # Maximum tokens in response | ||
|
|
@@ -28,7 +28,7 @@ embedding: | |
| # To get real time data. Currently it supports lightspeed-stack API. | ||
| # But can be easily integrated with other APIs with minimal change. | ||
| api: | ||
| enabled: true # Enable API calls instead of using pre-filled data | ||
| enabled: true # Enable API calls instead of using pre-filled data | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: only spaces, I'd keep the original indent |
||
| api_base: http://localhost:8080 # Base API URL | ||
| endpoint_type: streaming # Use "streaming" or "query" endpoint | ||
| timeout: 300 # API request timeout in seconds | ||
|
|
@@ -91,6 +91,26 @@ metrics_metadata: | |
| "script:action_eval": | ||
| description: "Script-based evaluation for infrastructure/environment validation" | ||
|
|
||
| # GEval turn-level metrics | ||
| "geval:technical_accuracy": | ||
| criteria: | | ||
| Assess whether the response provides technically accurate information, | ||
| commands, code, syntax, and follows relevant industry or | ||
| domain-specific best practices. The response should | ||
| contain valid syntax and use appropriate functions, modules, or tools. | ||
| evaluation_params: | ||
| - query | ||
| - response | ||
| - expected_response | ||
| evaluation_steps: | ||
| - "Verify that the provided syntax (e.g., code, commands, configuration) is valid and follows the language/tool's formatting rules." | ||
| - "Check if the response uses appropriate modules, functions, libraries, or parameters for the given task." | ||
| - "Assess whether the solution aligns with relevant official documentation or established best practices for the specific domain." | ||
| - "Verify the response directly and accurately addresses the user's specific query or task." | ||
| - "Check for potential security issues, significant inefficiencies, or anti-patterns." | ||
| threshold: 0.7 | ||
| description: "General technical accuracy of provided commands, code, or technical information" | ||
|
|
||
| # Conversation-level metrics metadata | ||
| conversation_level: | ||
| # DeepEval metrics | ||
|
|
@@ -107,6 +127,24 @@ metrics_metadata: | |
| threshold: 0.7 | ||
| description: "How well the model retains information from previous turns" | ||
|
|
||
| # GEval conversation-level metrics | ||
| "geval:conversation_coherence": | ||
| criteria: | | ||
| Evaluate whether the conversation maintains context and provides coherent | ||
| responses across multiple turns. The assistant should reference previous | ||
| exchanges and build upon earlier context. | ||
| evaluation_params: | ||
| - query | ||
| - response | ||
| evaluation_steps: | ||
| - "Check if the assistant remembers information from previous turns" | ||
| - "Verify responses build logically on previous context" | ||
| - "Assess whether the conversation flows naturally" | ||
| - "Check for contradictions with earlier statements" | ||
| threshold: 0.6 | ||
| description: "Context maintenance and coherence across conversation turns" | ||
|
|
||
|
|
||
| # Output Configuration | ||
| output: | ||
| output_dir: "./eval_output" | ||
|
|
||
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
Oops, something went wrong.
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.
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.
nit: only spaces, I'd keep the original indent