NewBertModel.ConfigΒΆ

Component: NewBertModel

class NewBertModel.Config[source]

Bases: _EncoderBaseModel.Config

All Attributes (including base classes)

Subclasses
  • NewBertRegressionModel.Config
  • BertSquadQAModel.Config
  • RoBERTa.Config
  • RoBERTaR3F.Config
  • RoBERTaRegression.Config
  • SELFIE.Config

Default JSON

{
    "inputs": {
        "tokens": {
            "BERTTensorizer": {
                "is_input": true,
                "columns": [
                    "text"
                ],
                "tokenizer": {
                    "WordPieceTokenizer": {
                        "basic_tokenizer": {
                            "split_regex": "\\s+",
                            "lowercase": true,
                            "use_byte_offsets": false
                        },
                        "wordpiece_vocab_path": "manifold://nlp_technologies/tree/huggingface-models/bert-base-uncased/vocab.txt"
                    }
                },
                "base_tokenizer": null,
                "vocab_file": "manifold://nlp_technologies/tree/huggingface-models/bert-base-uncased/vocab.txt",
                "max_seq_len": 128
            }
        },
        "dense": null,
        "labels": {
            "LabelTensorizer": {
                "is_input": false,
                "column": "label",
                "allow_unknown": false,
                "pad_in_vocab": false,
                "label_vocab": null,
                "label_vocab_file": null,
                "add_labels": null
            }
        },
        "num_tokens": {
            "is_input": false,
            "names": [
                "tokens"
            ],
            "indexes": [
                2
            ]
        }
    },
    "encoder": {
        "HuggingFaceBertSentenceEncoder": {
            "load_path": null,
            "save_path": null,
            "freeze": false,
            "shared_module_key": null,
            "output_dropout": 0.4,
            "embedding_dim": 768,
            "pooling": "cls_token",
            "export": false,
            "projection_dim": 0,
            "normalize_output_rep": false,
            "bert_cpt_dir": "manifold://nlp_technologies/tree/huggingface-models/bert-base-uncased/",
            "load_weights": true
        }
    },
    "decoder": {
        "load_path": null,
        "save_path": null,
        "freeze": false,
        "shared_module_key": null,
        "hidden_dims": [],
        "out_dim": null,
        "layer_norm": false,
        "dropout": 0.0,
        "bias": true,
        "activation": "relu",
        "temperature": 1.0,
        "spectral_normalization": false
    },
    "output_layer": {
        "load_path": null,
        "save_path": null,
        "freeze": false,
        "shared_module_key": null,
        "loss": {
            "CrossEntropyLoss": {}
        },
        "label_weights": null
    }
}