Versions in this module Expand all Collapse all v2 v2.0.1 Jul 30, 2026 v2.0.0 Jul 30, 2026 Changes in this version + const MaxToolResultContentBytes + func BuildMessagesFromEvents(events []memory.Event) ([]*model.Message, error) + func ProjectToolResultContent(resultJSON rawjson.Message, bounds *agent.Bounds, preview string, ...) (any, error) + func ValidateBedrock(messages []*model.Message, thinkingEnabled bool) error + type Ledger struct + func FromModelMessages(msgs []*model.Message) *Ledger + func NewLedger() *Ledger + func (l *Ledger) AppendText(text string) + func (l *Ledger) AppendThinking(tp ThinkingPart) + func (l *Ledger) AppendUserToolResults(results []ToolResultSpec) + func (l *Ledger) BuildMessages() []*model.Message + func (l *Ledger) DeclareToolUse(id, name string, args any) + func (l *Ledger) FlushAssistant() + func (l *Ledger) IsEmpty() bool + func (l *Ledger) MarshalJSON() ([]byte, error) + func (l *Ledger) UnmarshalJSON(data []byte) error + type Message struct + Meta map[string]any + Parts []Part + Role string + func (m *Message) UnmarshalJSON(data []byte) error + type Part interface + type TextPart struct + Text string + type ThinkingPart struct + Final bool + Index int + Redacted []byte + Signature string + Text string + type ToolResultPart struct + Content any + IsError bool + ToolUseID string + type ToolResultSpec struct + Content any + IsError bool + ToolUseID string + type ToolUsePart struct + Args any + ID string + Name string Other modules containing this package github.com/CaliLuke/loom-mcp