CoolFace
Modelpublic

prithivMLmods/Pyxidis-Manim-CodeGen-1.7B

sourceHugging Faceapache-2.0updated 1y agoView on Hugging Face
5likes66downloads
README.md104 linesDownload Raw Back to root
1---2license: apache-2.03language:4- en5base_model:6- Qwen/Qwen3-1.7B7pipeline_tag: text-generation8library_name: transformers9tags:10- text-generation-inference11- code12- trl13---14 15![1.png](https://cdn-uploads.huggingface.co/production/uploads/65bb837dbfb878f46c77de4c/4LKArEzZk53evXdv_no2u.png)16 17# **Pyxidis-Manim-CodeGen-1.7B (Experimental)**18 19> **Pyxidis-Manim-CodeGen-1.7B** is an **experimental math animation coding model** fine-tuned on **Qwen/Qwen3-1.7B** using **Manim-CodeGen code traces**.20> It is specialized for **Python-based mathematical animations with Manim**, making it ideal for educators, researchers, and developers working on math visualization and animation pipelines.21 22> \[!note]23> GGUF: [https://huggingface.co/prithivMLmods/Pyxidis-Manim-CodeGen-1.7B-GGUF](https://huggingface.co/prithivMLmods/Pyxidis-Manim-CodeGen-1.7B-GGUF)24 25---26 27## **Key Features**28 291. **Manim-Specific Code Generation**30   Trained on **Manim-CodeGen traces**, optimized for **Python-based animation scripting** of mathematical concepts and visual proofs.31 322. **Math + Code Synergy**33   Generates step-by-step **math derivations with corresponding animation code**, bridging symbolic reasoning with visualization.34 353. **Animation Workflow Optimization**36   Provides structured code for **scenes, transformations, graphs, and equations** in Manim, reducing boilerplate and debugging effort.37 384. **Python-Centric Reasoning**39   Produces **clean, modular, and reusable Python code**, supporting educational and research-driven animation pipelines.40 415. **Structured Output Mastery**42   Capable of outputting in **Python**, **Markdown**, and **LaTeX**, ideal for tutorials, educational notebooks, and automated video generation workflows.43 446. **Lightweight but Specialized**45   Focused on **Manim coding efficiency** while maintaining a deployable footprint for **GPU clusters** and **research labs**.46 47---48 49## **Quickstart with Transformers**50 51```python52from transformers import AutoModelForCausalLM, AutoTokenizer53 54model_name = "prithivMLmods/Pyxidis-Manim-CodeGen-1.7B"55 56model = AutoModelForCausalLM.from_pretrained(57    model_name,58    torch_dtype="auto",59    device_map="auto"60)61tokenizer = AutoTokenizer.from_pretrained(model_name)62 63prompt = "Write a Manim script to animate the Pythagorean theorem using squares on the triangle's sides."64 65messages = [66    {"role": "system", "content": "You are a Python coding assistant specialized in Manim-based math animations."},67    {"role": "user", "content": prompt}68]69 70text = tokenizer.apply_chat_template(71    messages,72    tokenize=False,73    add_generation_prompt=True74)75 76model_inputs = tokenizer([text], return_tensors="pt").to(model.device)77 78generated_ids = model.generate(79    **model_inputs,80    max_new_tokens=51281)82generated_ids = [83    output_ids[len(input_ids):] for input_ids, output_ids in zip(model_inputs.input_ids, generated_ids)84]85 86response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0]87print(response)88```89 90---91 92## **Intended Use**93 94* **Manim-based math animation coding** for research, teaching, and content creation95* **Educational visualization assistant** to convert math problems into animations96* **Python tutoring tool** for math-heavy animation workflows97* **Prototype generator** for interactive STEM video content98 99## **Limitations**100 101* Experimental model – may generate code requiring manual debugging102* Limited to **Manim coding workflows**, not general-purpose code assistant103* May not handle **complex multi-scene projects** without iterative refinement104* Prioritizes structured math + animation reasoning, less optimized for general dialogue