> ## Documentation Index
> Fetch the complete documentation index at: https://agno-v2-codex-docs-audit-20260719-0149.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Institutional learning

> Share what every review learns so the next one starts from the team's accumulated judgment.

A research team that does not learn re-derives the same conclusions and repeats the same mistakes. The value compounds when an insight from one review is available to every agent on the next. Agno's `LearningMachine` with a shared store and a global namespace puts every agent's learning in one place the whole team reads from.

```python theme={null}
from agno.agent import Agent
from agno.db.postgres import PostgresDb
from agno.learn import LearnedKnowledgeConfig, LearningMachine, LearningMode
from agno.models.openai import OpenAIResponses

# team_learnings is a Knowledge instance backed by a vector database, on its own
# table so learnings stay out of the research library's search results.
from agents.settings import team_learnings

db = PostgresDb(db_url="postgresql+psycopg://ai:ai@localhost:5532/ai")


def institutional_learning() -> LearningMachine:
    return LearningMachine(
        knowledge=team_learnings,
        learned_knowledge=LearnedKnowledgeConfig(
            mode=LearningMode.AGENTIC,
            namespace="global",
        ),
    )


learning_instructions = (
    "Use save_learning to store reusable insights. "
    "Use search_learnings to find prior knowledge before forming a view."
)

analyst = Agent(
    name="Financial Analyst",
    model=OpenAIResponses(id="gpt-5.5"),
    db=db,
    instructions=learning_instructions,
    learning=institutional_learning(),
)

risk_officer = Agent(
    name="Risk Officer",
    model=OpenAIResponses(id="gpt-5.5"),
    db=db,
    instructions=learning_instructions,
    learning=institutional_learning(),
)

# The risk officer captures an insight:
risk_officer.print_response(
    "Save this insight: analyst estimates lag this sector by about a quarter."
)

# Later, a different agent reads it back from the shared store:
analyst.learning_machine.learned_knowledge_store.print(query="estimate lag")
```

The learning is available to every agent and team sharing the store. In Agentic mode, retrieve it with `search_learnings`. The `Knowledge` instance is required. Without it, saves and searches log a warning and do nothing.

## Per-agent vs institutional

|           | User memory                                  | Institutional learning                     |
| --------- | -------------------------------------------- | ------------------------------------------ |
| Scope     | One user across agents sharing the database  | Every agent and team that shares the store |
| Namespace | Scoped by `user_id`                          | `"global"`                                 |
| Effect    | The user's preferences and facts follow them | The committee remembers                    |

For deep research, institutional is the point. The team's judgment should outlive any single review.

## What to capture

| Worth a learning                                 | Not worth a learning                         |
| ------------------------------------------------ | -------------------------------------------- |
| "Analyst estimates lag this sector by a quarter" | A one-off number from a single query         |
| "This data source double-counts renewals"        | A restatement of the mandate                 |
| A correction to a conclusion that was wrong      | A summary of what was already in the library |

Capture corrections and transferable insights. Leave durable facts to the [research library](/use-cases/deep-research/grounding-research) and rules to the static context.

## Modes

| Mode      | Behavior                                                                       | Use for                                           |
| --------- | ------------------------------------------------------------------------------ | ------------------------------------------------- |
| `ALWAYS`  | Start extraction from the current input on every run                           | Steady accumulation of observations               |
| `AGENTIC` | The agent decides what is worth keeping                                        | Research, where signal-to-noise matters           |
| `PROPOSE` | The model proposes a learning and asks before saving; approval is prompt-based | Low-risk review where soft approval is sufficient |

This is the same machine the [data agent uses to self-correct](/use-cases/data-agents/self-correcting-agents), pointed at a shared store instead of a per-warehouse one.

## Next steps

| Task                               | Guide                                                                     |
| ---------------------------------- | ------------------------------------------------------------------------- |
| Feed it grounded context too       | [Grounding research](/use-cases/deep-research/grounding-research)         |
| Audit what changed the team's mind | [Structured deliverable](/use-cases/deep-research/structured-deliverable) |

## Developer Resources

* [Learning Machines](/learning/overview)
* [Learning modes](/learning/learning-modes)
* [Learned knowledge cookbook](https://github.com/agno-agi/agno/tree/v2.7.4/cookbook/08_learning/05_learned_knowledge)
