1- # Discord Agent Examples
1+ # Discord Agent Example
22
3- Full-featured Discord AI agents using elizaOS, available in ** TypeScript ** , ** Python ** , and ** Rust ** .
3+ Full-featured TypeScript Discord AI agent using elizaOS.
44
55## Features
66
@@ -46,73 +46,36 @@ Required variables:
4646
4747### 4. Run the Agent
4848
49- Choose your preferred language:
50-
51- #### TypeScript
5249``` bash
53- cd typescript
50+ cd packages/examples/discord
5451bun install
55- bun start
52+ bun run start
5653# or for development with hot reload:
57- bun dev
58- ```
59-
60- #### Python
61- ``` bash
62- cd python
63- pip install -r requirements.txt
64- python agent.py
65- ```
66-
67- #### Rust
68- ``` bash
69- cd rust/discord-agent
70- cargo run --release
54+ bun run dev
7155```
7256
7357## Project Structure
7458
7559```
76- examples/discord/
60+ packages/ examples/discord/
7761├── env.example # Environment template
7862├── README.md # This file
79- ├── typescript/ # TypeScript implementation
80- │ ├── agent.ts # Main entry point
81- │ ├── character.ts # Bot personality
82- │ ├── handlers.ts # Event handlers
83- │ ├── package.json
84- │ └── __tests__/ # Tests
85- ├── python/ # Python implementation
86- │ ├── agent.py # Main entry point
87- │ ├── character.py # Bot personality
88- │ ├── handlers.py # Event handlers
89- │ ├── requirements.txt
90- │ └── tests/ # Tests
91- └── rust/ # Rust implementation
92- └── discord-agent/
93- ├── Cargo.toml
94- ├── src/
95- │ ├── main.rs # Main entry point
96- │ ├── character.rs # Bot personality
97- │ └── handlers.rs # Event handlers
98- └── tests/ # Tests
63+ ├── agent.ts # Main entry point
64+ ├── character.ts # Bot personality
65+ ├── handlers.ts # Event handlers
66+ ├── package.json
67+ └── tsconfig.json
9968```
10069
10170## Customization
10271
10372### Modify Bot Personality
10473
105- Edit the character file for your language:
106- - TypeScript: ` typescript/character.ts `
107- - Python: ` python/character.py `
108- - Rust: ` rust/discord-agent/src/character.rs `
74+ Edit ` character.ts ` .
10975
11076### Add Custom Commands
11177
112- Edit the handlers file to add new slash commands:
113- - TypeScript: ` typescript/handlers.ts `
114- - Python: ` python/handlers.py `
115- - Rust: ` rust/discord-agent/src/handlers.rs `
78+ Edit ` handlers.ts ` to add new slash commands.
11679
11780### Discord Settings
11881
@@ -137,14 +100,8 @@ Configure bot behavior in the character settings:
137100## Testing
138101
139102``` bash
140- # TypeScript
141- cd typescript && bun test
142-
143- # Python
144- cd python && pytest
145-
146- # Rust
147- cd rust/discord-agent && cargo test
103+ cd packages/examples/discord
104+ bun run test
148105```
149106
150107## Troubleshooting
0 commit comments