iobroker.ai-toolbox
Version:
The ioBroker AI Toolbox Adapter is a powerful integration that enables users to create and manage custom AI tools within their ioBroker smart home environment. This versatile adapter supports multiple Large Language Models (LLMs) and provides a flexible f
916 lines (915 loc) • 30.1 kB
JSON
{
"i18n": true,
"type": "tabs",
"items": {
"tab_2": {
"type": "panel",
"label": "Tools",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "Create and manage your AI tools. Each tool can be configured with a specific model, prompt, and parameters to optimize performance and results. You can also enable multimodal capabilities for tools that support vision/image requests.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"bot_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Name' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.bots && ii<data.bots.length; ii++){const t=data.bots[ii].bot_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.bots && ii<data.bots.length; ii++){const t=data.bots[ii].bot_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"bot_name_invalid_error": {
"type": "staticText",
"text": "ERROR: column 'Name' must contain characters A-Za-z0-9 and _ only and must not start with an _",
"newLine": true,
"hidden": "if (!data.bots) return true; for (const c of data.bots) {if (c.bot_name !== '' && !c.bot_name.match(/^[A-Za-z0-9]([A-Za-z0-9-_])*$/)) return false;}; return true;",
"validator": "if (!data.bots) return true; for (const c of data.bots) {if (c.bot_name !== '' && !c.bot_name.match(/^[A-Za-z0-9]([A-Za-z0-9-_])*$/)) return false;}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"bots": {
"type": "accordion",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Tools",
"clone": true,
"titleAttr": "bot_name",
"items": [
{
"attr": "tool_header",
"type": "header",
"text": "Tool Settings",
"size": 3,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"attr": "tool_description",
"type": "staticText",
"text": "Choose a name for your AI tool and select an appropriate model to process requests.",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"type": "text",
"attr": "bot_name",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6,
"label": "Name",
"tooltip": "Name for the Tool",
"default": "AI-Tool",
"maxLength": 30
},
{
"attr": "bot_model",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6,
"type": "selectSendTo",
"data": { "function": "getAvailableModels" },
"command": "getAvailableModels",
"label": "Model",
"width": "10% ",
"tooltip": "Which Model should be used for this tool"
},
{
"attr": "prompt_divider",
"type": "divider",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"attr": "prompt_header",
"type": "header",
"text": "Prompt Settings",
"size": 3,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"attr": "prompt_description",
"type": "staticText",
"text": "Create specific, detailed prompts for better results. If you're new to prompt engineering, consider reviewing prompt design tutorials and best practices.",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"type": "text",
"attr": "bot_system_prompt",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "System Prompt",
"tooltip": "The system prompt which should contain all relevant information that describes the tool",
"filter": false,
"sort": false,
"default": "You are an intelligent AI tool that has the task to..",
"minRows": 4,
"maxRows": 7,
"maxLength": 2000
},
{
"type": "text",
"attr": "bot_example_request",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Example request (Optional)",
"tooltip": "Example for a request you are going to send to the tool",
"filter": false,
"sort": false,
"default": "Please write an example of how you will send a request to this tool",
"minRows": 4,
"maxRows": 7,
"maxLength": 2000
},
{
"type": "text",
"attr": "bot_example_response",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Example response (Needed if Example request is defined!)",
"tooltip": "An example for the perfect answer to the defined example request",
"filter": false,
"sort": false,
"default": "Please write the answer in the format and style you would like to receive from the tool",
"minRows": 4,
"maxRows": 7,
"maxLength": 2000
},
{
"attr": "parameter_header",
"type": "header",
"text": "Tool parameters",
"size": 3,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"attr": "parameter_description",
"type": "staticText",
"text": "Configure these key parameters:\n- Message History: Number of previous messages to include for context\n- Temperature: Controls output creativity/randomness (0-1)\n- Maximum Tokens: Limits the length of the model's response",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"type": "number",
"attr": "chat_history",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Message History",
"tooltip": "If greater 0 previous messages will be included in the request so the tool will stay in context",
"filter": false,
"sort": false,
"min": 0,
"max": 60,
"step": 1,
"default": 0
},
{
"type": "number",
"attr": "temperature",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Temperature",
"tooltip": "Setting for creativity/consistency of the model's response. (Leave at default if you are not sure!)",
"filter": false,
"sort": false,
"min": 0,
"max": 1,
"step": 0.1,
"default": 0.6
},
{
"type": "number",
"attr": "max_tokens",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Max. Tokens",
"tooltip": "Limit the response of the tool to your desired amount of tokens.",
"filter": false,
"sort": false,
"min": 0,
"max": 10000,
"step": 1,
"default": 2000
},
{
"attr": "request_header",
"type": "header",
"text": "Request Settings",
"size": 3,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"attr": "request_description",
"type": "staticText",
"text": "Configure retry behavior for failed requests, including maximum attempts and delay between retries.",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"type": "number",
"attr": "max_retries",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Max. Retries",
"tooltip": "How many times should we retry if request to model fails",
"filter": false,
"sort": false,
"min": 0,
"max": 15,
"step": 1,
"default": 3
},
{
"type": "number",
"attr": "retry_delay",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Retry Delay in Seconds",
"tooltip": "How long to wait between retries",
"filter": false,
"sort": false,
"min": 0,
"max": 300,
"step": 1,
"default": 15
},
{
"attr": "multimodality_header",
"type": "header",
"text": "Multimodality",
"size": 3,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"attr": "multimodality_description",
"type": "staticText",
"text": "Enable multimodal capabilities for your tool. Ensure you select a model that supports multimodal requests to avoid errors or unexpected behavior.",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"type": "checkbox",
"attr": "use_vision",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Enable Vision/Image requests",
"tooltip": "Enable vision/image requests for this tool, used model MUST support Vision or requests will fail!",
"filter": false,
"sort": false,
"default": false
},
{
"attr": "vision_description",
"type": "staticText",
"text": "When enabled, a .image_url state will be created. Including an image URL in this state along with your text request will send both to the model for processing.",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
{
"type": "checkbox",
"attr": "include_vision_in_history",
"xs": 12,
"sm": 4,
"md": 4,
"lg": 4,
"xl": 4,
"label": "Include Vision Requests in chat history",
"tooltip": "Select if vision request should be included in the chat history",
"filter": false,
"sort": false,
"default": false
},
{
"attr": "vision_history_description",
"type": "staticText",
"text": "Note: Including vision requests in chat history can significantly increase token usage and associated costs due to the size of image data.",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
}
]
}
}
},
"tab_3": {
"type": "panel",
"label": "Anthropic",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "Please enter your Anthropic API Token to start using models like Opus, Haiku and Sonnet. If there are new models released you can simply add them in the table to start using them with ai assistants.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"dividerHdr": {
"newLine": true,
"type": "header",
"text": "Settings",
"size": 2
},
"anth_api_token": {
"type": "password",
"label": "API Token",
"xs": 12,
"sm": 12,
"md": 6,
"lg": 4,
"xl": 4
},
"anth_api_version": {
"type": "text",
"label": "Anthropic API Version",
"default": "2023-06-01",
"xs": 12,
"sm": 12,
"md": 6,
"lg": 4,
"xl": 4
},
"model_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Model' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.anth_models && ii<data.anth_models.length; ii++){const t=data.anth_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.anth_models && ii<data.anth_models.length; ii++){const t=data.anth_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"anth_models": {
"type": "table",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Models",
"showSecondAddAt": 5,
"items": [
{
"type": "checkbox",
"attr": "model_active",
"width": "10% ",
"title": "Active",
"tooltip": "Model is active",
"filter": true,
"sort": true,
"default": true
},
{
"type": "text",
"attr": "model_name",
"width": "90% ",
"title": "Model",
"tooltip": "Name of the Model",
"filter": true,
"sort": true,
"default": ""
}
]
}
}
},
"tab_4": {
"type": "panel",
"label": "OpenAI",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "Please enter your OpenAI API Token to start using models like Gpt4, Gpt4-o1, Gpt3-5. If there are new models released you can simply add them in the table to start using them with ai assistants.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"dividerHdr": {
"newLine": true,
"type": "header",
"text": "Settings",
"size": 2
},
"opai_api_token": {
"type": "password",
"label": "API Token",
"xs": 12,
"sm": 12,
"md": 6,
"lg": 4,
"xl": 4
},
"model_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Model' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.opai_models && ii<data.opai_models.length; ii++){const t=data.opai_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.opai_models && ii<data.opai_models.length; ii++){const t=data.opai_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"opai_models": {
"type": "table",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Models",
"showSecondAddAt": 5,
"items": [
{
"type": "checkbox",
"attr": "model_active",
"width": "10% ",
"title": "Active",
"tooltip": "Model is active",
"filter": true,
"sort": true,
"default": true
},
{
"type": "text",
"attr": "model_name",
"width": "90% ",
"title": "Model",
"tooltip": "Name of the Model",
"filter": true,
"sort": true,
"default": ""
}
]
}
}
},
"tab_5": {
"type": "panel",
"label": "Perplexity",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "Please enter your Perplexity API Token to start using the models. If there are new models released you can simply add them in the table to start using them with ai assistants.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"dividerHdr": {
"newLine": true,
"type": "header",
"text": "Settings",
"size": 2
},
"pplx_api_token": {
"type": "password",
"label": "API Token",
"xs": 12,
"sm": 12,
"md": 6,
"lg": 4,
"xl": 4
},
"model_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Model' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.pplx_models && ii<data.pplx_models.length; ii++){const t=data.pplx_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.pplx_models && ii<data.pplx_models.length; ii++){const t=data.pplx_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"pplx_models": {
"type": "table",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Models",
"showSecondAddAt": 5,
"items": [
{
"type": "checkbox",
"attr": "model_active",
"width": "10% ",
"title": "Active",
"tooltip": "Model is active",
"filter": true,
"sort": true,
"default": true
},
{
"type": "text",
"attr": "model_name",
"width": "90% ",
"title": "Model",
"tooltip": "Name of the Model",
"filter": true,
"sort": true,
"default": ""
}
]
}
}
},
"tab_6": {
"type": "panel",
"label": "Openrouter",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "Please enter your Openrouter API Token to start using the models. If there are new models released you can simply add them in the table to start using them with ai assistants.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"dividerHdr": {
"newLine": true,
"type": "header",
"text": "Settings",
"size": 2
},
"oprt_api_token": {
"type": "password",
"label": "API Token",
"xs": 12,
"sm": 12,
"md": 6,
"lg": 4,
"xl": 4
},
"model_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Model' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.pplx_models && ii<data.pplx_models.length; ii++){const t=data.pplx_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.pplx_models && ii<data.pplx_models.length; ii++){const t=data.pplx_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"oprt_models": {
"type": "table",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Models",
"showSecondAddAt": 5,
"items": [
{
"type": "checkbox",
"attr": "model_active",
"width": "10% ",
"title": "Active",
"tooltip": "Model is active",
"filter": true,
"sort": true,
"default": true
},
{
"type": "text",
"attr": "model_name",
"width": "90% ",
"title": "Model",
"tooltip": "Name of the Model",
"filter": true,
"sort": true,
"default": ""
}
]
}
}
},
"tab_8": {
"type": "panel",
"label": "Deepseek",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "Please enter your Deepseek API Token to start using the models. If there are new models released you can simply add them in the table to start using them with ai assistants.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"dividerHdr": {
"newLine": true,
"type": "header",
"text": "Settings",
"size": 2
},
"deep_api_token": {
"type": "password",
"label": "API Token",
"xs": 12,
"sm": 12,
"md": 6,
"lg": 4,
"xl": 4
},
"model_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Model' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.pplx_models && ii<data.pplx_models.length; ii++){const t=data.pplx_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.pplx_models && ii<data.pplx_models.length; ii++){const t=data.pplx_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"deep_models": {
"type": "table",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Models",
"showSecondAddAt": 5,
"items": [
{
"type": "checkbox",
"attr": "model_active",
"width": "10% ",
"title": "Active",
"tooltip": "Model is active",
"filter": true,
"sort": true,
"default": true
},
{
"type": "text",
"attr": "model_name",
"width": "90% ",
"title": "Model",
"tooltip": "Name of the Model",
"filter": true,
"sort": true,
"default": ""
}
]
}
}
},
"tab_7": {
"type": "panel",
"label": "Custom",
"items": {
"deviderTxt1": {
"type": "staticText",
"text": "You can use your custom or self hosted inference server to run open source models. The server needs to follow the rest api standards used by many providers, see examples below. Please make sure to add your used models by name to the table below.",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"link_lmstudio": {
"type": "staticLink",
"text": "Link to LM Studio",
"href": "https://lmstudio.ai/",
"icon": "info",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"link_localai": {
"type": "staticLink",
"text": "Link to LocalAI",
"href": "https://localai.io/",
"icon": "info",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"dividerHdr": {
"newLine": true,
"type": "header",
"text": "Settings",
"size": 2
},
"custom_api_url": {
"type": "text",
"label": "URL for Inference Server",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"default": "http://192.168.178.123:1234/v1/chat/completions"
},
"custom_api_token": {
"type": "password",
"label": "API Token for Inference Server",
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12
},
"model_name_unique_error": {
"type": "staticText",
"text": "ERROR: column 'Model' must contain unique text",
"newLine": true,
"hidden": "const x={}; for(let ii=0; data.custom_models && ii<data.custom_models.length; ii++){const t=data.custom_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validator": "const x={}; for(let ii=0; data.custom_models && ii<data.custom_models.length; ii++){const t=data.custom_models[ii].model_name; if (x[t]==='x') return false; x[t]='x';}; return true;",
"validatorNoSaveOnError": true,
"style": {
"color": "red"
},
"xs": 12,
"sm": 12,
"md": 12,
"lg": 6,
"xl": 6
},
"custom_models": {
"type": "table",
"newLine": true,
"xs": 12,
"sm": 12,
"md": 12,
"lg": 12,
"xl": 12,
"label": "Models",
"showSecondAddAt": 5,
"items": [
{
"type": "checkbox",
"attr": "model_active",
"width": "10% ",
"title": "Active",
"tooltip": "Model is active",
"filter": true,
"sort": true,
"default": true
},
{
"type": "text",
"attr": "model_name",
"width": "90% ",
"title": "Model",
"tooltip": "Name of the Model",
"filter": true,
"sort": true,
"default": ""
}
]
}
}
}
}
}