Files
ha-text-ai/custom_components/ha_text_ai/services.yaml
T

205 lines
6.9 KiB
YAML
Raw Normal View History

2024-11-18 01:36:58 +03:00
ask_question:
name: Ask Question
2024-11-19 14:00:33 +03:00
description: >-
Send a question to the AI model and receive a detailed response.
The response will be stored in the conversation history and can be retrieved later.
2024-11-19 14:35:45 +03:00
Response time may vary based on model selection and server load.
2024-11-20 01:02:27 +03:00
Supports various AI models with different capabilities and pricing.
2024-11-14 18:35:50 +03:00
fields:
2024-11-18 01:36:58 +03:00
question:
name: Question
2024-11-19 14:00:33 +03:00
description: >-
Your question or prompt for the AI assistant. Be specific and clear for better results.
You can ask about home automation, technical advice, or general questions.
2024-11-19 14:35:45 +03:00
For complex queries, consider breaking them into smaller parts.
2024-11-20 01:02:27 +03:00
The system will maintain conversation context for follow-up questions.
2024-11-14 18:35:50 +03:00
required: true
2024-11-19 14:00:33 +03:00
example: |
What automations would you recommend for a smart kitchen?
2024-11-19 14:35:45 +03:00
Consider energy efficiency, convenience, and integration with:
- Smart lighting
- Appliance control
- Temperature monitoring
- Voice commands
2024-11-14 18:35:50 +03:00
selector:
text:
multiline: true
2024-11-19 14:00:33 +03:00
type: text
2024-11-18 01:36:58 +03:00
2024-11-14 18:35:50 +03:00
model:
name: Model
2024-11-19 14:00:33 +03:00
description: >-
Select an AI model to use (optional, overrides default setting).
2024-11-20 01:02:27 +03:00
Different models have different capabilities, context limits, and response characteristics:
- GPT-3.5 Turbo: Fast, efficient, good for most tasks
- GPT-4: More capable, better reasoning, slower
- Claude-3: Advanced capabilities, longer context
2024-11-19 14:35:45 +03:00
Note: More capable models may have longer response times and higher API costs.
2024-11-14 18:35:50 +03:00
required: false
2024-11-19 12:45:26 +03:00
example: "gpt-3.5-turbo"
2024-11-18 01:36:58 +03:00
default: "gpt-3.5-turbo"
2024-11-14 18:35:50 +03:00
selector:
2024-11-18 01:36:58 +03:00
select:
2024-11-19 18:53:51 +03:00
custom_value: true
2024-11-18 01:36:58 +03:00
options:
2024-11-19 14:00:33 +03:00
- label: "GPT-3.5 Turbo (Fast & Efficient)"
2024-11-19 12:45:26 +03:00
value: "gpt-3.5-turbo"
2024-11-19 14:35:45 +03:00
- label: "GPT-3.5 Turbo 16K (Extended)"
value: "gpt-3.5-turbo-16k"
2024-11-19 14:00:33 +03:00
- label: "GPT-4 (Most Capable)"
2024-11-19 12:45:26 +03:00
value: "gpt-4"
2024-11-19 14:00:33 +03:00
- label: "GPT-4 32K (Extended Context)"
2024-11-19 12:45:26 +03:00
value: "gpt-4-32k"
2024-11-19 14:35:45 +03:00
- label: "GPT-4 Turbo (Latest)"
value: "gpt-4-1106-preview"
2024-11-20 01:02:27 +03:00
- label: "Claude-3 Sonnet (Balanced)"
2024-11-19 18:53:51 +03:00
value: "claude-3-sonnet"
2024-11-20 01:02:27 +03:00
- label: "Claude-3 Opus (Most Advanced)"
value: "claude-3-opus"
2024-11-19 14:00:33 +03:00
mode: dropdown
2024-11-18 01:36:58 +03:00
2024-11-14 18:35:50 +03:00
temperature:
name: Temperature
2024-11-19 14:00:33 +03:00
description: >-
2024-11-20 01:02:27 +03:00
Controls response creativity (0.0-2.0):
2024-11-19 14:35:45 +03:00
0.0-0.3: Focused, consistent responses (best for technical/factual queries)
0.4-0.7: Balanced responses (recommended for most uses)
0.8-2.0: More creative, varied responses (best for brainstorming)
Note: Higher values may produce less predictable results.
2024-11-14 18:35:50 +03:00
required: false
default: 0.7
selector:
number:
2024-11-18 01:36:58 +03:00
min: 0.0
2024-11-19 12:45:26 +03:00
max: 2.0
2024-11-14 18:35:50 +03:00
step: 0.1
2024-11-19 12:45:26 +03:00
mode: slider
2024-11-19 14:00:33 +03:00
unit_of_measurement: ""
2024-11-18 01:36:58 +03:00
2024-11-14 18:35:50 +03:00
max_tokens:
name: Max Tokens
2024-11-19 14:00:33 +03:00
description: >-
2024-11-20 01:02:27 +03:00
Maximum length of the response (1-4096 tokens).
2024-11-19 14:00:33 +03:00
Recommended ranges:
2024-11-20 01:02:27 +03:00
- Short (256-512): Quick answers, status updates
- Medium (512-1024): Detailed explanations
- Long (1024-4096): Complex analysis
Note: Token limits vary by model. Actual length may be shorter.
2024-11-14 18:35:50 +03:00
required: false
2024-11-18 01:36:58 +03:00
default: 1000
2024-11-14 18:35:50 +03:00
selector:
number:
min: 1
2024-11-19 12:45:26 +03:00
max: 4096
2024-11-18 01:36:58 +03:00
step: 1
2024-11-19 12:45:26 +03:00
mode: box
2024-11-18 01:36:58 +03:00
2024-11-19 18:53:51 +03:00
system_prompt:
name: System Prompt
description: >-
Optional system prompt to set context for this specific question.
This will temporarily override the default system prompt.
2024-11-20 01:02:27 +03:00
Use this to specify expertise areas, response format, or special instructions.
2024-11-19 18:53:51 +03:00
required: false
2024-11-20 01:02:27 +03:00
example: "You are a home automation expert focused on energy efficiency and security"
2024-11-19 18:53:51 +03:00
selector:
text:
multiline: true
2024-11-18 01:36:58 +03:00
clear_history:
name: Clear History
2024-11-19 14:00:33 +03:00
description: >-
Delete all stored questions and responses from the conversation history.
2024-11-19 14:35:45 +03:00
This action cannot be undone. Consider using 'get_history' first if you need to backup the data.
2024-11-20 01:02:27 +03:00
System prompt settings and configuration will be preserved.
2024-11-18 01:36:58 +03:00
fields: {}
get_history:
name: Get History
2024-11-19 14:00:33 +03:00
description: >-
2024-11-20 01:02:27 +03:00
Retrieve recent conversation history, including:
- Questions and responses
- Timestamps and response times
- Models used and token counts
- Temperature and other settings
Results are ordered from newest to oldest.
2024-11-18 01:36:58 +03:00
fields:
limit:
name: Limit
2024-11-19 14:00:33 +03:00
description: >-
2024-11-19 14:35:45 +03:00
Number of most recent conversations to return (1-100).
2024-11-19 14:00:33 +03:00
Higher values return more history but may take longer to process.
2024-11-19 14:35:45 +03:00
Default: 10 conversations
2024-11-14 18:35:50 +03:00
required: false
2024-11-18 01:36:58 +03:00
default: 10
2024-11-14 18:35:50 +03:00
selector:
number:
2024-11-18 01:36:58 +03:00
min: 1
max: 100
step: 1
2024-11-19 12:45:26 +03:00
mode: box
2024-11-18 01:36:58 +03:00
2024-11-19 14:35:45 +03:00
filter_model:
name: Filter by Model
description: >-
Only return conversations using a specific AI model.
Leave empty to show all models.
required: false
selector:
select:
2024-11-19 18:53:51 +03:00
custom_value: true
2024-11-19 14:35:45 +03:00
options:
- label: "All Models"
value: ""
- label: "GPT-3.5 Turbo"
value: "gpt-3.5-turbo"
- label: "GPT-4"
value: "gpt-4"
2024-11-20 01:02:27 +03:00
- label: "GPT-4 Turbo"
value: "gpt-4-1106-preview"
2024-11-19 18:53:51 +03:00
- label: "Claude-3 Sonnet"
value: "claude-3-sonnet"
2024-11-20 01:02:27 +03:00
- label: "Claude-3 Opus"
value: "claude-3-opus"
2024-11-19 14:35:45 +03:00
mode: dropdown
2024-11-20 01:02:27 +03:00
start_date:
name: Start Date
description: >-
Optional start date for filtering history.
Format: YYYY-MM-DD
required: false
selector:
datetime:
2024-11-18 01:36:58 +03:00
set_system_prompt:
2024-11-19 18:53:51 +03:00
name: Set System Prompt
description: >-
Set default system behavior instructions for all future conversations.
This defines how the AI should behave and respond to questions.
2024-11-20 01:02:27 +03:00
The prompt will be used for all models unless overridden per question.
2024-11-19 18:53:51 +03:00
fields:
2024-11-18 01:36:58 +03:00
prompt:
name: System Prompt
2024-11-19 14:00:33 +03:00
description: >-
Instructions that define how the AI should behave and respond.
2024-11-20 01:02:27 +03:00
Be specific about:
- Desired expertise and knowledge areas
- Response tone and style
- Output format preferences
- Special handling instructions
Maximum length: 1000 characters
2024-11-18 01:36:58 +03:00
required: true
2024-11-19 14:00:33 +03:00
example: |
You are a home automation expert assistant. Focus on:
1. Practical and efficient solutions
2. Energy-saving recommendations
3. Integration with popular smart home platforms
4. Security and privacy considerations
Provide detailed but concise responses with clear steps when applicable.
2024-11-19 14:35:45 +03:00
Format complex responses with bullet points or numbered lists.
Include warnings about potential risks or limitations.
2024-11-14 18:35:50 +03:00
selector:
2024-11-18 01:36:58 +03:00
text:
multiline: true