feat: optimize some prompts

This commit is contained in:
2023-11-13 18:35:37 +01:00
parent 1c17ca9d39
commit ca716bd672
14 changed files with 19 additions and 38 deletions

View File

@ -1,4 +1,5 @@
<script lang="ts">
import Loader from '$lib/components/Loader.svelte';
import Questions from '$lib/components/Questions.svelte';
import TextSplit from '$lib/components/TextSplit.svelte';
import Button from '$lib/components/button.svelte';

View File

@ -7,9 +7,9 @@ export const GET: RequestHandler = async function ({ params }) {
const inputName = params.name
const a = performance.now();
const prompt = `Generate 10 variants of the name ${inputName}. The names should sound very much like the original but also like noble names. Examples could be "lady rosalind of whitmore" "lord byron of castlemore" "Lord Max Richter". Choose english, german, french and italian sounding names. Only respond with 10 names seperated be newlines`;
const newPrompt = `Imagine you're hosting a grand masked ball in a magical realm where guests adopt noble titles that resonate with their true essence. You have a distinguished guest named ${inputName}, and you want to create an air of mystery and elegance and mystery by providing them with alternative noble names inspired by various European regions. Generate 10 names that carry the essence of ${inputName} but with a touch of grandeur, drawing inspiration from the diverse cultures surrounding Europe. Only respond with 10 suggestions seperated by newlines.`
const res = await chat(prompt, { isList: true, temperature: 1 });
const res = await chat(newPrompt, { isList: true, temperature: 1 });
console.log(`[AI] Generated names for ${inputName} in ${performance.now() - a}ms`);
console.log(JSON.stringify(res, null, 2));