This project is a customizable Discord bot powered by OpenAI. It features a friendly interaction model, supports image processing, maintains a conversation history and give your ai access to a set of tools
Discord AI Chatbot is an advanced AI-powered Discord bot that leverages the capabilities of AI models like GPT or Claude to provide interactive and engaging chat experiences. This bot integrates various features and tools to enhance user interactions and provide real-time information.
Clone the repository:
git clone [email protected]:Karhal/discord-ai-chatbot.git
cd discord-ai-chatbot
Install dependencies:
npm install
Set up configuration:
src/config.ts.dist
to src/config.ts
src/config.ts
with your API keys and preferencesStart the bot:
npm run start
The src/config.ts
file contains all the configuration options. Here are some key areas:
Refer to the comments in the config file for detailed explanations of each option.
config.ts
config.ts
To use Claude as your AI model:
config.ts
file under the claude.apiKey
field.Note: Anthropic may have specific requirements or a waitlist for API access. Check their current policies and follow their instructions to obtain API access.
Follow similar processes for other services like Brave Search, Google Search, CoinAPI, etc. Refer to each service's documentation for specific instructions.
To run this application in a production environment, follow these steps:
Install production dependencies only:
npm install --production
Build the project:
npm run build
Start the application:
npm start
The --production
flag ensures that only dependencies listed in the "dependencies" section of package.json
are installed, excluding devDependencies. This reduces the installation size and potential security risks in the production environment.
The build process uses tsup
to compile and minify the TypeScript code. The production build is generated in the dist
directory, with index.cjs
as the main entry point.
Make sure to set up any necessary environment variables before running the application in production.
npm test
npm run test:watch
npm run lint
Contributions are welcome! Please follow these steps:
git checkout -b feature/your-feature-name
Follow the Conventional Commits specification: [optional scope]: [optional body] [optional footer(s)]
Types: feat
, fix
, docs
, style
, refactor
, test
, chore
Example: feat(search): add Google Search integration
config.ts
node_modules
and running npm install
againThis project is licensed under the MIT License. See the LICENSE
file for details.
For support, please open an issue on the GitHub repository or join our Discord community [link to Discord].