fal.ai Skills
Skills for building inference.sh apps that wrap fal.ai model endpoints.
Authentication
fal.ai API Key: ../.fal.key
Load it before using fal.ai API:
bash
export FAL_KEY=$(cat ../.fal.key)
Workflow: Adding a New fal.ai Model
Use these skills in order:
1. Search for the model
Skill: fal-model-search
Find the fal.ai endpoint and get its OpenAPI schema:
bash
curl "https://api.fal.ai/v1/models?endpoint_id=fal-ai/MODEL_NAME&expand=openapi-3.0"
2. Check if already implemented
Skill: fal-implemented-models
Check ../IMPLEMENTED_MODELS.md to see if model exists.
3. Add the model
Skill: fal-add-model
IMPORTANT: This skill has a strict checklist. Follow each step IN ORDER:
- •Fetch OpenAPI schema
- •Write MODEL.md - STOP until complete
- •Fetch pricing
- •Write PRICING.md - STOP until complete
- •Run
infsh app init - •Implement inference.py
- •Test with
infsh run - •Update IMPLEMENTED_MODELS.md
- •Deploy with
infsh deploy
4. Configure pricing
Skill: fal-pricing
Fetch pricing and create CEL expressions for billing.
General inference.sh Skills
Skill: creating-apps
For general inference.sh development not specific to fal.ai:
| Skill | Purpose |
|---|---|
| using-the-cli | CLI commands |
| writing-app-logic | inference.py patterns |
| configuring-resources | inf.yml setup |
| managing-secrets | API keys and secrets |
| tracking-usage | Output metadata for billing |
| handling-cancellation | Long-running tasks |
| optimizing-performance | Best practices |
| debugging-issues | Troubleshooting |
Quick Reference
| Task | Skill |
|---|---|
| "Add fal.ai model X" | fal-add-model |
| "Find fal.ai models for Y" | fal-model-search |
| "Is model X implemented?" | fal-implemented-models |
| "Set up pricing for X" | fal-pricing |
| "How do I write inference.py?" | creating-apps/writing-app-logic |
| "Configure GPU resources" | creating-apps/configuring-resources |
Directory Structure
code
../
├── .fal.key # fal.ai API key
├── IMPLEMENTED_MODELS.md # Tracking file
├── fal_helper.py # Shared helper (copy to each app)
├── _skills/ # These skills
│ ├── SKILL.md # This file
│ ├── fal-add-model/
│ ├── fal-model-search/
│ ├── fal-implemented-models/
│ ├── fal-pricing/
│ └── creating-apps/
└── [app-name]/ # Each implemented app
├── inference.py
├── inf.yml
├── requirements.txt
├── __init__.py
├── fal_helper.py
├── MODEL.md # Schema documentation
└── PRICING.md # Pricing documentation