[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/ropoctl/sam3cpp/master/tools/sam3_text_encode.cpp [Back]  [Original]

#include "sam3/gguf_model.h"
#include "sam3/npy.h"
#include "sam3/text_encoder.h"

#include 
#include 
#include 
#include 
#include 

namespace {

std::vector read_tokens(const std::string & path) {
    std::ifstream in(path);
    if (!in) {
        throw std::runtime_error("failed to open tokens file: " + path);
    }
    std::vector tokens;
    int32_t value = 0;
    while (in >> value) {
        tokens.push_back(value);
    }
    return tokens;
}

}  // namespace

int main(int argc, char ** argv) {
    if (argc < 4) {
        std::cerr 

Web Proxy Viewer  |  New URL  |  Original Page