package orchestrator import ( "strings" "testing" "github.com/muyue/muyue/internal/config" ) func TestCleanAIResponse(t *testing.T) { tests := []struct { name string input string expected string }{ { "removes standard think tags", "reasoningresponse", "response", }, { "removes think with attrs", "reasoningreasoning>\nvisible", "text\nvisible", }, { "removes triple markers", "text\n<<<\ninternal\n>>>\nvisible", "text\nvisible", }, { "plain text unchanged", "Hello world", "Hello world", }, { "empty input", "", "", }, { "removes valid think block", " on opening tag, so won't match regex if result3 != ", so won't match if result4 != "reasoning after it, so won't match if result_real != "prefix