diff --git a/setup.sh b/setup.sh index 4e7a3961..00e5f20d 100755 --- a/setup.sh +++ b/setup.sh @@ -2,4 +2,5 @@ set -eu rm -rf /home/ChatGPT-Telegram-Bot git clone --depth 1 -b main https://github.com/yym68686/ChatGPT-Telegram-Bot.git +pip install -U md2tgmd python -u /home/ChatGPT-Telegram-Bot/bot.py \ No newline at end of file diff --git a/test/test_tgmd.py b/test/test_tgmd.py new file mode 100644 index 00000000..348ffeb7 --- /dev/null +++ b/test/test_tgmd.py @@ -0,0 +1,4 @@ +import md2tgmd +a = "### `probs.scatter_(1, ind`" +# a = "`🤖️ gpt-4-0125-preview`\n\n这段代码是一个关于如何在PyTorch中实现自回归模型生成功能的示例。其中包含了一个`top_k`函数和一个`AutoregressiveWrapper`类。首先,我会解释`top_k`函数中的`probs.scatter_(1, ind, val)`是如何工作的,然后再对整个代码进行概括说明。\n\n### `probs.scatter_(1, ind`" +print(md2tgmd.escape(a)) \ No newline at end of file