use sharp and improve prompting
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/cron/ci Pipeline was successful

This commit is contained in:
Madison Grubb
2025-09-05 16:48:35 -04:00
parent be7534be8d
commit a3c54b1c82
6 changed files with 559 additions and 13 deletions

View File

@@ -33,8 +33,6 @@ function parseObjects(raw, type = "rooms") {
}
export async function generateDungeon() {
console.log("Starting compact dungeon generation with debug logs...\n");
// Step 1: Titles
const generatedTitlesRaw = await callOllama(
`Generate 50 short, punchy dungeon titles (max 5 words each), numbered as a plain text list.
@@ -47,7 +45,7 @@ Each title should come from a different style or theme. Make the set varied and
- Weird fantasy: uncanny, surreal, unsettling
- Whimsical: fun, quirky, playful
Avoid repeating materials or adjectives. Absolutely do not use the words "Obsidian" or "Clockwork" in any title. If a title contains either word, it is invalid and must be discarded. Do not include explanations, markdown, or preambles. Do not include the style or theme in parenthesis. Only the 50 numbered titles.`,
Avoid repeating materials or adjectives. Absolutely do not use the words "Obsidian" or "Clockwork" in any title. Do not include explanations, markdown, or preambles. Do not include the style or theme in parenthesis. Only the 50 numbered titles.`,
undefined, 5, "Step 1: Titles"
);
const generatedTitles = parseList(generatedTitlesRaw);
@@ -57,7 +55,7 @@ Avoid repeating materials or adjectives. Absolutely do not use the words "Obsidi
// Step 2: Flavor text
const flavorRaw = await callOllama(
`Write a single evocative paragraph describing the location titled "${title}".
`Write a single evocative paragraph describing the location titled "${title}". Absolutely do not use the words "Obsidian" or "Clockwork" anywhere in the paragraph.
Do not include hooks, NPCs, treasure, or instructions. Do not use bullet points or em-dashes. Output plain text only, one paragraph. Maximum 4 sentences.`,
undefined, 5, "Step 2: Flavor"
);