Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/pjt222/agent-almanac/analyze-generative-diffusion-modelnpx skills add pjt222/agent-almanac --skill analyze-generative-diffusion-modelgit clone --depth 1 https://github.com/pjt222/agent-almanacWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/pjt222/agent-almanac/analyze-generative-diffusion-model)<a href="https://agentmods.dev/skills/pjt222/agent-almanac/analyze-generative-diffusion-model"><img src="https://agentmods.dev/badge/skills/pjt222/agent-almanac/analyze-generative-diffusion-model.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00104 | $0.03818 |
| Opus 5 | $0.00052 | $0.01909 |
| Sonnet 5 | $0.00021 | $0.00764 |
| Haiku 4.5 | $0.00010 | $0.00382 |
Grade A, and why
analyze-generative-diffusion-model scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 369 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Analyze a Generative Diffusion Model
Evaluate pre-trained generative diffusion models through quantitative quality metrics, noise schedule inspection, cross-attention map analysis, and latent space probing to understand model behavior, diagnose failure modes, and guide fine-tuning decisions.
When to Use
- Evaluating a pre-trained generative diffusion model's output quality with standard metrics
- Computing FID, IS, CLIP score, or precision/recall for generated image sets
- Inspecting and comparing noise schedules (linear, cosine, learned) via SNR curves
- Extracting cross-attention maps to understand text-to-image token-region correspondences
- Interpolating between latent codes or discovering semantic directions in the latent space
- Detecting out-of-distribution inputs for a diffusion model pipeline
Inputs
- Required: Pre-trained model identifier or checkpoint path (e.g.,
stabilityai/stable-diffusion-2-1) - Required: Analysis mode — one or more of:
metrics,schedule,attention,latent - Required: Reference dataset for metric computation (real images or dataset name)
- Optional: Text prompts for attention analysis (default: model-appropriate test prompts)
- Optional: Number of generated samples for metric computation (default: 10000)
- Optional: Device configuration (default:
cudaif available, elsecpu)
Procedure
Step 1: Quantitative Evaluation
Compute standard generative quality metrics against a reference dataset.
- Set up the evaluation pipeline:
import torch
from diffusers import StableDiffusionPipeline
from torchmetrics.image.fid import FrechetInceptionDistance
from torchmetrics.image.inception import InceptionScore
device = "cuda" if torch.cuda.is_available() else "cpu"
pipe = StableDiffusionPipeline.from_pretrained(
"stabilityai/stable-diffusion-2-1", torch_dtype=torch.float16
).to(device)
fid = FrechetInceptionDistance(feature=2048, normalize=True).to(device)
inception = InceptionScore(normalize=True).to(device)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3d ago First seen · 369 lines · 104 tokens per session scan A c910639015e3
analyze-generative-diffusion-model is a skill published in the GitHub repository pjt222/agent-almanac (32 stars, last pushed 2d ago), licensed MIT. It adds 104 tokens to every session and 3,818 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
metodo-3w1h
Dê a habilidade para agentes de IA de estruturar e otimizar prompts de imagens utilizando rigorosamente o método 3W1H (Who, What, Where, How) criado pelo Mário Lúcio. Utilize esta skill sempre que o usuário mencionar termos como 'gerar imagem', 'criar prompt de imagem', 'engenharia de prompt de imagem', 'fotorrealismo…
prompt-personagem
Gera automaticamente prompts detalhados de personagens para inteligência artificial. Utilizando listas pré-definidas de atributos, o script cria descrições únicas combinando gênero, idade, tom de pele, penteado e poses variadas. Use esta skill SEMPRE que o usuário invocar o gatilho "/personagem", independentemente de…
baoyu-danger-gemini-web
Generates images and text via reverse-engineered Gemini Web API. Supports text generation, image generation from prompts, reference images for vision input, and multi-turn conversations. Use when other skills need image generation backend, or when user requests "generate image with Gemini", "Gemini text generation"…
baoyu-imagine
AI image generation with OpenAI GPT Image 2, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream and Replicate APIs. Supports text-to-image, reference images, aspect ratios, and batch generation from saved prompt files. Sequential by default; use batch parallel generation when the…
voice-extractor
Capture a user's real writing voice from 5-20 prior samples, store a local voice.yaml fingerprint, and enforce it on newsjack drafts so AI tells disappear. Measures voice with named stylometry lenses (Burrows's Delta function-word vector, MATTR lexical diversity, sentence-length burstiness, Biber Dimension-1 register…
map
Build and commit a Cortex function knowledge graph — maps structural dependencies and domain intent relationships across all AI functions in the project. Supports --reduce (default on) for transitive reduction of the dependency graph.