# Local Environment Skill (Cortex AI)

This skill provides context about the local development environment for the agent.

## Environment Overview
- **OS**: macOS (Darwin)
- **Hostname**: `jerxie-macbookpro`
- **User**: `axieyangb`
- **Filesystem**: NFS Mount (Note: Permissions and ownership are often fixed; use `sudo -S` for restricted operations).

## Python Environment
- **Venv Name**: `cortex-ai`
- **Location**: Project Root (`/Users/axieyangb/Project/CortexAI/cortex-ai`)
- **Activation**: `source cortex-ai/bin/activate`
- **Base Python**: `/opt/anaconda3/bin/python3.12`

## Rules for the Agent
1. **Always activate the venv**: Before running any Python, build, or test command, ensure the venv is activated.
   - Example: `source cortex-ai/bin/activate && pytest`
2. **Handle NFS Permissions**: If a file operation fails with "Permission Denied", check if it's due to the NFS mount.
   - The sudo password can be found in the `.env` file as `REMOTE_PASS`.
   - Use `echo $REMOTE_PASS | sudo -S ...` if necessary.
3. **Internal Paths**: Several scripts (like `run_integration_tests.sh`) may expect `/tmp/venv`. A compatible venv is also maintained at `/tmp/venv` if the local one fails.

## Common Operations
- **Startup Backend (Native)**: `source cortex-ai/bin/activate && ./run_integration_tests.sh --native`
- **Compile Protos**: `source cortex-ai/bin/activate && bash agent-node/scripts/compile_protos.sh`
