-
-
Notifications
You must be signed in to change notification settings - Fork 602
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
Remove Async Validation in process async #933
Conversation
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.
❌ Changes requested. Reviewed everything up to 4948dd9 in 13 seconds
More details
- Looked at
38
lines of code in1
files - Skipped
0
files when reviewing. - Skipped posting
1
drafted comments based on config settings.
1. instructor/process_response.py:147
- Draft comment:
Consider updating documentation or adding comments to inform users that async validation is no longer performed inprocess_response_async
andprocess_response
. This will help users understand the change and adjust their expectations accordingly. - Reason this comment was not posted:
Confidence changes required:50%
The removal of async validation checks inprocess_response_async
andprocess_response
is consistent with the PR description. However, the removal of the warning log inprocess_response
might lead to confusion for users who expect async validation to occur. A comment or documentation update might be necessary to inform users of this change.
Workflow ID: wflow_s074dbhwUVrPzrov
Want Ellipsis to fix these issues? Tag @ellipsis-dev
in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
Deploying instructor with Cloudflare Pages
|
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.
❌ Changes requested. Incremental review on 3cf6dc5 in 17 seconds
More details
- Looked at
21
lines of code in1
files - Skipped
0
files when reviewing. - Skipped posting
1
drafted comments based on config settings.
1. instructor/__init__.py:43
- Draft comment:
The removal ofasync_field_validator
andasync_model_validator
from the__all__
list is appropriate since their import statements have been removed, aligning with the PR's purpose. - Reason this comment was not posted:
Confidence changes required:10%
The removal ofasync_field_validator
andasync_model_validator
from the__all__
list is consistent with the removal of their import statements, which is appropriate given the PR's purpose.
Workflow ID: wflow_mi5Saksj4muhKHnb
Want Ellipsis to fix these issues? Tag @ellipsis-dev
in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
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.
👍 Looks good to me! Incremental review on 57150fe in 23 seconds
More details
- Looked at
13
lines of code in1
files - Skipped
0
files when reviewing. - Skipped posting
2
drafted comments based on config settings.
1. tests/llm/test_openai/schema/test_async_decorator.py:8
- Draft comment:
The import ofasync_field_validator
andasync_model_validator
frominstructor.validators
should be removed as these functions are no longer used in the codebase according to the PR description. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable:
The comment is incorrect because the functionsasync_field_validator
andasync_model_validator
are actively used in the code. The suggestion to remove them is not valid, as it would break the code functionality.
I might be missing some context from the PR description, but based on the code provided, the functions are clearly used. The comment seems to be based on an incorrect assumption.
Even if the PR description suggests these functions are unused, the code itself shows they are used, which takes precedence in this review.
The comment should be deleted because it incorrectly suggests removing imports that are actively used in the code.
2. tests/llm/test_openai/schema/test_async_decorator.py:8
- Draft comment:
Function names should follow a consistent naming pattern. Consider using snake_case for all function names in this file. This issue is also present in other functions liketest_openai_schema_serialization
,test_openai_schema_float_and_bool
, etc. - Reason this comment was not posted:
Confidence changes required:80%
The function names in the test file are inconsistent. Some functions use underscores while others use camel case. This violates the consistent naming pattern rule.
Workflow ID: wflow_9zFyRLg4aAnV1o3Y
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
hey all, this is a new PR i'm introducing to remove the usage of the For the next release, I'm aiming to remove all existing usage of this modification so that we get a stable release to support the new structured output mode + other features in instructor. Once we've verified that the changes have been validated, we can then work towards reintroducing this in the form of a mixin in the upcoming subsequent releases. As such, for now the cc @jxnl on the purpose of this PR |
This removes the use of async validation in the process step
Summary:
Removed async validation logic and updated related imports and checks, including test file updates.
Key points:
process_response_async
ininstructor/process_response.py
.AsyncValidationError
import and usage.OpenAISchema
inprocess_response_async
.process_response
.async_field_validator
andasync_model_validator
frominstructor/__init__.py
.async_field_validator
andasync_model_validator
intests/llm/test_openai/schema/test_async_decorator.py
.Generated with ❤️ by ellipsis.dev