-
Notifications
You must be signed in to change notification settings - Fork 48
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add arguments to activate ilab plugin
Signed-off-by: 1000960000 user <aaron.chew1@ibm.com>
- Loading branch information
Showing
8 changed files
with
216 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Standard | ||
from dataclasses import dataclass | ||
|
||
# Local | ||
from .utils import ensure_nested_dataclasses_initialized, parsable_dataclass | ||
|
||
|
||
@parsable_dataclass | ||
@dataclass | ||
class PaddingFree: | ||
|
||
method: str = "huggingface" | ||
|
||
def __post_init__(self): | ||
if self.method != "huggingface": | ||
raise ValueError("only 'huggingface' method currently supported.") | ||
|
||
|
||
@dataclass | ||
class InstructLabConfig: | ||
|
||
padding_free: PaddingFree = None | ||
|
||
def __post_init__(self): | ||
# ensure nested dataclasses initialized | ||
ensure_nested_dataclasses_initialized(self) |
Oops, something went wrong.