Private
Public Access
1
0

Rename shared.State to shared.Shared

This commit is contained in:
2024-06-08 22:01:16 +00:00
parent c9e92e186e
commit c1ead83939
7 changed files with 36 additions and 36 deletions

View File

@@ -70,7 +70,7 @@ const (
)
type Model struct {
shared.State
shared.Shared
shared.Sections
// app state
@@ -104,9 +104,9 @@ type Model struct {
elapsed time.Duration
}
func Chat(state shared.State) Model {
func Chat(shared shared.Shared) Model {
m := Model{
State: state,
Shared: shared,
state: idle,
conversation: &models.Conversation{},
@@ -140,7 +140,7 @@ func Chat(state shared.State) Model {
m.replyCursor.SetChar(" ")
m.replyCursor.Focus()
system := state.Ctx.GetSystemPrompt()
system := shared.Ctx.GetSystemPrompt()
if system != "" {
m.messages = []models.Message{{
Role: models.MessageRoleSystem,