This commit is contained in:
@@ -47,14 +47,14 @@ async function callOllama(prompt, model = "gemma3n:e4b", retries = 6, stepName =
|
|||||||
function parseList(raw) {
|
function parseList(raw) {
|
||||||
return raw
|
return raw
|
||||||
.split("\n")
|
.split("\n")
|
||||||
.map(line => line.replace(/^\d+[\).\s-]*/, "").trim())
|
.map(line => line.replace(/^\d+[).\s-]*/, "").trim())
|
||||||
.filter(line => line.length > 0);
|
.filter(line => line.length > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
function parseObjects(raw, type = "rooms") {
|
function parseObjects(raw, type = "rooms") {
|
||||||
return raw
|
return raw
|
||||||
.split("\n")
|
.split("\n")
|
||||||
.map(line => line.replace(/^\d+[\).\s-]*/, "").trim())
|
.map(line => line.replace(/^\d+[).\s-]*/, "").trim())
|
||||||
.filter(line => line.length > 0)
|
.filter(line => line.length > 0)
|
||||||
.map(entry => {
|
.map(entry => {
|
||||||
if (type === "rooms") {
|
if (type === "rooms") {
|
||||||
|
|||||||
Reference in New Issue
Block a user