> ## Documentation Index
> Fetch the complete documentation index at: https://julius.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Learning from User Feedback

> How Julius incorporates your natural language feedback to improve query accuracy

## Overview

When you provide context or corrections during your conversations, Julius can permanently store those insights to improve future interactions. This happens automatically when you include helpful details in your natural language prompts.

## How Feedback Learning Works

As you interact with your data, you naturally provide context that helps Julius understand your schema better. Comments like "the customer\_id field actually refers to our B2B accounts" or "we use 'active' status to mean currently subscribed" contain valuable business logic that isn't captured in your raw schema.

Julius captures this feedback and evaluates whether it should become part of your learned schema knowledge. However, not all feedback makes it into storage—Julius validates the information before committing it.

## The Validation Process

Before storing user-provided information, Julius runs a validation check:

<img src="https://r2.julius.ai/feedback-validation-diagram.png" alt="Feedback Validation Process Diagram" style={{ width: "100%" }} />

**Feedback Captured**: When you provide context in your prompt, Julius notes this as potential schema knowledge.

**Query Execution**: Julius generates and executes the query based on your feedback.

**Result Validation**: If the query succeeds and returns expected results, the feedback is validated.

**Conditional Storage**:

* If the tool call succeeds: The feedback is stored as learned information
* If the tool call fails or returns errors: The feedback is discarded

This validation step ensures that only accurate information enters your learned knowledge store. If you provide incorrect context—for example, suggesting a column relationship that doesn't exist—Julius won't persist that misinformation.

## Example Scenario

**User prompt**: "Show me sales by region. By the way, the region\_code in our sales table maps to the short\_name field in territories, not the id."

**What happens**:

1. Julius captures the relationship hint: `sales.region_code` → `territories.short_name`
2. Julius generates a query using this relationship
3. If the query executes successfully → The relationship is stored
4. If the query fails (e.g., join produces no results or errors) → The relationship is not stored

## Best Practices

**Be specific**: "The status field uses 'A' for active and 'I' for inactive" is more helpful than vague descriptions

**Correct in context**: If Julius makes an incorrect assumption, correct it in your next prompt—the correction will be validated and stored

**Trust the validation**: You don't need to worry about accidentally teaching Julius incorrect information
