MCPcopy Create free account
hub / github.com/bigcode-project/starcoder / ModelArguments

Class ModelArguments

chat/config.py:26–56  ·  view source on GitHub ↗

Arguments pertaining to which model/config/tokenizer we are going to fine-tune, or train from scratch.

Source from the content-addressed store, hash-verified

24
25@dataclass
26class ModelArguments:
27 """
28 Arguments pertaining to which model/config/tokenizer we are going to fine-tune, or train from scratch.
29 """
30
31 model_name_or_path: Optional[str] = field(
32 default=None,
33 metadata={
34 "help": (
35 "The model checkpoint for weights initialization. Don't set if you want to train a model from scratch."
36 )
37 },
38 )
39 model_revision: str = field(
40 default="main",
41 metadata={"help": "The specific model version to use (can be a branch name, tag name or commit id)."},
42 )
43 torch_dtype: Optional[str] = field(
44 default=None,
45 metadata={
46 "help": (
47 "Override the default `torch.dtype` and load the model under this dtype. If `auto` is passed, the "
48 "dtype will be automatically derived from the model's weights."
49 ),
50 "choices": ["auto", "bfloat16", "float16", "float32"],
51 },
52 )
53 use_fast_tokenizer: bool = field(
54 default=True,
55 metadata={"help": "Whether to use one of the fast tokenizer (backed by the tokenizers library) or not."},
56 )
57
58
59@dataclass

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected