-
-
Notifications
You must be signed in to change notification settings - Fork 4.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
feat: TaskProcessing API #45094
feat: TaskProcessing API #45094
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.
Psalm found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.
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.
Yay, it looks gooood. Didn't make a full review yet, just using it for the work on the assistant.
It breaks NC though. I tried to rebase on master, no luck.
PHP Fatal error: Class OC\\Files\\Node\\LazyR
oot contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (OCP\\Files\\IRootFolder::getAppDataDirectoryName) in /var/www/html/dev
/server/lib/private/Files/Node/LazyRoot.php on line 39
lib/public/TaskProcessing/Events/AbstractTextProcessingEvent.php
Outdated
Show resolved
Hide resolved
a1f6f92
to
b9948ba
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.
A bump of the server version is needed to trigger the migration step.
Like this? version.php -$OC_Version = [30, 0, 0, 0];
+$OC_Version = [30, 0, 0, 1]; |
dadb8b2
to
27735d1
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.
Another partial review:
- We could use (optional) default values for input shape fields. It might not make sense in many cases but for example: "number of images" for TextToImage could have 1 as default value. Wdyt?
- The assistant needs a manager method AND/OR an endpoint to get all user's tasks (with a task type ID optional filter). Wdyt?
- [minor] CSRF might not be needed for
taskprocessing/tasks/{taskId}/file/{fileId}
, not a big deal, I currently add the requesttoken GET param to display images in the UI. - Task result files stored in data/appdata_iid/core/TaskProcessing/ are empty for the TextToImage task type (at least). I tried 2 providers (OpenAI and Replicate which are providers for the old TTI API).
- The manager is unable to read input files if they are in a user's storage. I tried an STT provider (for the old STT API), I get this exception raised: https://github.com/nextcloud/server/blob/enh/taskprocessing-api/lib/private/TaskProcessing/Manager.php#L763 which means this does not get the file: https://github.com/nextcloud/server/blob/enh/taskprocessing-api/lib/private/TaskProcessing/Manager.php#L759 . Happy to debug that together if you want.
|
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Co-authored-by: julien-nc <julien-nc@posteo.net> Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
…onal IO slots Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Co-authored-by: julien-nc <julien-nc@posteo.net> Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Co-authored-by: julien-nc <julien-nc@posteo.net> Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Wasn't able to load File from app data Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Co-authored-by: Kate <26026535+provokateurin@users.noreply.github.com> Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
e1a7a49
to
cac812d
Compare
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
* @return string | ||
* @since 30.0.0 | ||
*/ | ||
public function getAppDataDirectoryName(): string; |
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.
@marcelklehr Please document in https://docs.nextcloud.com/server/latest/developer_manual/app_publishing_maintenance/app_upgrade_guide/upgrade_to_30.html#id1
(all changes in lib/public/)
Summary
TODO
Checklist