| 3589 | } |
| 3590 | |
| 3591 | std::vector<std::string> llama_vocab::get_bpe_merges() const { |
| 3592 | std::vector<std::string> result(pimpl->bpe_ranks.size()); |
| 3593 | |
| 3594 | for (const auto & pair : pimpl->bpe_ranks) { |
| 3595 | result[pair.second] = pair.first.first + " " + pair.first.second; |
| 3596 | } |
| 3597 | |
| 3598 | return result; |
| 3599 | } |
| 3600 | |
| 3601 | std::vector<char> llama_vocab::get_precompiled_charsmap() const { |
| 3602 | return pimpl->precompiled_charsmap; |