Add project taskitem pool and planner fixes

This commit is contained in:
Bill
2026-03-18 01:02:21 -06:00
parent af6fa169b7
commit 69243141dd
15 changed files with 1860 additions and 91 deletions

View File

@@ -592,12 +592,26 @@ private:
ms);
sessionRecorder_.record(rec);
}
std::string text = result.dump(2);
response["result"] = {
{"content", json::array({{{"type", "text"}, {"text", text}}})},
{"isError", false},
{"whetstoneVersionHeader", buildVersionHeader(toolName)}
};
if (hasCallError(result)) {
const json& err = result["error"];
std::string text;
if (err.is_object()) text = err.value("message", err.dump(2));
else if (err.is_string()) text = err.get<std::string>();
else text = err.dump(2);
response["result"] = {
{"content", json::array({{{"type", "text"}, {"text", text}}})},
{"isError", true},
{"error", err},
{"whetstoneVersionHeader", buildVersionHeader(toolName)}
};
} else {
std::string text = result.dump(2);
response["result"] = {
{"content", json::array({{{"type", "text"}, {"text", text}}})},
{"isError", false},
{"whetstoneVersionHeader", buildVersionHeader(toolName)}
};
}
} catch (const std::exception& e) {
response["result"] = {
{"content", json::array({{{"type", "text"}, {"text", std::string("Error: ") + e.what()}}})},
@@ -708,7 +722,7 @@ private:
};
json resp = rpcCallback_(request);
if (resp.contains("result")) return resp["result"];
if (resp.contains("error")) return {{"error", resp["error"]["message"]}};
if (resp.contains("error")) return {{"error", resp["error"]}};
return resp;
}
@@ -1165,6 +1179,7 @@ private:
#include "mcp/RegisterWorkflowTools.h"
#include "mcp/RegisterWorkflowExecutionTools.h"
#include "mcp/RegisterRoutingTools.h"
#include "mcp/RegisterTaskitemPoolTools.h"
#include "mcp/RegisterOrchestratorTools.h"
#include "mcp/RegisterReviewTools.h"
#include "mcp/RegisterArchitectIntakeTools.h"