File tree Expand file tree Collapse file tree 3 files changed +38
-10
lines changed
Expand file tree Collapse file tree 3 files changed +38
-10
lines changed Original file line number Diff line number Diff line change 22
33This document contains critical information about working with this codebase. Follow these guidelines precisely.
44
5+ ## Environment Setup
6+
7+ To ensure everyone uses the same environment, follow these steps:
8+
9+ 1 . ** Initial Setup** : Run ` uv sync ` to create/update your environment from the lockfile
10+ 2 . ** After Pulling Changes** : If ` uv.lock ` has changed, run ` uv sync ` again
11+ 3 . ** Adding Dependencies** : Use ` uv add <package> ` which updates both pyproject.toml and uv.lock
12+ 4 . ** Removing Dependencies** : Use ` uv remove <package> `
13+
14+ The ` uv.lock ` file ensures all developers and CI/CD systems use exactly the same package versions.
15+
516## Core Development Rules
617
7181 . Package Management
819 - ONLY use uv, NEVER pip
20+ - Environment setup: ` uv sync ` (creates consistent environment from uv.lock)
921 - Installation: ` uv add package `
1022 - Running tools: ` uv run tool `
1123 - Upgrading: ` uv add --dev package --upgrade-package package `
Original file line number Diff line number Diff line change @@ -60,22 +60,38 @@ We humbly obsorbed the exquisite and efficient design of [lm-evaluation-harness]
6060
6161## Installation
6262
63- For direct usage, you can install the package from Git by running the following command:
63+ ### Using uv (Recommended for consistent environments)
64+
65+ We use ` uv ` for package management to ensure all developers use exactly the same package versions. First, install uv:
6466``` bash
6567curl -LsSf https://astral.sh/uv/install.sh | sh
66- uv venv eval
67- uv venv --python 3.12
68- source eval/bin/activate
69- uv pip install git+https://github.com/EvolvingLMMs-Lab/lmms-eval.git
7068```
7169
72- For development, you can install the package by cloning the repository and running the following command :
70+ For development with consistent environment :
7371``` bash
7472git clone https://github.com/EvolvingLMMs-Lab/lmms-eval
7573cd lmms-eval
76- uv venv dev
77- source dev/bin/activate
78- uv pip install -e .
74+ uv sync # This creates/updates your environment from uv.lock
75+ ```
76+
77+ To run commands:
78+ ``` bash
79+ uv run python -m lmms_eval --help # Run any command with uv run
80+ ```
81+
82+ To add new dependencies:
83+ ``` bash
84+ uv add < package> # Updates both pyproject.toml and uv.lock
85+ ```
86+
87+ ### Alternative Installation
88+
89+ For direct usage from Git:
90+ ``` bash
91+ uv venv eval
92+ uv venv --python 3.12
93+ source eval/bin/activate
94+ uv pip install git+https://github.com/EvolvingLMMs-Lab/lmms-eval.git
7995```
8096
8197<details >
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ classifiers = [
1919 " License :: OSI Approved :: MIT License" ,
2020 " Operating System :: OS Independent" ,
2121]
22- requires-python = " >=3.8 "
22+ requires-python = " >=3.9 "
2323dependencies = [
2424 " accelerate>=0.29.1" ,
2525 " black>=24.1.0" ,
You can’t perform that action at this time.
0 commit comments