-
Notifications
You must be signed in to change notification settings - Fork 21
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
First attempt at a parametrized JobCreate #740
First attempt at a parametrized JobCreate #740
Conversation
cf6d9aa
to
d8ae072
Compare
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.
Looking good so far! Made a code suggestion but looks like a very logical refactor. My only question would be whether you plan on addressing the custom logic of _get_job_params
in this PR. If you don't plan on addressing it here, can you make a separate issue to track elevating that out of the service layer?
The SDK needs to be updated. I have checked the backend unit and integration tests locally and they seem to work. |
72585b0
to
a17f040
Compare
The SDK and notebook tests have been updated. @veekaybee @aittalam I've changed the code of the notebook slightly. One important difference is that I have removed the model param in the eval lite job. AFAICT, it's not needed there. The notebook takes it from the initial model spec in the notebook and not from the output of the summarization job. Since the output is a csv, it didn't make sense to put the model there, but I'll check the results metadata. |
0c8ef33
to
4ca7e65
Compare
9159569
to
e6f13f3
Compare
c9357b2
to
293ae98
Compare
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.
My concern is that this PR is dropping support for the JobType.EVALUATION, which is needed to support the current frontend design. I may misunderstand the code. Other than that, only minor comments. Thanks for the work on this! (Let me know about JobType.EVALUATION and then I'll approve once that's worked out).
Thanks for this! One note, @javiermtorres this PR should still be in sync with the UI and keep an eye on how it interacts with /experiments. |
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.
Just a note that uploading a file w/o ground-truth and then clicking on "generate ground-truth" generates a "job not found error".
See log:
2025-02-10 - PR740.log
bcad25e
to
ce76b2b
Compare
9113f26
to
02c0b79
Compare
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.
Tested #847 in the context of reviewing #740 . I've only looked at the backend code (740), not the frontend code. But on the testing front, I did a demo:
- uploading a dataset with and w/o gt
- annotating one w/o gt
- launching an experiment with both local and API-based models
Overall, works as expected (🥳 ). There are a number of smaller issues, but let's get 847 in here and then 740 into main - and iterate on smaller separate issues :)
* remove redundant folders * refactor: fix imports * refactor: change folder structure * style: linting * cleanup * First attempt at a parametrized JobCreate * Replace templates with pydantic models * Adapt SDK and SDK tests * Fix sdk unit tests * Fix notebook tests * Fix tests * Fix job definition in workflows * Fix job unit test * Start a default workflow for experiments * Rebase to main * Align with routes in main * Move to experiments new endpoint * Streamline new experiments api * remove redundant folders * refactor: fix imports * refactor: change folder structure * style: linting * cleanup * WIP: migrate to new workflow apis * refactor some more stuff * use the new datastructure, hide runtime * refactor: cleanup Job vs Experiment in ExperimentDetails mess * style: linting * fixing things * style: linting * current state * results working * style: linting * current state * after merge fixes * checkpoint * things working ish * formatting * style: linting --------- Co-authored-by: Javier Torres <javier@mozilla.ai>
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.
With #847 in here and checks green, we have ourselves a usable new experiments workflow :)
THANK YOU for the effort @javiermtorres @khaledosman
What's changing
The JobCreate schema is changed to include a separate specific job_config. The openapi produced includes a
oneOf
constraint:The jobs and experiments services are changed accordingly.
Closes #706
How to test it
Tests should run correctly.
Additional notes for reviewers
N/A
I already...
/docs
)