Spoutlets: Specialized Prompt Templates
Spoutlets are the heart of Spout's dual-layer modularity principle - they are specialized prompt templates that define how modules process inputs and generate outputs. Currently based on Microsoft's Semantic Kernel original plugin format, spoutlets store configurations, examples, and transformation rules in self-contained files. While this format provides a solid foundation for structured specialization and flexible customization, Spout plans to expand support for additional prompt template formats in the future to accommodate diverse developer preferences and use cases.
1. Core Components of a Spoutlet
Each spoutlet consists of two main files:
prompt.txt - The template that guides the LLM's behavior:
[OBJECTIVE]
Clear statement of the transformation goal
[RULES]
Specific guidelines for the transformation
[EXAMPLES]
Input example
++++
Output example
[INPUT]
{{$input}}
++++
config.json - The execution settings and parameters:
{
"schema": 1,
"description": "Purpose of this spoutlet",
"execution_settings": {
"default": {
"max_tokens": 4096,
"temperature": 0.3,
"top_p": 0.3,
"presence_penalty": 0.0,
"frequency_penalty": 0.0
}
},
"input_variables": [
{
"name": "input",
"description": "Primary input text",
"defaultValue": ""
}
]
}
2. Spoutlet Categories
Spoutlets are loaded from the following folders:
- Default Spoutlets (
[module]_plugins/
)- Ship with core modules
- Provide standardized baseline functionality
- Maintained under version control
- Community-contributed improvements welcome
- Pro Spoutlets (
[module]_pro/
)- Premium templates for Spout Supporters
- Local Spoutlets (
[module]_local/
)- User-maintained custom templates
- Git-ignored for privacy
- Highest priority when duplicate names exist
3. Creating Custom Spoutlets
Following the principle of inclusive innovation, creating spoutlets is designed to be accessible to all skill levels:
- Define Template Structure
[OBJECTIVE] Clear, focused transformation goal [RULES] Numbered list of specific guidelines [EXAMPLES] Input/output pairs demonstrating desired behavior [INPUT] {{$input}} ++++
- Configure Settings
{ "schema": 1, "description": "Clear purpose statement", "execution_settings": { "default": { "temperature": 0.3, "top_p": 0.3, "max_tokens": 4096 } } }
4. Best Practices
Following the principle of human-centric automation:
- Start with clear objectives and rules
- Include relevant examples
- Use consistent formatting
- Test thoroughly with various inputs
- Document any special requirements
- Consider sharing useful templates with the community
5. Standard Parameters
Most modules work fine with these default settings below, but feel free to experiment with the settings to get the best results for your specific use case:
- temperature: 0.3
- top_p: 0.3
- max_tokens: 4096
- presence_penalty: 0.0
- frequency_penalty: 0.0
Conclusion
Spoutlets embody Spout's principles of dual-layer modularity and structured specialization while enabling inclusive innovation. Whether creating custom templates in [module]_local/
or contributing to the community via [module]_plugins/
, spoutlets provide a flexible yet structured way to customize AI workflows.
Through careful template design and configuration, spoutlets help maintain the balance between powerful automation and human control - ensuring AI remains a tool that enhances rather than replaces human creativity and decision-making.