-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Add skeleton support for native functions #9122
Conversation
ec427aa
to
1fd6619
Compare
All of the support code in the auto-annotation SDK layer is already there, we just need to send sublabel information when creating a native function, and validate it when running an agent. In addition, force keypoint sublabel types to be "points", since this is how the UI creates them for tasks/projects.
1fd6619
to
1b34d96
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #9122 +/- ##
===========================================
- Coverage 73.83% 73.30% -0.53%
===========================================
Files 431 448 +17
Lines 44804 45870 +1066
Branches 3892 3915 +23
===========================================
+ Hits 33081 33626 +545
- Misses 11723 12244 +521
|
raise CriticalError( | ||
incompatible_msg + f"{attr_desc} has values {remote_attr['values']!r}," | ||
f" but the function object declares values {attr.values!r}." | ||
) |
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.
Is there a way for the users to get notified that their function definition uses some unknown labels or attributes? If some annotations are silently ignored, it doesn't look really convenient to me. Maybe it's better to show some warning for ignored labels and attributes on agent startup?
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.
Do you mean the case where the local function has a label/sublabel/attribute that the remote function doesn't? At the moment I don't have any notifications for this case. My thinking was that since the end user only sees the remote function's labels, from their perspective everything will work as expected, even if the behind-the-scenes function object supports some extra labels.
That said, I'm not opposed to adding the warnings you propose; but I think it goes beyond the scope of this PR.
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.
Yes, this case. I think it should be added to avoid unexpectedly missing annotations in the case a label is renamed in the function implementation. Agree that it can be done in another PR.
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.
FWIW, if a label is renamed, that implies that there is a remote label with no corresponding local label, in which case the agent will abort.
Fix typo Co-authored-by: Maxim Zhiltsov <[email protected]>
|
Motivation and context
All of the support code in the auto-annotation SDK layer is already there, we just need to send sublabel information when creating a native function, and validate it when running an agent.
In addition, force keypoint sublabel types to be "points", since this is how the UI creates them for tasks/projects.
How has this been tested?
Tests will be added in the private repository.
Checklist
develop
branch[ ] I have linked related issues (see GitHub docs)License
Feel free to contact the maintainers if that's a concern.