Giter VIP home page Giter VIP logo

dingtalk-chatgpt-bot's Introduction

此版本不维护了,可以使用node版本的,支持session和key两种模式dingtalk-chatgpt-node

⚠️ This repository is deprecated and no longer maintained!

The python proxy api repo pygpt didn't work, you can use node version chatgpt-io

Change Log

  • 2022-03-08

    • 优化代码,修复代理服务器偶尔connect refused的问题
  • 2022-03-03

    • 使用sqlite3增加上下文功能, @bot /reset 命令会重新打开新聊天窗口 image
  • 2022-02-14

    • 增加docker部署
  • 2022-02-10

    • 机器人名字叫ChatGPT会被禁止使用, 可以换成其他的 image

DingTalk ChatGPT Bot(Unofficial API)

Uses API by PawanOsman

Disclaimer

This is not open source. PawanOsman can see all your requests and your session token.

Prerequisites

Feature

chat conversation context

reset conversation

Usage

python

  1. install dependencies
    pip3 install -r requirements.txt
    
  2. Update config.py variables with your own info
  3. execute script in background
    nohup python3 -u index.py > nohup.out 2>&1 &
    
  4. watch logs
    tail -30f nohup.out
    

docker

  1. get docker image and run
    docker run -dp 8083:8083 fengcailing/dingtalk-chatgpt-bot:1.0.2
    
  2. show docker list and get docker container id
    docker ps
    
  3. cd docker
    docker exec -it <containerId> /bin/sh
    
  4. update config.py(GPT_SESSION、APP_SECRET)
  5. exit docker
    exit
    
  6. create new iamge
    docker commit -m 'update config' <containerId> dingtalk-chatgpt-bot:v1
    
  7. stop pre container and run new image
    docker stop <containerId>
    docker run -dp 8083:8083 dingtalk-chatgpt-bot:v1
    
  8. watch logs
    docker logs -n 30 -f <new containerId>
    

If you @YourBotName in DingTalk group, it will get ChatGPT answer and reply.

E.g.

demo

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.