39 lines
1.1 KiB
Plaintext
39 lines
1.1 KiB
Plaintext
# cli.train { #axolotl.cli.train }
|
|
|
|
`cli.train`
|
|
|
|
CLI to run training on a model.
|
|
|
|
## Functions
|
|
|
|
| Name | Description |
|
|
| --- | --- |
|
|
| [do_cli](#axolotl.cli.train.do_cli) | Parses `axolotl` config, CLI args, and calls `do_train`. |
|
|
| [do_train](#axolotl.cli.train.do_train) | Trains a `transformers` model by first loading the dataset(s) specified in the |
|
|
|
|
### do_cli { #axolotl.cli.train.do_cli }
|
|
|
|
```python
|
|
cli.train.do_cli(config=Path('examples/'), **kwargs)
|
|
```
|
|
|
|
Parses `axolotl` config, CLI args, and calls `do_train`.
|
|
|
|
Args:
|
|
config: Path to `axolotl` config YAML file.
|
|
kwargs: Additional keyword arguments to override config file values.
|
|
|
|
### do_train { #axolotl.cli.train.do_train }
|
|
|
|
```python
|
|
cli.train.do_train(cfg, cli_args)
|
|
```
|
|
|
|
Trains a `transformers` model by first loading the dataset(s) specified in the
|
|
`axolotl` config, and then calling `axolotl.train.train`. Also runs the plugin
|
|
manager's `post_train_unload` once training completes.
|
|
|
|
Args:
|
|
cfg: Dictionary mapping `axolotl` config keys to values.
|
|
cli_args: Training-specific CLI arguments.
|