Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
MaxPositionEmbeddings int `json:"max_position_embeddings"`
ContextLength int `json:"context_length"`
ImageSize int `json:"image_size"`
ID2Label map[string]string `json:"id2label"`
TextConfig *Config `json:"text_config"`
VisionConfig *Config `json:"vision_config"`
}
Config contains the model metadata used by Hugot when loading a model.
type SpecialTokensConfig ¶
type SpecialTokensConfig struct {
SepToken TokenValue `json:"sep_token"`
}
type TokenValue ¶
type TokenValue struct {
Content string
}
func (*TokenValue) UnmarshalJSON ¶
func (v *TokenValue) UnmarshalJSON(data []byte) error
type TokenizerConfig ¶
type TokenizerConfig struct {
SepToken TokenValue `json:"sep_token"`
UnknownToken TokenValue `json:"unk_token"`
}
type TokenizerJSONConfig ¶
type TokenizerJSONConfig struct {
PostProcessor struct {
SpecialTokens map[string]json.RawMessage `json:"special_tokens"`
} `json:"post_processor"`
}
Click to show internal directories.
Click to hide internal directories.