Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ContradictionMatch ¶
type ContradictionMatch struct {
Memory Memory `json:"memory"`
Similarity float32 `json:"similarity"`
}
ContradictionMatch represents a potentially conflicting existing memory.
type Memory ¶
type Memory struct {
ID string `json:"id"`
Content string `json:"content"`
Scope Scope `json:"scope"`
Project string `json:"project,omitempty"`
Type MemoryType `json:"type"`
Tags []string `json:"tags,omitempty"`
Weight float64 `json:"weight"`
Supersedes string `json:"supersedes,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
TTL *time.Time `json:"ttl,omitempty"`
}
type MemoryType ¶
type MemoryType string
const ( TypeFact MemoryType = "fact" TypeRule MemoryType = "rule" TypeDecision MemoryType = "decision" TypeFeedback MemoryType = "feedback" TypeContext MemoryType = "context" TypeBootstrap MemoryType = "bootstrap" )
type RecallInput ¶
type RecallResult ¶
type RememberInput ¶
type RememberInput struct {
Content string `json:"content"`
Scope Scope `json:"scope"`
Project string `json:"project,omitempty"`
Type MemoryType `json:"type"`
Tags []string `json:"tags,omitempty"`
Weight float64 `json:"weight,omitempty"`
Supersedes string `json:"supersedes,omitempty"`
TTL string `json:"ttl,omitempty"` // duration string, e.g. "24h"
}
type RememberResult ¶
type RememberResult struct {
Memory *Memory `json:"memory"`
Contradictions []ContradictionMatch `json:"contradictions,omitempty"`
}
RememberResult is returned by Remember() — includes stored memory and any contradiction warnings.
Click to show internal directories.
Click to hide internal directories.