Updated Bing AI (markdown)
parent
fb1a2a4af9
commit
1fc04232f6
1 changed files with 34 additions and 9 deletions
43
Bing-AI.md
43
Bing-AI.md
|
@ -1,4 +1,6 @@
|
||||||
sample compose.yaml
|
Please carefully read the comments in the sample. <br>
|
||||||
|
|
||||||
|
sample `compose.yaml`
|
||||||
```yaml
|
```yaml
|
||||||
services:
|
services:
|
||||||
app:
|
app:
|
||||||
|
@ -8,11 +10,15 @@ services:
|
||||||
# build:
|
# build:
|
||||||
# context: .
|
# context: .
|
||||||
# dockerfile: ./Dockerfile
|
# dockerfile: ./Dockerfile
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
volumes:
|
volumes:
|
||||||
- ./config.json:/app/config.json
|
# use env file or config.json
|
||||||
- ./bot:/app/bot
|
# - ./config.json:/app/config.json
|
||||||
|
# use touch to create an empty file db, for persist database only
|
||||||
|
- ./db:/app/db
|
||||||
networks:
|
networks:
|
||||||
- matrix_bot
|
- matrix_network
|
||||||
api:
|
api:
|
||||||
# bing api
|
# bing api
|
||||||
image: hibobmaster/node-chatgpt-api:latest
|
image: hibobmaster/node-chatgpt-api:latest
|
||||||
|
@ -21,24 +27,43 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- ./settings.js:/var/chatgpt-api/settings.js
|
- ./settings.js:/var/chatgpt-api/settings.js
|
||||||
networks:
|
networks:
|
||||||
- matrix_bot
|
- matrix_network
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
matrix_bot:
|
matrix_network:
|
||||||
```
|
```
|
||||||
sample config.js
|
|
||||||
|
sample `.env`
|
||||||
|
```yaml
|
||||||
|
# Please remove the option that is blank
|
||||||
|
HOMESERVER="https://matrix.xxxxxx.xxxx" # required
|
||||||
|
USER_ID="@lullap:xxxxxxxxxxxxx.xxx" # required
|
||||||
|
PASSWORD="xxxxxxxxxxxxxxx" # Optional
|
||||||
|
DEVICE_ID="xxxxxxxxxxxxxx" # required
|
||||||
|
ROOM_ID="!FYCmBSkCRUXXXXXXXXX:matrix.XXX.XXX" # Optional, if not set, bot will work on the room it is in
|
||||||
|
OPENAI_API_KEY="xxxxxxxxxxxxxxxxx" # Optional, for !chat and !gpt command
|
||||||
|
BING_API_ENDPOINT="xxxxxxxxxxxxxxx" # Optional, for !bing command
|
||||||
|
ACCESS_TOKEN="xxxxxxxxxxxxxxxxxxxxx" # Optional, use user_id and password is recommended
|
||||||
|
JAILBREAKENABLED="true" # Optional
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
sample `config.json`
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
"homeserver": "https://xxxx",
|
"homeserver": "https://xxxx",
|
||||||
"user_id": "@lullap:xxxx",
|
"user_id": "@lullap:xxxx",
|
||||||
"password": "xxxxx",
|
"password": "xxxxx",
|
||||||
"device_id": "xxxxxx",
|
"device_id": "xxxxxx",
|
||||||
|
"room_id": "!FYCmBSkCRUxxxxxx:xxxxx.xxxx",
|
||||||
"api_key": "xxxxxxxx",
|
"api_key": "xxxxxxxx",
|
||||||
"bing_api_endpoint": "http://api:3000/conversation"
|
"bing_api_endpoint": "http://api:3000/conversation",
|
||||||
|
"jailbreakEnabled": true,
|
||||||
|
"access_token": "xxxxxxx"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
sample settings.js
|
sample `settings.js` , replace `bingAiClient->userToken` with your credentials
|
||||||
```js
|
```js
|
||||||
export default {
|
export default {
|
||||||
// Options for the Keyv cache, see https://www.npmjs.com/package/keyv.
|
// Options for the Keyv cache, see https://www.npmjs.com/package/keyv.
|
||||||
|
|
Loading…
Reference in a new issue