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

# update • AI Agent SDK

> update: Update an existing entry.

# update

<div className="flex items-center gap-2">
  <Badge color="purple">Method</Badge>
</div>

> This is a method of the [**LearnProtocol**](../classes/LearnProtocol) class in the [**protocols**](../modules/protocols) module.

Update an existing entry.

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
def update(entry_id: str, content: str, metadata: Optional[Dict[str, Any]]) -> Optional[Dict[str, Any]]
```

## Parameters

<ParamField query="entry_id" type="str" required={true}>
  Entry identifier
</ParamField>

<ParamField query="content" type="str" required={true}>
  New content
</ParamField>

<ParamField query="metadata" type="Optional" required={false}>
  Optional metadata to merge
</ParamField>

### Returns

<ResponseField name="Returns" type="Optional[Dict[str, Any]]">
  Updated entry or None if not found
</ResponseField>

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/memory/learn/protocols.py#L108">
  `praisonaiagents/memory/learn/protocols.py` at line 108
</Card>
