Skip to content

nnsay/chatbots

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

1. 安装依赖

# 仅第一次使用
python -m venv .bot

# 激活虚拟环境
source .bot/bin/activate

# 安装依赖
pip install -r requirements.txt

2. 聊天

2.1 启动

  • 无会话
python oncebot.py

  • 有会话
python chatbot.py

2.2 退出

退出快捷键: Ctl + C

2.3 安装全局命令

克隆 repo 到本地, 进入 repo 执行下面的脚本

export GOOGLE_API_KEY=xxxx

pip install -r requirements.txt

mkdir -p $HOME/.local/bin
export PATH="$HOME/.local/bin:$PATH"

make install

2.4 调试

如果想要查看 langchain 的一些输出, 可以增加 DEBUG 环境变量, 例如:

DEBUG=1 python chatbot.py

3. 其他

  • 生成 requirements

    pipreqs . --force --ignore .bot

About

Command line chatbot with Gemini

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published