Token-Optimierung: Prompt Caching + Tool-Result-Truncation in History
This commit is contained in:
1 parent
ec5917ef63
commit
f74409dd89
12 files changed
+220
-59
No files matched your search
@@ -112,6 +112,12 @@ async function apiExecCommand(sessionId, command) {
|
||||
});
|
||||
}
|
||||
|
||||
async function apiGetSystemPrompt(sessionId) {
|
||||
const resp = await fetch(`/api/sessions/${sessionId}/system-prompt`);
|
||||
if (!resp.ok) throw new Error('System-Prompt konnte nicht geladen werden');
|
||||
return resp.text();
|
||||
}
|
||||
|
||||
async function apiIsStreaming(sessionId) {
|
||||
const resp = await fetch(`/api/sessions/${sessionId}/streaming`);
|
||||
return resp.json();
|
||||
|
||||
Reference in new issue
Block a user