Documentation
¶
Overview ¶
Package messagehistory persists raw user-submitted chat messages for local composer recall.
Index ¶
Constants ¶
View Source
const (
// MaxEntriesPerScope is the hard cap for persisted messages in one CWD scope.
MaxEntriesPerScope = 1000
)
Variables ¶
This section is empty.
Functions ¶
func ResolveScopeCWD ¶
ResolveScopeCWD normalizes cwd and, when cwd is inside a Git worktree, returns the worktree root so history is shared across subdirectories of one project.
Types ¶
type Entry ¶
type Entry struct {
Version int `json:"v"`
CreatedAt time.Time `json:"ts"`
ScopeCWD string `json:"scope_cwd"`
ConversationID string `json:"conversation_id,omitempty"`
Profile string `json:"profile,omitempty"`
Source string `json:"source"`
Text string `json:"text"`
}
Entry is one raw user-submitted composer message.
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store writes JSONL history files under the Kodelet base directory.
func NewStore ¶
NewStore returns a store rooted in Kodelet's private base directory. It does not create directories until a message is appended.
func NewStoreWithBasePath ¶
NewStoreWithBasePath returns a store rooted at basePath.
Click to show internal directories.
Click to hide internal directories.