�
Natural Language to Scene Parser
: A fine-tuned 135M parameter model that converts text descriptions into structured JSON scene specifications.
⚠️
Note
: This model is the
text parsing component
of a larger physics-based GIF generation pipeline. It does NOT generate GIFs directly, it outputs structured JSON that is then processed by a separate physics engine and renderer.
What This Model Does
"a red ball bouncing to the right"
│
▼
┌─────────────────────┐
│ PhysicsGIF-135M │ ← THIS MODEL
│ (Text → JSON) │
└──────────┬──────────┘
│
▼
{
"objects": [{"type": "ball", "color": "#FF0000"}],
"motion": {"velocity": [3, 0], "gravity": 0.3, "bounce": 0.9},
"canvas": {"size": 128, "frames": 40}
}
The JSON output is then processed by
separate Python code
(physics engine + renderer) to create the actual GIF.
🎬 Example Outputs
Prompt
Generated GIF
"two triangles colliding with each other and exploding"
"a pink ball dropping slowly from up"
📊 Training Results
Metric
Value
Base Model
SmolLM2-135M-Instruct
Training Examples
500
Epochs
20
Final Loss
0.092
Loss Reduction
95.9%
Training Time
42 minutes
LoRA Rank
16
LoRA Alpha
32
📈 Training Visualizations
Training Loss Curve
Learning Rate Schedule
Gradient Norms
Per-Epoch Loss
Dataset Distribution
Convergence Analysis
🚀 Usage
With the Full Pipeline (Recommended)
To generate actual GIFs, you need the complete pipeline code:
🎬 PhysicsGIF Text-to-GIF Generator
Enter prompt: a red ball bouncing
Generating...
✓ Generated: output_1.gif
Using This Model Directly (Text → JSON only)
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained("vikramlingam/PhysicsGIF-135M")
tokenizer = AutoTokenizer.from_pretrained("vikramlingam/PhysicsGIF-135M")
prompt = '''<|im_start|>systemYou are a scene description parser. Convert text to JSON scene specification.<|im_end|><|im_start|>userConvert to scene JSON: a red ball bouncing to the right<|im_end|><|im_start|>assistant'''
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=200, do_sample=False)
result = tokenizer.decode(outputs[0])
# Output: JSON scene specification# You need physics.py and renderer.py to convert this to a GIF
PhysicsGIF-135M huggingface.co is an AI model on huggingface.co that provides PhysicsGIF-135M's model effect (), which can be used instantly with this vikramlingam PhysicsGIF-135M model. huggingface.co supports a free trial of the PhysicsGIF-135M model, and also provides paid use of the PhysicsGIF-135M. Support call PhysicsGIF-135M model through api, including Node.js, Python, http.
PhysicsGIF-135M huggingface.co is an online trial and call api platform, which integrates PhysicsGIF-135M's modeling effects, including api services, and provides a free online trial of PhysicsGIF-135M, you can try PhysicsGIF-135M online for free by clicking the link below.
vikramlingam PhysicsGIF-135M online free url in huggingface.co:
PhysicsGIF-135M is an open source model from GitHub that offers a free installation service, and any user can find PhysicsGIF-135M on GitHub to install. At the same time, huggingface.co provides the effect of PhysicsGIF-135M install, users can directly use PhysicsGIF-135M installed effect in huggingface.co for debugging and trial. It also supports api for free installation.