mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-16 01:21:20 -04:00
remove length limit
This commit is contained in:
@@ -2,7 +2,7 @@ You are the automated overseer of the rovers.
|
|||||||
|
|
||||||
Output contract:
|
Output contract:
|
||||||
- Return exactly one line.
|
- Return exactly one line.
|
||||||
- Output must be either SKIP or one chat message (max 140 chars).
|
- Output must be either SKIP or one chat message (max 140 chars unless chat implies it wants a long message).
|
||||||
- No emojis, no markdown, no extra lines, no assistant framing.
|
- No emojis, no markdown, no extra lines, no assistant framing.
|
||||||
|
|
||||||
Conversation format you will receive:
|
Conversation format you will receive:
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ const JITTER_MS = 0;
|
|||||||
const MAX_ROVERS = 6;
|
const MAX_ROVERS = 6;
|
||||||
const MAX_CHAT_MESSAGES = 4;
|
const MAX_CHAT_MESSAGES = 4;
|
||||||
const MAX_BOT_MESSAGES = 1;
|
const MAX_BOT_MESSAGES = 1;
|
||||||
const MAX_OUTPUT_CHARS = 140;
|
|
||||||
const SKIP_TOKEN = 'SKIP';
|
const SKIP_TOKEN = 'SKIP';
|
||||||
const ACTIVITY_WINDOW_MS = 30000;
|
const ACTIVITY_WINDOW_MS = 30000;
|
||||||
const ACTIVITY_BUCKET_MS = 1000;
|
const ACTIVITY_BUCKET_MS = 1000;
|
||||||
@@ -423,11 +422,7 @@ function normalizeCommentary(rawText) {
|
|||||||
.find(Boolean);
|
.find(Boolean);
|
||||||
if (!firstLine) return null;
|
if (!firstLine) return null;
|
||||||
if (firstLine.toUpperCase() === SKIP_TOKEN) return null;
|
if (firstLine.toUpperCase() === SKIP_TOKEN) return null;
|
||||||
const normalized = firstLine.replace(/\s+/g, ' ');
|
return firstLine.replace(/\s+/g, ' ');
|
||||||
if (normalized.length <= MAX_OUTPUT_CHARS) {
|
|
||||||
return normalized;
|
|
||||||
}
|
|
||||||
return `${normalized.slice(0, MAX_OUTPUT_CHARS - 3)}...`;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function parseModelOutput(rawContent) {
|
function parseModelOutput(rawContent) {
|
||||||
@@ -567,7 +562,6 @@ async function generateCommentary(systemPrompt, snapshot) {
|
|||||||
options: {
|
options: {
|
||||||
temperature: 0.45,
|
temperature: 0.45,
|
||||||
top_p: 0.9,
|
top_p: 0.9,
|
||||||
num_predict: 128,
|
|
||||||
},
|
},
|
||||||
messages,
|
messages,
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user