Skip to content

codemie-ai/codemie

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

61 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

CodeMie πŸ€–

License Website Docs

Platform for AI-Native Delivery, Modernization, and Business.

CodeMie is an open platform that lets teams build, orchestrate, and scale AI agents across the entire software lifecycle β€” from planning and coding to testing, deployment, and operations. It unites intelligent assistants, multi-agent workflows, deep integrations, and project knowledge in one system.

What you can do with CodeMie:

  • πŸš€ AI-Native SDLC & Delivery β€” Automate every phase of the software lifecycle: discovery, architecture, development, testing, and deployment with purpose-built AI agents.
  • πŸ”„ AI Migration & Modernization β€” Migrate and modernize legacy systems and mainframes using AI-powered analysis, code exploration (AICE), and automated transformation workflows.
  • πŸ’Ό AI for Business & Operations β€” Deploy AI agents across non-engineering functions such as finance, HR, sales, and support.

Key capabilities: multi-agent orchestration, rich data indexing (Git, Jira, Confluence, docs), deep integrations (MCP, AWS, Azure, GCP, Kubernetes), and a no-code Assistants Constructor.

This repository β€” codemie β€” is the core backend component of the CodeMie platform. It contains the FastAPI application, LangChain/LangGraph-based AI agents and orchestration, REST API, tool integrations, knowledge-base indexing (Git, Jira, Confluence), and all service-layer logic that powers the platform.

🌐 Website: codemie.ai πŸ“– Documentation: docs.codemie.ai πŸ–₯️ CLI tool: codemie-code

Quick Start

  1. Setup credentials (see Prerequisites & Setup)
  2. Configure .env with local database, search, and model provider settings
  3. Run with Docker:
    docker compose up --build codemie postgres elasticsearch
  4. Access: http://localhost:8080/docs

Prerequisites & Setup

Requirements

  • docker (or compatible engine)
  • docker compose (modern syntax)
  • Python 3.12 (recommended), pip, Poetry
  • Node.js (via NVM), npm
  • Git
  • Google Cloud SDK (gcloud CLI) - for authentication with GCP Artifact Registry
  • make (install via brew/choco if missing)

Local Environment Variables

# App mode
ENV=local
MODELS_ENV=azure

# Azure OpenAI (required unless you switch to AWS or GCP model config)
AZURE_OPENAI_API_KEY="<your_api_key>"
AZURE_OPENAI_URL="https://your-azure-openai-endpoint.example.com"

For local startup, CodeMie needs:

  • One configured model provider. For open source local setup, Azure is the simplest example:
    • MODELS_ENV=azure
    • OPENAI_API_TYPE=azure
    • AZURE_OPENAI_API_KEY
    • AZURE_OPENAI_URL

If you prefer another provider, use the matching model config under config/llms/ such as llm-aws-config.yaml or llm-gcp-config.yaml and set MODELS_ENV accordingly.

For the full environment variable reference and descriptions, see the public docs: https://docs.codemie.ai/admin/configuration/codemie/api-configuration

Running the Application

Docker 🐳

Core stack:

docker compose up --build codemie postgres elasticsearch

API Docs: http://localhost:8080/docs

Running Locally 🐍

Setup

  1. Install poetry according to the official guide
  2. Install dependencies: poetry install
  3. Download NLTK packages: poetry run download_nltk_packages
  4. Start required services locally, for example: docker compose up postgres elasticsearch
  5. Apply database migrations from src/external/alembic:
    cd src/external/alembic
    poetry run alembic upgrade head

Starting up

  1. Navigate to src directory: cd src/
  2. Run server: poetry run uvicorn codemie.rest_api.main:app --host=0.0.0.0 --port=8080 --reload
  3. Up and running! πŸ”₯ Check out http://localhost:8080/docs

Database migrations are managed with Alembic. For migration workflows, autogeneration, and conflict handling, see the Alembic README.

Installation 🏒

Local Development

# Install base dependencies
poetry install --sync

Docker Build

docker build -t codemie:latest .

Makefile Commands

  • Install deps: make install
  • Install OSS: make install-oss - Install base dependencies only (--sync)
  • Build: make build
  • Run unit tests: make test
  • Lint/format (ruff): make ruff
  • License headers: make license - Fix and verify Apache 2.0 license headers
  • Check license headers: make license-check - Check for missing headers (CI mode)
  • Fix license headers: make license-fix - Add missing license headers
  • Scan for secrets: make gitleaks - Run gitleaks in Docker to scan for hardcoded secrets
  • Run ALL checks + tests (strictly needed before commit): make verify - Runs ruff, license-check, gitleaks, and tests
  • Import AI Katas: make import-katas - Clone and import AI katas from GitHub repository

Git Hooks (pre-commit)

Hook toggle:

  • You can enable/disable the Codemie pre-commit hook via env var:
    • CODEMIE_PRECOMMIT_ENABLED=false (default)
    • CODEMIE_PRECOMMIT_ENABLED=true
    • Add to .env or export in shell: export CODEMIE_PRECOMMIT_ENABLED=false

Install:

  • poetry install
  • poetry run pre-commit install

Commit flow:

  • ruff format + ruff check --fix
  • If files changed: lists changed files and blocks commit; stage and commit again (tests run once next attempt)
  • If no changes: ruff check + pytest; prints concise test summary and blocks commit on failures

Manual:

  • Run all hooks: poetry run pre-commit run --all-files
  • Skip hooks for a single commit: git commit --no-verify (not recommended)

Troubleshooting:

  • core.hooksPath set: git config --unset-all core.hooksPath; then poetry run pre-commit install
  • Permission denied: chmod +x scripts/git-hooks/pre_commit.sh; git update-index --chmod=+x scripts/git-hooks/pre_commit.sh

Development

Development Workflow

Quick Reference:

  • Branch naming: <TICKET-ID>_short-description
  • Commit format: <TICKET-ID>: Short Description
  • Before commit: make verify (runs ruff, license-check, and tests)
  • PR requirements: At least 1 approval, green CI pipeline
  • Rerun pipeline: Comment /recheck on PR

Testing πŸ§ͺ

poetry run pytest tests/

Linting & Formatting πŸ“

Running Ruff

Linting:

poetry run ruff check

Formatting:

poetry run ruff format

License Headers πŸ“„

CodeMie uses Apache License 2.0 headers on all source files. Use these commands to manage license headers:

Check for missing headers:

make license-check                          # All files (CI-friendly)
make license-check FILE=path/to/file.py     # Single file

Add missing headers:

make license-fix                            # All files
make license-fix FILE=path/to/file.py       # Single file

Fix and verify (recommended):

make license                                # Fix then check all files
make license FILE=path/to/file.py           # Fix then check single file

For CI pipelines:

# Option 1: Direct command (quiet mode)
poetry run python scripts/license_headers/check_license_headers.py --check --quiet

# Option 2: Use verify target (includes ruff + license + tests)
make verify

The license checker:

  • Automatically preserves shebangs, encoding declarations, and XML declarations
  • Supports Python (.py) and Shell (.sh) files in src/, scripts/, and tests/
  • Excludes auto-generated files, documentation, and infrastructure files
  • Returns non-zero exit code if headers are missing (CI-friendly)

For more details, see scripts/license_headers/README.md.

Tools (src/codemie_tools/)

All CodeMie tools are co-located in this repo under src/codemie_tools/. There is no separate external package β€” tools are developed and shipped as part of the core repository.

Architecture

Two-layer design:

  • src/codemie_tools/ β€” foundational tool library: base classes (CodeMieTool, BaseToolkit, DiscoverableToolkit), all domain tool implementations, and ToolMetadata for SmartToolSelector discovery.
  • src/codemie/agents/tools/ β€” agent-facing toolkit layer: composes codemie_tools toolkits into CodeToolkit, KBToolkit, IDEToolkit, PlatformToolkit, SkillTool, and plugin tools.

Available Tool Categories

Category Path Coverage
Base src/codemie_tools/base/ CodeMieTool, BaseToolkit, ToolMetadata, utilities
Code src/codemie_tools/code/ SonarQube, linter, AI-assisted code editing (diff-coder)
Cloud src/codemie_tools/cloud/ AWS (S3, Bedrock, KMS), Azure (Blob, KeyVault), GCP (GCS, Vertex AI), Kubernetes
VCS / Git src/codemie_tools/core/vcs/ GitHub, GitLab, Bitbucket, Azure DevOps Git
Project Management src/codemie_tools/core/project_management/ Confluence, Jira
QA src/codemie_tools/qa/ X-ray, Zephyr Scale, Zephyr Squad
Data Management src/codemie_tools/data_management/ Elasticsearch, SQL, file system, code executor
File Analysis src/codemie_tools/file_analysis/ CSV, DOCX, PDF, PPTX, XLSX
Azure DevOps src/codemie_tools/azure_devops/ Wiki, Work Items, Test Plans
Notifications src/codemie_tools/notification/ Email, Telegram
ITSM src/codemie_tools/itsm/ ServiceNow
Access Management src/codemie_tools/access_management/ Keycloak
Research src/codemie_tools/research/ Web research
Vision src/codemie_tools/vision/ Image analysis
Open API src/codemie_tools/open_api/ Generic REST/OpenAPI invocation

Contributing to Tools

To add or modify a tool, work directly in src/codemie_tools/. For architecture patterns and step-by-step guides:

  • .codemie/guides/agents/agent-tools.md β€” base classes, execution flow, metadata
  • .codemie/guides/agents/custom-tool-creation.md β€” creating new tools
  • .codemie/guides/agents/tool-overview.md β€” SmartToolSelector and DiscoverableToolkit

License Compliance

Check licenses of production dependencies:

poetry run pip-licenses --packages $(poetry show --only main | awk '{print $1}' | tr '\n' ' ')

This checks licenses only for production packages (excludes dev dependencies like pytest, etc.).

Contributing

We welcome contributions! Please read our Contributing Guide and Code of Conduct before submitting a pull request.

License

CodeMie is licensed under the Apache License 2.0.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors