from pathlib import Path
path = Path('/home/admin/docker-projects/sub2api/backend/internal/service/openai_gateway_service.go')
text = path.read_text()
bad = 'lines := strings.Split(body, "' + '\n' + '")'
good = 'lines := strings.Split(body, "\\n")'
if bad not in text:
    raise SystemExit('bad split pattern not found')
path.write_text(text.replace(bad, good, 1))
print('fixed split literal')
