MCPcopy Create free account
hub / github.com/diillson/chatcli / moaToolsetForRun

Method moaToolsetForRun

cli/moa_turn.go:80–89  ·  view source on GitHub ↗

moaToolsetForRun decides the capabilities for a run: knowledge follows the same gate as the chat exception (enabled + a base attached to the session); recall is granted only when the compression layer is wired AND the shared history actually carries a CCR marker — offering it otherwise would be a de

(history []models.Message)

Source from the content-addressed store, hash-verified

78// retrieval did not surface — the pull closes that gap (and @moa in
79// agent/coder mode gets no memory push at all).
80func (cli *ChatCLI) moaToolsetForRun(history []models.Message) moaToolset {
81 ts := moaToolset{
82 knowledge: cli.chatKnowledgeActive(),
83 memory: loadMemoryMode() != memModeOff,
84 }
85 if cli.compressionLayer != nil && historyHasCCRMarkers(history) {
86 ts.recall = true
87 }
88 return ts
89}
90
91// historyHasCCRMarkers reports whether any message carries a "<<ccr:KEY>>"
92// compression marker, using the compress package's own key scanner.

Callers 5

handleMoACommandMethod · 0.95
RunMethod · 0.80

Calls 3

chatKnowledgeActiveMethod · 0.95
loadMemoryModeFunction · 0.85
historyHasCCRMarkersFunction · 0.85