mirror of
https://github.com/langchain-ai/docs.git
synced 2026-08-27 02:41:59 -04:00
18 lines
333 B
Plaintext
18 lines
333 B
Plaintext
```python
|
|
from deepagents import FilesystemPermission, create_deep_agent
|
|
|
|
|
|
# Read-only agent: deny all writes
|
|
agent = create_deep_agent(
|
|
model=model,
|
|
backend=backend,
|
|
permissions=[
|
|
FilesystemPermission(
|
|
operations=["write"],
|
|
paths=["/**"],
|
|
mode="deny",
|
|
),
|
|
],
|
|
)
|
|
```
|