โœจ 100% Local & Private โ€” No API keys required

๐Ÿง  Cognify AI

Code Cognition โ€” Your Local AI-Powered Code Assistant

A powerful CLI tool that brings AI-powered code cognition to your terminal.
Review code, generate functions, search semantically, refactor projects, and interact with an AI code agentโ€”all running locally with Ollama.

โœจ Powerful Features

Everything you need to supercharge your development workflow, running entirely on your local machine.

๐Ÿ”

Code Review

Analyze code for bugs, security vulnerabilities, performance issues, and style problems. Get actionable suggestions with severity levels.

โšก

Code Generation

Generate functions, classes, scripts, and unit tests from natural language descriptions. Includes type hints and docstrings.

๐Ÿ”Ž

Semantic Search

Search your codebase using natural language queries. Powered by RAG (Retrieval Augmented Generation) for intelligent results.

๐Ÿ“

AI File Editing

Edit files with natural language instructions. Preview changes before applying, with automatic backup support.

๐Ÿ”„

Multi-File Refactoring

Refactor across multiple files at once. Add docstrings, convert patterns, or apply consistent changes project-wide.

๐Ÿท๏ธ

Symbol Renaming

Rename functions, classes, and variables across your entire project. Smart detection ensures all references are updated.

๐Ÿ’ฌ

Interactive Chat

Have conversations with AI about your code. Ask questions, get explanations, and receive suggestions interactively.

๐Ÿ“Š

Codebase Indexing

Create a searchable semantic index of your codebase. Enables fast, intelligent code discovery and context retrieval.

๐Ÿค–

AI Code Agent

Interactive agent that understands your intent. Generate, review, edit, explain, and refactor code with natural language commands.

๐Ÿ”ฎ

Intent Classification

Smart intent detection automatically routes your requests to the right handlerโ€”generate, review, edit, explain, or refactor.

๐Ÿš€ Quick Start

Get up and running in minutes with these simple steps.

1

Install Ollama

Download and install Ollama from the official website to run LLMs locally.

# Download from https://ollama.ai
ollama pull deepseek-coder:6.7b
2

Install Cognify AI

Install directly from PyPI with a single command. No cloning required!

pip install cognify-code

๐Ÿ’ก For Google Gemini support: pip install cognify-code[google]

๐Ÿ’ก For Groq support: pip install cognify-code[groq]

๐Ÿ’ก For all providers: pip install cognify-code[all-providers]

3

Start Using

You're ready! Use either cognify or ai-assist command.

cognify status
# or
ai-assist review myfile.py

๐Ÿ“– Usage Examples

Powerful commands at your fingertips. Here's what you can do with Cognify AI.

๐Ÿ”

Code Review

# Review a single file
ai-assist review path/to/file.py

# Review with JSON output
ai-assist review src/ --format json
โšก

Code Generation

# Generate a function
ai-assist generate "binary search" --language python

# Generate a class
ai-assist generate "REST client" --mode class
๐Ÿ”Ž

Semantic Search

# Index your codebase first
ai-assist index .

# Search with natural language
ai-assist search "error handling"
๐Ÿ“

File Editing

# Preview changes before applying
ai-assist edit config.py "add logging" --preview

# Edit with backup
ai-assist edit utils.py "add type hints" --backup
๐Ÿ”„

Multi-File Refactoring

# Dry run to preview changes
ai-assist refactor "add docstrings" -p "**/*.py" --dry-run

# Apply with confirmation
ai-assist refactor "convert print to logging" --confirm
๐Ÿท๏ธ

Symbol Renaming

# Rename a function
ai-assist rename old_func new_func --type function

# Rename a class
ai-assist rename MyClass BetterClass --type class
๐Ÿค–

AI Code Agent

# Start interactive agent
ai-assist agent

# Quick commands
ai-assist agent-review src/main.py
ai-assist agent-generate "email validator"
ai-assist agent-explain config.py

๐Ÿ› ๏ธ Tech Stack

Built with modern, reliable technologies for the best developer experience.

๐Ÿฆœ LangChain
๐Ÿฆ™ Ollama
๐Ÿ—„๏ธ ChromaDB
๐Ÿค— Sentence Transformers
๐Ÿ–ฑ๏ธ Click
โœจ Rich
๐Ÿ“‹ Pydantic
๐Ÿงช Pytest