> For the complete documentation index, see [llms.txt](https://help.supporthunt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.supporthunt.com/action-blocks/ai-model.md).

# AI Model

For smarter replies and to answer open-ended queries from visitors, one would use the AI model action block.&#x20;

The AI model action block uses OpenAI APIs to answer the question from the trained data.&#x20;

<figure><img src="/files/zHcxH3Fk4eucYrpHHVPA" alt=""><figcaption><p>AI model - Action panel overview</p></figcaption></figure>

## Configurations on AI model

### AI model

Shows the list of AI models trained using the AI studio. [Learn more](broken://pages/D8YqCgWxUv0lvEWqVhen)

Based on the AI model you choose, the chatbot would answer the queries. Make sure you have trained the AI model with the right information.

### **Variable**&#x20;

To get an answer to your question from the AI model, we need to send the question to it.&#x20;

It is expected, that before the "AI model" action block, you must use a "Collect input" action block to ask the question and store the question asked into a variable.&#x20;

That variable which contains the question, is what is to be chosen here.&#x20;

### Persona

Define the persona text based on which the AI model would give its response. Basically, this helps you get an answer to a question the way you feel easy to consume.&#x20;

Common examples of persona are,

* Answer the questions asked in a simple and easy to understand manner
* Answer these questions as a 5-year old
* Give me answers considering me as a technical person
* For the duration of this conversation, please fully immerse yourself in the persona of Albert Einstein

### Restrict answer size

When a question is asked to the AI model, you can choose to define how long do you want the responses to be.&#x20;

This number is defined based on the unit of token.&#x20;

Tokens can be thought of as pieces of words; and 1 token=4 characters. [Learn more](https://help.openai.com/en/articles/4936856-what-are-tokens-and-how-to-count-them)

### Creativity in responses

You can control whether you would like to receive unique responses every time a question is asked or get the same response every time the question is asked.&#x20;

Define a number between 0 and 1. Nearer to 1 gives you distinct responses, and nearer to 0 gives you fix responses. By default, we keep the number as **0.5**.

### Allow external data

When you build an AI model using a domain or a set of files, your ideal goal is to have the chatbot answer the queries from that data only.

This configuration allows you to control whether you want the chatbot to answer questions from the global ChatGPT model or restrict it only the trained data of that AI model.

By default, this configuration is turned **OFF**.

### Ask for feedback&#x20;

After answering a question, the chatbot would ask for feedback i.e. thumbs up or down.&#x20;

The results of this feedback would be visible on the AI studio page.&#x20;

<figure><img src="/files/ZJ5K1TZVLD01cAaZV5Wu" alt=""><figcaption><p>AI model card showing the feedback gathered from visitors</p></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.supporthunt.com/action-blocks/ai-model.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
