Update aiEngine.js
Browse files- aiEngine.js +8 -2
aiEngine.js
CHANGED
|
@@ -92,7 +92,10 @@ export const AIEngine = {
|
|
| 92 |
callPMStream: async (history, input, onThink, onOutput, gdd = null) => {
|
| 93 |
const systemPrompt = prompts.pm_system_prompt || "You are a Project Manager.";
|
| 94 |
// ECONOMIC CAP: 15 messages max for PM to maintain context but control costs
|
| 95 |
-
const prompt = flattenHistory(history, input, systemPrompt,
|
|
|
|
|
|
|
|
|
|
| 96 |
|
| 97 |
const response = await fetch(`${REMOTE_SERVER_URL}/api/stream`, {
|
| 98 |
method: 'POST',
|
|
@@ -128,7 +131,10 @@ export const AIEngine = {
|
|
| 128 |
|
| 129 |
callPM: async (history, input, gdd = null) => {
|
| 130 |
const systemPrompt = prompts.pm_system_prompt || "You are a Project Manager.";
|
| 131 |
-
const prompt = flattenHistory(history, input, systemPrompt,
|
|
|
|
|
|
|
|
|
|
| 132 |
|
| 133 |
const response = await fetch(`${REMOTE_SERVER_URL}/api/generate`, {
|
| 134 |
method: 'POST',
|
|
|
|
| 92 |
callPMStream: async (history, input, onThink, onOutput, gdd = null) => {
|
| 93 |
const systemPrompt = prompts.pm_system_prompt || "You are a Project Manager.";
|
| 94 |
// ECONOMIC CAP: 15 messages max for PM to maintain context but control costs
|
| 95 |
+
const prompt = flattenHistory(history, input, systemPrompt,
|
| 96 |
+
//15,
|
| 97 |
+
10,
|
| 98 |
+
gdd);
|
| 99 |
|
| 100 |
const response = await fetch(`${REMOTE_SERVER_URL}/api/stream`, {
|
| 101 |
method: 'POST',
|
|
|
|
| 131 |
|
| 132 |
callPM: async (history, input, gdd = null) => {
|
| 133 |
const systemPrompt = prompts.pm_system_prompt || "You are a Project Manager.";
|
| 134 |
+
const prompt = flattenHistory(history, input, systemPrompt,
|
| 135 |
+
// 15,
|
| 136 |
+
10,
|
| 137 |
+
gdd); // Limit 15
|
| 138 |
|
| 139 |
const response = await fetch(`${REMOTE_SERVER_URL}/api/generate`, {
|
| 140 |
method: 'POST',
|