fix: let self-hosted servers handle images in tool returns
The Read tool was gated behind isLettaCloud() for image support, but self-hosted servers can handle base64 images too with the right server-side patches (converters.py + message.py). Removed the cloud-only gate — if the server can't handle it, it'll error gracefully. Better to try than to silently omit.
This commit is contained in:
@@ -18,12 +18,10 @@ import { validateRequiredParams } from "./validation.js";
|
||||
* Currently only api.letta.com supports this feature.
|
||||
*/
|
||||
function serverSupportsImageToolReturns(): boolean {
|
||||
const settings = settingsManager.getSettings();
|
||||
const baseURL =
|
||||
process.env.LETTA_BASE_URL ||
|
||||
settings.env?.LETTA_BASE_URL ||
|
||||
LETTA_CLOUD_API_URL;
|
||||
return baseURL === LETTA_CLOUD_API_URL;
|
||||
// TODO: replace with server capability discovery when available
|
||||
// Selfhosted servers with the message.py image patch support images
|
||||
// in tool returns via the Chat Completions path.
|
||||
return true;
|
||||
}
|
||||
|
||||
interface ReadArgs {
|
||||
|
||||
Reference in New Issue
Block a user