2.1 KiB
2.1 KiB
type, title, description, resource, tags, timestamp
| type | title | description | resource | tags | timestamp | ||||
|---|---|---|---|---|---|---|---|---|---|
| Guide | Common Usage Patterns | Common workflow patterns and recommended Sage Utils usage. | README.md |
|
2026-07-01T00:00:00Z |
This concept documents common Sage Utils usage patterns, including the most effective ways to combine prompt construction, model loading, and metadata capture.
Recommended usage patterns
1. Build prompts with Prompt Builder, then refine with the LLM tab
- Start with wildcards and tags in Prompt Builder.
- Generate a base prompt and optionally save it.
- Send the prompt to the LLM tab for refinement or elaboration.
- Use the final prompt in a workflow node.
2. Keep positive and negative prompts separate
- Use separate prompt fields for positive and negative prompt content.
- This makes prompt logic clearer and simplifies metadata extraction.
- Connect both streams to prompt-to-conditioning nodes when available.
3. Capture metadata explicitly
- Use
Sampler InfoorKSampler w/ Sampler Infoto expose sampler parameters. - Use loader nodes that emit
model_infoand LoRA stack details. - Pass these into
Construct Metadatafor auditability. - Save image metadata with
Save Image w/ Added Metadatafor A1111 compatibility.
4. Use example workflows as templates
- Import an example workflow from
example_workflows/. - Inspect how prompt, model, and metadata nodes are connected.
- Adapt the template to your model and prompt requirements.
5. Use model cache and diagnostics for maintenance
- Run
Model Scan & Reportto inspect model metadata and duplicates. - Use
Cache Maintenanceto find and clean ghost cache entries. - Use
Last LoRA Infoto validate the last LoRA in a stack.
Best practices
- Keep workflows modular: separate model loading, prompt assembly, generation, and save/export steps.
- Avoid hardcoding provider-specific settings in the workflow. Use shared node outputs instead.
- Favor nodes that produce both the generated artifact and metadata for reproducibility.