Skip to content

Conversation

@Chibionos
Copy link
Contributor

Summary

Add comprehensive evaluation framework for testing file input scenarios in the csv-processor sample.

Changes

Sample Updates (samples/csv-processor/)

  • ✅ Add Output model to main.py for proper evaluation data access
  • ✅ Create test data (sales_data.csv, large_dataset.csv, minimal.csv)
  • ✅ Add custom evaluators:
    • CSVShapeEvaluator: validates CSV dimensions (rows × columns)
    • CSVColumnsEvaluator: verifies expected column names
    • AttachmentCreatedEvaluator: checks output attachment creation
  • ✅ Add evaluation set (file-input-tests-local.json) with 3 test cases
  • ✅ Update uipath.json with Output model schema

CI/CD Integration (testcases/csv-processor-evals/)

  • ✅ Add testcase directory structure following existing patterns
  • ✅ Create run.sh script for automated evaluation runs
  • ✅ Add assert.py for validation of evaluation results
  • ✅ Configure pyproject.toml and uipath.json for testcase execution

Core Fixes

  • 🐛 Fix evaluator path resolution bug in _evaluator_factory.py
    • Support co-located .py and .json files in evaluators directory
    • Check direct path before falling back to /custom/ subdirectory
  • 📦 Add pandas dev dependency for CSV processing

Evaluation Results

All 3 test cases pass with perfect scores (1.0/1.0):

  • ✅ Test Sales Data CSV Processing
  • ✅ Test Large Dataset CSV Processing
  • ✅ Test Minimal CSV Processing

Test plan

  • Run evaluation locally: uv run uipath eval main evaluations/eval-sets/file-input-tests-local.json
  • Verify all evaluators score 1.0
  • Test CI/CD integration script: ./testcases/csv-processor-evals/run.sh
  • Verify CI/CD pipeline runs successfully in GitHub Actions

🤖 Generated with Claude Code

@github-actions github-actions bot added test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-llamaindex Triggers tests in the uipath-llamaindex-python repository labels Jan 22, 2026
Chibi Vikram and others added 2 commits January 23, 2026 09:22
…r sample

Add comprehensive evaluation framework for testing file input scenarios in the csv-processor sample.

## Changes

### Sample Updates (samples/csv-processor/)
- Add Output model to main.py for proper evaluation data access
- Create test data (sales_data.csv, large_dataset.csv, minimal.csv)
- Add custom evaluators:
  - CSVShapeEvaluator: validates CSV dimensions (rows × columns)
  - CSVColumnsEvaluator: verifies expected column names
  - AttachmentCreatedEvaluator: checks output attachment creation
- Add evaluation set (file-input-tests-local.json) with 3 test cases
- Update uipath.json with Output model schema

### CI/CD Integration (testcases/csv-processor-evals/)
- Add testcase directory structure following existing patterns
- Create run.sh script for automated evaluation runs
- Add assert.py for validation of evaluation results
- Configure pyproject.toml and uipath.json for testcase execution

### Core Fixes
- Fix evaluator path resolution bug in _evaluator_factory.py
  - Support co-located .py and .json files in evaluators directory
  - Check direct path before falling back to /custom/ subdirectory
- Add pandas dev dependency for CSV processing

## Evaluation Results
All 3 test cases pass with perfect scores (1.0/1.0):
- Test Sales Data CSV Processing
- Test Large Dataset CSV Processing
- Test Minimal CSV Processing

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Fixed three critical issues causing evaluation tests to fail:

1. Added pandas dependency to testcases/csv-processor-evals/pyproject.toml
   - Agent requires pandas but it was missing from eval dependencies

2. Fixed file paths in file-input-tests-local.json
   - Updated paths to be relative to testcases directory
   - Changed from "test-data/..." to "../../samples/csv-processor/test-data/..."

3. Optimized UiPath initialization in main.py
   - Moved UiPath() initialization to platform mode only
   - Prevents authentication errors when testing with local files

All tests now pass with scores of 1.0 for both evaluators.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@Chibionos Chibionos force-pushed the feat/csv-processor-evaluations branch from adf54bc to dc2658c Compare January 23, 2026 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-llamaindex Triggers tests in the uipath-llamaindex-python repository

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant