Skip to content

Maira Profiles

GPT Profiles is a unique and powerful feature offered by Maira. This feature allows you to define the purpose, personality, response instructions, and other various other settings.

You can create multiple profiles and switch between them as necessary based on our usecase. Below, we will explore this feature in more detail.

Create a new Profile

Navigate to the profile setup page

  • Name: Give a name to your profile, so that admins can easily understand its purpose.

  • Intro: Maira includes a feature that allows you to set specific instructions and rules for the AI, guiding how it generates responses.

    • Example: Always respond with concise and professional language while addressing the query directly. Ask three follow-up questions after each response. If you don't know the answer, say sorry and do not generate random answer.
  • System: This is a large language model (LLM) feature designed to set a mode or persona for the AI.

    • Example : You are a fitness coach, who provides personalized workout plans and nutrition advice based on individual goals and fitness levels.
  • Instructions: Use this section to provide clear guidance to end-users on how to interact with this specific profile. These instructions help users understand the scope, capabilities, and limitations of the profile, ensuring more efficient and relevant interactions.

    • General Guidelines for Writing Instructions:
      • Clearly state what types of questions or requests are appropriate for this profile.
      • Specify any limitations or topics that are out of scope.
      • Tailor the instructions to the datasets and features available to this profile.
      • Optionally, include best practices or tips for getting the most accurate responses.
    • Examples:
      • "You can ask about product features, troubleshooting steps, and account management."
      • "I can provide product recommendations and answer basic questions. For billing or sensitive account issues, please contact support via email."
      • "This chatbot is for HR-related consultation only. Please do not submit personal medical information."
      • "Ask me about fitness routines, nutrition advice, or general wellness tips. For medical emergencies, consult ça healthcare professional."
    • Note: Each profile may have different instructions based on its purpose and available data. Providing clear instructions improves user experience and helps set expectations.
  • Model: You can select the GPT model you want to use based on your needs from the dropdown. Please consider the purpose and the estimated token count when selecting the model, as this can significantly impact costs. You can learn more about OpenAI models from this page. This setting will impact the parameters search_max_token (tokens allocated for data sent to the model) and completion_token (tokens allocated for the reply). Note that intro, system, and query have token costs that are not included in the token size allocation. The selected model's CONTEXT WINDOW should cover the total token allocation. That is CONTEXT WINDOW ≥ search_max_token + completion_token + intro + system + query.

  • Temperature: The range of temperature is between 0-2. A lower temperature (closer to 0) makes the output more deterministic and focused, meaning the model will choose more likely words. A higher temperature (closer to 2) makes the output more random and creative, with a wider range of word choices.

  • top_p: An alternative to sampling with temperature, top_p also known as nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. In simple terms, when this value is between 0.1 to 0.3, your responses will be more grounded to the reference documents and instruction. The higher it is, it will be more creative and prone to hallucination. It is good to test and find the right value for your project.

  • top_k: (Anthropic models only): This controls how many of the most likely next words the model considers when generating a response. For example, if top_k is set to 10, the model will only choose from the 10 most likely next tokens. A lower value (e.g., 1–10) makes responses more focused and deterministic. A higher value (e.g., 30–50) allows for more diversity and creativity but may introduce randomness or off-topic content. Adjust this based on how grounded or exploratory you want the responses to be.

  • Frequency Penalty: A parameter that reduces the likelihood of the model repeating the same tokens in its output. It penalizes frequent token usage, encouraging more diverse word choices.

    • If frequency_penalty = 0.0, there is no penalty, and the model is free to repeat tokens.
    • Higher frequency_penalty values make the model less likely to repeat words, promoting more variation in the output.
  • Presence Penalty: Default=0.0, ge=0.0, le=2.0. A parameter that encourages the model to introduce new tokens by penalizing tokens that have already appeared in the output. This drives the model to use less common or new words.

  • Stop: stop determines when the model should stop generating texts(tokens). If a list of strings(up to 4 allowed) e.g. ["world", "coding"] provided, and model encounters any of them, it stops generating texts. Say, model generated hello world. world is in the stop sequence, so model will stop at hello and returns. Another example is model has so far generated I love coding and last token coding is in stop sequence. So model will stop generating new token and return I love. Stop sequence is an optional parameter, it defaults to an empty list. So model will continue generating tokens until the response finishes naturally.

  • access_tags: Access tags are used to restrict which profiles guest users can access. See the Guest User Management tutorial to learn how to add guest users.

  • search max token: This is the number of tokens allocated for context sent to the model. Default values are dynamic, each model has specific defaults. When search max token 0, GAIP will completely ignore internal database.

  • Completion Tokens: Default=2000, example=2500. This is the number of tokens allocated for the reply

  • Chat History Length: The number of past conversations retained as context for submission to GPT.

  • Is Personalizer Only: Is this profile for personalizer use only, default value False

    • Learn more This parameter impacts the context sent to Maira. If "is_personalizer_only": true then all dataset uploaded through datasets endpoints will be ignored, restricting the context to product catalog only. When "is_personalizer_only": false, then both Maira dataset and item catalog of personalizer will be used for context
  • Is Auto Evaluation: Determines weather the conversation evaluation run automatically after each conversation. (We will cover evaluation in detail in the Evaluation Tutorial). This is an optional field. Please note that evaluation is resource intensive, and can be run manually via another endpoint (Covered in the Evaluations tutorial).

  • Search Mode: Specifies the type of search. Acceptable values are "context", "full_text", or "hybrid".

    • Context Mode: Uses AI-powered contextual search to understand meaning and find relevant content from the datasets.
    • Full Text Mode: Uses keyword-based search to find relevant content from the datasets,
    • Hybrid Mode: Automatically decides whether to use contextual search based on the query

    NOTE:is_keyword_enabled in v1/maira/iask, acts as a "keyword boost" for contextual search only. It adds keyword filtering on top of vector similarity search when enabled, but has no impact when using full_text search mode.

  • Dataset Languages: - A list of language codes used to translate user queries before document retrieval. This improves relevance when the dataset is primarily in a different language than the query. If left empty, no translation is performed.

    • Supported values: en (English), ja (Japanese), ko (Korean).
    • When to use it: For example, if your dataset is mainly in Japanese but users submit queries in English, set this to ja. The system will translate the query to Japanese before retrieving documents, resulting in more accurate responses.
  • Dataset Tags: Which dataset tags should be included or excluded from context building. If not provided, then all datasets are considered for context building (We have talked about adding tags to dataset in the "dataset management" tutorial)

    • Include: Tags to include in context generation, all datasets beyond these tags are excluded
    • Exclude: Tags to exclude in context generation, all datasets beyond these tags are included

Once initial setup is completed, you can see a list of all your profiles in the "Profiles" table

profiles list table

From this page, you can create a new profile by clicking on the "CREATE PROFILE" button or edit or delete an existing profile with the button in the "Actions" column.

edit or create profile


View existing Profile

View all existing profiles

To view all existing profiles of a project, simply navigate to the "PROFILE" tab of your Project. There in the "Profiles" tab, you will see list of all your existing profiles.

navigate to project

list of profile

View details of a profile

To see the details of an existing profile, navigate to the "PROFILE" tab of your project and click on the Eye mark to see the detail of the profile.

see profile detail

Update a Profile

To update the an existing profile, navigate to the "PROFILE" tab of your project and click on the Pencil mark. A modal will open where you can edit the profile detail.

Edit profile detail

After update is done, click on the "UPDATE" button to confirm the changes and close the modal

Edit profile detail 2

Delete a Profile

To delete an existing profile, navigate to the "PROFILE" tab of your project and click on the Trash mark and confirm. Be aware that deleted profiles cannot be retrieved.

delete profile 1

delete profile 2