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

Function limitSessionPayloads

internal/daemon/native_tools.go:5935–5940  ·  view source on GitHub ↗
(items []T, limit int)

Source from the content-addressed store, hash-verified

5933}
5934
5935func limitSessionPayloads[T any](items []T, limit int) []T {
5936 if limit <= 0 || limit >= len(items) {
5937 return items
5938 }
5939 return items[:limit]
5940}
5941
5942func structuredResult(value any, preview string) (toolspkg.ToolResult, error) {
5943 data, err := json.Marshal(value)

Callers 1

sessionListMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected