Skip to content

Latest commit

 

History

History
176 lines (129 loc) · 3.78 KB

File metadata and controls

176 lines (129 loc) · 3.78 KB

Contributing to Metabase AI Assistant

Thank you for your interest in contributing to Metabase AI Assistant! This document provides guidelines for contributing to the project.

Table of Contents

Getting Started

  1. Fork the repository
  2. Clone your fork locally
  3. Set up the development environment
  4. Create a feature branch
  5. Make your changes
  6. Submit a pull request

Development Setup

# Clone your fork
git clone https://github.com/YOUR_USERNAME/metabase-ai-assistant.git
cd metabase-ai-assistant

# Install dependencies
npm install

# Copy environment template
cp .env.example .env

# Edit .env with your test credentials
# Run the MCP server
npm run mcp

How to Contribute

Types of Contributions

  • Bug Fixes: Fix issues and improve stability
  • New Features: Add new MCP tools or capabilities
  • Documentation: Improve README, add examples, fix typos
  • Tests: Add or improve test coverage
  • Performance: Optimize existing functionality

Before You Start

  1. Check existing issues and pull requests
  2. Open an issue to discuss major changes
  3. Ensure your contribution aligns with project goals

Pull Request Process

  1. Create a Branch

    git checkout -b feature/your-feature-name
  2. Make Changes

    • Write clean, readable code
    • Add tests if applicable
    • Update documentation
  3. Test Your Changes

    npm test
    npm run lint
  4. Commit Your Changes

    git commit -m "feat: add new feature description"
  5. Push and Create PR

    git push origin feature/your-feature-name
  6. PR Review

    • Address reviewer feedback
    • Keep PR focused and small
    • Update PR description as needed

Coding Standards

JavaScript/Node.js

  • Use ES Modules (import/export)
  • Use async/await for asynchronous code
  • Follow existing code style
  • Add JSDoc comments for public functions

File Structure

src/
├── mcp/           # MCP server and tools
├── metabase/      # Metabase API client
├── database/      # Direct database connections
├── ai/            # AI assistant functionality
├── utils/         # Utility functions
└── cli/           # CLI interface

Naming Conventions

  • Files: kebab-case (e.g., activity-logger.js)
  • Functions: camelCase (e.g., getDatabases)
  • Classes: PascalCase (e.g., MetabaseClient)
  • Constants: UPPER_SNAKE_CASE (e.g., MAX_RETRIES)

Commit Messages

Follow Conventional Commits:

type(scope): description

[optional body]

[optional footer]

Types

  • feat: New feature
  • fix: Bug fix
  • docs: Documentation changes
  • style: Code style changes (formatting)
  • refactor: Code refactoring
  • test: Adding or updating tests
  • chore: Maintenance tasks

Examples

feat(mcp): add user management tools
fix(database): handle connection timeout properly
docs(readme): update installation instructions

Reporting Issues

Bug Reports

Include:

  • Clear description of the bug
  • Steps to reproduce
  • Expected vs actual behavior
  • Environment details (Node.js version, OS)
  • Error messages or logs

Feature Requests

Include:

  • Clear description of the feature
  • Use case and motivation
  • Proposed implementation (optional)

Questions?


Copyright 2024-2026 ONMARTECH LLC Developed by Abdullah Enes SARI