Skip to content

Commit

Permalink
Add Lorebooks to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
miku448 committed Jul 25, 2024
1 parent 83a4a75 commit 9c7ad25
Show file tree
Hide file tree
Showing 11 changed files with 94 additions and 0 deletions.
Binary file modified apps/bot-directory/public/favicon.ico
Binary file not shown.
Binary file modified apps/interactor/public/favicon.ico
Binary file not shown.
1 change: 1 addition & 0 deletions docs/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
**
Binary file modified docs/src/assets/favicon.ico
Binary file not shown.
Binary file modified docs/src/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/src/assets/novel-builder/homepage.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/src/assets/novel-builder/tutorial_1.mp4
Binary file not shown.
Binary file added docs/src/assets/novel-builder/tutorial_2.mp4
Binary file not shown.
31 changes: 31 additions & 0 deletions docs/src/guides/novel-builder/1-get-started.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
label: Get Started
icon: package
order: 100
---

# Get Started
This tool allows you to create **Generative Visual Novels** using AI, export them to Ren'Py, or make them playable in the MikuGG platform. Follow the steps below to create your own visual novel.

First go to [build.miku.gg](https://build.miku.gg) and select **Start from scratch** to create a blank project.

![](/assets/novel-builder/homepage.png)


### Set Up Novel Details

First we need to set up some basic details about the novel you plan to create.

[!embed](/assets/novel-builder/tutorial_1.mp4)

Novel Title
: Enter the name of your novel.

Novel Description
: Provide a brief description of your novel.

Author Name
: Enter your username or handle.

Profile Image
: Upload a 256x256 square image to be used as the profile image for your novel.
58 changes: 58 additions & 0 deletions docs/src/guides/novel-builder/2-lorebooks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
label: Lorebooks
icon: book
order: 99
---

# Lorebooks

Lorebooks are a powerful feature in the Miku.gg Novel Builder that allow you to create dynamic and context-aware responses from your AI characters. Essentially, a lorebook is a collection of prompts and information entries that provide the AI with specific details about your novel's world, characters, or story. By defining keywords for each entry, you ensure that the AI references this information only when it's relevant, which helps maintain an efficient use of tokens and keeps the AI's responses consistent and informed.

### Creating a Lorebook

Creating lorebooks involves defining individual entries. Each entry consists of content that describes a particular aspect of your novel's world, such as the geography of a fictional country or the background of a character, along with keywords that trigger the use of this content.

[!embed Lorebook creation tutorial](/assets/novel-builder/tutorial_2.mp4)

### Steps
1. First, click on **New Lorebook** and put the basic information.
- **Name**: Enter the name of the lorebook.
- **Description**: Provide a brief description of the lorebook.
2. Now, create entires by clicking on **+ Entry**. And for each entry fill the following.
- **Entry Name**: Enter the name of the entry.
- **Content**: Provide the content for the entry. [How do I format it?](#entry-optimization)
- **Keywords**: Define keywords that will trigger the inclusion of this entry in the AI's prompts.

!!!info When will an entry be used?
The entry will be used when a keyword is **mentioned in the conversation**. Only the top 3 entries are will be added per AI response. *The keyword order is important. Put the most relevant keyword first.*
!!!

### Lorebook visibility

+++ Global Lorebook
Check the **Global lorebook** option if you want the lorebook to be used throughout the entire novel.
+++ Scene-Specific Lorebook
The lorebook will be used only in the scenes you specify when creating them.
+++ Character-Specific Lorebook
The lorebook will be used whenever the a specific character is present. You can select it when creating a character.
+++

### Entry optimization
Keep entries concise and relevant. Use keywords wisely to ensure the AI has the right context without overloading its memory with unnecessary information.

The content should have the Q-A format.
```
user: Which country are we in?
Anna: Did you forget your head too, user? We are in Tokyo, Japan!
```
This also allows to give a personality to the response, so the AI can use it as example.

!!!warning Use templates
To refer the player, wrap the word `user` in between double `{` `}`. This will be replaced with the player's chosen name when playing.
If you want to do the same for the character, warp `char` with double curly braces.

See the tutorial video above for reference.
!!!

By following these steps, you can create rich, dynamic lorebooks that enhance the depth and realism of your visual novel, providing the AI with the necessary context to generate immersive and accurate responses.

4 changes: 4 additions & 0 deletions docs/src/guides/novel-builder/index.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
order: 1000
icon: tools
expanded: true
label: Novel Builder

0 comments on commit 9c7ad25

Please sign in to comment.