Update README.md

This commit is contained in:
Charles Packer
2025-10-26 00:17:42 -07:00
committed by GitHub
parent 9112f3fcbc
commit e602abf919

View File

@@ -92,6 +92,30 @@ letta -p "run tests" --tools "Bash,Read" # Only load specific tools
letta -p "analyze code" --tools "" # No tools (analysis only) letta -p "analyze code" --tools "" # No tools (analysis only)
``` ```
Use `--output-format json` to get additional information, including the agent ID ("session_id"):
```bash
# regular text output
$ letta -p "hi there"
Hi! How can I help you today?
# structured output
$ letta -p "hi there" --output-format json
{
"type": "result",
"subtype": "success",
"is_error": false,
"duration_ms": 5454,
"duration_api_ms": 2098,
"num_turns": 1,
"result": "Hi! How can I help you today?",
"session_id": "agent-8ab431ca-63e0-4ca1-ba83-b64d66d95a0f",
"usage": {
"input_tokens": 294,
"output_tokens": 97
}
}
```
### Permissions ### Permissions
**Tool selection** (controls which tools are loaded): **Tool selection** (controls which tools are loaded):