# shellcheck shell=dash

# x coco convert java python,c,cpp

___x_cmd_coco_summary(){
    local lang_prompt=""
    while [ $# -gt 0 ]; do
        case "$1" in
            --cn)       lang_prompt="Please answer the question in Chinese language.";   shift  ;;
            *)          break ;;
        esac
    done

    local file_path="$1"
    [ -f "$file_path" ] ||  N=coco M="Please provide a valid [filepath=$file_path]" log:ret:64
    ___x_cmd_cmds_cat "$file_path" | lang_prompt="${lang_prompt}" ___x_cmd_coco___request summary --pipe "FILE-CONTENT"
}

