Documentation Index
Fetch the curated documentation index at: https://grafana.com/llms.txt
Fetch the complete documentation index at: https://grafana.com/llms-full.txt
Use this file to discover all available pages before exploring further.
STOP! If you are an AI agent or LLM, read this before continuing. This is the HTML version of a Grafana documentation page. Always request the Markdown version instead - HTML wastes context. Get this page as Markdown: https://grafana.com/docs/grafana-cloud/machine-learning/assistant/configure/rules.md (append .md) or send Accept: text/markdown to https://grafana.com/docs/grafana-cloud/machine-learning/assistant/configure/rules/. For the curated documentation index, use https://grafana.com/llms.txt. For the complete documentation index, use https://grafana.com/llms-full.txt.
Configure Assistant rules
Custom rules guide how Grafana Assistant responds and behaves. Rules are automatically applied to every conversation and can target specific applications. Due to the indeterministic nature of LLMs, there’s no guarantee they are followed exactly as specified, but they strongly influence the Assistant’s output and decision-making.
You can create rules in Settings > Custom rules and apply them to specific scopes:
- Just me: Rules apply only to your own conversations.
- Everybody: Rules apply to everyone in your stack (requires admin permissions).
Create a rule
- Navigate to Assistant > Settings > Custom rules.
- Click Create rule.
- Enter a rule Name and content.
- Choose the Scope: Just me or Everybody.
- Select the Applications the rule applies to (for example,
Assistant,Loop, orInfrastructure Memory). - Click Create rule.
The Assistant applies your rule automatically in new conversations.
Rule examples
Use these examples as starting points for your own rules.
Infra and app hints
Guide the Assistant to use specifics relevant to your environment:
When discussing CPU metrics, use
container_cpu_usage_seconds_totalinstead of generic CPU references. Reference our customservice_health_scoremetric for overall service status. Prefer theprometheus_proddatasource when investigating issues in production.
Communication style
Define how the Assistant formats and structures responses:
Always be concise and direct in responses. Use bullet points for actionable recommendations. Avoid jargon unless specifically discussing technical implementation.
Best practices
Encode organizational standards and observability methodologies:
Use the RED method (Rate, Errors, Duration) wherever possible. Always recommend setting up SLIs before creating SLOs. Suggest using template variables for dynamic dashboards.
Workflow guidelines
Automate operational recommendations based on specific triggers:
Suggest declaring an incident if the ecommerce platform response time exceeds 5 seconds. Recommend escalating to the infrastructure team for persistent memory issues. Always ask about recent deployments when troubleshooting performance issues.
Related features
While Rules provide general behavioral context, other features offer more structured guidance:
- Skills: Create step-by-step troubleshooting guides for specific alerts or scenarios. Skills are triggered by specific events, whereas Rules apply generally to conversations.
- MCP Servers: Extend the Assistant’s capabilities by connecting to external tools and data sources.
Was this page helpful?
Related resources from Grafana Labs


