Skip to content

Lukabura/epd 2131 allow dataset attributes to be renamed python sdk update#384

Open
lukabura-ab wants to merge 3 commits intomainfrom
lukabura/epd-2131-allow-dataset-attributes-to-be-renamed-python-sdk-update
Open

Lukabura/epd 2131 allow dataset attributes to be renamed python sdk update#384
lukabura-ab wants to merge 3 commits intomainfrom
lukabura/epd-2131-allow-dataset-attributes-to-be-renamed-python-sdk-update

Conversation

@lukabura-ab
Copy link
Copy Markdown
Contributor

@lukabura-ab lukabura-ab commented Aug 18, 2025

Allow dataset attributes to be renamed

Greptile Summary

This PR implements functionality to allow dataset attributes to be renamed across the Autoblocks Python SDK. The changes introduce several key capabilities:

Dataset Update Functionality: A new update_dataset method has been added to the datasets client, allowing users to modify dataset names and schema properties after creation. This method includes comprehensive validation to prevent duplicate property names and follows existing patterns for schema processing.

Human Review API Expansion: The human review module has been significantly expanded with new models and endpoints for test cases and comparison pairs. New models include JobTestCase, TestCaseResult, OutputField, PairItem, Pair, and PairDetail, along with utility functions for text manipulation and item normalization.

API Model Refactoring: The codebase has undergone a refactoring from complex AutoblocksTestCaseResult* models to streamlined HumanReviewPair* models. This simplification removes nested structures like input/output field types, comments, and grades in favor of a cleaner pair-based comparison approach focused on output fields.

Validation Infrastructure: New validation utilities have been added, including validate_unique_property_names which ensures schema property names remain unique when renaming operations occur. This validation is exposed through the public API and integrated into both create and update operations.

Public API Updates: Multiple modules have been updated to expose new functionality through their public interfaces, including datasets utils, human review models, and API models. All changes follow the established pattern of re-exporting implementation details from the _impl folder.

The changes integrate well with the existing codebase architecture, maintaining backward compatibility through deprecation warnings while introducing cleaner, more focused APIs for dataset manipulation and human review workflows.

Confidence score: 4/5

  • This PR introduces significant new functionality with proper validation and error handling, but the scope is large enough to warrant careful testing
  • Score reflects well-structured code following established patterns, but complexity of changes across multiple modules increases risk
  • Pay close attention to autoblocks/_impl/datasets/client.py and autoblocks/_impl/api/client.py for the core dataset update and human review refactoring logic

Copy link
Copy Markdown

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

12 files reviewed, 4 comments

Edit Code Review Bot Settings | Greptile

Comment thread autoblocks/_impl/api/models.py Outdated
Comment thread autoblocks/_impl/datasets/client.py Outdated
Comment thread tests/autoblocks/test_human_review.py Outdated
Comment thread autoblocks/_impl/datasets/util.py Outdated
@lukabura-ab lukabura-ab force-pushed the lukabura/epd-2131-allow-dataset-attributes-to-be-renamed-python-sdk-update branch from 304d37b to 892bc99 Compare August 18, 2025 08:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant