on main help sign in
fix: use proper bool check
b680a4aChristian Rocha
internal/agent/tools/tools.go+1−1
@@ -61,7 +61,7 @@ func GetModelNameFromContext(ctx context.Context) string {
61// markdown description when CRUSH_SHORT_TOOL_DESCRIPTIONS is set, significantly
61// markdown description when CRUSH_SHORT_TOOL_DESCRIPTIONS is set, significantly
62// reducing token usage. Otherwise returns the full description.
62// reducing token usage. Otherwise returns the full description.
63func FirstLineDescription(content []byte) string {
63func FirstLineDescription(content []byte) string {
64− if os.Getenv("CRUSH_SHORT_TOOL_DESCRIPTIONS") == "" {
64+ if v, _ := strconv.ParseBool(os.Getenv("CRUSH_SHORT_TOOL_DESCRIPTIONS")); !v {
65 return strings.TrimSpace(string(content))
65 return strings.TrimSpace(string(content))
66 }
66 }
67 for line := range strings.SplitSeq(string(content), "\n") {
67 for line := range strings.SplitSeq(string(content), "\n") {