MCPcopy Create free account
hub / github.com/compozy/agh / memoryList

Method memoryList

internal/daemon/native_tools.go:2357–2377  ·  view source on GitHub ↗
(
	ctx context.Context,
	scope toolspkg.Scope,
	req toolspkg.CallRequest,
)

Source from the content-addressed store, hash-verified

2355}
2356
2357func (n *daemonNativeTools) memoryList(
2358 ctx context.Context,
2359 scope toolspkg.Scope,
2360 req toolspkg.CallRequest,
2361) (toolspkg.ToolResult, error) {
2362 var input memoryListInput
2363 if err := decodeNativeInput(req, &input); err != nil {
2364 return toolspkg.ToolResult{}, err
2365 }
2366 payload, err := n.memoryHeaderPayloads(ctx, scope, memoryToolSelector{
2367 Scope: input.Scope,
2368 Workspace: input.Workspace,
2369 AgentName: input.AgentName,
2370 AgentTier: input.AgentTier,
2371 })
2372 if err != nil {
2373 return toolspkg.ToolResult{}, nativeMemoryToolError(req.ToolID, err)
2374 }
2375 payload = limitMemoryPayloads(payload, input.Limit)
2376 return structuredResult(map[string]any{"memories": payload}, fmt.Sprintf("%d memories", len(payload)))
2377}
2378
2379func (n *daemonNativeTools) memoryShow(
2380 ctx context.Context,

Callers

nothing calls this directly

Calls 5

memoryHeaderPayloadsMethod · 0.95
decodeNativeInputFunction · 0.85
nativeMemoryToolErrorFunction · 0.85
limitMemoryPayloadsFunction · 0.85
structuredResultFunction · 0.85

Tested by

no test coverage detected