mirror of
https://github.com/sst/opencode.git
synced 2025-12-23 10:11:41 +00:00
feat: compact command with auto-compact
This commit is contained in:
parent
364cf5b429
commit
49423da081
16 changed files with 507 additions and 73 deletions
|
|
@ -7,6 +7,8 @@ INSERT INTO sessions (
|
|||
prompt_tokens,
|
||||
completion_tokens,
|
||||
cost,
|
||||
summary,
|
||||
summarized_at,
|
||||
updated_at,
|
||||
created_at
|
||||
) VALUES (
|
||||
|
|
@ -17,6 +19,8 @@ INSERT INTO sessions (
|
|||
?,
|
||||
?,
|
||||
?,
|
||||
?,
|
||||
?,
|
||||
strftime('%s', 'now'),
|
||||
strftime('%s', 'now')
|
||||
) RETURNING *;
|
||||
|
|
@ -38,7 +42,9 @@ SET
|
|||
title = ?,
|
||||
prompt_tokens = ?,
|
||||
completion_tokens = ?,
|
||||
cost = ?
|
||||
cost = ?,
|
||||
summary = ?,
|
||||
summarized_at = ?
|
||||
WHERE id = ?
|
||||
RETURNING *;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue