Skip to content

Commit 14ae4b1

Browse files
authored
Cleanup/use uv 6 (#71)
* use uv Signed-off-by: kerthcet <kerthcet@gmail.com> * update readme.md Signed-off-by: kerthcet <kerthcet@gmail.com> --------- Signed-off-by: kerthcet <kerthcet@gmail.com>
1 parent 9fd9a55 commit 14ae4b1

7 files changed

Lines changed: 244 additions & 375 deletions

File tree

Makefile

Lines changed: 25 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,31 @@
1-
.PHONY: lint
2-
lint:
3-
# mypy .
4-
black .
5-
6-
.PHONY: test
7-
test: unit-test integration-test
8-
9-
.PHONY: unit-test
10-
unit-test: lint
11-
ifdef key
12-
pytest tests/unit_tests -v -k $(key)
13-
else
14-
pytest tests/unit_tests
15-
endif
16-
17-
.PHONY: integration-test
18-
integration-test: lint
19-
ifdef key
20-
pytest tests/integration_tests -v -k $(key)
21-
else
22-
pytest tests/integration_tests
23-
endif
24-
25-
.PHONY: check
26-
check: lint test integration-test
1+
POETRY := poetry
2+
RUFF := .venv/bin/ruff
3+
PYTEST := .venv/bin/pytest
274

285
.PHONY: build
296
build: lint
30-
poetry build
7+
$(POETRY) build
318

329
.PHONY: publish
3310
publish: build
34-
poetry publish --username=__token__ --password=$(INFTYAI_PYPI_TOKEN)
11+
$(POETRY) publish --username=__token__ --password=$(INFTYAI_PYPI_TOKEN)
12+
13+
.PHONY: lint
14+
lint:
15+
$(RUFF) check .
16+
17+
.PHONY: format
18+
format:
19+
$(RUFF) format .
20+
$(RUFF) check --fix .
21+
22+
.PHONY: test
23+
test: lint
24+
$(PYTEST) tests/unit --timeout=15
25+
26+
.PHONY: test-integration
27+
test-integration: lint
28+
$(PYTEST) tests/integration --timeout=30
29+
'
30+
.PHONY: test-all
31+
test-all: test test-integration

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,10 @@
22

33
[![Latest Release](https://img.shields.io/github/v/release/inftyai/amrs?include_prereleases)](https://github.com/inftyai/amrs/releases/latest)
44

5-
The Adaptive Model Routing System (AMRS) is a cutting-edge framework designed to select the best-fit model for exploration and exploitation.
5+
The Adaptive Model Routing System (AMRS) is a cutting-edge framework designed to select the best-fit model for exploration and exploitation. (still under development)
66

7-
## Contributions
7+
## Contributing
88

99
🚀 All kinds of contributions are welcomed ! Please follow [Contributing](/CONTRIBUTING.md).
10+
11+
[![Star History Chart](https://api.star-history.com/svg?repos=inftyai/amrs&type=Date)](https://www.star-history.com/#inftyai/amrs&Date)

poetry.lock

Lines changed: 0 additions & 330 deletions
This file was deleted.

pyproject.toml

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,40 @@
1-
[tool.poetry]
1+
[project]
22
name = "AMRS"
33
version = "0.0.0"
44
description = "The adaptive model routing system for exploration and exploitation."
5-
authors = ["InftyAI"]
6-
license = "MIT License"
5+
authors = [
6+
{ name = "InftyAI", email = "contact@inftyai.com" }
7+
]
8+
license = {text = "MIT License"}
79
readme = "README.md"
10+
requires-python = ">=3.12"
811

9-
[tool.poetry.dependencies]
10-
python = "^3.10"
12+
dependencies = []
1113

12-
[tool.poetry.group.dev.dependencies]
13-
mypy = "^1.5.1"
14-
black = "^23.9.1"
15-
pytest = "^7.4.2"
14+
[dependency-groups]
15+
dev = [
16+
{include-group = "lint"},
17+
{include-group = "test"}
18+
]
19+
lint = [
20+
"ruff>=0.12",
21+
]
22+
test = [
23+
"pytest>=8.4",
24+
"pytest-asyncio>=0.22",
25+
"pytest-timeout>=2.1",
26+
# Data generation
27+
"faker>=37.12",
28+
]
1629

1730
[build-system]
18-
requires = ["poetry-core"]
19-
build-backend = "poetry.core.masonry.api"
31+
requires = ["hatchling"]
32+
build-backend = "hatchling.build"
2033

2134
[tool.pytest.ini_options]
2235
markers = [
2336
"integration_test: marks tests as integration tests",
2437
]
25-
filterwarnings = [
26-
"ignore::DeprecationWarning",
27-
]
2838

2939
[tool.mypy]
3040
exclude = [

start.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
1-
eval $(poetry env activate)
1+
#!/usr/bin/env bash
2+
3+
uv venv
4+
source .venv/bin/activate
5+
uv sync

uv.lock

Lines changed: 186 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)