Simplify gpt, remove local llama and allow not pasting. - annna - Annna the nice friendly bot.
 (HTM) git clone git://bitreich.org/annna/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/annna/
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) Tags
 (DIR) README
       ---
 (DIR) commit 184caad66a4b23805ac3afcec77dc48107eb3ae2
 (DIR) parent 27a48535ce736f7a97b89b39acef695d569e3b09
 (HTM) Author: Annna Robert-Houdin <annna@bitreich.org>
       Date:   Sat,  1 Aug 2026 00:22:32 +0200
       
       Simplify gpt, remove local llama and allow not pasting.
       
       Diffstat:
         M gpt                                 |      60 ++++---------------------------
         M modules/hashtags/hashtags.txt       |       1 -
       
       2 files changed, 7 insertions(+), 54 deletions(-)
       ---
 (DIR) diff --git a/gpt b/gpt
       @@ -2,58 +2,8 @@
        
        export PATH="$HOME/bin:$PATH:/br/bin"
        
       -# TODO: Remove due to outdated model.
       -function local_llama() {
       -        #ggmlbase="/br/ai/ggml"
       -        ggmlbase="/br/ai/llama.cpp"
       -        #ggmlbin="./build/bin/gpt-2"
       -        ggmlbin="./build/bin/llama-cli"
       -        #ggmlmodel="models/gpt-2-1558M/ggml-model.bin"
       -        ggmlmodel="models/Meta-Llama-3.1-8B-Instruct-Q4_K_M.gguf"
       -        ggmlntokens="$((69 * 2))"
       -
       -        cd $ggmlbase
       -        if mountpoint -q /br/ai/tmp;
       -        then
       -                ggmlbasename="$(basename "${ggmlmodel}")"
       -                ggmltmppath="/br/ai/tmp/${ggmlbasename}"
       -                [ ! -r "${ggmltmppath}" ] && cp "$ggmlmodel" /br/ai/tmp        
       -                [ -r "${ggmltmppath}" ] && ggmlmodel="${ggmltmppath}"
       -        fi
       -
       -        prompt="$1"
       -        if [ -z "$prompt" ];
       -        then
       -                cat \
       -                | $ggmlbin -m $ggmlmodel -n $ggmlntokens -t 3 \
       -                        --no-warmup --simple-io --no-display-prompt --grammar 'root ::= ([^\x00-\x1F])*' \
       -                        -cnv 2>/dev/null \
       -                        | sed -E '/^$/d;s/^>[[:blank:]]+//;q' \
       -                        | sed -e 's/^"//;s/"$//;'
       -        else
       -                printf "%s\n" "${prompt}" \
       -                | $ggmlbin -m $ggmlmodel -n $ggmlntokens -t 3 \
       -                        --no-warmup --simple-io --no-display-prompt --grammar 'root ::= ([^\x00-\x1F])*' \
       -                        -cnv 2>/dev/null \
       -                        | sed -E '/^$/d;s/^>[[:blank:]]+//;q' \
       -                        | sed -e 's/^"//;s/"$//;'
       -        fi
       -        #$ggmlbin -m $ggmlmodel -n $ggmlntokens \
       -        #        --simple-io --no-display-prompt --grammar 'root ::= ([^\x00-\x1F])*' \
       -        #        -p "$1" 2>/dev/null \
       -        #        | head -n1 \
       -        #        | sed -E 's/^[[:blank:]]+//;s/[[:blank:]]*\[end of text\]$//' \
       -        #        | tr -d '"'
       -}
       -
        function remote_llama() {
                prompt="$1"
       -        #ggmlmodel="AutumnAurelium/llama3.1-abliterated"
       -        #ggmlmodel="mannix/llama3.1-8b-abliterated"
       -        #ggmlmodel="huihui_ai/gpt-oss-abliterated:20b"
       -        #ggmlmodel="huihui_ai/qwen3-abliterated:16b"
       -        #ggmlmodel="huihui_ai/gemma3-abliterated:12b"
       -        #ggmlmodel="huihui_ai/deepseek-r1-abliterated:14b"
                ggmlmodel="dmtx/qwen3.5-9b-abliterated"
                if [ -z "$prompt" ];
                then
       @@ -75,8 +25,12 @@ function remote_llama() {
        
        prompt="$1"
        response="$(remote_llama "${prompt}")"
       -[ -z "${response}" ] && response="$(local_llama "${prompt}")"
       -olines="$(printf "%s\n" "${response}" | wc -l)"
       -[ $olines -gt 1 ] && response="$(printf "%s\n" "${response}" | bitreich-paste)"
       +[ -z "${response}" ] && exit 0
       +
       +if [ -z "${NO_PASTING}" ];
       +then
       +        olines="$(printf "%s\n" "${response}" | wc -l)"
       +        [ $olines -gt 1 ] && response="$(printf "%s\n" "${response}" | bitreich-paste)"
       +fi
        [ -n "${response}" ] && printf "%s\n" "${response}"
        
 (DIR) diff --git a/modules/hashtags/hashtags.txt b/modules/hashtags/hashtags.txt
       @@ -1,4 +1,3 @@
       -#*h₂móh₃ǵʰos gophers://bitreich.org/I/memecache/*h₂móh₃ǵʰos.png
        #-20-social-credit gophers://bitreich.org/I/memecache/-20-social-credit.png
        #0-0-0 gophers://bitreich.org/I/memecache/0-0-0.jpg
        #0-fucks gophers://bitreich.org/I/memecache/0-fucks.jpg