diff --git a/.config/ai/scpt/api_ten.zsh b/.config/ai/scpt/api_ten.zsh index bf95292..66a65a1 100755 --- a/.config/ai/scpt/api_ten.zsh +++ b/.config/ai/scpt/api_ten.zsh @@ -30,6 +30,9 @@ host_card_json=`curl -sL $host_card` n_cid=$HOME/.config/ai/txt/tmp_notify_cid.txt f_cfg=$HOME/.config/ai/txt/tmp_ten_config.txt +host=`cat ~/.config/ai/token.toml|head -n 1 |cut -d '"' -f 2` + + function moon_check(){ moon_now=`date +"%Y%m%d"` moon_j=$HOME/.config/ai/scpt/full_moon.j @@ -822,7 +825,12 @@ function card_post() { link="https://card.syui.ai/${username}" text=`echo "$title +${cten}\n$body\nten : $ten_su\n$ten_kai : $old_ten_char ---> $ten_char $ten_yak_ok"` - tmp_atr=`ai reply-og "$text" --cid $cid --uri $uri --img $img --title "$title" --description "$desc" --link $link` + + if [ "$host" = "bsky.social" ];then + tmp_atr=`ai reply-og "$text" --cid $cid --uri $uri --img $img --title "$title" --description "$desc" --link $link` + else + tmp_atr=`ai reply "$text" --cid $cid --uri $uri` + fi ten_shutdown } diff --git a/.config/ai/scpt/card_fortune.zsh b/.config/ai/scpt/card_fortune.zsh index ee67276..321d788 100755 --- a/.config/ai/scpt/card_fortune.zsh +++ b/.config/ai/scpt/card_fortune.zsh @@ -8,6 +8,14 @@ did=$2 cid=$3 uri=$4 +host=`cat ~/.config/ai/token.toml|head -n 1 |cut -d '"' -f 2` +if [ "$host" != "bsky.social" ];then + uranai="アイのカード占いを作ってやってみて。感じる答えを出して。できれば140文字以内でお願い。" + body=`ai chat "$uranai"` + ai reply "$body" -c $cid -u $uri + exit +fi + if [ ! -d $HOME/.config/ai/txt ];then mkdir -p $HOME/.config/ai/txt fi