百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
D

Digital-Beings

> DevOps
开源

一个平台,让研究人员可以将智能 AI 直接连接到实时通信网络和 3D 世界。您的 AI,随时随地。

99 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

一个平台,让研究人员可以将智能 AI 直接连接到实时通信网络和 3D 世界。您的 AI,随时随地。

About

Digital Beings is a software that connects AI agents with a range of IM and VR software, making their deployment easier. You pick a bot, fill the account data and you're able to converse with a bot using SMS, Twitter or other social media.

Made in partnership with SuperReality, a free open source teaching platform for everyone.

Digital Beings is written in Typescript and Python. Typescript is used for the clients of most known social networks, as well as XR-Engine, a 3D metaverse architecture. A layer that connects the AI agents is called the server, and is written in Python.

Digital Being supports:

  • Discord (Servers, Threads, DMs)
  • Twitter (Tweets, DMs)
  • Instagram (DMs)
  • Messenger (DMs - Facebook Pages)
  • Reddit (Posts, Messages)
  • Telegram (Groupmessages , DMs)
  • Twilio (SMS)
  • WhatsAPP (untested)
  • XR-Engine (chat, also supports commands and events from other users - proximity, emotions, etc.)
  • Zoom (unfinished, supports video group calls).

The Client is using either the API for connecting to the different services like Discord, Messenger, etc, or Puppeteer for emulating the browser to connect to the XR-Engine and Zoom.

Out of the box, the server supports these AI bots:

  • DiaoloGPT
  • GPTNeo
  • Wizard of Wikipedia
  • OpenChat
  • GPT-j
  • Droidlet
  • Rasa
  • GPT-3 by OpenAI

The server can fetch chat history and transform it to a list.

The client is connected with the server using TCP sockets, sending JSON-encoded packets.

Right now these TCP packets may contain:

  • sendMessage - chat packet message
  • sendSlashCommand - Discord slash command - can be implemented to other clients too
  • sendUserUpdateEvent - on Discord join server, leave, on online, idle or offline, all events can be fed to agents
  • sendGetAgents - returns a list of the active agents
  • sendSetAgentsFields - this command can be used to update the context of an agent
  • sendPingSoloAgent - this command can be used to ping an agent directly, if many agents are active
  • sendMessageReaction - this command is sent when a user reacts to a message, currently implemented in Discord
  • sendMessageEdit - this command is sent when a message is edited, in order to update the agent’s response too
  • sendMetadata - this command is used to send the metadata of the current server - currently implemented in Discord and the XR-Engine

New packets can be implemented easily, the only thing to be noted is that the ID should be different from the old packets, also the packet should be sent as a JSON string, like the examples, to avoid any issues with the server. More info about Networking

Requirements

Digital Being requires the following to run:

  • Node.JS - version 16 or more
  • NPM - will be installed through Node.JS
  • Python - version 3.8 or more
  • Docker - makes the setup easy through using the containers

Setup

Docker (WSL/Linux):

  • Install Docker
  • Install docker-compose
  • Clone the repository and switch to its directory
  • Run the docker-compose build command to build the containers
  • In order to run the image you can use docker-compose up (if in Putty you can use docker-compose up -d to keep the image open after closing)
  • In order to close the image you can either use docker-compose down or Ctrl + Alt + C

Windows 10:

  • Install the requirements (Node.js, NPMhttps://npmjs.com/, Python)
  • Install Rust, which is needed in for the tokenizers library in requirements.txt
  • Install C++ build tools through Visual Studio Community
  • Clone the repository (git clone [email protected]:XRFoundation/DigitalBeing.git) and open the DigitalBeing directory
  • Run npm install
  • Run pip install -r requirements.txt
  • Rename the .env.default to .env (or make a new copy) and update the variables
  • Install PostgreSQL, setup the user and the database according to the parameters starting with PG* in an .env file and run the init.sql (root folder)
  • Run the bot in using npm run start in the command line

Without Docker (WSL/Linux):

  • Install the requirements (Node.JS, NPM and Python)
  • Run npm install
  • Run pip install -r requirements.txt
  • Install Postgres, setup the user and the database and run the init.sql (root folder)
  • Rename the .env.default to .env (or make a new copy) and update the variables
  • Run the bot in using npm run in the command line

Miscellaneous / Troubleshooting

Docker-compose up editor.sh error

If you get this error ERROR: for testbot_editor_1 Cannot start service editor: OCI runtime create failed: container_linux.go:380: starting container process caused: exec: "./editor.sh": permission denied: unknown before running the command docker-compose up run: chmod +x editor.sh in the root folder

How to install Postgres manual - without docker

  • sudo apt-get install postgresql - installs the postgresql service on the machine
  • sudo passwd postgres - the user postgres is created, with this command you can set a password, as the service runs on this user, close and reopen terminal if on WSL otherwise reboot
  • sudo service postgresql start - to start the postgres service
  • sudo -u postgres psql - to connect to postgres as the postgres user - the user can be changed to a custom user
  • if you want to run postgres on a different user you can use this command: sudo -u postgres createuser
  • to change the user password you will need to connect to postgres as the main user (postgres) and run: alter user with encrypted password '';
  • use create database ; to create the new database for the bot
  • to grant all privilages to the new user, run: grant all privileges on database to ;
  • then use \c
  • finally run the init.sql file that can be located in the root folder in order to create the database
  • Here you can find more detailed instructions

Changing active agents

Attention: applies to installed agent code.

Open server/agent_params.py and add / remove the SELECT_AGENTS list using the agent name string.

Selecting active clients

Attention: applies to the installed clients only.

Open src/initialize.ts and comment/uncomment the clients you need, if you need a client that uses a web server (ex. Twilio), go to client/webserver.ts and uncomment line 17 otherwise you can leave it commented.

Selecting available agents

Go to server/agent_params.py and add the agent name in SELECTED_AGENTS array, or delete / comment unwanted agents, like this.

Selecting available clients

Go to the src/initialize.ts and comment/uncomment the needed clients, like this.

Port forwarding (used for Twilio)

Port forwarding is needed in order to enable public access to a service, like the database, web server or the bot manager. Twilio needs an access to notify the DigitalBeing about SMS events.

Public IP is available (Docker)

In order to expose a port in the public inside docker go to docker-compose.yaml, edit the contaier you want to change and add the port according to this syntax.

yaml
ports:
  - "HOST_PORT:CONTAINER_PORT"

Example:

More details on the syntax are available in Compose documentation.

Public IP is not available (ngrok)

A software called ngrok may help if you are using a home network and are beyond the nat. It creates a tunnel that enables public access to your computer. In order to use ngrok, you will need to install it (it supports both windows and linux) and run ngrok http port through the command line. This command will generate a new URL that will be later use for public access.

This step can be used for the Editor, Twilio or Messenger, which needs public access to the computer.

Twilio setup

In order to run Twilio, you will need to have your ports forwarded. Puppeteer error, that it cant find Chrome: WSL can cause an error with puppeteer that it cant find chromium driver, in order to fix it you will need to install chrome manually, running the following commands:

bash
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
bash
sudo apt -y install ./google-chrome-stable_current_amd64.deb

XR-Engine Support:

DigitalBeing is able to connect to the XR-Engine using Puppeteer.

DigitalBeing is able to imitate a character in XR-engine and access its functions. It currently selects a random model. It works using a virtual headful client (runs like headless, but in headful mode virtual, as puppeteer doesn't support Audio and Video in headless mode) in the engine. Currently, DigitalBeing has a builtin support for the chat, which allows it to talk with users and use chat commands. It also has access to the client-logs, which have info about the bot, be it scene metadata or something else.

Available Commands - all commands start with a slash (/):

  • /move x,y,z moves to x,y,z position using navmesh
  • /metadata scene gets the scene metadata
  • /metadata world,max_distance (from bot) gets the world metadata (objects) around the bot
  • /listAllusers sends a client log with all users
  • /goTo landmark (based on world metadata) moves towards a landmark
  • /emote emote_name players an emote
  • /getPosition user get the position of a user
  • /getRotation user get the rotation of a user
  • /getScale user get the scale of a user
  • /getTransform user get the transform of a user (position, rotation, scale)
  • /subscribe system subscribe to chat system
  • /unsubscribe system unsubscribe from a chat system
  • /getSubscribed get the current subscribed chat systems
  • /follow user follow a user
  • /follow stop stop following a user
  • /getChatHistory get the recent chat history as client log
  • /getLocalUserId get the local user id as client log

Note: the xrengine-client.ts has all the functions needed to send commands or generally a chat message.

Scripts Structure:

The [XR-Engine](https://github.com/EtherealEngine/etherealengi

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

TypeScriptaiartificial-intelligencebotcomputer-vision

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类DevOps
定价开源

> 相关工具

D
Docker
容器化平台,标准化应用交付
G
GitHub Actions
GitHub 原生 CI/CD 工作流
N
Nginx
高性能 Web 服务器与反向代理