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

Function HasLevel

internal/thinking/convert.go:101–108  ·  view source on GitHub ↗

HasLevel reports whether the given target level exists in the levels slice. Matching is case-insensitive with leading/trailing whitespace trimmed.

(levels []string, target string)

Source from the content-addressed store, hash-verified

99// HasLevel reports whether the given target level exists in the levels slice.
100// Matching is case-insensitive with leading/trailing whitespace trimmed.
101func HasLevel(levels []string, target string) bool {
102 for _, level := range levels {
103 if strings.EqualFold(strings.TrimSpace(level), target) {
104 return true
105 }
106 }
107 return false
108}
109
110// MapToClaudeEffort maps a generic thinking level string to a Claude adaptive
111// thinking effort value (low/medium/high/max).

Callers 5

ApplyMethod · 0.92
ApplyMethod · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected