MCPcopy Create free account
hub / github.com/GongShichen/LuminaCode / isTransientMessage

Function isTransientMessage

sessionmemory/store.go:742–756  ·  view source on GitHub ↗
(msg map[string]any)

Source from the content-addressed store, hash-verified

740 if err := rows.Scan(&id); err != nil {
741 rows.Close()
742 return err
743 }
744 ids = append(ids, id)
745 }
746 rows.Close()
747 for _, id := range ids {
748 if _, err := s.db.ExecContext(ctx, `DELETE FROM messages WHERE id = ?`, id); err != nil {
749 return err
750 }
751 }
752 return nil
753}
754
755func (s *Store) maxUserTurn(ctx context.Context) int {
756 var value sql.NullInt64
757 _ = s.db.QueryRowContext(ctx, `SELECT MAX(user_turn_count) FROM messages`).Scan(&value)
758 if value.Valid {
759 return int(value.Int64)

Callers 1

IngestMessagesMethod · 0.85

Calls 1

stringValueFunction · 0.70

Tested by

no test coverage detected