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
| <script lang="ts"> | |
| import { FolderOpen, Plus, Loader2, Braces } from '@lucide/svelte'; | |
| import { toast } from 'svelte-sonner'; | |
| import * as Dialog from '$lib/components/ui/dialog'; | |
| import { Button } from '$lib/components/ui/button'; | |
| import { mcpStore } from '$lib/stores/mcp.svelte'; | |
| import { conversationsStore } from '$lib/stores/conversations.svelte'; | |
| import { | |
| mcpResources, | |
| mcpTotalResourceCount, | |
| mcpResourceStore | |
| } from '$lib/stores/mcp-resources.svelte'; | |
| import { | |
| McpResourcesBrowser, | |
| McpResourcePreview, | |
| McpResourceTemplateForm | |
| } from '$lib/components/app'; | |
| import { getResourceDisplayName } from '$lib/utils'; | |
| import type { MCPResourceInfo, MCPResourceContent, MCPResourceTemplateInfo } from '$lib/types'; | |
| import { SvelteSet } from 'svelte/reactivity'; | |
| interface Props { | |
| open?: boolean; | |
| onOpenChange?: (open: boolean) => void; | |
| onAttach?: (resource: MCPResourceInfo) => void; | |
| preSelectedUri?: string; | |
| } | |
| let { open = $bindable(false), onOpenChange, onAttach, preSelectedUri }: Props = $props(); | |
| let selectedResources = new SvelteSet<string>(); | |
| let lastSelectedUri = $state<string | null>(null); | |
| let isAttaching = $state(false); | |
| let selectedTemplate = $state<MCPResourceTemplateInfo | null>(null); | |
| let templatePreviewUri = $state<string | null>(null); | |
| let templatePreviewContent = $state<MCPResourceContent[] | null>(null); | |
| let templatePreviewLoading = $state(false); | |
| let templatePreviewError = $state<string | null>(null); | |
| const totalCount = $derived(mcpTotalResourceCount()); | |
| $effect(() => { | |
| if (open) { | |
| loadResources(); | |
| if (preSelectedUri) { | |
| selectedResources.clear(); | |
| selectedResources.add(preSelectedUri); | |
| lastSelectedUri = preSelectedUri; | |
| } | |
| } | |
| }); | |
| async function loadResources() { | |
| const perChatOverrides = conversationsStore.getAllMcpServerOverrides(); | |
| const initialized = await mcpStore.ensureInitialized(perChatOverrides); | |
| if (initialized) { | |
| await mcpStore.fetchAllResources(); | |
| } | |
| } | |
| function handleOpenChange(newOpen: boolean) { | |
| open = newOpen; | |
| onOpenChange?.(newOpen); | |
| if (!newOpen) { | |
| selectedResources.clear(); | |
| lastSelectedUri = null; | |
| clearTemplateState(); | |
| } | |
| } | |
| function clearTemplateState() { | |
| selectedTemplate = null; | |
| templatePreviewUri = null; | |
| templatePreviewContent = null; | |
| templatePreviewLoading = false; | |
| templatePreviewError = null; | |
| } | |
| function handleTemplateSelect(template: MCPResourceTemplateInfo) { | |
| selectedResources.clear(); | |
| lastSelectedUri = null; | |
| if ( | |
| selectedTemplate?.uriTemplate === template.uriTemplate && | |
| selectedTemplate?.serverName === template.serverName | |
| ) { | |
| clearTemplateState(); | |
| return; | |
| } | |
| selectedTemplate = template; | |
| templatePreviewUri = null; | |
| templatePreviewContent = null; | |
| templatePreviewLoading = false; | |
| templatePreviewError = null; | |
| } | |
| async function handleTemplateResolve(uri: string, serverName: string) { | |
| templatePreviewUri = uri; | |
| templatePreviewContent = null; | |
| templatePreviewLoading = true; | |
| templatePreviewError = null; | |
| try { | |
| const content = await mcpStore.readResourceByUri(serverName, uri); | |
| if (content) { | |
| templatePreviewContent = content; | |
| } else { | |
| templatePreviewError = 'Failed to read resource'; | |
| } | |
| } catch (error) { | |
| templatePreviewError = error instanceof Error ? error.message : 'Unknown error'; | |
| } finally { | |
| templatePreviewLoading = false; | |
| } | |
| } | |
| function handleTemplateCancelForm() { | |
| clearTemplateState(); | |
| } | |
| async function handleAttachTemplateResource() { | |
| if (!templatePreviewUri || !selectedTemplate || !templatePreviewContent) return; | |
| isAttaching = true; | |
| try { | |
| const knownResource = mcpResourceStore.findResourceByUri(templatePreviewUri); | |
| if (knownResource) { | |
| if (!mcpResourceStore.isAttached(knownResource.uri)) { | |
| await mcpStore.attachResource(knownResource.uri); | |
| } | |
| toast.success(`Resource attached: ${knownResource.title || knownResource.name}`); | |
| } else { | |
| if (mcpResourceStore.isAttached(templatePreviewUri)) { | |
| toast.info('Resource already attached'); | |
| handleOpenChange(false); | |
| return; | |
| } | |
| const resourceInfo: MCPResourceInfo = { | |
| uri: templatePreviewUri, | |
| name: templatePreviewUri.split('/').pop() || templatePreviewUri, | |
| serverName: selectedTemplate.serverName | |
| }; | |
| const attachment = mcpResourceStore.addAttachment(resourceInfo); | |
| mcpResourceStore.updateAttachmentContent(attachment.id, templatePreviewContent); | |
| toast.success(`Resource attached: ${resourceInfo.name}`); | |
| } | |
| handleOpenChange(false); | |
| } catch (error) { | |
| console.error('Failed to attach template resource:', error); | |
| } finally { | |
| isAttaching = false; | |
| } | |
| } | |
| function handleResourceSelect(resource: MCPResourceInfo, shiftKey: boolean = false) { | |
| clearTemplateState(); | |
| if (shiftKey && lastSelectedUri) { | |
| const allResources = getAllResourcesFlatInTreeOrder(); | |
| const lastIndex = allResources.findIndex((r) => r.uri === lastSelectedUri); | |
| const currentIndex = allResources.findIndex((r) => r.uri === resource.uri); | |
| if (lastIndex !== -1 && currentIndex !== -1) { | |
| const start = Math.min(lastIndex, currentIndex); | |
| const end = Math.max(lastIndex, currentIndex); | |
| for (let i = start; i <= end; i++) { | |
| selectedResources.add(allResources[i].uri); | |
| } | |
| } | |
| } else { | |
| selectedResources.clear(); | |
| selectedResources.add(resource.uri); | |
| lastSelectedUri = resource.uri; | |
| } | |
| } | |
| function handleResourceToggle(resource: MCPResourceInfo, checked: boolean) { | |
| clearTemplateState(); | |
| if (checked) { | |
| selectedResources.add(resource.uri); | |
| } else { | |
| selectedResources.delete(resource.uri); | |
| } | |
| lastSelectedUri = resource.uri; | |
| } | |
| function getAllResourcesFlatInTreeOrder(): MCPResourceInfo[] { | |
| const allResources: MCPResourceInfo[] = []; | |
| const resourcesMap = mcpResources(); | |
| for (const [serverName, serverRes] of resourcesMap.entries()) { | |
| for (const resource of serverRes.resources) { | |
| allResources.push({ ...resource, serverName }); | |
| } | |
| } | |
| return allResources.sort((a, b) => { | |
| const aName = getResourceDisplayName(a); | |
| const bName = getResourceDisplayName(b); | |
| return aName.localeCompare(bName); | |
| }); | |
| } | |
| async function handleAttach() { | |
| if (selectedResources.size === 0) return; | |
| isAttaching = true; | |
| try { | |
| const allResources = getAllResourcesFlatInTreeOrder(); | |
| const resourcesToAttach = allResources.filter((r) => selectedResources.has(r.uri)); | |
| for (const resource of resourcesToAttach) { | |
| await mcpStore.attachResource(resource.uri); | |
| onAttach?.(resource); | |
| } | |
| const count = resourcesToAttach.length; | |
| toast.success( | |
| count === 1 | |
| ? `Resource attached: ${resourcesToAttach[0].name}` | |
| : `${count} resources attached` | |
| ); | |
| handleOpenChange(false); | |
| } catch (error) { | |
| console.error('Failed to attach resources:', error); | |
| } finally { | |
| isAttaching = false; | |
| } | |
| } | |
| const selectedTemplateUri = $derived(selectedTemplate?.uriTemplate ?? null); | |
| const hasTemplateResult = $derived( | |
| !!selectedTemplate && !!templatePreviewContent && !!templatePreviewUri | |
| ); | |
| </script> | |
| <Dialog.Root {open} onOpenChange={handleOpenChange}> | |
| <Dialog.Content class="max-h-[80vh] !max-w-4xl overflow-hidden p-0"> | |
| <Dialog.Header class="border-b border-border/30 px-6 py-4"> | |
| <Dialog.Title class="flex items-center gap-2"> | |
| <FolderOpen class="h-5 w-5" /> | |
| <span>MCP Resources</span> | |
| {#if totalCount > 0} | |
| <span class="text-sm font-normal text-muted-foreground">({totalCount})</span> | |
| {/if} | |
| </Dialog.Title> | |
| <Dialog.Description> | |
| Browse and attach resources from connected MCP servers to your chat context. | |
| </Dialog.Description> | |
| </Dialog.Header> | |
| <div class="flex h-[500px] min-w-0"> | |
| <div class="w-72 shrink-0 overflow-y-auto border-r border-border/30 p-4"> | |
| <McpResourcesBrowser | |
| onSelect={handleResourceSelect} | |
| onToggle={handleResourceToggle} | |
| onTemplateSelect={handleTemplateSelect} | |
| selectedUris={selectedResources} | |
| {selectedTemplateUri} | |
| expandToUri={preSelectedUri} | |
| /> | |
| </div> | |
| <div class="min-w-0 flex-1 overflow-auto p-4"> | |
| {#if selectedTemplate && !templatePreviewContent} | |
| <div class="flex h-full flex-col"> | |
| <div class="mb-3 flex items-center gap-2"> | |
| <Braces class="h-4 w-4 text-muted-foreground" /> | |
| <span class="text-sm font-medium"> | |
| {selectedTemplate.title || selectedTemplate.name} | |
| </span> | |
| </div> | |
| {#if selectedTemplate.description} | |
| <p class="mb-4 text-xs text-muted-foreground"> | |
| {selectedTemplate.description} | |
| </p> | |
| {/if} | |
| <div class="mb-4 rounded-md border border-border/50 bg-muted/30 px-3 py-2"> | |
| <p class="font-mono text-xs break-all text-muted-foreground"> | |
| {selectedTemplate.uriTemplate} | |
| </p> | |
| </div> | |
| {#if templatePreviewLoading} | |
| <div class="flex flex-1 items-center justify-center"> | |
| <Loader2 class="h-6 w-6 animate-spin text-muted-foreground" /> | |
| </div> | |
| {:else if templatePreviewError} | |
| <div class="flex flex-1 flex-col items-center justify-center gap-2 text-red-500"> | |
| <span class="text-sm">{templatePreviewError}</span> | |
| <Button | |
| size="sm" | |
| variant="outline" | |
| onclick={() => { | |
| templatePreviewError = null; | |
| }} | |
| > | |
| Try again | |
| </Button> | |
| </div> | |
| {:else} | |
| <McpResourceTemplateForm | |
| template={selectedTemplate} | |
| onResolve={handleTemplateResolve} | |
| onCancel={handleTemplateCancelForm} | |
| /> | |
| {/if} | |
| </div> | |
| {:else if hasTemplateResult} | |
| <!-- Template resolved: show preview --> | |
| <McpResourcePreview | |
| resource={{ | |
| uri: templatePreviewUri ?? '', | |
| name: templatePreviewUri?.split('/').pop() || (templatePreviewUri ?? ''), | |
| serverName: selectedTemplate?.serverName || '' | |
| }} | |
| preloadedContent={templatePreviewContent} | |
| /> | |
| {:else if selectedResources.size === 1} | |
| {@const allResources = getAllResourcesFlatInTreeOrder()} | |
| {@const selectedResource = allResources.find((r) => selectedResources.has(r.uri))} | |
| <McpResourcePreview resource={selectedResource ?? null} /> | |
| {:else if selectedResources.size > 1} | |
| <div class="flex flex-col gap-10"> | |
| {#each getAllResourcesFlatInTreeOrder() as resource (resource.uri)} | |
| {#if selectedResources.has(resource.uri)} | |
| <McpResourcePreview {resource} /> | |
| {/if} | |
| {/each} | |
| </div> | |
| {:else} | |
| <div class="flex h-full items-center justify-center text-sm text-muted-foreground"> | |
| Select a resource to preview | |
| </div> | |
| {/if} | |
| </div> | |
| </div> | |
| <Dialog.Footer class="border-t border-border/30 px-6 py-4"> | |
| <Button variant="outline" onclick={() => handleOpenChange(false)}>Cancel</Button> | |
| {#if hasTemplateResult} | |
| <Button onclick={handleAttachTemplateResource} disabled={isAttaching}> | |
| {#if isAttaching} | |
| <Loader2 class="mr-2 h-4 w-4 animate-spin" /> | |
| {:else} | |
| <Plus class="mr-2 h-4 w-4" /> | |
| {/if} | |
| Attach Resource | |
| </Button> | |
| {:else} | |
| <Button onclick={handleAttach} disabled={selectedResources.size === 0 || isAttaching}> | |
| {#if isAttaching} | |
| <Loader2 class="mr-2 h-4 w-4 animate-spin" /> | |
| {:else} | |
| <Plus class="mr-2 h-4 w-4" /> | |
| {/if} | |
| Attach {selectedResources.size > 0 ? `(${selectedResources.size})` : 'Resource'} | |
| </Button> | |
| {/if} | |
| </Dialog.Footer> | |
| </Dialog.Content> | |
| </Dialog.Root> | |