How OLM can be a tool for an AI Agent
The kubectl operator CLI seems like a good candidate for an entry point for an AI-based agent to use OLM as a tool to manage Cluster Extensions. If this statement is true, we need a concise way to programmatically describe the tool to an LLM. One way would to be to walk the cobra commands concatenating them in a useful form for inclusion in an LLM system prompt. Once the LLM has the tool added in this manner it can reason about how to use the tool to implement user's desired goals for managing extensions.
The end result would be something like this to the LLM:
system_message= """ You are an AI assistant designed to help users efficiently and accurately. Your primary goal is to provide helpful, precise, and clear responses.
You have access to the following tools:
Tool Name: 'kubectl operator', Description: Manage operators in a cluster from the command line. kubectl operator helps you manage operator installations in your cluster. It can install and uninstall operator catalogs, list operators available for installation, and install and uninstall operators from the installed catalogs. The following sub commands and options are allowed... """