Ask AI
This document explains the Ask AI node, which lets you interact with AI models to process text and generate responses.
Node Inputs
Required Fields
- Prompt: Main instruction or question for the AI. It should be clear and detailed to guide the AI to give you the best possible answer.
Optional Fields
- Context: Additional information to help AI effectively respond to the query in the prompt. Context can be referenced in the prompt.
More Options
-
Prompt Template: Structure for combining prompt and context
- Default Template:
- Visible under “More Options” in the node
- Only modify if default structure doesn’t meet your needs
- Contains placeholders
{prompt}
and{context}
- Stays constant across runs unless modified
- Default Template:
-
Choose AI Model: Select the AI model you want to use
-
Temperature: Controls response creativity (0-1). Default temparture is ‘1’
- 0: More focused, consistent
- 1: More creative, varied
-
Maximum Tokens: Limits response length
-
Cache Response: Save responses for reuse
Show As Input Options
You can expose these fields as inputs to the node by clicking on Configure Inputs
:
- Prompt
- Context
- Prompt Template
- Temperature
- Maximum Tokens
Key Concepts
Prompt vs. Prompt Template
-
Prompt:
- Actual question or instruction for the AI
- Required input
- Examples: “Summarize this article”, “Translate to Spanish”
-
Prompt Template:
- Defines structure for combining prompt and context
- Optional parameter
- Uses placeholders
{prompt}
and{context}
- Default template works for most cases
- Modify only for specific formatting needs
Node Output
- Response: AI’s generated answer or output
Node Functionality
The Ask AI node connects to various AI models to:
- Generate text responses
- Process/analyze content
- Answer questions
- Summarize information
- Convert data formats
Available AI Models
- Claude 3.5 Sonnet
- Claude 3 Haiku
- OpenAI o1
- OpenAI o1 mini
- GPT-4o
- GPT-4o Mini
- Gemini 1.5 Pro/Flash
- Azure OpenAI
- And more
Note: Auto-Select uses a third-party model routing service and automatically chooses the appropriate model for cost, performance, and availability. Not ideal if consistent model behavior is needed.
Common Use Cases
- Content Creation:
- Data Analysis:
- Customer Support:
Loop Mode Pattern
- Batch Processing:
Important Considerations
-
Credit Costs:
- Expert models (OpenAI o1): 30 credits
- Advanced models (GPT-4o & Claude 3.5): 20 credits
- Standard models: 2 credits per run
- With API key: 1 credit (configure in credentials page)
-
Function Calling:
- ‘Use Function’ option for structured output
- Only available for OpenAI models
- More details: OpenAI Function Calling Documentation
-
Model Selection:
- Choose specific models for consistent behavior
- Consider task complexity when selecting models
In summary, the Ask AI node is your interface to AI models, helping you automate text processing and generation tasks with customizable control over the output style and format.