Blog
All Blog Posts | Next Post | Previous Post
Supercharging Delphi Apps with TMS AI Studio v1.2 Toolsets: Fine-Grained AI Function Control
Today
Artificial Intelligence is no longer a futuristic conceptits a present-day differentiator. Businesses are racing to embed AI capabilities into their applications, and developers who miss this wave risk falling behind. For Delphi VCL and FMX developers, TMS AI Studio is the bridge to seamlessly integrate cutting-edge LLMs such as OpenAI, Gemini, Grok, Mistral, Perplexity, Claude, Ollama, DeepSeek, and more.
At the heart of this integration lies the new toolset mechanism of the TTMSMCPCloudAI
component now available in TMS AI Studio v1.2. This powerful design lets you expose fine-grained, predefined functions to the AI in a controlled and efficient way. With toolsets, you can teach the LLM how to interact with your application while keeping the communication lightweight, relevant, and future-proof. Think of a toolset as a native MCP server built-in in your application.
Why Toolsets Matter
When you expose functions to an LLM, you are essentially giving it a vocabulary of actions it can take. The toolset defines these actions. A bloated set of tools will slow down interactions and burden the AI with unnecessary complexity. The key is to keep toolsets focused, minimal, and purposefulallowing the LLM to be effective without being overwhelmed.
Each toolset TTMSMCPCloudAIToolSet
in TMS AI Studio is tied to the TTMSMCPCloudAI
component:
And if you want to go beyond whats provided out-of-the-box, you can easily create your own toolset by descending from TTMSFNCCloudAIToolSet and override the virtual method DefineTools where you add the tools you want to bundle.
Predefined Toolsets in TMS AI Studio
TMS AI Studio already comes with several ready-to-use toolsets that cover common scenarios. Lets look at them in detail, along with real-world use cases.
1. Logging with TTMSFNCCloudAILogger
The logging toolset gives the AI controlled access to output messageswhether to the console, a message box, or a log file.
Available tools:
-
MessageShow
Show a message dialog. -
ConsoleShow
Write output to the console. -
LogToFile
Append text to a log file.
Use cases:
-
Letting the AI provide progress updates during a long-running task.
-
Capturing LLM reasoning for debugging.
-
Building an AI-powered assistant that keeps a trace of its conversations in a file.
Example:
2. File System Access with TTMSFNCCloudAIFileSystem
This toolset lets the AI interact with the local file system in a structured, restricted manner.
Available tools:
-
DoGetFiles
,DoGetFolders
Enumerate files and directories. -
DoGetTextFile
,DoWriteTextFile
,DoAppendTextFile
Read, create, or update text files. -
DoCreateFolder
,DoCopyFile
,DoMoveFile
Manage files and folders.
Use cases:
-
Letting the AI organize project files on disk.
-
AI-powered document editors that read/write local notes.
-
Automation of repetitive file management tasks through natural language prompts.
Example Prompt to the AI:
Find all .log
files in the logs
folder and summarize their contents.
3. Data Handling with TTMSFNCCloudAIDataSet
This toolset exposes Delphis TDataSet
functionality to the AIallowing it to query and manipulate database records.
Available tools:
-
DoGetFields
,DoGetTableName
Inspect schema. -
DoNext
,DoPrevious
,DoFirst
,DoLast
,DoMove
Navigate records. -
DoGetRecords
,DoGetRecord
Fetch data. -
DoAddRecord
,DoModifyRecord
,DoLocateRecord
Manipulate records.
Use cases:
-
Natural-language querying of datasets (e.g., Show me all customers from Germany).
-
AI-driven data exploration tools in Delphi apps.
-
Automating record updates via conversational input.
Example:
Imagine a CRM system where a user asks the AI:
Find the most recent 10 orders for customer John Smith and update the delivery status to Shipped.
The AI can do this using the exposed dataset tools.
4. Email Integration with TTMSFNCCloudAIEmail
This toolset gives the AI controlled access to sending and retrieving emails via POP3/SMTP.
Available tools:
-
DoSendEmail
Send email. -
DoGetCountEmail
Check inbox message count. -
DoRetrieveEmail
Retrieve emails.
Use cases:
-
An AI-powered assistant that can draft and send reports directly from Delphi applications.
-
Smart inbox triage: Summarize todays new emails from clients and mark urgent ones.
-
Automated email responses with human approval.
Example:
Now, the AI can send status updates directly to stakeholders.
The Future-Proof Advantage of TMS AI Studio
The true strength of TMS AI Studio is abstraction. Instead of binding your Delphi app to one vendors LLM, you can switch between OpenAI, Gemini, Claude, Mistral, or even run local models with Ollamawithout rewriting your integration. Your investment stays future proof, regardless of where the AI landscape shifts.
And by carefully curating toolsets, you ensure that the LLM works with just the right amount of control: not too much, not too little.
Conclusion: Dont Miss the AI Wave
The competitive edge of applications increasingly depends on their AI capabilities. Native Delphi VCL & FMX developers can no longer afford to ignore this shift. With TMS AI Studio and its powerful toolset system, you can:
-
Give LLMs fine-grained but lightweight control over your application.
-
Leverage ready-to-use toolsets for logging, file systems, datasets, and email.
-
Expand with your own toolsets tailored to your business needs.
-
Stay future proof with seamless multi-LLM integration.
👉 If you havent started embedding AI into your Delphi apps yet, now is the time. The tools are here. The use cases are endless. And the risk of being left behind is real.
Bruno Fierens

This blog post has not received any comments yet.
All Blog Posts | Next Post | Previous Post