Thank you for your interest in contributing to the Cerebras MCP (Model Context Protocol) server! We welcome contributions from the community and are excited to collaborate with you.
If you have questions about the MCP server or need help:
- Join our Discord community: https://discord.gg/fQwFthdrq2
- File bugs and feature requests in our GitHub issues
- Check the documentation in our README.md
If you encounter any bugs or have feature requests, please file them in our GitHub issues with as much detail as possible.
When reporting a bug, please include:
- A clear description of the issue
- Steps to reproduce the problem
- Expected behavior vs. actual behavior
- IDE/editor being used (Claude Code, Cursor, Cline, VS Code, Crush)
- Node.js version and operating system
- Any relevant error messages or logs from the MCP server
- Node.js (version 18 or higher)
- npm
- One of the supported IDEs: Claude Code, Cursor, Cline, VS Code, or Crush
-
Clone the repository:
git clone https://github.com/cerebras/cerebras-code-mcp.git cd cerebras-code-mcp -
Install dependencies:
npm install
-
Test the MCP server:
node src/index.js --help
-
Run the interactive configuration:
node src/index.js --config
-
Test the MCP server directly:
CEREBRAS_API_KEY=your_key node src/index.js
-
Test the configuration wizard:
node src/index.js --config
-
Test the removal wizard:
node src/index.js --remove
-
Test with different IDEs:
CEREBRAS_MCP_IDE=cursor CEREBRAS_API_KEY=your_key node src/index.js
To publish a new version:
npm version patch # or minor/major
npm publishThis will update the version and publish to npm registry.
To test the MCP server during development:
-
Unit Testing: Test individual components
# Test API connections node -e "import('./src/api/cerebras.js').then(m => console.log('✅ Cerebras API loaded'))" # Test configuration node -e "import('./src/config/constants.js').then(m => console.log('✅ Constants loaded'))"
-
Integration Testing: Test with actual IDEs
- Set up the MCP server in your preferred IDE
- Test the
writetool functionality - Verify API key configuration
- Test different formatting outputs
-
Cross-Platform Testing: Test on different operating systems
- macOS: Test with standard paths
- Windows: Test with Windows-specific paths
- Linux: Test with Linux-specific paths
The project follows these standards:
- ES6+ JavaScript: Use modern JavaScript features
- Consistent Formatting: Use consistent indentation and spacing
- Clear Naming: Use descriptive variable and function names
- Error Handling: Always handle errors gracefully
- Documentation: Comment complex logic and functions
src/index.js: Main entry point and CLI handlersrc/server/mcp-server.js: Core MCP server implementationsrc/server/tool-handlers.js: Tool implementation (write tool)src/config/interactive-config.js: Setup and removal wizardssrc/config/constants.js: Configuration constants and pathssrc/formatting/: Response formatting for different IDEssrc/api/: API clients for Cerebras and OpenRouter
- Fork the repository
- Create a new branch for your feature or bug fix
- Make your changes
- Ensure your code follows the project's style guidelines
- Test your changes thoroughly
- Commit your changes with a clear, descriptive commit message
- Push your branch to your fork
- Open a pull request with a detailed description of your changes
- Keep pull requests focused on a single feature or bug fix
- Include a clear description of what the pull request does
- Reference any related issues in the pull request description
- Ensure all checks pass before submitting