Text Generation
Safetensors
MLX
English
mlx-lm
prompt-reconstruction
prompt-inversion
prompt-recovery
inverse-prompting
response-to-prompt
semantic-similarity
ultrachat
qwen2.5
lora
apple-silicon
8-bit precision
quantized
small-language-model
Instructions to use ddrisco11/TROUT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use ddrisco11/TROUT with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # if on a CUDA device, also pip install mlx[cuda] # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("ddrisco11/TROUT") prompt = "Once upon a time in" text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- MLX LM
How to use ddrisco11/TROUT with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Generate some text mlx_lm.generate --model "ddrisco11/TROUT" --prompt "Once upon a time"
- Atomic Chat
File size: 1,434 Bytes
afef78e cf2408d afef78e | 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 31 32 33 34 35 36 37 38 | ---
language:
- en
pipeline_tag: text-generation
tags:
- prompt-reconstruction
- prompt-inversion
- prompt-recovery
- inverse-prompting
- response-to-prompt
- semantic-similarity
- ultrachat
- qwen2.5
- lora
- mlx
- apple-silicon
- 8-bit
- quantized
- small-language-model
license: apache-2.0
base_model: Qwen/Qwen2.5-0.5B-Instruct
datasets:
- HuggingFaceH4/ultrachat_200k
library_name: mlx-lm
---
# TROUT

David Driscoll 路 inpuT Reconstruction from Output Using Transformers. Predicts a plausible user prompt from one assistant response.
**Preview, supervised step 500** 路 Mean prompt cosine similarity **0.696** on 24 UltraChat validation responses with the included 8-bit base. Final held-out evaluation is pending.
Download with `hf download ddrisco11/TROUT --local-dir TROUT`. On Apple silicon, load with `mlx_lm.load("TROUT/base-8bit", adapter_path="TROUT")`.
[GitHub and inference instructions](https://github.com/ddrisco11/response-to-prompt)
**Sources** 路 [Qwen2.5-0.5B-Instruct](https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct) 路 [UltraChat 200k](https://huggingface.co/datasets/HuggingFaceH4/ultrachat_200k) 路 [MiniLM sentence encoder used for evaluation](https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2) 路 [Hu et al., LoRA](https://arxiv.org/abs/2106.09685) 路 [Zhang, Morris & Shmatikov, Output2Prompt (EMNLP 2024)](https://aclanthology.org/2024.emnlp-main.819/).
|