feat: Add google provider thinking mode (#255)

fix: add signature
This commit is contained in:
Petr Mironychev
2025-11-13 23:52:38 +01:00
committed by GitHub
parent 5e580b8792
commit 30885c0373
4 changed files with 236 additions and 24 deletions

View File

@ -52,6 +52,7 @@ public:
const LLMCore::RequestID &requestId, const QUrl &url, const QJsonObject &payload) override;
bool supportsTools() const override;
bool supportThinking() const override;
void cancelRequest(const LLMCore::RequestID &requestId) override;
public slots:
@ -69,11 +70,14 @@ private slots:
private:
void processStreamChunk(const QString &requestId, const QJsonObject &chunk);
void handleMessageComplete(const QString &requestId);
void emitPendingThinkingBlocks(const QString &requestId);
void cleanupRequest(const LLMCore::RequestID &requestId);
QHash<LLMCore::RequestID, GoogleMessage *> m_messages;
QHash<LLMCore::RequestID, QUrl> m_requestUrls;
QHash<LLMCore::RequestID, QJsonObject> m_originalRequests;
QHash<LLMCore::RequestID, int> m_emittedThinkingBlocksCount;
QSet<LLMCore::RequestID> m_failedRequests;
Tools::ToolsManager *m_toolsManager;
};