MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / RecordToolsDirect

Method RecordToolsDirect

internal/sessions/session.go:246–254  ·  view source on GitHub ↗

RecordToolsDirect sets the session's tools from a pre-built slice (for testing).

(tools []observedtools.ObservedTool)

Source from the content-addressed store, hash-verified

244
245// RecordToolsDirect sets the session's tools from a pre-built slice (for testing).
246func (s *Session) RecordToolsDirect(tools []observedtools.ObservedTool) {
247 s.mu.Lock()
248 defer s.mu.Unlock()
249 s.Tools = tools
250 s.toolProfile = nil
251 if s.Agent == AgentUnknown {
252 s.Agent = detectAgent(tools)
253 }
254}

Calls 1

detectAgentFunction · 0.85