# God mode prompt

Prompt templates & God mode prompt let you control exactly how character data (personality, context, memories, etc.) is injected into the AI system prompt, completely overwriting AICord's defaults.

{% hint style="danger" %}
Adding anything to God mode prompt might break your character since it **completely overwrites** AICord's default system instructions. Do this at your own risk and only when you understand what you're doing. AICord team provides no support for malfuctioning God mode prompts.
{% endhint %}

{% hint style="info" %}

## Best Practices

#### Keep prompts structured

Use clear sections such as:

```
<context>...</context>
<personality>...</personality>
<rules>...</rules>
<knowledge>...</knowledge>
```

Or:

```
Context:
...

Personality:
...
```

Structured prompts help AI models stay consistent.
{% endhint %}

{% hint style="warning" %}

#### Avoid overly long or detailed prompts

Large prompts waste tokens and reduce response quality. Usually smaller and simpler prompts are better than dumping thousands of pages of character lore.

Focus on:

• key personality traits\
• relevant knowledge\
• important rules

Think of prompting as giving simple, easy to understand instructions to model.
{% endhint %}

## What is God mode prompt?

AICord characters use AICord's **system prompt** by default to tell the AI model how it should roleplay as the character, its boundaries, style and format instructions, etc.

System prompts are a set low-level instructions the AI engine must adhere to and follow regardless of conversation. This is like having a God mode and being able to shape the AI model's personality from the ground up.

We added custom system prompts to AICord as **God mode prompts** to help experienced users customize **every** aspect of their characters.

* Would you like your character to not act like a character but instead be a regular homework assistant? Fine, you can do this!
* Would you like your character narrate things as a third person? You are now able to do this!

## Prompt templates

When editing your custom God mode prompt, you can use a template structure that allows you to insert AICord-side values into your prompt fully dynamically.

This enables deeper customization while keeping prompts structured and efficient.

Prompt templates are plain text files that use **variables** and **conditional blocks**.

Example:

```
Act as {name} 

Your short backstory:
{context} 

Personality traits: 
{personality}

Never, ever roleplay actions.
```

When the prompt template is rendered, AICord replaces variables with character data on the fly like this using AICord values (for example, the context and personality fields you set normally when editing your character):

```
Act as Luna

Your short backstory:
A playful AI fox spirit who lives inside Discord.

Personality traits:
Witty, playful, curious

Never, ever roleplay actions.
```

### Variables

Variables inject values from the character profile.

Syntax:

```
{variable_name_here}
```

Example:

```
{name} -> Inserts character name into prompt
{personality} -> Inserts personality
{context} -> Inserts short backstory
{user} -> Inserts the user's name the character is currently chatting with
{channel} -> Inserts the channel name where the conversation is happening
```

### Conditional Blocks

Some character fields may be empty. Conditional blocks allow template sections to **only appear when data exists**. This reduces the cognitive load and confusion of AI models because they don't see empty sections when a field is empty/not existing.

There can be 2 types of conditional blocks:

* **Empty field checks:**

  Ensures that the field exists and it's not empty, otherwise it doesn't render the block and its content.
* **Conditional checks:**\
  There are conditions that evaluate to `True` or `False`, like `is_style_human` is `True` and renders the block if the character response style is set to Human. Otherwise, if this value is `False`, the block and its content is never rendered.

Syntax:

```
[variable_name]
some random text instructions here...
{variable_name}
[/variable_name]
```

Example

```
[appearance] 
Your appearance is the following:
{appearance}  
[/appearance]
```

If the character has no appearance set, the block will **not be included in the final prompt**, meaning that the character will not get "Your appearance is the following:" at all with the empty line under it.

### Formatting

Some variables contain lists (likes, memories, knowledge entries).

These can be formatted with **modifiers**.

Here, we are showcasing some use cases for this. Let's say that our likes field has ice cream, football, coding and hanging out on Discord.

#### `{likes:bullet}`

Formats the likes field in rendered system prompt to use bullet points:

* ice cream
* football
* coding
* hanging out on Discord

#### `{likes:list}`

Formats the likes field in rendered system prompt to appear as normal list:

ice cream, football, coding, hanging out on Discord

#### `{user:upper}`

Formats the user's name in rendered system prompt to have all uppercase letters:

Instead of "Peter", it renders "PETER"

#### `{user:lower}`

Formats the user's name in rendered system prompt to have all lowercase letters:

Instead of "Peter" or "PETER" or "PeTeR", it renders "peter"

### Conversation Style Blocks

Characters can use different speaking styles.

Templates may include conditional sections such as:

```
This block below renders only when conversation style is set to Human:
[is_style_human]
    Respond ONLY with direct speech, exactly as a real person would text or speak in a casual conversation. 

    FORBIDDEN - NEVER use these:

    - Asterisks for actions: *chuckles*, *smiles*, *laughs*, *sighs*, *nods*, *winks*, etc.
    - Narration in any form
    - Stage directions describing tone
    - Emotes or action descriptors

    CORRECT

    - Plain conversational text
    - Normal punctuation (. , ! ?)
    - Dialogue exactly like a real message

    Example:

    WRONG: *chuckles* Well, that's interesting!  
    WRONG: Oh really? (in a sultry voice)  
    RIGHT: Well, that's interesting!  
    RIGHT: Oh really?
[/is_style_human]

This block below renders only when conversation style is set to Roleplay:
[is_style_roleplay]
    Respond in a roleplay style, describing your actions and speech as if you were the character. Use asterisks for actions and descriptions. Immerse yourself fully in the character and roleplay.
[/is_style_roleplay]

This block below renders only when conversation style is set to Narrator:
[is_style_narrator]
    Respond in a narrative style, describing the scene and the character's actions as if you were a story narrator. Use rich descriptions and immerse yourself in the storytelling.
[/is_style_narrator]
```

AICord automatically selects the correct style block.

## Available variables & conditionals

### Variables

| Variable name         | Description                                            | Can be empty? |
| --------------------- | ------------------------------------------------------ | ------------- |
| `{name}`              | Character name                                         | No            |
| `{context}`           | Short backstory or context of character                | No            |
| `{personality}`       | Personality traits                                     | No            |
| `{appearance}`        | Appearance                                             | Yes           |
| `{age}`               | Age                                                    | Yes           |
| `{likes}`             | Likes                                                  | Yes           |
| `{dislikes}`          | Dislikes                                               | Yes           |
| `{user}`              | Currently chatting user's display name                 | No            |
| `{channel}`           | Channel of current conversation                        | No            |
| `{language}`          | Language of responses                                  | No            |
| `{answer_length}`     | Answer length in a number of words                     | No            |
| `{general_knowledge}` | General knowledge                                      | Yes           |
| `{relationships}`     | Relationships                                          | Yes           |
| `{goals}`             | Goals                                                  | Yes           |
| `{user_persona}`      | Persona of the current user character is chatting with | Yes           |
| `{memories}`          | Persistent memories of character                       | Yes           |
| `{knowledge_chunks}`  | Relevant knowledge base chunks of character            | Yes           |

### Conditionals

Variables can be used both as variables and conditionals, while conditionals can only be used as conditionals.

| Conditional name      | Description                               |
| --------------------- | ----------------------------------------- |
| `[is_style_human]`    | Whether or not response style is human    |
| `[is_style_roleplay]` | Whether or not response style is roleplay |
| `[is_style_narrator]` | Whether or not response style is narrator |


---

# Agent Instructions: 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://docs.aicordapp.com/premium/god-mode-prompt.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.
