The FineCode documentation is organized into the following sections:
- Home (
index.md): Landing page highlighting main benefits and quick start - Getting Started (
getting-started.md): Installation and basic usage - IDE and MCP Setup (
getting-started-ide-mcp.md): VSCode and MCP-client integration setup - Concepts (
concepts.md): Core concepts and architecture overview - Configuration (
configuration.md): Detailed configuration options - CLI Reference (
cli.md): Command-line interface documentation
- Guides:
- Creating an Extension (
guides/creating-extension.md) - Creating a Preset (
guides/creating-preset.md) - Multi-Project Workspace (
guides/workspace.md)
- Creating an Extension (
- Built-in Actions (
reference/actions.md) - Extensions (
reference/extensions.md) - LSP and MCP Architecture (
reference/lsp-mcp-architecture.md): Protocol and server lifecycle internals - LSP Client Protocol (
reference/lsp-protocol.md): LSP client/server protocol details and custom commands
- Overview (
development.md): Contributing to FineCode core development - WM Protocol (
wm-protocol.md): Technical protocol and endpoint reference - WM-ER Protocol (
wm-er-protocol.md): WM and Extension Runner protocol details - Developing FineCode (
guides/developing-finecode.md): Monorepo workflows and conventions
- F.A.Q.: Common questions and troubleshooting
- Changelog/Release Notes: Version history and migration guides
FineCode is a monorepo containing multiple Python packages. To set up the development environment:
- Python 3.11 - 3.14
- Git
git clone https://github.com/finecode-dev/finecode.git
cd finecode
# Create development virtual environment
python -m venv .venvs/dev_workspace
source .venvs/dev_workspace/bin/activate
# Install development dependencies
pip install --group=dev_workspace# Prepare virtual environments for all packages
python -m finecode prepare-envsFineCode follows a modular architecture with clear separation of concerns:
The main package that:
- Discovers projects in the workspace
- Resolves configuration from multiple sources
- Manages virtual environments per tool
- Provides CLI interface
- Exposes LSP API for IDE integration
- Delegates tool execution to Extension Runners
Executes tool handlers in purpose-specific virtual environments:
- Runs inside a purpose-specific venv (e.g.
dev_no_runtime) - Imports and executes handler code
- Communicates with Workspace Manager via JSON-RPC/LSP
Public API for extension authors:
- Defines action interfaces and base classes
- Provides built-in action definitions (lint, format, build, etc.)
- Protocol definitions for handlers and services
The Workspace Manager follows strict layered architecture enforced by import-linter:
finecode.lsp_server.lsp_server ← top layer (IDE-facing)
↓
finecode.lsp_server.services ← service layer
↓
finecode.domain ← domain models (no upward imports)
LSP protocol types may only be used in finecode.runner.runner_client and finecode.lsp_server.lsp_server.
# Run all tests
pytest tests/
# Run tests for specific package
pytest finecode_extension_api/tests/# Build all packages
python -m build
# Or use the finecode build action
python -m finecode run build_artifact# Run linting
python -m finecode run lint
# Check formatting
python -m finecode run check_formatting
# Format code
python -m finecode run format# Start LSP server for IDE integration testing
python -m finecode start-lsp --stdio- Follow PEP 8 style guidelines
- Use type hints for all function parameters and return values
- Write docstrings in Google format
- Keep line length under 88 characters (Black default)
- Fork the repository
- Create a feature branch from
main - Make your changes
- Run tests and linting:
python -m finecode run lint check_formatting - Submit a pull request with a clear description
Use conventional commit format:
feat:for new featuresfix:for bug fixesdocs:for documentation changesrefactor:for code refactoringtest:for test additions/modifications
- All new code must include unit tests
- Maintain or improve code coverage
- Test both success and error paths
- Use descriptive test names
FineCode uses setuptools-scm for automatic versioning from git tags.
- Update version in git tag:
git tag v0.4.0 - Push tag:
git push origin v0.4.0 - CI/CD will automatically build and publish packages
The monorepo contains interdependent packages that must be released in order:
finecode_jsonrpcfinecode_httpclientfinecode_extension_apifinecode_extension_runnerfinecode_builtin_handlersfinecode(main package)
Use alpha/beta/rc suffixes for pre-releases:
v0.4.0a1(alpha 1)v0.4.0b2(beta 2)v0.4.0rc1(release candidate 1)