feat: Run for quick refactoring only reading context tools

This commit is contained in:
Petr Mironychev
2025-11-17 11:25:42 +01:00
parent 31e3d9db7c
commit 9974b2f5e6
13 changed files with 103 additions and 13 deletions

View File

@ -128,8 +128,13 @@ void ClaudeProvider::prepareRequest(
}
if (isToolsEnabled) {
LLMCore::RunToolsFilter filter = LLMCore::RunToolsFilter::ALL;
if (type == LLMCore::RequestType::QuickRefactoring) {
filter = LLMCore::RunToolsFilter::OnlyRead;
}
auto toolsDefinitions = m_toolsManager->getToolsDefinitions(
LLMCore::ToolSchemaFormat::Claude);
LLMCore::ToolSchemaFormat::Claude, filter);
if (!toolsDefinitions.isEmpty()) {
request["tools"] = toolsDefinitions;
LOG_MESSAGE(QString("Added %1 tools to Claude request").arg(toolsDefinitions.size()));