mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-10-09 23:15:23 +00:00
20 lines
488 B
C++
20 lines
488 B
C++
//
|
|
// Created by mfuntowicz on 6/30/24.
|
|
//
|
|
#include <filesystem>
|
|
#include "rust/cxx.h"
|
|
|
|
#include "backends/trtllm/include/backend.h"
|
|
|
|
namespace huggingface::tgi::backends {
|
|
/***
|
|
*
|
|
* @param engineFolder
|
|
* @return
|
|
*/
|
|
std::unique_ptr<TensorRtLlmBackend> create_trtllm_backend(rust::Str engineFolder) {
|
|
const auto enginePath = std::string_view(engineFolder.begin(), engineFolder.end());
|
|
return std::make_unique<TensorRtLlmBackend>(enginePath);
|
|
}
|
|
|
|
} |