--- language: - en license: apache-2.0 base_model: Qwen/Qwen2.5-7B-Instruct pipeline_tag: text-generation library_name: transformers tags: - fundraising - non-profit - coaching - conversational - sft - lora datasets: - Mic-Fundraiser/fundraising-english-sft --- # Fundraising Coach — English A conversational language model fine-tuned exclusively on nonprofit fundraising coaching in English. Produces structured answers: **diagnosis → options → recommendation**. Trained to avoid fabricating statistics or specific legal/tax guidance. Base: [`Qwen/Qwen2.5-7B-Instruct`](https://huggingface.co/Qwen/Qwen2.5-7B-Instruct). Dataset: [`Mic-Fundraiser/fundraising-english-sft`](https://huggingface.co/datasets/Mic-Fundraiser/fundraising-english-sft) (10,085 train + 530 val, distilled from 14 reference texts). ## Try it [Live demo on Hugging Face Spaces](https://huggingface.co/spaces/Mic-Fundraiser/fundraising-coach-en-demo) ## Usage ```python from transformers import AutoModelForCausalLM, AutoTokenizer model_id = "Mic-Fundraiser/fundraising-coach-en" tokenizer = AutoTokenizer.from_pretrained(model_id) model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype="auto", device_map="auto") SYSTEM = ( "You are an experienced nonprofit fundraising coach. For any substantive question, " "structure your answer as: (1) a brief diagnosis of what the core issue really is, " "(2) the main options with their tradeoffs, (3) a concrete recommendation with the " "reasoning behind it. Be direct, grounded, and practical." ) messages = [ {"role": "system", "content": SYSTEM}, {"role": "user", "content": "Our annual fund is flat. What should I look at first?"}, ] input_ids = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt", return_dict=False).to(model.device) out = model.generate(input_ids, max_new_tokens=500, do_sample=True, temperature=0.6, top_p=0.9, repetition_penalty=1.05) print(tokenizer.decode(out[0][input_ids.shape[1]:], skip_special_tokens=True)) ``` ## Training | | | |---|---| | Method | SFT + QLoRA (4-bit) | | LoRA | r=32, α=64, dropout=0.05 | | Modules | q/k/v/o/gate/up/down | | Epochs | 2 | | LR | 1.5e-4 · cosine | | Eff. batch | 16 · grad accum 8 | | Seq length | 2048 · packing enabled | | Hardware | NVIDIA L40S (HF Jobs) | | Framework | TRL + PEFT + transformers | ## Limitations - Knowledge is shaped by the 14 source texts; regulation, platforms, and trends post-2023 are underrepresented. - Deliberately refuses to invent precise statistics. May feel evasive on "what percentage of donors..." questions. - English-only. For Italian see [`fundraising-assistant`](https://huggingface.co/Mic-Fundraiser/fundraising-assistant). - 2048-token context during training: long multi-turn sessions may lose earlier details.