MCP server that enforces coding style decisions based on taste and convention
Project description
High-Taste
An MCP (Model Context Protocol) server that enforces coding style decisions based on high-taste and convention rather than semantic correctness. Following the "Effective C++" tradition, High-Taste provides rules with examples and rationale to maintain consistent, readable code.
Overview
High-Taste helps development teams maintain code quality by:
- Checking new code against established high-taste rules (like a linter for style preferences)
- Learning from expert refactoring by analyzing before/after diffs to create new rules
- Integrating seamlessly with Claude Code and VS Code via MCP
Unlike traditional linters that focus on syntax and semantics, High-Taste enforces subjective but important style decisions that make code more maintainable, readable, and consistent with team preferences.
Core Functions
taste_check
Analyzes Python files against existing high-taste rules and reports violations with specific line numbers and rule references.
Input: List of file contents (Python code) Output: Linting-style errors with rule numbers and descriptions
taste_acquire
Learns new high-taste rules by analyzing diffs where experienced programmers have refactored code originally written by junior developers or AI.
Input: Set of git diffs showing before/after code changes Output: New rules created or confirmation that existing rules already cover the patterns
Implementation Plan
Phase 1: Core Architecture
-
Rule System Design
- Create
rules/directory with markdown files (one rule per file) - Implement rule parser to extract patterns, examples, and metadata
- Design rule matching engine using AST analysis for semantic patterns
- Create rule numbering/ID system for references
- Create
-
MCP Server Foundation
- Set up MCP server infrastructure with proper protocol handling
- Implement
high-taste_checkfunction with file content analysis - Implement
taste_acquirefunction with diff analysis - Create standardized JSON output formats for both functions
Phase 2: Pattern Recognition
-
high-taste_check Implementation
- Build AST-based pattern matcher for Python code structures
- Implement rule violation detection with line number reporting
- Create rule severity system (error, warning, suggestion)
- Add support for incremental checking (only changed lines)
-
taste_acquire Implementation
- Develop diff parser to extract before/after code patterns
- Create pattern generalization algorithm (specific → general rules)
- Implement rule conflict detection and resolution
- Build automatic rule description generation
Phase 3: Integration
-
IDE Integration
- Configure MCP server for Claude Code integration
- Set up VS Code MCP client configuration
- Create configuration files for both environments
- Test end-to-end workflow in both IDEs
-
Rule Management
- Implement rule CRUD operations (create, read, update, disable)
- Add rule versioning and change tracking
- Create rule validation and testing framework
- Build rule export/import functionality
Phase 4: Advanced Features
-
Intelligence Enhancements
- Add machine learning for better pattern recognition
- Implement context-aware rule application
- Create rule recommendation system
- Add support for custom rule templates
-
Monitoring and Metrics
- Track rule violation frequency and trends
- Measure rule effectiveness and adoption
- Create dashboard for team rule compliance
- Add automated rule quality assessment
Installation
Install from PyPI
# Install using pip
pip install high-taste
# Or install using uv
uv pip install high-taste
# Or run directly with uvx (no installation needed)
uvx high-taste --help
Install from source
git clone https://github.com/alexdong/high-taste.git
cd high-taste
uv pip install -e .
Usage
Command Line Interface
High-Taste provides a CLI for standalone usage and testing:
# List all available taste rules
high-taste rules
# Check Python files for taste violations
high-taste check file1.py file2.py
# Start the MCP server
high-taste serve
# Enable debug logging
high-taste --debug check file.py
Using with uvx
You can run High-Taste directly without installation using uvx:
# Run any command with uvx
uvx high-taste rules
uvx high-taste check mycode.py
uvx high-taste serve
MCP Integration
To use High-Taste as an MCP server with Claude Code or VS Code:
- For Claude Code: Copy
configs/claude-code.jsonto your Claude Code configuration directory - For VS Code: Copy
configs/vscode.jsonto your VS Code configuration directory
Then the taste_check and taste_acquire tools will be available in your IDE.
Project Structure
./
├── src/
│ ├── high_taste/ # Main MCP server code
│ │ ├── server.py # MCP server implementation
│ │ ├── rules/ # Rule management and matching
│ │ ├── parsers/ # AST and diff parsing
│ │ └── utils/ # Helper functions
├── rules/ # High-Taste rules (markdown files)
│ ├── 001-assertions-over-exceptions.md
│ ├── 002-load-resources-once.md
│ ├── 003-eliminate-deep-nesting.md
│ ├── 004-dynamic-data-discovery.md
│ ├── 005-structured-return-types.md
│ ├── 006-database-transaction-safety.md
│ └── ...
├── tests/ # Test files
├── examples/ # Example configurations
├── docs/ # Documentation
└── configs/ # MCP client configurations
├── claude-code.json
└── vscode.json
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file high_taste-0.1.0.tar.gz.
File metadata
- Download URL: high_taste-0.1.0.tar.gz
- Upload date:
- Size: 38.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ba08a5f904ce1cea75aaa7ddadb5f3a9f885c9b0ecf5be84f13af33d263c5bac
|
|
| MD5 |
b5a8efef4ed8b33f9cc5fab723cc51d5
|
|
| BLAKE2b-256 |
ad6581bfb0663ac5e4a70a51399d029d300db44c09f887bcb41bbcd9ea3f7a97
|
File details
Details for the file high_taste-0.1.0-py3-none-any.whl.
File metadata
- Download URL: high_taste-0.1.0-py3-none-any.whl
- Upload date:
- Size: 33.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e80069e115d7d57148804879dbdd8dcc4a4f4f62d5c18f93f53775752333158f
|
|
| MD5 |
9810dd5e9552124a6acb427ee7d34f98
|
|
| BLAKE2b-256 |
23b513cb21e806153e5d554cd147ccd867c157649869cc953254fb5811f34710
|