Safetensors
GGUF
Turkish
llama
Llama-3
instruct
finetune
chatml
gpt4
synthetic data
distillation
function calling
json mode
axolotl
roleplaying
chat
Instructions to use tda45/TdAI with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use tda45/TdAI with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="tda45/TdAI", filename="llama.cpp/models/ggml-vocab-aquila.gguf", )
output = llm( "Once upon a time,", max_tokens=512, echo=True ) print(output)
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use tda45/TdAI with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf tda45/TdAI # Run inference directly in the terminal: llama cli -hf tda45/TdAI
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf tda45/TdAI # Run inference directly in the terminal: llama cli -hf tda45/TdAI
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf tda45/TdAI # Run inference directly in the terminal: ./llama-cli -hf tda45/TdAI
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf tda45/TdAI # Run inference directly in the terminal: ./build/bin/llama-cli -hf tda45/TdAI
Use Docker
docker model run hf.co/tda45/TdAI
- LM Studio
- Jan
- Ollama
How to use tda45/TdAI with Ollama:
ollama run hf.co/tda45/TdAI
- Unsloth Studio
How to use tda45/TdAI with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for tda45/TdAI to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for tda45/TdAI to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for tda45/TdAI to start chatting
- Atomic Chat new
- Docker Model Runner
How to use tda45/TdAI with Docker Model Runner:
docker model run hf.co/tda45/TdAI
- Lemonade
How to use tda45/TdAI with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull tda45/TdAI
Run and chat with the model
lemonade run user.TdAI-{{QUANT_TAG}}List all available models
lemonade list
| // Export usage message (-h) to markdown format | |
| // Automatically update the markdown docs | |
| struct md_file { | |
| llama_example ex; | |
| std::string fname; | |
| std::string specific_section_header; | |
| }; | |
| std::vector<md_file> md_files = { | |
| {LLAMA_EXAMPLE_CLI, "tools/cli/README.md", "CLI-specific params"}, | |
| {LLAMA_EXAMPLE_COMPLETION, "tools/completion/README.md", "Completion-specific params"}, | |
| {LLAMA_EXAMPLE_SERVER, "tools/server/README.md", "Server-specific params"}, | |
| }; | |
| static void write_table_header(std::ostringstream & ss) { | |
| ss << "| Argument | Explanation |\n"; | |
| ss << "| -------- | ----------- |\n"; | |
| } | |
| static void write_table_entry(std::ostringstream & ss, const common_arg & opt) { | |
| ss << "| `"; | |
| // args | |
| auto all_args = opt.get_args(); | |
| for (const auto & arg : all_args) { | |
| if (arg == all_args.front()) { | |
| ss << arg; | |
| if (all_args.size() > 1) ss << ", "; | |
| } else { | |
| ss << arg << (arg != all_args.back() ? ", " : ""); | |
| } | |
| } | |
| // value hint | |
| if (opt.value_hint) { | |
| std::string md_value_hint(opt.value_hint); | |
| string_replace_all(md_value_hint, "|", "\\|"); | |
| ss << " " << md_value_hint; | |
| } | |
| if (opt.value_hint_2) { | |
| std::string md_value_hint_2(opt.value_hint_2); | |
| string_replace_all(md_value_hint_2, "|", "\\|"); | |
| ss << " " << md_value_hint_2; | |
| } | |
| // help text | |
| std::string md_help(opt.help); | |
| md_help = string_strip(md_help); | |
| string_replace_all(md_help, "\n", "<br/>"); | |
| string_replace_all(md_help, "|", "\\|"); | |
| ss << "` | " << md_help << " |\n"; | |
| } | |
| static void write_table(std::ostringstream & ss, std::vector<common_arg *> & opts) { | |
| write_table_header(ss); | |
| for (const auto & opt : opts) { | |
| write_table_entry(ss, *opt); | |
| } | |
| } | |
| static void write_help(std::ostringstream & ss, const md_file & md) { | |
| common_params params; | |
| auto ctx_arg = common_params_parser_init(params, md.ex); | |
| std::vector<common_arg *> common_options; | |
| std::vector<common_arg *> sampling_options; | |
| std::vector<common_arg *> specific_options; | |
| for (auto & opt : ctx_arg.options) { | |
| // in case multiple LLAMA_EXAMPLE_* are set, we prioritize the LLAMA_EXAMPLE_* matching current example | |
| if (opt.is_sampling) { | |
| sampling_options.push_back(&opt); | |
| } else if (opt.in_example(ctx_arg.ex)) { | |
| specific_options.push_back(&opt); | |
| } else { | |
| common_options.push_back(&opt); | |
| } | |
| } | |
| ss << HELP_START_MARKER << "\n\n"; | |
| ss << NOTE_MESSAGE << "\n\n"; | |
| ss << "### Common params\n\n"; | |
| write_table(ss, common_options); | |
| ss << "\n\n### Sampling params\n\n"; | |
| write_table(ss, sampling_options); | |
| ss << "\n\n### " << md.specific_section_header << "\n\n"; | |
| write_table(ss, specific_options); | |
| ss << "\n" << HELP_END_MARKER; | |
| } | |
| int main(int, char **) { | |
| std::setlocale(LC_NUMERIC, "C"); | |
| for (const auto & md : md_files) { | |
| std::ifstream infile(md.fname); | |
| if (!infile.is_open()) { | |
| fprintf(stderr, "failed to open file '%s' for reading\n", md.fname.c_str()); | |
| return 1; | |
| } | |
| std::ostringstream ss; | |
| ss << infile.rdbuf(); | |
| infile.close(); | |
| std::string content = ss.str(); | |
| size_t help_start = content.find(HELP_START_MARKER); | |
| size_t help_end = content.find(HELP_END_MARKER); | |
| if (help_start == std::string::npos || help_end == std::string::npos || help_end <= help_start) { | |
| fprintf(stderr, "failed to find help markers in file '%s'\n", md.fname.c_str()); | |
| return 1; | |
| } | |
| std::ostringstream new_help_ss; | |
| write_help(new_help_ss, md); | |
| std::string new_help = new_help_ss.str(); | |
| content = content.substr(0, help_start) + new_help + content.substr(help_end + strlen(HELP_END_MARKER)); | |
| std::ofstream outfile(md.fname); | |
| if (!outfile.is_open()) { | |
| fprintf(stderr, "failed to open file '%s' for writing\n", md.fname.c_str()); | |
| return 1; | |
| } | |
| outfile << content; | |
| outfile.close(); | |
| printf("Updated help in '%s'\n", md.fname.c_str()); | |
| } | |
| return 0; | |
| } | |