[v1] add v1 folders (#9225)

This commit is contained in:
Yaowei Zheng 2025-10-02 15:25:57 +08:00 committed by GitHub
parent a0d44c650a
commit 1d96c62df2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
23 changed files with 16 additions and 17 deletions

View File

@ -25,12 +25,13 @@ USAGE = (
+ "| Usage: |\n" + "| Usage: |\n"
+ "| llamafactory-cli api -h: launch an OpenAI-style API server |\n" + "| llamafactory-cli api -h: launch an OpenAI-style API server |\n"
+ "| llamafactory-cli chat -h: launch a chat interface in CLI |\n" + "| llamafactory-cli chat -h: launch a chat interface in CLI |\n"
+ "| llamafactory-cli eval -h: evaluate models |\n"
+ "| llamafactory-cli export -h: merge LoRA adapters and export model |\n" + "| llamafactory-cli export -h: merge LoRA adapters and export model |\n"
+ "| llamafactory-cli train -h: train models |\n" + "| llamafactory-cli train -h: train models |\n"
+ "| llamafactory-cli webchat -h: launch a chat interface in Web UI |\n" + "| llamafactory-cli webchat -h: launch a chat interface in Web UI |\n"
+ "| llamafactory-cli webui: launch LlamaBoard |\n" + "| llamafactory-cli webui: launch LlamaBoard |\n"
+ "| llamafactory-cli env: show environment info |\n"
+ "| llamafactory-cli version: show version info |\n" + "| llamafactory-cli version: show version info |\n"
+ "| Hint: You can use `lmf` as a shortcut for `llamafactory-cli`. |\n"
+ "-" * 70 + "-" * 70
) )
@ -48,9 +49,7 @@ def _run_chat():
def _run_eval(): def _run_eval():
from .eval.evaluator import run_eval raise NotImplementedError("Evaluation will be deprecated in the future.")
return run_eval()
def _export_model(): def _export_model():

View File

@ -15,22 +15,22 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import os
import platform
import accelerate
import datasets
import peft
import torch
import transformers
import trl
from transformers.utils import is_torch_cuda_available, is_torch_npu_available
VERSION = "0.9.4.dev0" VERSION = "0.9.4.dev0"
def print_env() -> None: def print_env() -> None:
import os
import platform
import accelerate
import datasets
import peft
import torch
import transformers
import trl
from transformers.utils import is_torch_cuda_available, is_torch_npu_available
info = { info = {
"`llamafactory` version": VERSION, "`llamafactory` version": VERSION,
"Platform": platform.platform(), "Platform": platform.platform(),

View File

@ -12,10 +12,10 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
from llamafactory.train.tuner import run_exp # use absolute import
def launch(): def launch():
from llamafactory.train.tuner import run_exp # use absolute import
run_exp() run_exp()

View File

View File

View File

View File

View File

View File

View File

View File

View File