The AI Assistant is an LLM-powered chatbot that can create virtual assets for you. See AI Assistant for more information about accessing the AI Assistant. Be aware that LLMs can provide inaccurate information, which can affect this feature. Due diligence is recommended.
Creating a Virtual Asset with the AI Assistant
You can use the AI Assistant to help you create a virtual asset in Virtualize. There are two methods available to you: using an OpenAI/Swagger service definition and working without one.
With a Service Definition
If you have an OpenAI/Swagger service definition that you want to create a virtual asset for, you can just ask the AI Assistant for help creating a virtual asset and provide it with a URL or absolute file path to the service definition. It will analyze the service definition and make suggestions. You can choose one of its suggestions or describe the virtual asset you want. For example, you might ask the AI Assistant:
Create a virtual asset from definition:
https://petstore.swagger.io/v2/swagger.json
Include operations for adding, updating, and retrieving pet information.
The AI Assistant will show you the virtual asset it proposes based on your request, including a responder suite with related operations populated payload data when applicable, and ask you if you want to save it. You can choose to accept the virtual asset or ask for changes. For example, you might decide you want to add an operation to delete pet information. When it asks you if you want to proceed, you could say:
Add an operation to delete pet information.
The AI Assistant would recreate the virtual asset with the new operation. In this way, you can modify the virtual asset until you have exactly what you want.
Virtual asset responders will be parameterized based on incoming requests when applicable. Values that are not parameterized will be populated with AI-generated values.
Without a Service Definition
If you don't have an OpenAI/Swagger service definition to use, you can still get the AI Assistant's help creating a virtual asset. You can provide it with text descriptions of how the service works, which can include endpoints, payloads, and so on, which the AI Assistant will analyze then propose what responders it thinks would be most appropriate. This method can result in some gaps in the proposal which you might need to fill in, but it's a good way to get a jump on the process.
Depending on the detail of your description, the AI Assistant might propose:
- endpoints
- responder correlations
- response payloads (literal)
- status codes
The AI Assistant will ask for changes to the proposed virtual service before creating it.