Buckets:
| namespace neuroflow { | |
| class GenerativeModel { | |
| public: | |
| std::unique_ptr<CausalLMHead> lm_head_; | |
| std::unique_ptr<Tokenizer> tokenizer_; | |
| std::unique_ptr<SamplingStrategy> sampler_; | |
| NeuroFlowModel* neuroflow_model_; | |
| GenerativeModel(const CausalLMConfig& lm_config, | |
| std::unique_ptr<Tokenizer> tokenizer, | |
| NeuroFlowModel* nf_model = nullptr); | |
| GenerateOutput generate(const std::string& prompt, const GenerateConfig& config); | |
| Tensor apply_sn_gating(const Tensor& hidden, const Tensor& logits); | |
| Tensor inject_memory(const Tensor& query, const Tensor& logits); | |
| Tensor apply_repetition_penalty(Tensor logits, const GenerateConfig& config, | |
| const std::vector<size_t>& generated); | |
| Tensor apply_punct_penalty(Tensor logits, const GenerateConfig& config); | |
| void set_strategy(SamplingStrategyType type); | |
| void clear_cache(); | |
| CacheStats cache_stats() const; | |
| }; | |
| } // namespace neuroflow | |
Xet Storage Details
- Size:
- 1.36 kB
- Xet hash:
- b0b0faa926fa169cc5dc0d082b138f494e4c084c4c39e0b3b186619741128ccf
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.