Skip to content

feat(Assistant): implement full Assistant features also on client - #10345

Open
Rello wants to merge 5 commits into
masterfrom
feature/newAssistant
Open

feat(Assistant): implement full Assistant features also on client#10345
Rello wants to merge 5 commits into
masterfrom
feature/newAssistant

Conversation

@Rello

@Rello Rello commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator
  • cover all server Assistant feature
  • continue conversations on server/client
  • isolated assistant dialog for better modularisation of the client
Bildschirmfoto 2026-09-01 um 18 53 26 Bildschirmfoto 2026-09-01 um 18 52 42

@Rello Rello added the design Design, UI, UX, etc. label Jul 10, 2026
@Rello

Rello commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator Author

@kra-mo @jancborchardt

@Rello Rello added this to the 34.0.1 milestone Jul 10, 2026
@Rello Rello changed the title feat: implement full Assistant features also on client draft: implement full Assistant features also on client Jul 10, 2026
@Rello Rello modified the milestones: 34.0.1, 34.0.2 Jul 30, 2026
@Rello Rello modified the milestones: 34.0.2, 35.0.0 Aug 11, 2026
@kra-mo

kra-mo commented Aug 14, 2026

Copy link
Copy Markdown
Member

The Assistant on the web will likely be redesigned next cycle, so I'd maybe hold off on iterating on the UI for now.

@Rello

Rello commented Aug 21, 2026

Copy link
Copy Markdown
Collaborator Author

The Assistant on the web will likely be redesigned next cycle, so I'd maybe hold off on iterating on the UI for now.

Hello,
next cycle you mean 36?
the current one is pretty useless so I would like to get at least the current approach in.
For simplicity I would suggests that we hide all buttons on the top and only default it to the "chat". because this feature will then sync with the conversations on the server.
the current implementation is pure temporary and super alpha. the proper chat-only implementation would make it actually very usable already

@Rello

Rello commented Aug 21, 2026

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

@Rello

Rello commented Aug 21, 2026

Copy link
Copy Markdown
Collaborator Author
  • Reload icon we can remove I would say. its there to reload the conversations from the server. it is reloaded during the window startup. its not very likely that there are new conversations for the same user when they are currently in this dialog. less distraction.
  • new chat needs to move next to the conversation dropdown

Copilot AI commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Merge conflicts with origin/master have been resolved in commit a4d01ff. The resolution keeps both the unified search UI (from this PR) and the assistant panel features, while adopting master's updated file paths (src/gui/activity/qml/ActivitiesWindow.qml, src/gui/search/unifiedsearchresultslistmodel.h).

@kra-mo

kra-mo commented Aug 21, 2026

Copy link
Copy Markdown
Member

Hello,
next cycle you mean 36?

Yes.

For simplicity I would suggests that we hide all buttons on the top and only default it to the "chat". because this feature will then sync with the conversations on the server.

That's fine by me.

@Rello
Rello marked this pull request as ready for review August 22, 2026 21:50

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 97e91ad54d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/gui/tray/MainWindow.qml
Comment thread src/gui/assistant/qml/AssistantWindow.qml Outdated
Comment thread src/gui/assistant/assistantcontroller.cpp Outdated
Comment thread src/gui/assistant/assistantcontroller.cpp Outdated
Move Assistant operations into a dedicated controller and expose task and chat workflows in a separate window.

Signed-off-by: Rello <Rello@users.noreply.github.com>
Signed-off-by: Rello <github@scherello.de>
Assisted-by: Codex:GPT-5
@Rello
Rello force-pushed the feature/newAssistant branch from 97e91ad to 26cdfe0 Compare August 23, 2026 06:28
Remove the legacy tray implementation, encapsulate Assistant resources and networking, reject stale asynchronous replies, and bound chat polling.

Signed-off-by: Rello <github@scherello.de>
Assisted-by: Codex:GPT-5

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c66f53a706

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/gui/tray/MainWindow.qml
Comment thread src/gui/assistant/assistanttasktypemodel.cpp
Signed-off-by: Rello <github@scherello.de>
Assisted-by: Codex:GPT-5
@github-actions

Copy link
Copy Markdown
Contributor

Artifact containing the AppImage: nextcloud-appimage-pr-10345.zip

Digest: sha256:90c2ee18ffb51c2776bed2fe30c7c5e87929a148ede2aba92843599e16a9119f

To test this change/fix you can download the above artifact file, unzip it, and run it.

Please make sure to quit your existing Nextcloud app and backup your data.

@kra-mo kra-mo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

An improvement

@Rello Rello changed the title draft: implement full Assistant features also on client feat(Assistant): implement full Assistant features also on client Aug 28, 2026
@Rello

Rello commented Aug 28, 2026

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

Keep assistant module in src/gui/assistant/ with requestGeneration API.
Remove assistant methods from usermodel.cpp (moved to assistant module).
Remove src/libsync/ocsassistantconnector.cpp (moved to src/gui/assistant/).

Assisted-by: ClaudeCode:claude-sonnet-4-5

Co-authored-by: Rello <13385119+Rello@users.noreply.github.com>

Copilot AI commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Merge conflicts with origin/master have been resolved in commit 4d2f519. Key resolutions:

  • Kept the requestGeneration API in src/gui/assistant/ocsassistantconnector.h
  • Removed the assistant methods that master added back to usermodel.cpp (they live in the assistant module now)
  • Deleted src/libsync/ocsassistantconnector.cpp (superseded by src/gui/assistant/ocsassistantconnector.cpp)

Comment thread src/gui/assistant/qml/AssistantChatView.qml Outdated
Comment thread src/gui/assistant/qml/AssistantChatView.qml Outdated
Comment thread src/gui/assistant/qml/AssistantChatView.qml Outdated
Comment thread src/gui/assistant/qml/AssistantChatView.qml Outdated
Comment thread src/gui/assistant/qml/AssistantChatView.qml Outdated
Comment thread src/gui/tray/usermodel.h Outdated
Comment thread src/gui/CMakeLists.txt Outdated
Comment thread src/gui/CMakeLists.txt Outdated
Comment thread src/gui/assistant/assistantutils.cpp
Comment thread src/gui/assistant/ocsassistantconnector.cpp Outdated
@claucambra

Copy link
Copy Markdown
Collaborator

Also seems like this doesn't build correctly @Rello maybe worth checking the agent product?

Split large QML components, centralize UI measurements, align QML registration and Qt keyword usage, and cover chat status handling.

Signed-off-by: Rello <github@scherello.de>
Assisted-by: Codex:GPT-5

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8ec87677a6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

requestFailed(QStringLiteral("chatConversations"), statusCode);
return;
}
_chatConversations.replaceFromResponse(json, _selectedChatConversationId);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Unwrap OCS data before parsing chat responses

All added chat requests target /ocs/v2.php, and JsonApiJob delivers the complete OCS document, but this passes that object directly to AssistantConversationModel::replaceFromResponse(), which reads only json.array(). A normal { "ocs": { "data": [...] } } response therefore produces an empty conversation list; the create-message, generation, and session handlers make the same top-level assumption and consequently fail to find IDs or messages. Unwrap ocs.data consistently and cover these workflows with realistically enveloped responses.

AGENTS.md reference: AGENTS.md:L33-L36

Useful? React with 👍 / 👎.

@sonarqubecloud

sonarqubecloud Bot commented Sep 1, 2026

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
20.4% Coverage on New Code (required ≥ 80%)
257 New Code Smells (required ≤ 0)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

@claucambra claucambra left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Some small changes and one bigger one. I think the test suite is insufficient for the breadth of additions being made here

void slotChatSessionChecked(quint64 requestGeneration, const QJsonDocument &json, int statusCode);

private:
[[nodiscard]] quint64 beginRequest();

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Could we not just remove the [[nodiscard]] rather than casting to void wherever we don't need the result?

Comment on lines +64 to +67
return true;
}();
Q_UNUSED(initialized)
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

What is the point of returning a value here?

Comment on lines +20 to +23
static void initializeAssistantResources()
{
Q_INIT_RESOURCE(assistant);
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I'm not sure why we need this to be its own function? can't we just use it in the lambda below?

Comment on lines +74 to +80
void dateTextDoesNotGuessTimestampUnit()
{
constexpr auto timestamp = 1000000000001LL;
const auto expected = QLocale::system().toString(QDateTime::fromSecsSinceEpoch(timestamp), QLocale::ShortFormat);

QCOMPARE(AssistantUtils::dateText(timestamp), expected);
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This test does not in actuality test anything useful; it's verifying a past implementation detail. Should be removed


}

class TestAssistantController : public QObject

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This test suite seems to be really limited compared to all the new additions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

design Design, UI, UX, etc.

Projects

Status: NC35

Development

Successfully merging this pull request may close these issues.

4 participants