File size: 553 Bytes
fb6457c | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #pragma once
#include "bsh_tensor.hpp"
#include <vector>
#include <string>
namespace bsh {
class Engine {
public:
Engine();
~Engine();
void initialize();
void process(const Tensor& input, Tensor& output);
void shutdown();
std::string get_version() const;
std::string get_status() const;
private:
bool initialized_;
std::vector<Tensor> state_;
void apply_attention(const Tensor& query, const Tensor& key,
const Tensor& value, Tensor& output);
};
} // namespace bsh
|