[build-system]
build-backend = "hatchling.build"
requires = [ "hatchling" ]
[project]
name = "evo2_mcp"
version = "0.2.2"
description = "MCP server for generating, scoring and embedding genomic sequences using Evo 2"
readme = "README.md"
license = { file = "LICENSE" }
maintainers = [
{ name = "Jules Kreuer", email = "jules.kreuer@uni-tuebingen.de" },
]
authors = [
{ name = "Jules Kreuer" },
]
requires-python = ">=3.12"
keywords = [
"mcp",
"model-context-protocol",
"evo2",
"genomics",
"bioinformatics",
"sequence-generation",
"embeddings",
"deep-learning",
]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Science/Research",
"Intended Audience :: Developers",
"License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Scientific/Engineering :: Bio-Informatics",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
]
dependencies = [
# for debug logging (referenced from the issue template)
# "session-info2",
"click",
"fastmcp",
"numpy",
"torch",
]
optional-dependencies.evo2 = [
# Evo2 dependencies - must be installed in specific order:
# 1. conda install -c nvidia cuda-nvcc cuda-cudart-dev
# 2. conda install -c conda-forge transformer-engine-torch=2.3.0
# 3. pip install flash-attn==2.8.0.post2 --no-build-isolation
# 4. pip install evo2
# See README.md for detailed installation instructions
"evo2",
]
optional-dependencies.dev = [
"pre-commit",
"twine>=4.0.2",
]
optional-dependencies.doc = [
"docutils>=0.8,!=0.18.*,!=0.19.*",
"ipykernel",
"ipython",
"myst-nb>=1.1",
"pandas",
# Until pybtex >0.24.0 releases: https://bitbucket.org/pybtex-devs/pybtex/issues/169/
"setuptools",
"sphinx>=8.1",
"sphinx-book-theme>=1",
"sphinx-copybutton",
"sphinx-tabs",
# "sphinxcontrib-bibtex>=1",
"sphinxext-opengraph",
"sphinx-autoapi",
]
optional-dependencies.test = [
"coverage",
"pytest",
"pytest-asyncio",
]
# https://docs.pypi.org/project_metadata/#project-urls
urls.Documentation = "https://evo2-mcp.readthedocs.io/"
urls.Homepage = "https://github.com/not-a-feature/evo2-mcp"
urls.Source = "https://github.com/not-a-feature/evo2-mcp"
urls."Bug Tracker" = "https://github.com/not-a-feature/evo2-mcp/issues"
urls.Changelog = "https://evo2-mcp.readthedocs.io/en/latest/changelog.html"
urls."BioContextAI" = "https://biocontext.ai/registry/not-a-feature/evo2-mcp"
scripts.evo2_mcp = "evo2_mcp.main:run_app"
[tool.hatch.build.targets.wheel]
packages = [ "src/evo2_mcp" ]
[tool.hatch.envs.default]
installer = "uv"
features = [ "dev" ]
[tool.hatch.envs.docs]
features = [ "doc" ]
scripts.build = "sphinx-build -M html docs docs/_build -W {args}"
scripts.open = "python -m webbrowser -t docs/_build/html/index.html"
scripts.clean = "git clean -fdX -- {args:docs}"
# Test the lowest and highest supported Python versions with normal deps
[[tool.hatch.envs.hatch-test.matrix]]
deps = [ "stable" ]
python = [ "3.12", "3.13" ]
# Test the newest supported Python version also with pre-release deps
[[tool.hatch.envs.hatch-test.matrix]]
deps = [ "pre" ]
python = [ "3.13" ]
[tool.hatch.envs.hatch-test]
features = [ "test" ]
[tool.hatch.envs.hatch-test.overrides]
# If the matrix variable `deps` is set to "pre",
# set the environment variable `UV_PRERELEASE` to "allow".
matrix.deps.env-vars = [
{ key = "UV_PRERELEASE", value = "allow", if = [ "pre" ] },
]
[tool.ruff]
line-length = 120
src = [ "src" ]
extend-include = [ "*.ipynb" ]
format.docstring-code-format = true
lint.select = [
"B", # flake8-bugbear
"BLE", # flake8-blind-except
"C4", # flake8-comprehensions
"D", # pydocstyle
"E", # Error detected by Pycodestyle
"F", # Errors detected by Pyflakes
"I", # isort
"RUF100", # Report unused noqa directives
"TID", # flake8-tidy-imports
"UP", # pyupgrade
"W", # Warning detected by Pycodestyle
]
lint.ignore = [
"B008", # Errors from function calls in argument defaults. These are fine when the result is immutable.
"D100", # Missing docstring in public module
"D104", # Missing docstring in public package
"D105", # __magic__ methods are often self-explanatory, allow missing docstrings
"D107", # Missing docstring in __init__
# Disable one in each pair of mutually incompatible rules
"D203", # We don't want a blank line before a class docstring
"D213", # <> We want docstrings to start immediately after the opening triple quote
"D400", # first line should end with a period [Bug: doesn’t work with single-line docstrings]
"D401", # First line should be in imperative mood; try rephrasing
"E501", # line too long -> we accept long comment lines; formatter gets rid of long code lines
"E731", # Do not assign a lambda expression, use a def -> lambda expression assignments are convenient
"E741", # allow I, O, l as variable names -> I is the identity matrix
]
lint.per-file-ignores."*/__init__.py" = [ "F401" ]
lint.per-file-ignores."docs/*" = [ "I" ]
lint.per-file-ignores."tests/*" = [ "D" ]
lint.pydocstyle.convention = "numpy"
[tool.pytest.ini_options]
pythonpath = "src"
testpaths = [ "tests" ]
python_files = "test_*.py"
python_functions = "test_*"
xfail_strict = true
addopts = [
"--import-mode=importlib", # allow using test files with same name
]
markers = [
"real_evo2: run against the installed Evo 2 implementation",
]
[tool.coverage.run]
source = [ "src/evo2_mcp" ]
omit = [
"*/tests/test_*.py",
]