MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / unicode_utf8_to_byte

Function unicode_utf8_to_byte

external/llama_tokenizer/unicode.cpp:1034–1037  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1032}
1033
1034uint8_t unicode_utf8_to_byte(const std::string & utf8) {
1035 static std::unordered_map<std::string, uint8_t> map = unicode_utf8_to_byte_map();
1036 return map.at(utf8);
1037}
1038
1039uint32_t unicode_tolower(uint32_t cpt) {
1040 // binary search

Callers 1

decode_bpeFunction · 0.85

Calls 2

unicode_utf8_to_byte_mapFunction · 0.85
atMethod · 0.45

Tested by

no test coverage detected