> ## 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.

# workspace • AI Agent SDK

> Workspace management for PraisonAI agents.

# workspace

AI Agent

Workspace management for PraisonAI agents.

This module provides workspace isolation and security for agent operations,
particularly for bots and gateways that need to scope file operations to
specific directories.

## Import

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
from praisonaiagents import workspace
```

## Classes

> [card] [Workspace](https://praison.ai/docs/sdk/reference/praisonaiagents/classes/Workspace.md)
>
> Workspace configuration for agent operations.

## Functions

> [card] [validate\_within\_dir()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/validate_within_dir.md)
>
> Validate that a path is contained within an allowed root directory.

> [card] [has\_traversal\_component()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/has_traversal_component.md)
>
> Check if a path contains directory traversal components.

### Constants

| Name | Value |
| - | - |
| `_LAZY_ISOLATION` | `{'WorkspaceIsolationProtocol': ('protocols', 'WorkspaceIsolationProtocol'), 'NoIsolationAdapter': ('adapters', 'NoIsolationAdapter'), 'GitWorktreeAdapter': ('adapters', 'GitWorktreeAdapter')}` |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.