aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/pyproject.toml
diff options
context:
space:
mode:
authorHsiangNianian <i@jyunko.cn>2025-12-30 20:16:05 +0800
committerHsiangNianian <i@jyunko.cn>2025-12-30 20:16:05 +0800
commit5dd166366b8a2f4699c1841ebd7fceabcd9868a4 (patch)
tree85d78772054529579176547c00aee9559cffff37 /pyproject.toml
parentdd55c70225367dec9e8d88821b4d65fcd24edd65 (diff)
downloadbase-model-5dd166366b8a2f4699c1841ebd7fceabcd9868a4.tar.gz
base-model-5dd166366b8a2f4699c1841ebd7fceabcd9868a4.zip
refactor: Refactor TRPG NER model SDK: restructure codebase into base_model_trpgner package, implement training and inference modules, and add model download functionality. Remove legacy training and utils modules. Enhance documentation and examples for better usability.
Diffstat (limited to 'pyproject.toml')
-rw-r--r--pyproject.toml77
1 files changed, 44 insertions, 33 deletions
diff --git a/pyproject.toml b/pyproject.toml
index d9b6d38..a1dcc20 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -6,13 +6,19 @@ build-backend = "hatchling.build"
name = "base-model-trpgner"
version = "0.1.1"
description = "HydroRoll TRPG NER 模型 - 桌上角色扮演游戏日志命名实体识别"
-authors = [
- { name = "HsiangNianian", email = "leader@hydroroll.team" }
-]
+authors = [{ name = "HsiangNianian", email = "leader@hydroroll.team" }]
readme = "README.md"
requires-python = ">=3.12"
license = { text = "AFL-3.0" }
-keywords = ["hydroroll", "trpg", "nlp", "ner", "chinese", "onnx", "robot framework"]
+keywords = [
+ "hydroroll",
+ "trpg",
+ "nlp",
+ "ner",
+ "chinese",
+ "onnx",
+ "robot framework",
+]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
@@ -24,11 +30,7 @@ classifiers = [
"Topic :: Text Processing :: Linguistic",
]
-dependencies = [
- "numpy>=1.24.0",
- "onnxruntime>=1.23.2",
- "transformers>=4.57.3",
-]
+dependencies = ["numpy>=1.24.0", "onnxruntime>=1.23.2", "transformers>=4.57.3"]
[project.optional-dependencies]
train = [
@@ -43,14 +45,8 @@ dev = [
"black>=24.0.0",
"ruff>=0.1.0",
]
-webui = [
- "base-model-trpgner[train]",
- "gradio>=6.2.0",
- "scikit-learn>=1.4.0",
-]
-all = [
- "base-model-trpgner[train,webui,dev]",
-]
+webui = ["base-model-trpgner[train]", "gradio>=6.2.0", "scikit-learn>=1.4.0"]
+all = ["base-model-trpgner[train,webui,dev]"]
[project.urls]
Homepage = "https://ailab.hydroroll.team/"
@@ -59,10 +55,9 @@ Documentation = "https://ailab.hydroroll.team/"
Issues = "https://github.com/HydroRoll-Team/base-model/issues"
[tool.hatch.build.targets.wheel]
-packages = ["src/basemodel"]
-# 只包含 ONNX 推理需要的文件(约 41MB)
+packages = ["src/base_model_trpgner"]
artifacts = [
- "src/basemodel/**/*.py",
+ "src/base_model_trpgner/**/*.py",
"models/trpg-final/model.onnx",
"models/trpg-final/model.onnx.data",
"models/trpg-final/config.json",
@@ -73,23 +68,39 @@ artifacts = [
]
[tool.hatch.build.targets.wheel.shared-data]
-"models/trpg-final" = "basemodel/models/trpg-final"
+"models/trpg-final" = "base_model_trpgner/models/trpg-final"
[tool.hatch.build.targets.sdist]
-include = [
- "/src",
- "/models/trpg-final",
- "/README.md",
- "/COPYING",
-]
+include = ["/src", "/models/trpg-final", "/README.md", "/COPYING"]
[tool.ruff]
exclude = [
- ".bzr", ".direnv", ".eggs", ".git", ".git-rewrite", ".hg",
- ".ipynb_checkpoints", ".mypy_cache", ".nox", ".pants.d",
- ".pyenv", ".pytest_cache", ".pytype", ".ruff_cache", ".svn",
- ".tox", ".venv", ".vscode", "__pypackages__", "_build",
- "buck-out", "build", "dist", "node_modules", "site-packages", "venv",
+ ".bzr",
+ ".direnv",
+ ".eggs",
+ ".git",
+ ".git-rewrite",
+ ".hg",
+ ".ipynb_checkpoints",
+ ".mypy_cache",
+ ".nox",
+ ".pants.d",
+ ".pyenv",
+ ".pytest_cache",
+ ".pytype",
+ ".ruff_cache",
+ ".svn",
+ ".tox",
+ ".venv",
+ ".vscode",
+ "__pypackages__",
+ "_build",
+ "buck-out",
+ "build",
+ "dist",
+ "node_modules",
+ "site-packages",
+ "venv",
]
line-length = 100
indent-width = 4
@@ -112,4 +123,4 @@ line-length = 100
target-version = ["py312"]
[tool.uv]
-dev-dependencies = [] \ No newline at end of file
+dev-dependencies = []