Skip to content

Instantly share code, notes, and snippets.

@AhmadYasin2
Created August 15, 2026 02:06
Show Gist options
  • Select an option

  • Save AhmadYasin2/0659867b469cee3c50b9c515d3604277 to your computer and use it in GitHub Desktop.

Select an option

Save AhmadYasin2/0659867b469cee3c50b9c515d3604277 to your computer and use it in GitHub Desktop.
Repository Wiki — generated by GitNexus
This file has been truncated, but you can view the full file.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Harakat — Wiki</title>
<script src="https://cdn.jsdelivr.net/npm/marked@11.0.0/marked.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/mermaid@11/dist/mermaid.min.js"></script>
<style>
*{margin:0;padding:0;box-sizing:border-box}
:root{
--bg:#ffffff;--sidebar-bg:#f8f9fb;--border:#e5e7eb;
--text:#1e293b;--text-muted:#64748b;--primary:#2563eb;
--primary-soft:#eff6ff;--hover:#f1f5f9;--code-bg:#f1f5f9;
--radius:8px;--shadow:0 1px 3px rgba(0,0,0,.08);
}
body{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;
line-height:1.65;color:var(--text);background:var(--bg)}
.layout{display:flex;min-height:100vh}
.sidebar{width:280px;background:var(--sidebar-bg);border-right:1px solid var(--border);
position:fixed;top:0;left:0;bottom:0;overflow-y:auto;padding:24px 16px;
display:flex;flex-direction:column;z-index:10}
.content{margin-left:280px;flex:1;padding:48px 64px;max-width:960px}
.sidebar-header{margin-bottom:20px;padding-bottom:16px;border-bottom:1px solid var(--border)}
.sidebar-title{font-size:16px;font-weight:700;color:var(--text);display:flex;align-items:center;gap:8px}
.sidebar-title svg{flex-shrink:0}
.sidebar-meta{font-size:11px;color:var(--text-muted);margin-top:6px}
.nav-section{margin-bottom:2px}
.nav-item{display:block;padding:7px 12px;border-radius:var(--radius);cursor:pointer;
font-size:13px;color:var(--text);text-decoration:none;transition:all .15s;
white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.nav-item:hover{background:var(--hover)}
.nav-item.active{background:var(--primary-soft);color:var(--primary);font-weight:600}
.nav-item.overview{font-weight:600;margin-bottom:4px}
.nav-children{padding-left:14px;border-left:1px solid var(--border);margin-left:12px}
.nav-group-label{font-size:11px;font-weight:600;color:var(--text-muted);
text-transform:uppercase;letter-spacing:.5px;padding:12px 12px 4px;user-select:none}
.sidebar-footer{margin-top:auto;padding-top:16px;border-top:1px solid var(--border);
font-size:11px;color:var(--text-muted);text-align:center}
.content h1{font-size:28px;font-weight:700;margin-bottom:8px;line-height:1.3}
.content h2{font-size:22px;font-weight:600;margin:32px 0 12px;padding-bottom:6px;border-bottom:1px solid var(--border)}
.content h3{font-size:17px;font-weight:600;margin:24px 0 8px}
.content h4{font-size:15px;font-weight:600;margin:20px 0 6px}
.content p{margin:12px 0}
.content ul,.content ol{margin:12px 0 12px 24px}
.content li{margin:4px 0}
.content a{color:var(--primary);text-decoration:none}
.content a:hover{text-decoration:underline}
.content blockquote{border-left:3px solid var(--primary);padding:8px 16px;margin:16px 0;
background:var(--primary-soft);border-radius:0 var(--radius) var(--radius) 0;
color:var(--text-muted);font-size:14px}
.content code{font-family:'SF Mono',Consolas,'Courier New',monospace;font-size:13px;
background:var(--code-bg);padding:2px 6px;border-radius:4px}
.content pre{background:#1e293b;color:#e2e8f0;border-radius:var(--radius);padding:16px;
overflow-x:auto;margin:16px 0}
.content pre code{background:none;padding:0;font-size:13px;line-height:1.6;color:inherit}
.content table{border-collapse:collapse;width:100%;margin:16px 0}
.content th,.content td{border:1px solid var(--border);padding:8px 12px;text-align:left;font-size:14px}
.content th{background:var(--sidebar-bg);font-weight:600}
.content img{max-width:100%;border-radius:var(--radius)}
.content hr{border:none;border-top:1px solid var(--border);margin:32px 0}
.content .mermaid{margin:20px 0;text-align:center}
.menu-toggle{display:none;position:fixed;top:12px;left:12px;z-index:20;
background:var(--bg);border:1px solid var(--border);border-radius:var(--radius);
padding:8px 12px;cursor:pointer;font-size:18px;box-shadow:var(--shadow)}
@media(max-width:768px){
.sidebar{transform:translateX(-100%);transition:transform .2s}
.sidebar.open{transform:translateX(0);box-shadow:2px 0 12px rgba(0,0,0,.1)}
.content{margin-left:0;padding:24px 20px;padding-top:56px}
.menu-toggle{display:block}
}
.empty-state{text-align:center;padding:80px 20px;color:var(--text-muted)}
.empty-state h2{font-size:20px;margin-bottom:8px;border:none}
</style>
</head>
<body>
<button class="menu-toggle" id="menu-toggle" aria-label="Toggle menu">&#9776;</button>
<div class="layout">
<nav class="sidebar" id="sidebar">
<div class="sidebar-header">
<div class="sidebar-title">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M2 3h6a4 4 0 014 4v14a3 3 0 00-3-3H2z"/><path d="M22 3h-6a4 4 0 00-4 4v14a3 3 0 013-3h7z"/></svg>
Harakat
</div>
<div class="sidebar-meta" id="meta-info"></div>
</div>
<div id="nav-tree"></div>
<div class="sidebar-footer">Generated by GitNexus</div>
</nav>
<main class="content" id="content">
<div class="empty-state"><h2>Loading…</h2></div>
</main>
</div>
<script>
var PAGES = {"deploy-inference":"# deploy — inference\n\n\n\n# deploy/inference — Inference Deployment Module\n\n## Overview\n\nThe `deploy/inference` module provides the infrastructure for running vLLM-based inference services on GPU workstations. It handles provisioning, configuration, and operational management of Qwen3.6-35B-A3B-FP8 multimodal models for document processing pipelines.\n\nThe module consists of:\n- **Provisioning scripts** (`provision.sh`) — Initial box setup and vLLM server launch\n- **Box management scripts** (`box-up.sh`) — Runtime configuration and OCR cleanup\n- **Performance benchmarks** — Throughput measurements and capacity planning\n- **Pipeline integration** — Connection to the v2 document processing system\n\n## Architecture\n\n```mermaid\ngraph TB\n A[Pipeline V2] -->|document requests| B[Inference Client]\n B -->|HTTP 8000+N| C[vLLM Shards]\n C -->|GPU| D[RTX PRO 6000]\n D -->|VRAM| E[Qwen3.6-35B-A3B-FP8]\n F[provision.sh] -->|setup| C\n G[box-up.sh] -->|runtime config| C\n H[ensure.sh] -->|health check| C\n I[status.sh] -->|monitoring| C\n```\n\n## Key Components\n\n### 1. Provisioning (`provision.sh`)\n\n**Purpose:** Blank box → N vLLM servers in one command.\n\n**Key behaviors:**\n- Installs vLLM via `uv` into `/venv/vllm` (faster than pip)\n- Downloads FP8 checkpoint to `/workspace/huggingface-cache`\n- Launches ONE server per GPU with isolated ports (8000+N)\n- Writes process-control scripts to `/workspace`\n\n**Critical flags:**\n```bash\n--max-model-len 69632\n--gpu-memory-utilization 0.90\n--max-num-seqs 64\n--max-num-batched-tokens 32768\n--enable-chunked-prefill\n--limit-mm-per-prompt '{\"image\": 4}'\n```\n\n**Process control scripts generated:**\n- `launch-shard.sh` — Individual shard launcher\n- `status.sh` — Health monitoring\n- `ensure.sh` — Auto-restart dead shards\n- `stop.sh` — Clean shutdown\n\n**Warning:** Never use `--language-model-only` — this hides the vision tower and breaks multimodal inference.\n\n### 2. Box Management (`box-up.sh`)\n\n**Purpose:** Runtime configuration after the owner starts the box.\n\n**Key operations:**\n1. **Clears OCR from VRAM** — Kills `DeepSeek-OCR` and `glm-ocr` processes\n2. **Launches Qwen vision** — Full multimodal model (not `--language-model-only`)\n3. **Falls back** — Tries JSON form of `--limit-mm-per-prompt`, then key=value\n\n**Port note:** Uses `127.0.0.1:18010` for the tunnel, not 18000 (which is the F2LLM query embedder).\n\n### 3. Process Control Scripts\n\n**`status.sh`** — Ground truth for client feeding:\n```bash\n# Reads from each server's log file\n# GPU-% is worthless (reads 100% while starving at 1 request)\n# Running: N reqs is the actual metric\n```\n\n**`ensure.sh`** — Relaunches dead shards:\n```bash\n# Checks HTTP /v1/models endpoint\n# Relaunches by bare path, not pattern (pkill -f matches the script itself)\n# Run from cron every 2 minutes\n```\n\n**`stop.sh`** — Clean shutdown:\n```bash\n# Kills by PID file first\n# Then kills EngineCore children (VLLM::EngineCore pattern doesn't match)\n# Uses nvidia-smi to find PIDs holding VRAM\n```\n\n## Configuration of Record\n\n**Server flags** (`/workspace/vllm.flags.BEST`):\n```bash\nvllm serve Qwen/Qwen3.6-35B-A3B-FP8 \\\n --host 127.0.0.1 --port 8000 \\\n --reasoning-parser qwen3 \\\n --max-model-len 69632 \\\n --gpu-memory-utilization 0.90 \\\n --max-num-seqs 512 \\\n --max-num-batched-tokens 8192 \\\n --enable-chunked-prefill \\\n --kv-cache-dtype fp8 \\\n --limit-mm-per-prompt '{\"image\":4}' \\\n --api-server-count 4\n```\n\n**Not set (with reasons):**\n- `--enable-prefix-caching` — Measured worthless (only ~50-token shared prefix)\n- `--mm-processor-cache-gb > 0` — Every page is distinct in production\n- Higher `--gpu-memory-utilization` — KV reaches 100% at ceiling; tradeoff is 6% throughput for 1.7× latency\n\n## Performance Characteristics\n\n### Single Card Ceiling (RTX PRO 6000 Blackwell)\n\n| Workload | total tok/s | pages/min | cards/min | KV max |\n|----------|-------------|-----------|-----------|--------|\n| page only | 5,607.5 | 99.0 | — | 0.835 |\n| mixed (1 card/5 pages) | 6,022.8 | 65.8 | 12.5 | 0.872 |\n| card only | 8,175.7 | — | 49.0 | 0.873 |\n\n**Operating point:** 5,607 tok/s at 384 offered concurrency, no preemption, KV at 83%\n\n**Peak:** 5,960 tok/s at 768 offered, KV at 100%, preemptions active\n\n### Throughput vs. Concurrency\n\n| offered | total tok/s | running | queued | limiter |\n|---------|-------------|---------|--------|---------|\n| 256 | 5,330 | 147.9 | 1.2 | front-end |\n| 384 | 5,607.5 | 218.8 | 5.0 | KV queue forming |\n| 512 | 5,608.9 | 278.6 | 17.5 | preemption |\n| 768 | 5,959.7 | 315.5 | 151.1 | preemption |\n\n**Two caps:**\n1. **API server pinned at ~1 core** — Single process limits request intake\n2. **`--max-num-seqs`** — Engine stops accepting when this is hit\n\n**Solution:** `--api-server-count 4` + `--max-num-seqs 512` + multi-process driver\n\n### Reasoning ON vs OFF\n\n| Setting | total tok/s | pages/min | cards/min | p50 |\n|---------|-------------|-----------|-----------|-----|\n| OFF | 6,022.8 | 65.8 | 12.5 | 226s |\n| ON | 4,409.8 | 34.1 | 6.82 | 315s |\n\n**Ratio:** 1.37× throughput, 1.93× pages/min, 1.84× cards/min\n\n**Quality:** Identical identifiers on 50 samples (0 lost in either setting)\n\n## Pipeline Integration\n\n### Document Processing Flow\n\n```mermaid\ngraph LR\n A[Document] -->|Lane 2/3| B[GPU Inference]\n B -->|card| C[Harakat_AI POST /parse/card]\n B -->|page| D[HarakatOffices_Server readDocumentV2]\n C -->|503| E[Retryable - host off]\n C -->|422| F[Stop re-queueing]\n D -->|store.ts rules| G[corpus-v2/reading.ts]\n G -->|unavailable ≠ failed| H[search-index queue]\n```\n\n### Lane Selection\n\n| Lane | Selection | count |\n|------|-----------|-------|\n| 3 — file types | `ext:xlsx,xls,tif,heic,zip,rar,doc,msg` | 2,654 |\n| 2 — Arabic re-read | `arabic:50` (≥50 Arabic chars, no Arabic in card) | 1,351 |\n| 1 — pageless | `by_type_handler` ⊂ lane 3 | 103 |\n\n**Lane 4 (DWG)** — Out of scope by owner instruction\n\n### Type Prep Converter\n\n**Supported formats:** `xlsx xls tif heic zip rar doc msg`\n\n**Key changes from v1:**\n- `openpyxl` instead of `pandas` (60 MB reduction)\n- `lsar` instead of `unrar`\n- Page attribution as member\n- LibreOffice per-call profile (single-instance lock)\n\n**Not supported:** `mpp` — No converter exists\n\n## Operational Procedures\n\n### Starting a New Box\n\n```bash\n# 1. Provision the box\nbash deploy/inference/provision.sh <instance_id>\n\n# 2. Set up the tunnel\nbash scripts/inference-tunnel.sh up <instance_id>\n\n# 3. Preflight checks\nbash scripts/pipeline-v2/preflight.sh --box\n\n# 4. Keep shards alive (cron every 2 min)\nssh -p <port> root@<ip> 'nohup bash -c \"while true; do bash /workspace/ensure.sh; sleep 120; done\" >/workspace/ensure.log 2>&1 &'\n```\n\n### Monitoring\n\n```bash\n# Check shard status\nbash /workspace/status.sh\n\n# Check GPU memory\nnvidia-smi --query-gpu=index,memory.used,memory.total,utilization.gpu --format=csv,noheader\n\n# Check vLLM health\ncurl -s http://127.0.0.1:8000/v1/models\n```\n\n### Stopping\n\n```bash\n# Clean shutdown\nbash /workspace/stop.sh\n```\n\n## Troubleshooting\n\n### Shard won't start\n\n**Symptoms:** `shard N DID NOT COME UP` in provision output\n\n**Check:**\n```bash\ntail -20 /workspace/shardN.log | grep -vE \"warnings.warn|softmax\"\n```\n\n**Common causes:**\n- VRAM contention during sequential launch (wait 15s between shards)\n- `--limit-mm-per-prompt` flag drift (JSON vs key=value fallback)\n- EngineCore child holding VRAM after API server kill\n\n### Dead shard\n\n**Symptoms:** `Running: 0 reqs` in status output\n\n**Fix:** `bash /workspace/ensure.sh` or manual relaunch\n\n### Client underfeeding\n\n**Symptoms:** Server running < 150 reqs at 256 offered\n\n**Diagnosis:**\n```bash\n# Check API server cores\n# APIServer cores busy: 1.06 (452 threads, one process)\n# EngineCore cores busy: 4.05\n```\n\n**Solution:** Increase `--api-server-count` and `--max-num-seqs`\n\n### KV cache not filling\n\n**Symptoms:** KV max < 80% at high concurrency\n\n**Cause:** `--max-num-seqs` too low\n\n**Fix:** Raise to 512+ (measured ceiling at 768)\n\n## Cost Estimates\n\n**Single card:**\n- ~$1.04/hr\n- ~5,710 pages per dollar\n- ~99 pages/min at operating point\n\n**Lane 2+3 (3,649 documents):**\n- ~5.3 hours with reasoning OFF\n- ~11.2 hours with reasoning ON\n- ~$5.50–$6.03 total\n\n**Per-item cost:**\n- One page read: ~3,400 tokens\n- One document card: ~10,000 tokens\n\n## Connection to Other Modules\n\n### `deploy/inference/` → `scripts/pipeline-v2/`\n\n- `preflight.sh --box` validates inference readiness\n- `owedPageReads` / `owedCardBuilds` queues drive GPU work\n- `readDocumentV2` + `buildCardV2` implement store.ts rules\n\n### `deploy/inference/` → `HarakatOffices_Server`\n\n- `POST /parse/card` — Card generation endpoint\n- `core/corpus-v2/reading.ts` — Reading path implementation\n- `corpus-v2:read` — Always-full queues for new documents\n\n### `deploy/inference/` → `type_prep`\n\n- `POST /parse/extract` — Type conversion endpoint\n- `type_prep.py` — File format converters (openpyxl, lsar, LibreOffice)\n\n## Notes\n\n- **No OCR model** — DeepSeek-OCR killed, Qwen-vision is the only reader\n- **No vector embedding** — `enqueueVectorIndex` not in scope (track Z7)\n- **No DWG processing** — Lane 4 out of scope by owner instruction\n- **No manual loading** — Lane output travels the product's own path\n- **No manifest-driven work** — Queues driven by database predicates","deploy-local":"# deploy — local\n\n\n\n# deploy/local\n\n## Overview\n\nThis module defines the canonical local development profile for the Harakat stack. Its primary purpose is to enforce a coherent local environment that prevents services from silently pointing at production infrastructure.\n\nThe recurring hazard identified in the test pipeline (2026-06-30) involved three independent configurations drifting to production. This profile, combined with the boot guard, mitigates this risk by enforcing strict validation at startup.\n\n## Safety Guard Mechanism\n\nThe core safety mechanism relies on the `HARAKAT_LOCAL=1` environment variable. When this variable is set, the server and AI service boot guards refuse to start if specific conditions are met.\n\n### Guard Implementation\n\nTwo distinct guard functions enforce this logic across the stack:\n\n1. **Server Guard**: `assertLocalProfileCoherent`\n * **Location**: `../../HarakatOffices_Server/src/core/config/local-guard.ts`\n * **Behavior**: Refuses to boot if any service URL contains `harakat.tech` or if an environment key is BOM-corrupted.\n2. **AI Guard**: `assert_local_profile_coherent`\n * **Location**: `../../Harakat_AI/core/local_guard.py`\n * **Behavior**: Refuses to boot if any service URL contains `harakat.tech` or if an environment key is BOM-corrupted.\n\n### Validation Logic\n\nWhen `HARAKAT_LOCAL=1` is active, the guards perform the following checks:\n\n1. **URL Validation**: Scans configuration URLs for the production domain `harakat.tech`.\n2. **Encoding Validation**: Detects UTF-8 BOM (Byte Order Mark) prefixes on environment keys. A BOM at the start of an env file corrupts the first key (e.g., `NEXT_PUBLIC_API_URL`), potentially causing silent misconfiguration.\n\nIf either check fails, the service aborts startup with a clear error message. In production, `HARAKAT_LOCAL` is unset, allowing normal booting.\n\n## Environment Configuration\n\nThe following table lists the canonical environment variables required for a valid local profile.\n\n| Service | Key | Local Value | Notes |\n|---|---|---|---|\n| **FE** | `NEXT_PUBLIC_API_URL` | `http://localhost:5000` | |\n| **Server** | `CLIENT_ORIGIN` | `http://localhost:3000` | |\n| **Server** | `STARTUP_PLATFORM_URL` | `http://localhost:3000` | |\n| **Server** | `CUSTOM_EMAIL_REDIRECT_URI` | `http://localhost:3000/oauth-callback` | |\n| **Server** | `WEBAUTHN_ORIGIN` | `http://localhost:3000` | |\n| **Server** | `HARAKAT_LOCAL` | `1` | **Required for guard** |\n| **AI** | `HARAKAT_API_URL` | `http://localhost:5000` | |\n| **AI** | `STARTUP_PLATFORM_URL` | `http://localhost:3000` | |\n| **AI** | `HARAKAT_LOCAL` | `1` | **Required for guard** |\n| **ERP** | `ERP_PER_EMPLOYEE` | `on` | |\n| **ERP** | `ERP_ANCHORING_ENABLED` | `on` | |\n\n### File Hierarchy\n\n* **Production Hosts**: Stored in the prod `.env` file.\n* **Local Overrides**: Stored in submodule-specific `.env.local` files (gitignored).\n* **Secrets**: Real secret values remain in `.env.local` and are not committed.\n* **Canonical Port**: The Frontend canonical port is `:3000` (where `next dev` runs). Earlier values like `:3002` caused mismatches (Gap E) and should not be used.\n\n## Bringup Procedure\n\nFollow this sequence to ensure a consistent local stack.\n\n### 1. Infrastructure & ERP\n\nStart the infrastructure and ERP services using the server's environment file.\n\n```bash\ndocker compose -p harakat -f docker-compose.yml --env-file HarakatOffices_Server/.env up -d\n```\n\n### 2. Odoo Port Verification\n\nEnsure the provisioned Odoo instance serves on port `:8069`. A stray `erp-erp_odoo-1` stack must be stopped to prevent port squatting with an empty addon-less DB (which causes `Object erp.gateway doesn't exist` errors).\n\n```bash\ndocker stop erp-erp_odoo-1 erp-erp_db-1 2>/dev/null\ndocker compose -p harakat -f docker-compose.yml --env-file HarakatOffices_Server/.env up -d erp\n```\n\n### 3. Server\n\nNavigate to the server directory and start the development server. It loads `.env` then `.env.local`.\n\n```bash\ncd HarakatOffices_Server && pnpm dev\n```\n\n### 4. AI Service\n\nNavigate to the AI directory and run uvicorn. It loads `.env` then `.env.local` with overrides.\n\n```bash\ncd Harakat_AI && <run uvicorn>\n```\n\n### 5. Frontend\n\nNavigate to the frontend directory.\n\n```bash\ncd StartupsPlatform && pnpm dev -p 3000\n```\n*Note: Use a prod build for crawls if required.*\n\n## Known Hazards\n\n### UTF-8 BOM Corruption\n\nA UTF-8 BOM at the top of an environment file corrupts the **first key** (e.g., `NEXT_PUBLIC_API_URL`). This was the root cause of the FE silently pointing at production.\n\n* **Detection**: The guard detects any BOM-prefixed env key.\n* **Prevention**: Always save `.env*` files as **UTF-8 without BOM**.\n\n### Port Conflicts\n\n* **ERP**: Ensure `erp-erp_odoo-1` is stopped before starting the ERP stack to avoid port `:8069` conflicts.\n* **FE**: Ensure `:3000` is free. The `:3002` port was previously used but caused passkey origin mismatches (Gap E).","deploy-nginx":"# deploy — nginx\n\n\n\n# deploy/nginx\n\nThis module contains the Nginx configuration for the `harakat.tech` infrastructure. It acts as a reverse proxy, SSL terminator, and load balancer for multiple internal services. The configuration is modularized to separate global settings, security parameters, and domain-specific routing.\n\n## Overview\n\nThe Nginx configuration manages traffic for four primary domains:\n* `harakat.tech` (Landing Page)\n* `app.harakat.tech` (Startups Platform)\n* `admin.harakat.tech` (Admin Dashboard)\n* `api.harakat.tech` (Backend API)\n\nThe system enforces HTTPS, implements rate limiting, and proxies requests to internal containers (`landing`, `startups`, `admin`, `server`, `ai`).\n\n## Architecture\n\nThe configuration follows a layered approach:\n1. **Global Settings:** Defined in `nginx.conf`.\n2. **Security & Proxy Defaults:** Defined in `ssl-params.conf` and `proxy-params.conf`.\n3. **Domain Routing:** Defined in `conf.d/` (HTTP and HTTPS blocks).\n\n```mermaid\ngraph TD\n Client[Client] -->|HTTPS/HTTP| Nginx[Nginx]\n Nginx -->|Proxy| Landing[landing:3000]\n Nginx -->|Proxy| Startups[startups:3000]\n Nginx -->|Proxy| Admin[admin:3000]\n Nginx -->|Proxy| Server[server:5000]\n Nginx -->|Proxy| AI[ai:8000]\n Nginx -->|Certbot| CertbotDir[/var/www/certbot]\n```\n\n## Configuration Files\n\n### `nginx.conf`\nThe main entry point. It defines global worker processes, logging, compression, and rate limiting zones.\n\n* **Workers:** `worker_processes auto` to utilize all CPU cores.\n* **Logging:** Access and error logs are written to `/var/log/nginx/`.\n* **Compression:** Gzip is enabled for text, JSON, and JS assets.\n* **Rate Limiting:** Two zones are defined:\n * `api`: 30 requests/second (10m memory).\n * `login`: 5 requests/minute (10m memory).\n* **Includes:** Loads all `.conf` files from `/etc/nginx/conf.d/`.\n\n### `00-http.conf`\nTemporary configuration used during SSL certificate issuance. It listens on port 80 and performs two functions:\n1. **Certbot Challenge:** Serves files from `/var/www/certbot` for ACME validation.\n2. **Redirect:** Returns a 301 redirect to the HTTPS version of the same host.\n\n**Domains Covered:**\n* `harakat.tech`\n* `app.harakat.tech`\n* `admin.harakat.tech`\n* `api.harakat.tech`\n\n### `01-https.conf`\nProduction configuration. This file is activated after SSL certificates are obtained. It listens on port 443 with HTTP/2 support.\n\n* **SSL Certificates:** Points to Let's Encrypt paths (`/etc/letsencrypt/live/harakat.tech/`).\n* **Proxying:** Routes traffic to internal services based on `server_name`.\n* **Special Routing (API):**\n * `/api/ai/`: Strips the prefix and proxies to `ai:8000` with a 120s timeout.\n * `/api/(auth|startup-auth)/login`: Rate limited to 5 requests/minute.\n * `/`: General API traffic rate limited to 30 requests/second.\n\n### `proxy-params.conf`\nShared proxy headers and timeouts applied to all proxied requests.\n\n* **Headers:** Sets `Host`, `X-Real-IP`, `X-Forwarded-For`, and `X-Forwarded-Proto` to ensure backend services see the original client details.\n* **Timeouts:** Default `proxy_read_timeout` and `proxy_send_timeout` are set to 60s.\n* **Upgrade:** Supports WebSocket upgrades (`Upgrade` and `Connection` headers).\n\n### `ssl-params.conf`\nShared SSL/TLS hardening settings.\n\n* **Protocols:** Enforces TLSv1.2 and TLSv1.3.\n* **Ciphers:** Restricts to ECDHE ciphers with AES-GCM.\n* **Session Management:** Caches sessions for 10 minutes, disables session tickets.\n* **HSTS:** Adds `Strict-Transport-Security` header with a 1-year max-age.\n* **OCSP Stapling:** Enabled for performance and privacy.\n\n## Service Routing\n\nThe following table maps external domains to internal services.\n\n| Domain | Internal Service | Port | Purpose |\n| :--- | :--- | :--- | :--- |\n| `harakat.tech` | `landing` | 3000 | Landing Page |\n| `app.harakat.tech` | `startups` | 3000 | Startups Platform |\n| `admin.harakat.tech` | `admin` | 3000 | Admin Dashboard |\n| `api.harakat.tech` | `server` | 5000 | Backend API |\n| `api.harakat.tech` | `ai` | 8000 | AI Proxy |\n\n## Security & Performance\n\n### SSL/TLS\nAll traffic is terminated at Nginx. The configuration enforces modern TLS standards:\n* **Protocols:** Only TLSv1.2 and TLSv1.3 are allowed.\n* **Ciphers:** Strong ECDHE ciphers are prioritized.\n* **HSTS:** Prevents downgrade attacks via the `Strict-Transport-Security` header.\n\n### Rate Limiting\nRate limiting is applied at the Nginx level to protect backend services from abuse.\n\n* **Login Endpoints:** `/api/(auth|startup-auth)/login` are limited to 5 requests per minute (`zone=login`).\n* **General API:** All other API routes are limited to 30 requests per second (`zone=api`).\n* **AI Proxy:** The `/api/ai/` route allows 20 requests per second (`zone=api`) but has extended timeouts for heavy computation.\n\n### Security Headers\nGlobal headers are applied to all responses:\n* `X-Content-Type-Options: nosniff`\n* `X-Frame-Options: SAMEORIGIN`\n* `X-XSS-Protection: 1; mode=block`\n* `Referrer-Policy: strict-origin-when-cross-origin`\n\n## Deployment Workflow\n\n### 1. Initial Setup\n1. Ensure `00-http.conf` is active.\n2. Run Certbot to obtain SSL certificates for `harakat.tech` (and subdomains).\n3. Certbot will place challenge files in `/var/www/certbot`.\n\n### 2. SSL Activation\n1. Once certificates are verified, ensure `01-https.conf` is active.\n2. Verify certificate paths in `01-https.conf` match the Let's Encrypt installation location.\n3. Reload Nginx: `nginx -s reload`.\n\n### 3. Maintenance\n* **Certificate Renewal:** Certbot handles renewal automatically. Nginx config paths remain valid.\n* **Service Updates:** If internal service ports change, update `proxy_pass` directives in `01-https.conf`.\n* **Rate Limiting:** Adjust `limit_req_zone` definitions in `nginx.conf` if traffic patterns change.\n\n## Troubleshooting\n\n* **502 Bad Gateway:** Check if the internal service (e.g., `landing:3000`) is running and accessible from the Nginx container/host.\n* **403 Forbidden:** Verify file permissions on `/var/www/certbot` if ACME challenges fail.\n* **SSL Errors:** Check `/var/log/nginx/error.log` for certificate path mismatches or protocol errors.\n* **Rate Limiting:** If legitimate traffic is blocked, increase the `rate` value in `nginx.conf` or adjust `burst` values in `01-https.conf`.","deploy-openbao":"# deploy — openbao\n\n\n\n# deploy/openbao\n\nThis module configures and manages the OpenBao instance used by Harakat for encrypt-at-rest (P1) of the corpus. It consists of a persistent configuration file, a Docker environment setup, and a sidecar script to handle the auto-unsealing process required for single-node deployments.\n\n## Overview\n\nOpenBao is deployed as a single-node instance to provide a persistent Key Management System (KMS). Unlike standard development setups, a production OpenBao instance starts in a **SEALED** state after every restart. This module ensures the instance remains unsealed automatically to allow continuous corpus reads and writes without manual intervention.\n\n## Components\n\nThe module comprises three primary files:\n\n1. **`config.hcl`**: The core OpenBao configuration defining storage, listeners, and lease TTLs.\n2. **`bao.env`**: Docker environment variables used to inject the configuration into the container.\n3. **`auto-unseal.sh`**: A shell script sidecar that monitors the OpenBao status and performs unsealing operations using stored keys.\n\n## Architecture\n\nThe deployment relies on a persistent volume for data storage and a sidecar pattern for lifecycle management.\n\n### Startup Flow\n\nWhen the container starts, OpenBao initializes in a sealed state. The `auto-unseal.sh` script runs concurrently, polling the status and attempting to unseal the instance if necessary.\n\n```mermaid\nsequenceDiagram\n participant Docker as Docker Compose\n participant OpenBao as OpenBao Container\n participant Sidecar as auto-unseal.sh\n participant Keys as /keys/unseal-keys.txt\n\n Docker->>OpenBao: Start Container\n OpenBao->>OpenBao: Initialize Storage\n OpenBao-->>OpenBao: State: SEALED\n Sidecar->>OpenBao: Check Status (bao status)\n OpenBao-->>Sidecar: Exit Code 2 (Sealed)\n Sidecar->>Keys: Read Unseal Keys\n Sidecar->>OpenBao: Unseal Key (bao operator unseal)\n OpenBao-->>OpenBao: State: UNSEALED\n Sidecar->>OpenBao: Verify Status\n OpenBao-->>Sidecar: Exit Code 0 (Unsealed)\n Sidecar->>Sidecar: Exit Loop\n```\n\n## Configuration Details\n\n### `config.hcl`\n\nThis file defines the operational parameters for the OpenBao instance.\n\n* **Storage**: Uses file-based storage at `/openbao/data`. This path is mounted via a Docker named volume to persist data across container restarts.\n* **Listener**: Binds to `0.0.0.0:8200`. TLS is disabled (`tls_disable = true`) for internal communication.\n* **Lease TTLs**:\n * `default_lease_ttl`: 168 hours (7 days).\n * `max_lease_ttl`: 720 hours (30 days).\n* **UI**: Disabled (`ui = false`) to reduce the attack surface.\n\n### `bao.env`\n\nThis file provides the configuration to the Docker container via environment variables.\n\n* `BAO_LOCAL_CONFIG`: A JSON string containing the configuration from `config.hcl`. This avoids the need to mount the HCL file directly in some Docker setups, though the source code indicates `config.hcl` is also mounted.\n* **Note**: The `config.hcl` file takes precedence or is used alongside this depending on the specific Docker entrypoint configuration in the parent `docker-compose.yml`.\n\n### `auto-unseal.sh`\n\nThis script runs as a sidecar process. It implements a polling loop to manage the unsealing state.\n\n* **Status Check**: Uses `bao status -address=\"$ADDR\"`.\n * Exit code `0`: Instance is unsealed.\n * Exit code `2`: Instance is sealed.\n * Other: Instance is unreachable.\n* **Unseal Logic**:\n * If sealed (code `2`) and the keys file exists, it iterates through `/keys/unseal-keys.txt`.\n * It calls `bao operator unseal` for each key until the status returns to unsealed.\n * It uses `|| true` to prevent a single failed key from stopping the loop, allowing it to try subsequent keys.\n* **Polling Interval**: Sleeps for 10 seconds between checks.\n\n## Key Files and Secrets\n\n### Unseal Keys\n\n* **Location**: `/keys/unseal-keys.txt` (mounted from `deploy/openbao/unseal-keys.local.txt`).\n* **Format**: One key per line.\n* **Management**: This file is **gitignored**. It must be backed up externally. Losing these keys orphans the corpus data, as the OpenBao instance cannot be unsealed without them.\n\n## Security Considerations\n\n### Local Key Storage\nThe unseal keys are stored on the host machine in `deploy/openbao/unseal-keys.local.txt`.\n* **Risk**: Any operator with access to the box can unseal the instance.\n* **Mitigation**: This is an acceptable interim measure for the current single pre-prod tenant.\n* **Future**: True operator-exclusion requires HSM, cloud-KMS auto-unseal, or confidential compute.\n\n### Network Exposure\n* The listener binds to `0.0.0.0:8200` but is only published via the Docker port mapping.\n* The UI is disabled to prevent direct web access.\n* TLS is disabled for internal communication; ensure the network path between the sidecar and OpenBao is trusted.\n\n## Operational Notes\n\n* **Backup**: Regularly back up `deploy/openbao/unseal-keys.local.txt` and the Docker volume containing `/openbao/data`.\n* **Restart Behavior**: If the container restarts, OpenBao will seal. The sidecar will automatically detect this and unseal the instance using the keys file.\n* **Dependencies**: Requires the OpenBao CLI (`bao`) to be available in the environment where `auto-unseal.sh` executes.","deploy-spire":"# deploy — spire\n\n\n\n# deploy/spire\n\nThis module implements the SPIRE-based identity infrastructure for the Harakat P1 stack. It manages the trust root, node attestation, and workload identity issuance for the `harakat-ai` and `harakat-server` containers.\n\nThe implementation consists of three primary components:\n1. **SPIRE Server**: The trust anchor and issuer of SVIDs/JWT-SVIDs.\n2. **SPIRE Agent**: The daemon running inside the infrastructure VM that attests workloads and serves the Workload API.\n3. **SVID Sidecar**: A custom container that fetches identity from the Agent and materializes files for application consumption.\n\n## Architecture\n\nThe identity flow follows a strict separation of concerns. The SPIRE Server signs identities. The SPIRE Agent validates workloads (via Docker labels) and issues identities. The SVID Sidecar acts as a bridge, fetching the identity and writing it to a shared volume in a format the application containers can read directly.\n\n```mermaid\nsequenceDiagram\n participant App as App Container<br/>(harakat-ai/server)\n participant Sidecar as SVID Sidecar\n participant Agent as SPIRE Agent\n participant Server as SPIRE Server\n\n App->>Sidecar: Mount Volume (Read-Only)\n Sidecar->>Agent: Fetch JWT (unix socket)\n Agent->>Server: Validate Workload (Docker Label)\n Server-->>Agent: Issue JWT-SVID + Bundle\n Agent-->>Sidecar: Return JSON Response\n Sidecar->>Sidecar: Validate & Write Files\n Sidecar->>App: Provide svid.jwt, bundle.jwks\n```\n\n## SPIRE Server Configuration\n\nLocated in `deploy/spire/server.conf`, the server acts as the root of trust for the `harakat.tech` trust domain.\n\n### Key Settings\n* **Trust Domain**: `harakat.tech`\n* **Data Store**: SQLite (`/opt/spire/data/server/datastore.sqlite3`).\n* **Key Management**: Disk-based (`/opt/spire/data/server/keys.json`).\n* **Node Attestor**: `join_token`. This is a single-use token mechanism. The server generates a token for the agent (`spiffe://harakat.tech/agent`) during bootstrap.\n* **TTLs**:\n * `ca_ttl`: 24h\n * `default_x509_svid_ttl`: 1h\n * `default_jwt_svid_ttl`: 5m\n\n### Bootstrap\nThe server requires an initial bootstrap step to generate the join token for the agent:\n```bash\ndocker exec harakat_spire_server \\\n /opt/spire/bin/spire-server token generate -spiffeID spiffe://harakat.tech/agent\n```\nThis token is passed to the agent as `SPIRE_JOIN_TOKEN`.\n\n## SPIRE Agent Configuration\n\nLocated in `deploy/spire/agent.conf`, the agent runs within the infrastructure VM and serves the Workload API.\n\n### Key Settings\n* **Server Address**: `spire-server:8081`\n* **Socket Path**: `/run/spire/agent/api.sock`\n* **Key Management**: Disk-based (`/opt/spire/data/agent`). This is critical for `restart: unless-stopped` policies. The agent renews its node SVID without needing a new join token on every restart.\n* **Workload Attestor**: `docker`. Matches containers by label selector (e.g., `docker:label:com.harakat.workload:harakat-ai`).\n* **Bootstrap**: `insecure_bootstrap = true`. Trusts the server's bundle on first contact. This is acceptable for the single-VM internal network but should be hardened with a pinned trust bundle if the agent is ever remote.\n\n## SVID Sidecar\n\nThe SVID Sidecar is a custom container defined in `deploy/spire/svid-sidecar/Dockerfile`. It is not a standard SPIRE component but a shim designed to match the application's existing identity loading logic.\n\n### Purpose\nThe applications (`HarakatOffices_Server` and `Harakat_AI`) were written to read identity from files (`svid.ts` and `spiffe_identity.py`). While `spiffe-helper` exists upstream, its output format (base64 map) does not match the JWKS format (`{\"keys\":[...]}`) required by these loaders. This sidecar fetches the identity and writes it in the exact format the apps expect.\n\n### Execution Flow\nThe sidecar runs as a long-lived process with the following logic:\n\n1. **Initialization**:\n * Reads required environment variables: `SPIFFE_WORKLOAD`, `SPIFFE_AUDIENCE`, `SPIFFE_TRUST_DOMAIN`.\n * Defaults: `SPIFFE_TRUST_DOMAIN=harakat.tech`, `SPIFFE_SOCKET_PATH=/run/spire/agent/api.sock`.\n * Constructs expected SPIFFE ID: `spiffe://${TRUST_DOMAIN}/workload/${WORKLOAD}`.\n\n2. **Fetch Loop**:\n * Calls `spire-agent api fetch jwt` via the unix socket.\n * **Validation**:\n * Checks that the response contains an SVID and a Bundle for the trust domain.\n * **Identity Assertion**: Verifies the returned `spiffe_id` matches `EXPECT_ID`. If mismatched, it refuses to write the file to prevent identity confusion.\n * **Bundle Validation**: Decodes the base64 bundle and ensures it parses as a valid JWKS with at least one key.\n * **Atomic Write**:\n * Writes `svid.jwt` and `bundle.jwks` to `$OUT_DIR` (default `/run/spiffe`).\n * Uses `mv -f` on a temp file to ensure atomicity.\n * Sets permissions to `0644`.\n * **Ready Flag**: Creates `$OUT_DIR/.ready` only after successful fetch.\n\n3. **Retry Logic**:\n * `fetch_with_retry` attempts up to `MAX_FAILURES` (default 12) times with `RETRY_SECONDS` (default 5) between attempts.\n * **Fail-Closed**: If `MAX_FAILURES` are exhausted, it removes `.ready` and exits non-zero. This triggers a container restart. It does *not* delete `svid.jwt` to avoid instant outage if the app holds a valid token.\n\n### Environment Variables\n| Variable | Required | Default | Description |\n| :--- | :--- | :--- | :--- |\n| `SPIFFE_WORKLOAD` | Yes | - | `harakat-ai` or `harakat-server` |\n| `SPIFFE_AUDIENCE` | Yes | - | The peer this workload calls (e.g., `harakat-server`) |\n| `SPIFFE_TRUST_DOMAIN` | No | `harakat.tech` | Trust domain for the SPIFFE ID |\n| `SPIFFE_SOCKET_PATH` | No | `/run/spire/agent/api.sock` | Path to SPIRE Agent socket |\n| `OUT_DIR` | No | `/run/spiffe` | Output directory for identity files |\n| `REFRESH_SECONDS` | No | `120` | Interval between refresh attempts |\n| `RETRY_SECONDS` | No | `5` | Delay between fetch retries |\n| `MAX_FAILURES` | No | `12` | Max consecutive failures before exit |\n\n## Healthcheck\n\nLocated in `deploy/spire/svid-sidecar/svid-healthcheck.sh`, this script is used by Docker Compose to gate application startup.\n\n### Logic\n1. **File Existence**: Checks for `.ready`, `svid.jwt`, and `bundle.jwks`.\n2. **Bundle Validation**: Uses `jq` to ensure `bundle.jwks` contains a `keys` array with length > 0.\n3. **Expiry Check**:\n * Decodes the JWT payload from `svid.jwt`.\n * Extracts the `exp` claim.\n * Compares against current Unix timestamp.\n4. **Result**: Returns `0` (healthy) if all checks pass, `1` (unhealthy) otherwise.\n\n### Integration\nDocker Compose uses this healthcheck to ensure the sidecar is fully ready before starting the application:\n```yaml\ndepends_on:\n svid-sidecar:\n condition: service_healthy\n```\nThis prevents the application from booting into a state where `AGENT_CAPABILITY_ENFORCEMENT` is active but no trust bundle exists.\n\n## Application Integration\n\nThe sidecar writes to a shared volume mounted read-only into the application containers.\n\n* **HarakatOffices_Server**: Reads `svid.jwt` and `bundle.jwks` via `svid.ts::loadOwnSvid` and `loadTrustBundle`.\n* **Harakat_AI**: Reads `svid.jwt` and `bundle.jwks` via `spiffe_identity.py::load_svid` and `_load_bundle_set`.\n\nBoth applications perform their own expiry checks on the JWT payload. The sidecar ensures the files are valid and not expired at the time of write, but the application is responsible for refreshing or rejecting the token if it expires before the next sidecar refresh.\n\n## Security Considerations\n\n* **Fail-Closed**: The sidecar removes `.ready` on failure, forcing the application to restart or fail health checks. This prevents the app from running with a potentially stale or invalid identity.\n* **Atomic Writes**: Files are written to a temp file and moved. Readers never see a half-written SVID.\n* **Identity Scoping**: The sidecar is attested by the SPIRE Agent using the same Docker label as the application. It cannot obtain an SVID for a workload it is not registered for (`PermissionDenied: no identity issued`).\n* **Volume Isolation**: Each sidecar writes to its own volume. The `ai` container cannot read the `server`'s SVID and vice versa.\n* **TTLs**: Short-lived JWT-SVIDs (5m) limit the blast radius of a compromised token.","deploy":"# deploy\n\n\n\n# deploy\n\nThe `deploy` module orchestrates the infrastructure stack for the Harakat platform, managing secure identity, network routing, encryption, and model inference across production and local environments. It ensures that services are provisioned correctly, identities are verified, and data is encrypted at rest, while preventing configuration drift between development and production.\n\n## Architecture\n\nThe deployment stack follows a layered security and routing model:\n\n1. **Network Entry:** Traffic enters through `deploy/nginx`, which acts as the reverse proxy and load balancer for all public domains (`harakat.tech`, `app.harakat.tech`, `admin.harakat.tech`, `api.harakat.tech`).\n2. **Identity & Security:** Internal services (`harakat-ai`, `harakat-server`) authenticate via `deploy/spire` (SPIRE) for workload identity. Data at rest is encrypted using `deploy/openbao` (OpenBao), which manages the KMS and handles auto-unsealing for single-node deployments.\n3. **Inference & Logic:** `deploy/inference` provisions vLLM-based GPU workstations for multimodal model processing. `deploy/rooms` handles relay logic and cryptographic operations for data submission and loading.\n4. **Environment Safety:** `deploy/local` enforces a canonical local development profile using boot guards (e.g., `HARAKAT_LOCAL=1`) to prevent accidental production configuration drift.\n\n## Workflow\n\n```mermaid\ngraph TD\n Client[Client] -->|HTTPS| Nginx[deploy/nginx]\n Nginx -->|Proxy| Rooms[deploy/rooms]\n Nginx -->|Proxy| Inference[deploy/inference]\n Nginx -->|Proxy| Server[deploy/local]\n \n SPIRE[deploy/spire] -->|Identity| Inference\n SPIRE -->|Identity| Server\n \n OpenBao[deploy/openbao] -->|Encryption| Rooms\n OpenBao -->|Encryption| Inference\n \n LocalGuard[deploy/local] -->|Guard| Server\n```\n\n## Sub-modules\n\n* **[deploy/inference](deploy/inference.md)**: Manages vLLM-based inference services, GPU provisioning, and model configuration for document processing pipelines.\n* **[deploy/local](deploy/local.md)**: Enforces local development safety profiles and boot guards to prevent production configuration drift.\n* **[deploy/nginx](deploy/nginx.md)**: Configures reverse proxying, SSL termination, and load balancing for all public-facing domains.\n* **[deploy/openbao](deploy/openbao.md)**: Provides encrypt-at-rest (P1) capabilities via a single-node Key Management System with auto-unsealing.\n* **[deploy/spire](deploy/spire.md)**: Implements SPIRE-based identity infrastructure for workload attestation and SVID issuance.\n* **[deploy/rooms](deploy/rooms.md)**: Handles relay logic, cryptographic operations, and data loading for the application stack.","docs-automl":"# docs — automl\n\n\n\n# docs/automl — AutoML Feature Design & Exploration\n\n## Overview\n\nThis module contains the design documentation and technology exploration for the **Self-Building Predictive Capabilities** feature. It defines how the assistant will identify learnable patterns in tenant data and offer to handle them automatically — without exposing ML terminology to users.\n\nThe module consists of two core documents:\n\n| File | Purpose |\n|------|---------|\n| `FEATURE_UPDATE_AUTOML.md` | End-to-end feature design, pipeline, security model, and build order |\n| `TIMESFM_EXPLORATION.md` | Technology evaluation for time-series forecasting capabilities |\n\n---\n\n## 1. Purpose & Scope\n\n### 1.1 What This Feature Does\n\nThe assistant continuously analyzes tenant data (documents, chats, connected systems) to identify recurring patterns it can act on. When a pattern is detected, the assistant offers to handle it automatically. Examples:\n\n- Flag invoices likely to be paid late\n- Score new leads by likelihood to convert\n- Surface contracts with unusual clauses\n\n**Critical constraint:** Users never see ML terminology. They see: *\"the assistant is learning\"*, *\"I noticed a pattern\"*, *\"I can now do X for you automatically\"*.\n\n### 1.2 What This Module Documents\n\nThis documentation module captures:\n\n1. **The complete pipeline** from pattern detection to live capability\n2. **Security architecture** for artifacts and approvals\n3. **Technology decisions** (classical estimators vs. foundation models)\n4. **Integration points** with existing codebase\n5. **Build order** for phased implementation\n\n---\n\n## 2. The Pipeline Architecture\n\n### 2.1 High-Level Flow\n\n```mermaid\nflowchart TD\n subgraph DataSources[Tenant Data Sources]\n PD[ParsedDocument]\n KN[KnowledgeNode]\n KE[KnowledgeEdge]\n CH[Chats]\n DS[Drive Sync]\n end\n \n subgraph Pipeline[8-Step Pipeline]\n PS[1. Pattern Scout] --> OP[2. Opportunity]\n OP --> SURF[3. Surfacing Layer]\n SURF --> DEF[4. Definition Chat]\n DEF --> SANDBOX[5. Ephemeral Sandbox]\n SANDBOX --> TRAIN[6. Train + Evaluate]\n TRAIN --> VALID[7. Human Validation]\n VALID --> LIVE[8. Live Operation]\n end\n \n subgraph Outputs[Outputs]\n DIGEST[Weekly Digest Email]\n BUBBLE[Contextual Suggestion]\n CHAT[Explicit Chat Request]\n end\n \n DataSources --> PS\n PS --> DIGEST\n PS --> BUBBLE\n PS --> CHAT\n LIVE --> MONITOR[Drift Monitoring]\n```\n\n### 2.2 Trigger Surfaces\n\nThree channels surface opportunities, chosen by confidence + value score:\n\n| Surface | When | Format |\n|---------|------|--------|\n| **Weekly digest email** | Once per week, up to 2 items | Email with [Yes/No/More] buttons |\n| **Contextual bubbles** | During chat or after file upload | In-app dismissable bubbles |\n| **Explicit chat request** | After users understand the pattern | Routes via `propose_predictive_capability` intent |\n\n**Build order:** 2.1 (digest) → 2.2 (bubbles) → 2.3 (explicit)\n\n---\n\n## 3. Key Components\n\n### 3.1 Pattern Scout (Step 1)\n\nRuns weekly and on ingest over tier-A nodes. Clusters by document type / entity / topic and scores each cluster on:\n\n- Signal strength\n- Recurrence\n- Business value\n\nOutputs `CapabilityOpportunity` records with `status = proposed`.\n\n**Integration point:** Walks `ParsedDocument`, `KnowledgeNode`, `KnowledgeEdge` from existing data sources.\n\n### 3.2 Definition Conversation (Step 3)\n\nLLM-led chat that resolves the prediction target in plain language:\n\n- *\"When you say 'risky invoice', do you mean late, unpaid, or…?\"*\n- *\"Should I look at amount, vendor, terms, or all three?\"*\n\nOutput: `CapabilitySpec` (target, signal columns, decision threshold, audit cadence).\n\n**Integration point:** Extends `Harakat_AI/workflows/assistant_workflow.py` with `propose_predictive_capability` intent.\n\n### 3.3 Ephemeral Training Sandbox (Steps 4-6)\n\n- Spins up isolated container with read-only data view\n- Pulls only columns named in `PredictionSpec`\n- Hashes manifest (record IDs + timestamps) → persisted\n- **Raw data NEVER leaves the sandbox**\n\n**Default estimators:** Logistic regression, gradient-boosted trees. Deep nets are off the menu for v1.\n\n### 3.4 Human-in-the-Loop Validation (Step 7)\n\nShows 10 high-scored and 10 low-scored items. User approves → capability goes live.\n\n**Security gate:** WebAuthn / passkey required for high-impact actions (see §5).\n\n### 3.5 Live Operation + Drift Monitoring (Step 8)\n\n- Scores new matching documents\n- Weekly accuracy check vs. recent ground truth\n- If accuracy drops > threshold → pause + notify user\n- User can disable capability at any time\n\n---\n\n## 4. Data Model\n\n### 4.1 Persistent Objects (Server)\n\nAll internal-only; not exposed to users.\n\n| Model | Purpose | Key Fields |\n|-------|---------|------------|\n| `LearnedCapability` | One row per accepted capability | `status`, `startupId`, `tier` |\n| `CapabilityOpportunity` | Pattern scout output | `score`, `dismissed`, `opportunity_id` |\n| `CapabilitySpec` | Structured `PredictionSpec` | JSON, tier-stamped |\n| `CapabilityArtifact` | Serialized trained object | **Encrypted at rest** |\n| `CapabilityRun` | Scoring/evaluation invocation | For audit and drift detection |\n| `CapabilityFeedback` | User labels | Per-user, tier-aware |\n| `CapabilityApproval` | WebAuthn-signed approval | Attestation + payload hash |\n\nAll carry `startupId` and respect the existing tier system from `src/modules/startup/assistant.service.ts`.\n\n### 4.2 Status Lifecycle\n\n```\nproposed → in_definition → training → validating → live → paused → retired\n```\n\nTransitions are gated by user approval and security checks.\n\n---\n\n## 5. Security Architecture\n\n### 5.1 Plaintext Secrets Fix (Already Shipped)\n\nBefore adding new sensitive surfaces, existing plaintext storage of `DriveIntegration.accessToken/refreshToken` and `Startup.zohoAccountPassword/customEmailRefreshToken/customEmailAccessToken` has been closed:\n\n- **`src/core/security/secret-cipher.ts`** — AES-256-GCM with versioned envelope (`enc:v1:` prefix)\n- **`src/core/config/prisma.ts`** — Prisma client extension that transparently encrypts on write\n- **`src/scripts/encrypt-existing-secrets.ts`** — One-shot migration script\n- **`env.ts`** — `SECRET_ENCRYPTION_KEY` is now required in production\n\n**Rollout steps:**\n1. Generate key: `node -e \"console.log(require('crypto').randomBytes(32).toString('base64'))\"`\n2. Set `SECRET_ENCRYPTION_KEY=…` in prod env\n3. Deploy code\n4. Run `npm run encrypt:secrets` once\n5. Back up `SECRET_ENCRYPTION_KEY` to separate secure store\n\n### 5.2 Encryption for Capability Surface\n\nLayered approach:\n\n1. **Envelope encryption for `CapabilityArtifact` blobs**\n - Each artifact gets its own data key (DEK)\n - DEK encrypted by tenant-scoped key (KEK)\n - KEK wrapped by `SECRET_ENCRYPTION_KEY` (or cloud KMS later)\n\n2. **Ephemeral training sandboxes**\n - Step 4–6 runs in isolated container\n - Raw training data **never** persisted outside it\n - Hashed manifest (record IDs + timestamps) persisted for reproducibility\n\n3. **Tier-gated artifacts**\n - `CapabilityArtifact` carries the tier of data it was trained on\n - Tools apply `tierLevel(nodeTier) <= myLevel` check (same as `src/modules/knowledge/knowledge.service.ts#L80`)\n - Finance-tier capability cannot be invoked from marketing-tier session\n\n4. **Differential privacy (later, opt-in)**\n - For high-sensitivity tenants\n - Training with DP noise prevents membership-inference attacks\n\n### 5.3 WebAuthn / Passkeys\n\n**Correction:** WebAuthn / FIDO2 is **authentication**, not encryption. It proves *who* is approving — it does not protect data at rest.\n\nApply surgically at high-impact gates:\n\n- **Go-live approval** (`CapabilityApproval`): user signs payload hash with passkey\n- **Capability deletion / re-training**: same passkey re-prompt\n- **Connecting new high-risk data source** (banking, payroll): passkey required\n\n**What we do NOT gate with passkey:**\n- Weekly digest email\n- In-chat suggestion bubbles\n- \"Would you flag this?\" labelling questions\n- Day-to-day chat\n\n**Implementation:** SimpleWebAuthn (server) + WebAuthn browser API. Passkey enrolment can reuse existing 2FA scaffolding on `Admin` (`QUICK_START_2FA.md`) — but also add to `StartupUser`, which currently has **no second factor at all**.\n\n### 5.4 What We Are Not Claiming\n\n- We are not claiming \"your data never leaves your store\" — it transits the sandbox. We *are* claiming it is not duplicated to a permanent store.\n- We are not claiming the artifact itself is non-sensitive. It is. It is encrypted, tier-gated, and access-logged.\n- WebAuthn does not encrypt anything. It only signs an approval.\n\n---\n\n## 6. Synthetic Augmentation\n\n### 6.1 The Correct Framing\n\nThe naive approach (\"here's a synthetic invoice I made — what do you think?\") fails because users nitpick the artifact instead of giving us the label we need.\n\n**Correct framing:**\n> *\"If this invoice arrived tomorrow, would you flag it as late-risk? **yes / no / not sure**\"*\n\nThis sidesteps the uncanny-valley problem and harvests the human's decision boundary.\n\n### 6.2 Operating Rules\n\n- Cluster real examples first; generate variants per cluster, never globally\n- Two questions per user per week, max. Route by tier (CFO sees finance variants; sales lead sees lead variants)\n- Show progress: *\"3 more validations and I can start flagging late-payers.\"*\n- Track inter-rater agreement when two users see the same item — disagreement is a useful signal\n- Be honest about N: a capability built on 40 real + 200 synthetic should ship with the message *\"I'm still learning — my early calls may need your eye.\"*\n\n---\n\n## 7. Technology Decisions\n\n### 7.1 Classical Estimators vs. Foundation Models\n\n**Design stance:** Default to small, interpretable estimators (logistic regression, gradient-boosted trees). Deep nets are off the menu for v1.\n\n**Rationale:**\n- Most planned capabilities are **classification / scoring** over documents and text\n- Deep nets are harder to interpret and debug\n- Small estimators work well with limited data\n\n### 7.2 TimesFM Exploration\n\nGoogle TimesFM is a **time-series forecasting** foundation model. It is an excellent fit for the **forecasting** slice (cash-flow, demand, stock-out timing) but **not** for the classification majority.\n\n**Fit by capability:**\n\n| Capability | Time-Series? | Best Engine |\n|------------|--------------|-------------|\n| Late-payment flagger | No | Small estimator |\n| Lead-conversion scorer | No | Small estimator |\n| Unusual-clause detection | No | LLM + small estimator |\n| Duplicate-supplier detection | No | LLM + similarity |\n| Cash-flow forecast | Yes | **TimesFM** |\n| Demand forecast | Yes | **TimesFM** |\n| Stock-out timing | Yes | **TimesFM** |\n\n**Recommendation:**\n1. Don't position TimesFM as \"the AutoML feature\" — it covers forecasting only\n2. Adopt it for forecasting capabilities via managed BigQuery/AlloyDB path\n3. Sequence it after Odoo integration (forecasting needs structured operational time series)\n4. Keep classical estimator path for classification capabilities\n\n**Architecture:**\n\n```mermaid\nflowchart TD\n subgraph Definition[Definition Chat]\n DEF[Resolve target] --> SPLIT{Forecasting<br/>or classification?}\n end\n \n SPLIT -->|classification / scoring| EST[Small estimator<br/>in ephemeral sandbox]\n SPLIT -->|time series| TFM[TimesFM via BigQuery / AlloyDB<br/>zero-shot, no training]\n \n EST --> VAL[Validation UI]\n TFM --> VAL\n VAL --> LIVE[Live capability]\n```\n\n---\n\n## 8. Integration Points\n\n### 8.1 Existing Codebase\n\n| Component | Integration | Notes |\n|-----------|-------------|-------|\n| `src/modules/startup/assistant.service.ts` | Tier system | All capabilities respect existing tier checks |\n| `src/modules/knowledge/knowledge.service.ts` | Tier gating | Use same `tierLevel(nodeTier) <= myLevel` check |\n| `Harakat_AI/workflows/assistant_workflow.py` | Intent routing | Add `propose_predictive_capability` intent |\n| `src/core/security/secret-cipher.ts` | Encryption | Reuse existing AES-256-GCM envelope |\n| `src/core/config/prisma.ts` | Prisma extension | Add capability models to encrypted fields |\n| `QUICK_START_2FA.md` | Passkey enrolment | Extend to `StartupUser` |\n| `PLATFORM_OVERVIEW.md` | Feature status | Update §8, §11 to reflect capability pipeline |\n| `odoo.md` | Data source | Structured data makes forecasting worthwhile |\n| `CLAUDE.md` | Tier handling | Fix inverted-polarity check before shipping |\n\n### 8.2 Data Sources\n\n- `ParsedDocument` — existing document parsing\n- `KnowledgeNode` / `KnowledgeEdge` — existing knowledge graph\n- `Chats` — existing chat history\n- `Drive sync` — existing file sync\n- **Future:** Odoo integration for structured operational data\n\n---\n\n## 9. Build Order\n\n1. **Plaintext-secrets fix** — done in this branch\n2. **Pattern scout v0.1** — runs weekly over `ParsedDocument`, emits `CapabilityOpportunity` rows. Internal-only, validate signal\n3. **Digest email** — top opportunity per tenant, with one-click feedback. Measure click-through and \"not interested\" rates\n4. **Definition chat + spec generation** — extend `assistant_workflow.py` with `propose_predictive_capability` intent + structured output\n5. **Ephemeral training sandbox** — one container per training run, scikit-learn baseline. Persist artifact (encrypted) + manifest hash + metrics\n6. **Validation UI** — the \"10 high, 10 low\" review screen. Approval click goes live (no WebAuthn yet — gate that on §8)\n7. **Suggestion bubbles** — once the digest loop is trusted\n8. **WebAuthn enrolment for `StartupUser`** — and gate go-live approvals on it\n9. **Synthetic augmentation loop** — only after evidence the bottleneck is data scarcity\n10. **Drift monitoring + auto-pause**\n\n---\n\n## 10. Open Questions\n\n| Question | Status | Notes |\n|----------|--------|-------|\n| Where does the sandbox run in single-VM topology? | Open | Likely separate container in compose stack with no network egress. Move to GCP Cloud Run / Vertex Custom Jobs when leaving bare VM |\n| KMS choice: envelope encryption vs. GCP KMS | Open | Envelope simpler, current state. KMS better blast-radius story, more operational overhead. Recommend KMS once >5 paying tenants |\n| Inverted-polarity tier check on `KnowledgeNode.accessTier = null` | Open | Fix before capability surface ships. Otherwise null-tier capability invocable by anyone |\n| Passkey enrolment UX for non-technical founders on mobile-only flows | Open | Needs design |\n\n---\n\n## 11. Glossary\n\n| Internal Term | User-Facing Language |\n|---------------|---------------------|\n| Predictive capability / model | \"Something the assistant can do for you\" |\n| Training | \"The assistant is learning\" |\n| Opportunity / proposal | \"I noticed something\" |\n| Spec / target / features | (never shown — resolved through plain conversation) |\n| Accuracy / metric | \"How often I'd be right on data that looks like yours\" |\n| Synthetic augmentation | \"Quick check — here's an example, what would you do?\" |\n| Drift detection | \"Something has changed — I want to recheck before I keep going\" |\n| Approval / passkey gate | \"Confirm with your security key to turn this on\" |\n\n---\n\n## 12. Related Documentation\n\n- `PLATFORM_OVERVIEW.md` §8, §11 — where capabilities sit and why they're not live\n- `odoo.md` — the structured-data integration that makes forecasting capabilities worthwhile\n- `QUICK_START_2FA.md` — existing 2FA scaffolding for passkey enrolment\n- `CLAUDE.md` — tier handling and inverted-polarity considerations\n- `src/core/security/secret-cipher.ts` — existing encryption implementation\n- `src/modules/startup/assistant.service.ts` — tier system implementation\n- `src/modules/knowledge/knowledge.service.ts` — tier gating implementation\n- `Harakat_AI/workflows/assistant_workflow.py` — intent routing implementation\n\n---\n\n## 13. Contributing\n\nWhen contributing to this module:\n\n1. **Maintain the user-facing language rule** — never expose ML jargon in user-facing text\n2. **Respect the tier system** — all capabilities must respect existing tier checks\n3. **Follow the security model** — artifacts are encrypted, approvals are signed, sandboxes are ephemeral\n4. **Track the build order** — don't implement step 9 before step 6 is validated\n5. **Document integration points** — clearly show how new code connects to existing systems\n\nFor questions about the feature design, refer to `FEATURE_UPDATE_AUTOML.md`. For technology decisions about forecasting, refer to `TIMESFM_EXPLORATION.md`.","docs-capacity":"# docs — capacity\n\n\n\n# docs/capacity — Token Economics & Hardware Capacity Analysis\n\n## Overview\n\nThe `docs/capacity` module provides capacity planning documentation for the Harakat Offices multi-agent workspace platform. It contains two core artifacts:\n\n1. **`estimate.md`** — The capacity estimation task specification and methodology\n2. **`harakat_capacity_comparison.md`** — The deliverable analysis comparing Apple Silicon hardware against candidate models\n\nThis module serves as the single source of truth for hardware procurement decisions, helping teams determine which machine configuration can support their target user count given the actual token economics of the live runtime.\n\n---\n\n## Purpose\n\nThe module answers three critical questions for infrastructure planning:\n\n| Question | Answer Source |\n|---|---|\n| How many concurrent users can each machine serve? | `harakat_capacity_comparison.md` §4 |\n| Which model should run on which hardware? | `harakat_capacity_comparison.md` §5 |\n| What are the real token costs per inference step? | `harakat_capacity_comparison.md` §2 |\n\nThe analysis is grounded in **measured** token counts from the actual codebase, not theoretical estimates. Every token number cites a specific file and line location.\n\n---\n\n## Architecture\n\n```mermaid\ngraph TD\n A[Harakat Runtime] -->|generates| B[Token Economics]\n B -->|feeds| C[Capacity Analysis]\n C -->|outputs| D[Hardware Recommendations]\n D -->|guides| E[Procurement Decisions]\n \n subgraph \"Codebase Sources\"\n A -->|prompts/schemas| F[docs/capacity/estimate.md]\n A -->|runtime behavior| G[docs/capacity/harakat_capacity_comparison.md]\n end\n \n subgraph \"Analysis Components\"\n F -->|Phase 1| H[Token Measurement]\n F -->|Phase 2| I[Hardware Facts]\n F -->|Phase 3| J[Comparison Matrix]\n end\n```\n\n---\n\n## Key Components\n\n### 1. Token Economics Measurement (`estimate.md` Phase 1)\n\nThe module measures real token usage from the codebase across these components:\n\n| Component | Measured Value | Source Location |\n|---|---|---|\n| System prompts | 1,022 tokens (PLANNER) + 470 tokens (Hermes base) | `system_prompt.py:7`, `run_agent.py:2582-2656` |\n| Tool schemas | 5,166–6,296 tokens | `core/tools.py:906` |\n| Retrieved units | 600–2,160 tokens per result | `core/tools.py:406-418`, `core/tools.py:479` |\n| Prefetch block | 1.3k–2.8k tokens | `harakat_memory_provider.py:255-302` |\n| Max output | 4,096 tokens | `aia_runner.py:215` |\n\n**Per-step working set** (the key metric):\n- **p50**: ~8.5k tokens\n- **p90**: ~14k tokens \n- **worst-case**: ~24–28k tokens\n\n### 2. Hardware Facts (`estimate.md` Phase 2)\n\nFour candidate machines with verified specifications:\n\n| Machine | Usable RAM | GPU Cores | Bandwidth |\n|---|---|---|---|\n| M4 Pro | ~38 GB | 20 | ~273 GB/s |\n| M4 Max | ~54 GB | 40 | ~410 GB/s |\n| M3 Ultra (60c) | ~84 GB | 60 | ~819 GB/s |\n| M3 Ultra (80c) | ~84 GB | 80 | ~819 GB/s |\n\n**Critical constraint**: MLX on Apple Silicon uses **pre-allocated KV per slot** (no paged attention). Memory must be sized for peak concurrent contexts, not average.\n\n### 3. Model Comparison (`harakat_capacity_comparison.md` §4)\n\nThe master comparison matrix shows max concurrent humans per machine/model pair:\n\n```\nQwen3.6-35B-A3B (hybrid) dominates due to KV efficiency:\n- M4 Max: 129 contexts / 64 humans (4k output)\n- M3 Ultra 80c: 269 contexts / 134 humans (4k output)\n\nFull-attention models are KV-bound:\n- Qwen3-14B: 25 contexts / 12 humans (M4 Max, 4k output)\n- ~6× fewer than hybrid despite smaller weights\n```\n\n### 4. Recommendations (`harakat_capacity_comparison.md` §7)\n\n| Decision | Recommendation |\n|---|---|\n| Pilot (≤5 users) | M4 Max 64 GB + Qwen3.6-35B-A3B @ Q4 |\n| Scale (tens of users) | M3 Ultra 96 GB 80-core + Qwen3.6-35B-A3B |\n| Tiered architecture | Router Qwen3-4B + Worker 35B-A3B |\n| Serving | MLX 4-bit (`unsloth/Qwen3.6-35B-A3B-UD-MLX-4bit`) |\n\n---\n\n## How It Works\n\n### Token Measurement Method\n\n1. **Tokenizer**: `tiktoken cl100k_base` proxy (Qwen tokenizer unavailable)\n2. **Heuristic**: ±10% margin for all token counts\n3. **Citations**: Every number links to specific file:line\n\n### KV Memory Calculation\n\n**Hybrid models** (Qwen 35B-A3B, 3.5-9B):\n```\nKV_bytes/token = 2 × n_layers_kv × n_kv_heads × head_dim × bytes_elem\nQwen 35B-A3B: 10 layers × 2 heads × 256 dim × 1 byte = 10 KB/token\n```\n\n**Full-attention models** (Qwen 14B, Mistral 7B):\n```\nQwen 14B: 40 layers × 8 heads × 128 dim × 1 byte = 80 KB/token\n```\n\n**KV budget formula**:\n```\nKV_budget = usable_RAM × 0.80 − weights_Q4\ncontexts = KV_budget ÷ (KV_per_token × working_set_size)\nhumans = (contexts − 1) ÷ 2\n```\n\n### Execution Flow\n\n```mermaid\nsequenceDiagram\n participant Dev as Developer\n participant Doc as Capacity Docs\n participant Code as Harakat Codebase\n participant Hardware as Hardware Selection\n \n Dev->>Doc: Needs capacity estimate\n Doc->>Code: Measure token costs\n Code-->>Doc: Returns file:line citations\n Doc->>Doc: Calculate KV per model\n Doc->>Hardware: Recommend machine/model\n Hardware->>Dev: Procurement decision\n```\n\n---\n\n## Integration Points\n\n### With Harakat Runtime\n\nThe capacity analysis directly references runtime behavior:\n\n| Runtime Component | Capacity Impact |\n|---|---|\n| `aia_runner.py` | Sets `max_tokens=4096`, iteration budgets |\n| `core/tools.py` | 38 tool definitions = 5.2–6.3k tokens per call |\n| `harakat_memory_provider.py` | Prefetch block assembly logic |\n| `native_config.py` | Compression triggers at 50% context window |\n\n### With Model Serving Stack\n\n| Stack Component | Constraint |\n|---|---|\n| MLX | Pre-allocates KV per slot, no overcommit |\n| llama.cpp | `--ctx-checkpoints 128` recommended for multi-session |\n| Ollama | No Qwen3.6 vision projector support |\n| vLLM | Not available on Metal |\n\n---\n\n## Contributing\n\n### Adding New Models\n\n1. Measure KV head config from model card\n2. Add to `harakat_capacity_comparison.md` §3 table\n3. Update master matrix in §4\n4. Document assumptions clearly\n\n### Updating Token Measurements\n\n1. Run `tiktoken` on actual code snippets\n2. Update `harakat_capacity_comparison.md` §2 tables\n3. Add file:line citations\n4. Flag any assumptions with `[ASSUMPTION]`\n\n### Hardware Changes\n\nIf new Apple Silicon hardware is released:\n1. Add to `estimate.md` Phase 2 table\n2. Recalculate KV budget with same formula\n3. Update master comparison matrix\n4. Note bandwidth vs core count tradeoffs\n\n---\n\n## Known Limitations\n\n| Limitation | Impact |\n|---|---|\n| Token counts use `cl100k_base` proxy | ±10% margin on all numbers |\n| Gemma-4 KV config assumed | Must verify before purchase |\n| Qwen3.5-9B KV heads assumed | 4 heads assumed; verify from model card |\n| No speculative decoding | Current stack doesn't support it |\n| Vision projector not in Ollama | Use llama.cpp/MLX-VLM for multimodal |\n\n---\n\n## Related Documentation\n\n| Document | Purpose |\n|---|---|\n| `docs/capacity/estimate.md` | Task specification and methodology |\n| `docs/capacity/harakat_capacity_comparison.md` | Analysis deliverable |\n| `docs/architecture/` | System architecture overview |\n| `docs/models/` | Model cards and specifications |\n\n---\n\n## Quick Reference\n\n| Metric | Value |\n|---|---|\n| Working set p90 | 14k tokens |\n| Tool schema bundle | 5.2–6.3k tokens |\n| Max output | 4,096 tokens |\n| Safety margin | 20% of usable RAM |\n| KV default | 8-bit |\n| Weights default | Q4 |\n| Recommended model | Qwen3.6-35B-A3B |\n| Recommended machine | M3 Ultra 96 GB 80-core |","docs-deployment":"# docs — deployment\n\n\n\n# Deployment Module\n\n## Overview\n\nThe `docs/deployment` module serves as the operational reference for deploying the `HarakatOffices_Server` container environment. It defines the procedures required to transition the production VM beyond a standard Docker rebuild.\n\nUnlike standard application modules, this module does not contain executable logic. It tracks **manual intervention points** and **schema evolution** that must occur on the deployed VM. While the Docker image handles code and schema updates automatically, specific data integrity checks and security migrations require human oversight.\n\n## Automated Deployment Pipeline\n\nA standard `docker-compose up --build server` triggers the following automated actions within the `HarakatOffices_Server` container:\n\n1. **Schema Migration**: `npx prisma migrate deploy` executes on container start.\n2. **Client Generation**: `prisma generate` regenerates the typed Prisma client.\n3. **Module Activation**: Backend modules for access-key, audit-log, mutation queue, policy CRUD, skill collision, auto-load, scenario-template, scheduled-task, peer notes, and sync-call loops become available.\n\n### Schema Migrations\n\nThe following migrations are applied automatically during the rebuild process:\n\n| Migration | Description |\n| :--- | :--- |\n| `20260517000000_add_audit_entry` | Creates `AuditEntry`, `AuditActor`, indexes, and foreign keys. |\n| `20260517010000_add_mutation_proposal` | Creates the proposal queue for agent-proposed durable mutations. |\n| `20260517020000_phase_b_vessel_foundation` | Adds `Policy`, `Skill`, `UserAssistantSkill`, `AutoloadEntry`, `ScenarioTemplate`, `AssistantScenarioRun`, `AssistantScheduledTask`, Phase-B `UserAssistant` fields, and `AssistantMemory.tierAtCapture`. |\n| `20260517030000_phase_c_inter_assistant_fabric` | Adds `AssistantPeerNote`, `AssistantSyncCall`, note intent/status enums, and indexes for async notes plus guarded sync calls. |\n\n**Verification**: After a rebuild, verify the generated Prisma client contains references for `AuditEntry`, `MutationProposal`, `Policy`, `Skill`, and `AutoloadEntry`.\n\n## Manual Intervention Points\n\nCertain operations cannot be automated due to data sensitivity or security requirements. These must be executed manually on the VM.\n\n### 1. KnowledgeNode Polarity Audit\n\nThe `knowledge.service.ts` polarity flip changes `accessTier = NULL` from effectively public to default-deny. Before shipping this change, a read-only audit must be performed on production data.\n\n**Procedure:**\n1. Execute the audit script against the running container.\n2. Review the output for total null-tier rows, breakdowns by `startupId` and `kind`, and 20 recent samples.\n3. Decide whether to backfill explicit tiers or accept the new invisibility.\n\n```bash\ndocker compose exec server npx tsx src/scripts/audit-null-tier-nodes.ts\ndocker compose exec server npx tsx src/scripts/audit-null-tier-nodes.ts --json\n```\n\n**Constraints:**\n- The script makes **no writes**.\n- Must be run before the new image goes live.\n\n### 2. Plaintext Secrets Migration\n\nLegacy plaintext secrets must be encrypted using a one-shot migration. This is idempotent but requires a secure `SECRET_ENCRYPTION_KEY`.\n\n**Procedure:**\n1. Generate a new key if not already set:\n ```bash\n node -e \"console.log(require('crypto').randomBytes(32).toString('base64'))\"\n ```\n2. Set `SECRET_ENCRYPTION_KEY` in the production environment variables.\n3. Run the encryption script:\n ```bash\n docker compose exec server npm run encrypt:secrets\n ```\n\n**Constraints:**\n- Legacy plaintext rows continue to work until this runs (via `decryptSecret` pass-through).\n- **Critical**: Back up `SECRET_ENCRYPTION_KEY` to a separate secure store. Losing this key results in permanent loss of all encrypted connected-account tokens.\n\n## Build-Time Constraints & Troubleshooting\n\n### Windows Development Environment\nLocal Windows development may encounter `EPERM` errors during `prisma generate` if another Node process holds `query_engine-windows.dll.node`.\n\n**Resolution:**\n- Stop `tsx watch` processes.\n- Allow Docker to regenerate the client in a clean container.\n\n### Migration Drift\nIf `prisma migrate deploy` reports drift on the VM:\n1. **Snapshot** production data immediately.\n2. Do **not** run `migrate resolve` blindly.\n3. Investigate the drift source before proceeding.\n\n## Rollback Strategy\n\nThe new migrations are additive, with the exception of `AssistantMemory.tierAtCapture`, which performs a non-null backfill of existing `accessTier` values.\n\n**Primary Rollback Scenario:** KnowledgeNode Polarity Flip\nIf the polarity flip causes runtime issues:\n1. Revert the polarity changes in `knowledge.service.ts`.\n2. Rebuild and redeploy the Docker image.\n3. Leave the additive migrations in place (do not revert schema migrations).\n\n## Deployment Lifecycle\n\nThe following sequence illustrates the interaction between automated container actions and manual deployment steps.\n\n```mermaid\nsequenceDiagram\n participant Dev as Developer\n participant Docker as Docker Compose\n participant DB as Prisma DB\n participant Script as Manual Scripts\n participant Env as Env Config\n\n Dev->>Docker: docker-compose up --build\n Docker->>DB: npx prisma migrate deploy\n Docker->>DB: prisma generate\n Docker-->>Dev: Container Ready\n Dev->>Script: Run audit-null-tier-nodes.ts\n Script-->>Dev: Report Null-Tier Rows\n Dev->>Env: Set SECRET_ENCRYPTION_KEY\n Dev->>Script: Run encrypt:secrets\n Script-->>DB: Encrypt Legacy Secrets\n Dev->>Dev: Verify Rollback Plan\n```\n\n## Key Components Reference\n\n| Component | Location | Purpose |\n| :--- | :--- | :--- |\n| `Dockerfile` | `HarakatOffices_Server/Dockerfile` | Defines container entrypoint and migration triggers. |\n| `audit-null-tier-nodes.ts` | `src/scripts/` | Read-only report for `KnowledgeNode` access tier data. |\n| `encrypt:secrets` | `package.json` | Script to migrate plaintext secrets to encrypted storage. |\n| `knowledge.service.ts` | `src/` | Service containing polarity flip logic for `KnowledgeNode`. |\n| `prisma` | `node_modules/` | ORM managing schema migrations and client generation. |","docs-formal":"# docs — formal\n\n\n\n# Tenant-Resolution Formal Model\n\nThis module provides a bounded executable model for verifying tenant-resolution ordering in `HarakatOffices_Server`. It implements a state machine that enumerates all possible interleavings of tenant resolution steps against concurrent world events (switches, refreshes, concurrent requests) to assert seven security invariants.\n\nThe model is designed to satisfy Register **A8** requirements for \"bounded executable models + mutation testing\" without relying on TLA+ or external services. It consists of three core files: `model.py` (state machine), `exhaustive.py` (verification engine), and `mutation.py` (harness).\n\n## Architecture\n\nThe verification process is split into a state machine definition and an execution engine.\n\n```mermaid\nflowchart TD\n Main[main] --> Explore[explore]\n Explore --> Interleave[interleavings]\n Interleave --> RunS1[run_s1]\n Interleave --> RunS2[run_s2]\n RunS1 --> Apply[apply_step]\n RunS2 --> Apply\n Apply --> Model[model.py]\n Apply --> World[World State]\n World --> Judge[judge]\n Judge --> Invariants[check_invariants]\n Judge --> Mutants[mutation.py]\n Mutants --> Policy[Policy Mutants]\n```\n\n### Components\n\n* **`model.py`**: Defines the state machine. It contains the `World`, `Request`, `Policy`, and `Observation` dataclasses. It implements the logic for the four resolution steps (`claim`, `row`, `bind`, `read`) and world events (`switch`, `refresh`).\n* **`exhaustive.py`**: The verification engine. It uses `itertools.permutations` to enumerate orderings of steps and events, filters them by program order, and asserts invariants against the resulting `World` state.\n* **`mutation.py`**: The mutation harness. It modifies `Policy` clauses to break the model and requires specific invariants to fail, proving the clauses are guarded.\n\n## The State Machine\n\nThe model simulates the tenant resolution pipeline found in `src/middleware/startup-auth.ts` and `src/middleware/access-claims.ts`. Every tenant-scoped request executes four observable steps in program order:\n\n1. **`claim`**: Extracts `startupId` from the JWT (`req.startupId`).\n2. **`row`**: Reads the authoritative `StartupUser.startupId` from Postgres.\n3. **`bind`**: Compares `claim` vs `row`. Refuses if they disagree.\n4. **`read`**: Executes tenant-scoped reads (caches included).\n\n### Key Data Structures\n\n* **`Policy`**: A dataclass defining the clauses of the resolution rule.\n * `check_claim_against_row`: Enables the cross-check at `bind`.\n * `unchecked_shape`: Defines behavior if cross-check is disabled (`claim` vs `split`).\n * `tenant_in_cache_key`: Ensures tenant is part of cache keys.\n * `per_request_binding`: Ensures bound tenant is not process-global.\n * `bind_snapshot_is_stable`: Ensures `read` uses the `bind` snapshot.\n* **`World`**: The mutable shared state. Tracks `row` (authoritative tenant), `tokens` (session tokens), `cache`, and `observations`.\n* **`Request`**: Represents an in-flight request. Tracks `pinned_token` (whether the client re-reads the token) and step state (`refused`, `bound_row_side`).\n* **`Observation`**: Captures the result of a `read` step, including `read_row_side`, `read_claim_side`, and cache hit details.\n\n## Scenarios\n\nThe model enumerates two specific scenarios to cover isolation properties.\n\n### Scenario 1: Single Request vs Moving World\n* **Events**: 4 steps + 1 switch + 1 refresh.\n* **Logic**: One request (`R1`) runs against a world where the user's tenant changes (`switch`) and a new token is minted (`refresh`) concurrently.\n* **Permutations**: 30 valid orderings (filtered from 720).\n* **Cube**: 16 parameter combinations.\n* **Total Runs**: 480.\n\n### Scenario 2: Two Concurrent Requests + Switch\n* **Events**: 4+4 steps + 1 switch.\n* **Logic**: Two requests (`R1`, `R2`) for different tenants run concurrently, sharing one cache. A switch occurs for one of the users.\n* **Permutations**: 630 valid orderings (filtered from 362,880).\n* **Cube**: 64 parameter combinations.\n* **Total Runs**: 40,320.\n\n**Total Coverage**: 40,800 ordering × parameter combinations checked in ~0.5s.\n\n## Invariants\n\nThe model asserts seven invariants over the `Observation` data.\n\n| Invariant | Description |\n| :--- | :--- |\n| **I1** | **No wrong-tenant read**: The read executes under exactly the tenant `bind` authorized. |\n| **I2** | **No cross-tenant cache observation**: A cache hit only returns a value written for the same tenant. |\n| **I3** | **Bind refuses, never repairs**: `claim ≠ row` produces no read at all. |\n| **I4** | **Stability**: A switch landing strictly inside the `bind`→`read` window does not retarget the request. |\n| **I5** | **No process-global tenant**: Two concurrent requests for two tenants each read their own. |\n| **I6** | **Bounded staleness**: Once a switch is visible to a request's own `row` read, that request can never read the pre-switch tenant. |\n| **I7** | **No split-brain**: `req.startupId` consumers and `req.accessClaims` consumers inside ONE request resolve to the same tenant. |\n\n## Mutation Harness\n\n`mutation.py` ensures the invariants are meaningful by breaking the model clauses.\n\n### Strategy\nEach clause in `model.Policy` is turned off to create a mutant. The harness requires a **witness** (a specific counterexample) for each mutant. A mutant that remains green is a failure, indicating the clause is unguarded.\n\n### Mutants\n\n| Mutant | Clause Dropped | Required Witness |\n| :--- | :--- | :--- |\n| **M1** | `check_claim_against_row` (claim-only) | **I6** (4,082×) |\n| **M2** | `check_claim_against_row` (split) | **I7** (40,544×) |\n| **M3** | `tenant_in_cache_key` | **I2** (5,040×) |\n| **M4** | `per_request_binding` | **I5** (2,880×) |\n| **M5** | `bind_snapshot_is_stable` | **I4** (2,042×) |\n\n### Execution Flow\n1. **Control Run**: `explore(SPEC, collect=True)` must produce **zero** witnesses.\n2. **Mutant Run**: `explore(mutant_policy, collect=True)` must produce witnesses for the specific invariant guarding that clause.\n3. **Failure**: If a mutant produces no witnesses, or if the wrong invariant fires, the harness exits with code 1.\n\n## Execution\n\nRun the scripts from the module root:\n\n```bash\npython3 exhaustive.py # Verifies invariants (exits 0 on success)\npython3 mutation.py # Verifies invariants have teeth (exits 0 only if all caught)\nbash scripts/isolation-proof.sh # Runs both plus A/B lane gate\n```\n\n**Note**: `exhaustive.py` alone is not meaningful; a model with weak assertions is green for every implementation. `mutation.py` provides the verification that the assertions actually guard the code.\n\n## Integration with Codebase\n\nThe model abstracts specific implementation details but maps directly to shipped code:\n\n* **`claim`**: `src/middleware/startup-auth.ts:45,89`\n* **`row`**: `src/middleware/access-claims.ts:42-53`\n* **`bind`**: `src/middleware/access-claims.ts:63`\n* **`read`**: `retrieval-cache.ts:40`, `folder-cache.ts:46`\n* **Routes**: The model assumes a single resolution pipeline. The shipped server has two pipelines (one with cross-check, one without). The A/B isolation lane (`testpipe/isolation/`) reproduces the witness this model predicts for the route without the cross-check.\n\n## Honest Limits\n\nThis model enumerates bounded abstract transitions, not SQL schedules or full system behavior.\n\n* **SQL Isolation**: Postgres isolation levels, transaction boundaries, and connection-pool reuse are outside the model.\n* **Concurrency Scope**: Isolation is a pairwise property. Two tenants is the limit; three simultaneous requests or two switches are not enumerated.\n* **Cache Model**: The cache is modelled as one key with one entry. TTL expiry, LRU eviction, and `authorityVersion` are not modelled.\n* **JWT Verification**: The model assumes `jwt.verify` succeeds. Signature forgery and algorithm confusion are out of scope.\n* **Clock Skew**: Token expiry and clock skew are not modelled. The model proves the ordering property, not the duration.\n* **Middleware Mounting**: The model does not know which routes mount which middleware. It models one resolution pipeline.","docs-personas":"# docs — personas\n\n\n\n# Personas Module\n\n## Overview\n\nThe **Personas Module** serves as the single source of truth for all test tenants and user accounts within the Harakat platform. It replaced legacy registries (`journeys/fixtures/personas.ts`, `tenants.json`) to ensure consistency across pipelines. Every test persona is defined in a dedicated `persona.md` file within `docs/personas/`.\n\nDevelopers must load personas from these files. Do not re-declare user data next to pipeline scripts.\n\n## File Structure & Schema\n\nEach persona resides in a dedicated folder under `docs/personas/`. The structure is:\n\n```text\ndocs/personas/\n├── README.md # Module overview, global rules, password trap\n├── aqarat/\n│ └── persona.md # Tenant 99\n├── dar/\n│ └── persona.md # Tenant 96\n├── ibtisama/\n│ └── persona.md # Tenant 97\n├── lifespace/\n│ └── persona.md # Tenant 19 (Staging)\n├── wahaj/\n│ └── persona.md # Tenant 98\n└── waqf/\n └── persona.md # Tenant 95\n```\n\n### The 8-Section Standard\n\nEvery `persona.md` file must contain exactly eight sections to ensure pipelines are writable from the file alone:\n\n1. **Header Block:** Tenant ID, org type, backend status, re-seeding commands.\n2. **Business Context:** A sentence describing the business and its specific data problem.\n3. **The Cast:** Name, login, level, reporting line, and daily responsibilities.\n4. **Enabled Apps:** List of installed applications.\n5. **Identity Flip:** Custom field requirements and terminology changes (e.g., `Project` → `Patient`).\n6. **Journeys:** Specific flows (J1, J2...) to drive during testing.\n7. **Assistant Queries:** Behavioral asks to assert on records/tool calls.\n8. **Known Baseline:** Regressions or specific traps to measure against.\n\n## Tenant Lifecycle\n\n### Seeding and Resetting\n\nFor **Company Tenants (96–99)**, the system is designed to be re-converged idempotently.\n\n1. **Seed Company Personas:**\n ```sh\n pnpm dotenv -e .env.local -e .env -- tsx src/scripts/seed-company-personas.ts --apply\n ```\n2. **Push Kernel Claims:**\n Every write made by these users is a kernel write. The kernel denies unknown user IDs. You must push claims for each tenant ID sequentially:\n ```sh\n pnpm kernel:claims-push 96\n pnpm kernel:claims-push 97\n pnpm kernel:claims-push 98\n pnpm kernel:claims-push 99\n ```\n *Note: Do not use `--` before the ID.*\n\n### Staging Tenant (19)\n\n**Tenant 19 (LifeSpace)** is a long-lived staging environment with real synced data. It is **not** a vertical persona.\n\n* **Hard Rule:** Never re-seed or wipe Tenant 19.\n* **Hard Rule:** Never re-run the Drive sync or document backfill.\n* **Usage:** Use only for data-safety guardrails, deep org tree testing, and longitudinal regressions.\n* **Maintenance:** Additive only.\n\n## Authentication & Security\n\n### The Password Trap\n\nTest accounts do **not** share a single password. Using a shared constant will result in 401 errors that look like product bugs.\n\n| Password | Applies To |\n| :--- | :--- |\n| `HarakatTest!2607` | `coordiantor@lifespace.ae` (Tenant 19) and `e5admin@harakat.local` (Tenant 95) |\n| `Harakat#Test2026` | All other accounts (Tenants 96–99, and Tenant 19 non-admins) |\n\n### Access Control\n\nAccess rules are tested against the **org tree**, not just rank.\n* **Reporting Lines:** A user's visibility is determined by who they report to.\n* **Branches:** Users in different branches (e.g., Marketing vs. Procurement) must not see each other's scoped material.\n* **Levels:** Level 0 (Owner) sees everything; Level 2+ must be restricted from admin surfaces.\n\n## Tenant Catalog\n\n| Tenant ID | Name | Type | Backend | Password | Key Characteristic |\n| :--- | :--- | :--- | :--- | :--- | :--- |\n| **95** | Al Khair Waqf | NGO | Kernel + Awqaf | `HarakatTest!2607` | Arabic-first, Fund Accounting, Awqaf Pack |\n| **19** | LifeSpace | Staging | Mixed | `HarakatTest!2607` | Deep org tree, real corpus, never re-seed |\n| **96** | Dar Interiors | Company | Kernel | `Harakat#Test2026` | Fan-out/join stress (Design → Build) |\n| **97** | Ibtisama Dental | Company | Kernel | `Harakat#Test2026` | Identity flip (Project → Patient) |\n| **98** | Wahaj Marketing | Company | Kernel | `Harakat#Test2026` | Retainer/Campaign connectivity |\n| **99** | Aqarat Realty | Company | Kernel | `Harakat#Test2026` | Brokerage (No Property Model) |\n\n## Pipeline Integration\n\n### Loading Personas\n\nPipelines must load persona data from `docs/personas/` rather than hardcoding credentials. The `persona.md` files act as the configuration contract.\n\n### Execution Flow\n\n```mermaid\nflowchart TD\n A[Pipeline Start] --> B{Load Persona}\n B -->|Tenant 96-99| C[Seed Company Script]\n B -->|Tenant 19| D[Skip Seed / Read State]\n C --> E[Push Kernel Claims]\n D --> E\n E --> F[Run Test Walks]\n F --> G{Assertion Check}\n G -->|Pass| H[Report Success]\n G -->|Fail| I[Check Known Baseline]\n I -->|Known Bug| H\n I -->|New Bug| J[Update persona.md]\n```\n\n### Integration Points\n\n* **Seed Script:** `src/scripts/seed-company-personas.ts`\n* **Kernel Command:** `pnpm kernel:claims-push <ID>`\n* **Test Harness:** `journeys/` (uses loaded persona data)\n* **Assistant Harness:** `testpipe/` (drives assistant across retrieval/email)\n\n## Maintenance Rules\n\n1. **Facts are Verified:** Every level, role, and user ID in these files must come from a real login. If the server disagrees, fix the file before trusting results.\n2. **Move Capabilities, Don't Delete:** If a walk proves a user cannot do something, move it to the `cannot` section with the reason. Do not silently drop the line.\n3. **Tenant 19 Safety:** Never re-seed Tenant 19. Losing the startup-19 corpus is not recoverable.\n4. **Known Baselines:** Update the `Known baseline` section when a regression is fixed or a new trap is discovered. This prevents rediscovering known issues.\n\n## Known Technical Constraints\n\n* **Tenant 19 Backend:** Runs on its own ERP container (`harakat-erp-t19-g2`). Cloned from shared DB, carries residue.\n* **Passkeys:** Origin-bound to `http://localhost:3000`. Credentials registered elsewhere are rejected.\n* **Odoo Dependency:** Tenant 95 (Waqf) has a remaining dependency on `/erp/session` returning 500 for `res.company`.\n* **Language:** Tenant 95 requires `dir=\"rtl\" lang=\"ar\"` to survive reload.","docs-reference":"# docs — reference\n\n\n\n# docs/reference Module\n\n## Overview\n\nThe `docs/reference` module contains three distinct types of documentation artifacts:\n\n1. **Implementation examples** - Working code samples for external integrations\n2. **Procedure specifications** - Human-readable workflow definitions for business processes\n3. **Skill documentation** - Technical guides for document manipulation capabilities\n\nThis module serves as a reference library for developers who need to understand or extend these specific capabilities.\n\n---\n\n## File: `google-liveapi-example.py`\n\n### Purpose\n\nA complete implementation example for Google's LiveAPI (real-time multimodal AI) integration. This script demonstrates how to:\n\n- Connect to Google's LiveAPI with audio/video streaming\n- Handle bidirectional audio communication\n- Stream camera or screen capture to the model\n- Process real-time responses from the model\n\n### Key Components\n\n#### Configuration Constants\n\n```python\nMODEL = \"models/gemini-3.1-flash-live-preview\"\nSEND_SAMPLE_RATE = 16000 # Audio sent to model\nRECEIVE_SAMPLE_RATE = 24000 # Audio received from model\nCHUNK_SIZE = 1024 # Audio buffer size\nDEFAULT_MODE = \"camera\" # Default video source\n```\n\n#### Client Setup\n\n```python\nclient = genai.Client(\n http_options={\"api_version\": \"v1beta\"},\n api_key=os.environ.get(\"GEMINI_API_KEY\"),\n)\n\nCONFIG = types.LiveConnectConfig(\n response_modalities=[\"AUDIO\"],\n media_resolution=\"MEDIA_RESOLUTION_MEDIUM\",\n speech_config=types.SpeechConfig(\n voice_config=types.VoiceConfig(\n prebuilt_voice_config=types.PrebuiltVoiceConfig(voice_name=\"Zephyr\")\n )\n ),\n context_window_compression=types.ContextWindowCompressionConfig(\n trigger_tokens=104857,\n sliding_window=types.SlidingWindow(target_tokens=52428),\n ),\n)\n```\n\n#### AudioLoop Class Architecture\n\nThe `AudioLoop` class orchestrates all real-time communication tasks using `asyncio.TaskGroup`.\n\n```mermaid\ngraph TD\n A[AudioLoop.run] --> B[asyncio.TaskGroup]\n B --> C[send_text_task]\n B --> D[send_realtime_task]\n B --> E[listen_audio_task]\n B --> F[get_frames_task]\n B --> G[get_screen_task]\n B --> H[receive_audio_task]\n B --> I[play_audio_task]\n \n C --> J[User Input Queue]\n D --> K[Media Queue]\n E --> L[Audio In Queue]\n F --> M[Camera Stream]\n G --> N[Screen Stream]\n H --> O[Audio In Queue]\n I --> L\n```\n\n### Task Breakdown\n\n| Task | Method | Purpose |\n|------|--------|---------|\n| User input | `send_text()` | Accepts text commands from user |\n| Media streaming | `send_realtime()` | Sends camera/screen frames to model |\n| Microphone input | `listen_audio()` | Captures audio from microphone |\n| Camera capture | `get_frames()` | Streams camera video (1 FPS) |\n| Screen capture | `get_screen()` | Streams screen capture (1 FPS) |\n| Model response | `receive_audio()` | Receives audio/text from model |\n| Audio playback | `play_audio()` | Plays received audio to speakers |\n\n### Critical Implementation Details\n\n#### Async Thread Safety\n\nAll blocking operations use `asyncio.to_thread()`:\n\n```python\n# Camera capture - blocks if not in thread\nframe = await asyncio.to_thread(self._get_frame, cap)\n\n# Audio stream setup - blocks if not in thread\nself.audio_stream = await asyncio.to_thread(\n pya.open,\n format=FORMAT,\n channels=CHANNELS,\n rate=SEND_SAMPLE_RATE,\n input=True,\n frames_per_buffer=CHUNK_SIZE,\n)\n```\n\n#### Queue Management\n\n```python\nself.audio_in_queue = asyncio.Queue() # Model → Speaker\nself.out_queue = asyncio.Queue(maxsize=5) # User → Model\n```\n\nThe `out_queue` has a maxsize of 5 to prevent overflow when the model is slow to respond.\n\n#### Image Processing Pipeline\n\n```python\ndef _get_frame(self, cap):\n ret, frame = cap.read()\n if not ret:\n return None\n \n # BGR → RGB conversion (OpenCV default is BGR)\n frame_rgb = cv2.cvtColor(frame, cv2.COLOR_BGR2RGB)\n img = PIL.Image.fromarray(frame_rgb)\n img.thumbnail([1024, 1024])\n \n # Encode to JPEG\n image_io = io.BytesIO()\n img.save(image_io, format=\"jpeg\")\n image_io.seek(0)\n \n return {\n \"mime_type\": \"image/jpeg\",\n \"data\": base64.b64encode(image_io.read()).decode()\n }\n```\n\n### Error Handling\n\n```python\nasync def run(self):\n try:\n async with (\n client.aio.live.connect(model=MODEL, config=CONFIG) as session,\n asyncio.TaskGroup() as tg,\n ):\n # ... task setup ...\n await send_text_task\n raise asyncio.CancelledError(\"User requested exit\")\n \n except asyncio.CancelledError:\n pass\n except ExceptionGroup as EG:\n if self.audio_stream is not None:\n self.audio_stream.close()\n traceback.print_exception(EG)\n```\n\n### Usage\n\n```bash\n# Camera mode (default)\npython google-liveapi-example.py\n\n# Screen capture mode\npython google-liveapi-example.py --mode screen\n\n# Disable video\npython google-liveapi-example.py --mode none\n```\n\n---\n\n## File: `material-request-form-procedure.md`\n\n### Purpose\n\nA complete procedure specification for the Material Request Form workflow. This document maps directly to database schema fields and defines the complete business logic for procurement requests.\n\n### Architecture Mapping\n\n| Document Section | Database Entity |\n|-----------------|-----------------|\n| Procedure registration | `Procedure` row |\n| Step definitions | `Procedure.steps` JSON |\n| Run execution | `ProcedureRun` rows |\n| Capability scores | `CapabilityRun` rows |\n| Audit trail | `AuditEntry` rows |\n| Policy conflicts | `PolicyConflict` rows |\n\n### Procedure Flow\n\n```mermaid\nflowchart TD\n Start[User triggers procedure] --> S1[s1: Intake & Validation]\n S1 --> S2[s2: Estimation]\n S2 --> S3[s3: In Contract Decision]\n \n S3 -->|score ≥ 0.7| S4[s4: Issue PO]\n S3 -->|score ≤ 0.3| S7[s7: Manager Decision]\n S3 -->|\"0.3 < score < 0.7\"| Pause[PAUSED_AWAITING_APPROVAL]\n \n S7 -->|Client Approval| S8[s8: Client Approval]\n S7 -->|Variation| S9[s9: Estimation/Variation]\n S7 -->|Reject| Abort[Abort]\n \n S8 --> S4\n S9 --> S8\n S4 --> S5[s5: Procurement]\n S5 --> S6[s6: Delivery]\n S6 --> Complete[Procedure Completed]\n \n S4 -->|PO blocked| Escalate[Escalate]\n S5 -->|No quotes| Escalate\n S6 -->|Delivery delayed| Escalate\n```\n\n### Step Definitions\n\n| Step ID | Type | Assignee | Key Tools |\n|---------|------|----------|-----------|\n| s1 | `human_input` | Requester | OCR, Document extraction |\n| s2 | `assistant_action` | Estimation | Rate card lookup, cost calculation |\n| s3 | `decision` | Auto/Manager | `in_contract_classifier` |\n| s4 | `assistant_action` | Finance | `finance/issue_po` MCP |\n| s5 | `assistant_action` | Procurement | RFQ, quote ranking |\n| s6 | `wait` | Site | Email polling |\n| s7 | `human_input` | Manager | Branch selection |\n| s8 | `assistant_action` | Client Liaison | Email, approval tracking |\n| s9 | `assistant_action` | Estimation | Variation calculation |\n\n### Capability Training\n\nTwo predictive capabilities are proposed for this procedure:\n\n| Capability | Training Data | Features |\n|------------|---------------|----------|\n| `in_contract_classifier` | Manager decisions at s3 | Total cost, BOQ coverage, rate deviation |\n| `quote_ranker` | Vendor selections at s5 | Quote price, vendor history, lead time |\n\n### Policy Gates\n\n| Policy | Effect |\n|--------|--------|\n| `externalCommsAllowed: false` | Email steps require human approval |\n| `highStakesThresholdUsd: 5000` | POs > $5K require WebAuthn passkey |\n| `permittedCapabilityActions` | Blocks disallowed AI actions |\n| `dataRetention: 13 months` | Auto-archive after 13 months |\n\n---\n\n## File: `writing_docs_skill.md`\n\n### Purpose\n\nTechnical documentation for the DOCX document creation and manipulation skill. This guide covers the `docx-js` library usage patterns and common pitfalls.\n\n### Core Architecture\n\nDOCX files are ZIP archives containing XML. The skill provides two main approaches:\n\n1. **Programmatic creation** - Using `docx-js` to generate new documents\n2. **XML editing** - Unpack → edit XML → repack for modifications\n\n### Document Creation Patterns\n\n#### Page Size Configuration\n\n```javascript\nsections: [{\n properties: {\n page: {\n size: {\n width: 12240, // US Letter in DXA\n height: 15840\n },\n margin: { top: 1440, right: 1440, bottom: 1440, left: 1440 }\n }\n }\n}]\n```\n\n**DXA Unit Reference:** 1440 DXA = 1 inch\n\n| Paper | Width (DXA) | Height (DXA) |\n|-------|-------------|--------------|\n| US Letter | 12,240 | 15,840 |\n| A4 | 11,906 | 16,838 |\n\n#### Critical Rules\n\n| Rule | Reason |\n|------|--------|\n| Never use `WidthType.PERCENTAGE` | Breaks in Google Docs |\n| Always use `WidthType.DXA` | Consistent rendering |\n| Set `outlineLevel` on headings | Required for TOC |\n| Use `LevelFormat.BULLET` for bullets | Unicode bullets don't work |\n| Set `type` on `ImageRun` | Required parameter |\n| Use `ShadingType.CLEAR` | Prevents black backgrounds |\n\n#### Table Implementation\n\n```javascript\nnew Table({\n width: { size: 9360, type: WidthType.DXA },\n columnWidths: [4680, 4680],\n rows: [\n new TableRow({\n children: [\n new TableCell({\n width: { size: 4680, type: WidthType.DXA },\n borders: { top: border, bottom: border, left: border, right: border },\n children: [new Paragraph({ children: [new TextRun(\"Cell\")] })]\n })\n ]\n })\n ]\n})\n```\n\n**Table width rules:**\n- Table `width` must equal sum of `columnWidths`\n- Each cell `width` must match its column\n- Cell `margins` are internal padding (not added to width)\n\n### Document Editing Workflow\n\n```mermaid\nflowchart LR\n A[Input .docx] --> B[Unpack XML]\n B --> C[Edit XML files]\n C --> D[Pack .docx]\n D --> E[Validate]\n E -->|Fail| F[Auto-repair]\n F --> D\n E -->|Pass| G[Output .docx]\n```\n\n#### Step 1: Unpack\n```bash\npython scripts/office/unpack.py document.docx unpacked/\n```\n\n#### Step 2: Edit XML\n- Use `comment.py` for tracked changes\n- Use smart quotes: `&#x2019;` (apostrophe), `&#x201C;` (opening quote)\n- Replace entire `<w:r>` blocks for tracked changes\n\n#### Step 3: Pack\n```bash\npython scripts/office/pack.py unpacked/ output.docx --original document.docx\n```\n\n### Dependencies\n\n| Tool | Purpose |\n|------|---------|\n| `docx` (npm) | Programmatic document creation |\n| `pandoc` | Text extraction from DOCX |\n| `LibreOffice` | PDF conversion |\n| `Poppler` | Image extraction from PDF |\n\n---\n\n## Module Integration\n\n### How These Files Connect\n\n```mermaid\ngraph LR\n A[docs/reference] --> B[google-liveapi-example.py]\n A --> C[material-request-form-procedure.md]\n A --> D[writing_docs_skill.md]\n \n B --> E[genai.Client]\n B --> F[asyncio.TaskGroup]\n \n C --> G[ProcedureRun]\n C --> H[CapabilityRun]\n C --> I[AuditEntry]\n \n D --> J[docx-js]\n D --> K[XML editing]\n```\n\n### When to Use Each File\n\n| Use Case | Reference File |\n|----------|----------------|\n| Real-time AI with audio/video | `google-liveapi-example.py` |\n| Procurement workflow implementation | `material-request-form-procedure.md` |\n| DOCX document generation | `writing_docs_skill.md` |\n\n### Contributing Guidelines\n\n1. **google-liveapi-example.py**: Update only when API changes require breaking modifications\n2. **material-request-form-procedure.md**: Update when SOP changes or new capabilities are added\n3. **writing_docs_skill.md**: Update when `docx-js` library changes or new patterns emerge\n\nAll changes should maintain backward compatibility with existing implementations.","docs-retrieval":"# docs — retrieval\n\n\n\n# Retrieval Module — Technical Documentation\n\n## Overview\n\nThe Harakat retrieval system is a **vectorless, hierarchical, agentic retrieval pipeline** that combines Meilisearch full-text search with AI-generated document summaries and an agentic orchestrator. The system is intentionally designed without embedding models or vector databases to minimize operational complexity and cost.\n\nA hybrid vector option (Gemini Embedding 2 + Qdrant) is available as an optional add-on for specific use cases: multilingual retrieval, scanned-image PDFs, and paraphrase matching.\n\n---\n\n## Current Architecture\n\n### Core Design Principles\n\n| Principle | Rationale |\n|-----------|-----------|\n| **Vectorless by default** | No embedding bill, no re-indexing on model changes, minimal VM footprint |\n| **Hierarchical indexing** | PageIndex trees split documents into sections with AI descriptions |\n| **Agentic loop** | Search → open tree → read pages → refine |\n| **Tier-filtered** | All retrieval respects tenant access boundaries |\n\n### System Components\n\n```mermaid\nflowchart TB\n subgraph Client\n QRY[User Query]\n end\n \n subgraph Server\n API[Knowledge Routes]\n ORCH[Docs Orchestrator]\n RETRIEVAL[Retrieval Budget Specialist]\n end\n \n subgraph AI Service\n CLEAN[clean_workflow.py]\n ENRICH[enrichment_workflow.py]\n MULTIMODAL[multimodal_description.py]\n end\n \n subgraph Queue Workers\n CLEAN_DOC[clean-document.worker.ts]\n ENRICH_DOC[enrich-document.worker.ts]\n SEARCH_IDX[search-index.worker.ts]\n TOC_REBUILD[toc-rebuild.worker.ts]\n end\n \n subgraph Storage\n MEILI[(Meilisearch)]\n DB[(Postgres)]\n end\n \n QRY --> API\n API --> ORCH\n ORCH --> RETRIEVAL\n RETRIEVAL -.-> CLEAN\n RETRIEVAL -.-> ENRICH\n RETRIEVAL -.-> MULTIMODAL\n CLEAN --> CLEAN_DOC\n ENRICH --> ENRICH_DOC\n ENRICH --> SEARCH_IDX\n SEARCH_IDX --> MEILI\n TOC_REBUILD --> DB\n MEILI --> API\n DB --> API\n```\n\n---\n\n## Data Models\n\n### Prisma Schema Extensions\n\nThe retrieval system adds 5 new tables and 3 columns to `ParsedDocument`:\n\n```prisma\n// New tables\nmodel DocumentAbstract {\n id Int @id @default(autoincrement())\n parsedDocumentId Int\n text String\n tierLevel Int\n createdAt DateTime @default(now())\n}\n\nmodel MultimodalDescription {\n id Int @id @default(autoincrement())\n parsedDocumentId Int\n text String\n tierLevel Int\n createdAt DateTime @default(now())\n}\n\nmodel FolderRollup {\n id Int @id @default(autoincrement())\n folderId Int\n text String\n tierLevel Int\n createdAt DateTime @default(now())\n}\n\nmodel TenantTOC {\n id Int @id @default(autoincrement())\n startupId Int\n text String\n tierLevel Int\n createdAt DateTime @default(now())\n}\n\nmodel Entity {\n id Int @id @default(autoincrement())\n parsedDocumentId Int\n text String\n tierLevel Int\n createdAt DateTime @default(now())\n}\n\n// Extended ParsedDocument\nmodel ParsedDocument {\n cleanedAt DateTime?\n docDescription String?\n // ... existing fields\n}\n```\n\n### Tier Filtering Logic\n\nTier filtering is enforced at multiple layers:\n\n```typescript\n// search.service.ts\nfunction tierStringToLevel(tier: string): number {\n // null = MOST_RESTRICTIVE_TIER (polarity flip)\n}\n\n// Every Meilisearch filter clause includes tier level\n// Every derived row inherits tier from source node\n// TenantTOC is redacted at read\n```\n\n---\n\n## Queue Architecture\n\n### Six BullMQ Queues\n\nAll workers self-skip when `ENABLE_RETRIEVAL_V2 !== \"true\"`:\n\n| Queue | Worker | Purpose |\n|-------|--------|---------|\n| `clean-document` | `clean-document.worker.ts` | Deterministic 9-rule pipeline (no LLM) |\n| `enrich-document` | `enrich-document.worker.ts` | AI-generated abstracts, multimodal descriptions |\n| `entity-extract` | `entity-extract.worker.ts` | Entity extraction with taxonomy constraints |\n| `search-index` | `search-index.worker.ts` | Meilisearch indexing |\n| `folder-rollup` | `folder-rollup.worker.ts` | Folder-level summaries |\n| `toc-rebuild` | `toc-rebuild.worker.ts` | Tenant table of contents |\n\n### Worker Registration\n\n```typescript\n// queues.ts\nexport const queues = {\n cleanDocument: 'clean-document',\n enrichDocument: 'enrich-document',\n entityExtract: 'entity-extract',\n searchIndex: 'search-index',\n folderRollup: 'folder-rollup',\n tocRebuild: 'toc-rebuild',\n}\n```\n\n### Worker Self-Skip Pattern\n\n```typescript\n// All workers in src/core/queue/workers/\nif (process.env.ENABLE_RETRIEVAL_V2 !== 'true') {\n return; // Skip execution\n}\n```\n\n---\n\n## AI Endpoints\n\n### Clean Workflow (Deterministic)\n\n```python\n# Harakat_AI/workflows/clean_workflow.py\n# 9-rule pipeline, no LLM\n# Input: raw document bytes\n# Output: cleaned text\n```\n\n### Multimodal Description\n\n```python\n# Harakat_AI/workflows/multimodal_description.py\n# Per-MIME dispatch:\n# - Excel → LibreOffice → PDF → vision\n# - PDF → PyMuPDF → vision\n# - Images → OCR + vision\n# - Text → fallback\n```\n\n### Enrichment Workflow (LLM)\n\n```python\n# Harakat_AI/workflows/enrichment_workflow.py\n# Four structured-JSON endpoints:\n# - /parse/abstract\n# - /parse/folder-rollup\n# - /parse/tenant-toc\n# - /parse/entities (taxonomy-constrained)\n```\n\n---\n\n## Agentic Retrieval Loop\n\n### Orchestrator Configuration\n\n```python\n# Harakat_AI/agents/specialists/retrieval_budget.py\n# Caps: 30k tokens, 14s wall-clock, 4 rounds\n# Env-overridable limits\n```\n\n### Retrieval Flow\n\n```python\n# Harakat_AI/agents/specialists/docs_orchestrator.py\n# 4-round agentic loop with retrieval_trace envelopes\n```\n\n### Server Entry Point\n\n```typescript\n// HarakatOffices_Server/src/modules/knowledge/knowledge.routes.ts\nPOST /api/startup/knowledge/retrieve\nModes: toc | search | abstract\n```\n\n### Retrieval Trace Envelope\n\n```python\n# Harakat_AI/envelopes/result_envelope.py\n# retrieval_trace kind added to envelopes\n```\n\n---\n\n## Hybrid Vector Option (Qdrant + Gemini Embedding 2)\n\n### When to Add Vectors\n\n**Add vectors if:**\n- Users hit the **paraphrase wall** (search words not in documents)\n- **Multilingual retrieval** matters (Arabic↔English)\n- **Scanned/image PDFs** are common and OCR fails\n- Willing to operate one more stateful service\n\n**Skip vectors if:**\n- Current retrieval quality meets needs\n- Document volume is modest and born-digital\n- Want minimal VM footprint and ops surface\n\n### Cost Analysis\n\n#### Storage/RAM (Qdrant)\n\n| Chunks | Raw Vectors | RAM (768-dim) | With Quantization |\n|--------|-------------|---------------|-------------------|\n| 100k | ~0.3 GB | ~0.5 GB | ~0.1 GB |\n| 1M | ~3 GB | ~4-6 GB | ~0.7-1.5 GB |\n| 5M | ~15 GB | ~20-30 GB | ~3-7 GB |\n\n**Recommendation:** Start at 768 dimensions with quantization enabled.\n\n#### Embedding Bill\n\n```\none-time backfill ≈ (total tokens) / 1,000,000 × $0.20\nincremental ≈ tokens per new/changed doc (batch = 50% off)\n```\n\n### Hybrid Architecture\n\n```mermaid\nflowchart LR\n DOC[Document] --> TXT[Text + PageIndex]\n TXT --> FTS[(Meilisearch)]\n TXT -.-> EMB[Gemini Embedding 2]\n EMB -.-> Q[(Qdrant)]\n QRY[User Query] --> FTS\n QRY -.-> EMB\n FTS --> MERGE[Merge + Rerank + Tier Filter]\n Q -.-> MERGE\n MERGE --> ANS[Answer with Citations]\n```\n\n### Implementation Path\n\n1. Keep Meilisearch as precision/keyword/tier-filter layer\n2. Add Gemini Embedding 2 + Qdrant as recall booster\n3. Start at 768 dimensions with quantization on\n4. Use batch API (50% off)\n5. Reuse existing tier filter for vector hits\n\n---\n\n## Operations & Maintenance\n\n### Environment Variables\n\n```bash\n# HarakatOffices_Server/.env\nMEILI_URL=http://meilisearch:7700\nMEILI_MASTER_KEY=<32-char random>\nENABLE_RETRIEVAL_V2=false # Default: keep off\n```\n\n### Migration Deployment\n\n```bash\ncd HarakatOffices_Server\nnpx prisma migrate deploy\n# Applies:\n# - 20260521000000_retrieval_v2_models\n# - 20260521010000_retrieval_v2_tenant_flag\n```\n\n### Per-Tenant Rollout\n\n```bash\n# List all tenants\npnpm flip:retrieval-v2 --list\n\n# Backfill pilot tenant (dry-run first)\npnpm backfill:retrieval-v2 --startup 19 --operator-email <email> --dry-run\npnpm backfill:retrieval-v2 --startup 19 --operator-email <email> --limit 200\n\n# Flip tenant on\npnpm flip:retrieval-v2 --startup 19 --on --operator-email <email>\n\n# Rollout to remaining tenants\npnpm flip:retrieval-v2 --startup <id> --on --operator-email <email>\n```\n\n### Rollback\n\n```bash\n# Force-disable for any tenant\npnpm flip:retrieval-v2 --startup <id> --off --operator-email <email>\n# AI service falls back to legacy LIKE path\n```\n\n### Monitoring\n\nWatch these metrics via PostHog:\n- `retrieval.latency_ms`\n- `retrieval.rounds`\n\n---\n\n## Security Invariants\n\n- ✅ `canSee` on every server read path\n- ✅ `writeAudit` per mutation\n- ✅ Polarity-flip (`null = MOST_RESTRICTIVE_TIER`) honored\n- ✅ Tier inheritance on derived rows\n- ✅ No client-side tierLevel input\n- ✅ Workers are SYSTEM actors (no agent-owned table writes)\n\n---\n\n## Troubleshooting\n\n### Failed PageIndex Build\n\n```typescript\n// retryFailedPageIndexBuilds(startupId, opts)\n// Re-enqueue parse-tree with force=true and smaller chunk-size\n// Fallback: deterministic outline from regex-detected headings\n```\n\n### Empty docDescription\n\n```typescript\n// Fallback: hash of first 1k cleaned chars\n// Ensures Meilisearch never sees null\n```\n\n### Worker Not Running\n\n```bash\n# Check queue registration\ngrep \"enqueueParseTree\" src/core/queue/queues.ts\n\n# Verify worker file exists\nls src/core/queue/workers/parse-tree.worker.ts\n```\n\n---\n\n## Related Documentation\n\n- `PLATFORM_OVERVIEW.md` §7 — vectorless retrieval explanation\n- `odoo.md` — semantic search over tabular data (separate question)\n- `docs/retrieval/EMBEDDINGS_QDRANT.md` — vector addition decision framework\n\n---\n\n## Version History\n\n| Version | Date | Status |\n|---------|------|--------|\n| v2 | 2026-05-21 | Phases A–I complete on disk |\n| v1 | N/A | Legacy LIKE-based retrieval |\n\n**Current State:** Gated behind `ENABLE_RETRIEVAL_V2=false`. Legacy retrieval remains unchanged until explicitly enabled.","docs-security":"# docs — security\n\n\n\n# docs/security — Security Audit & Conformance Documentation\n\n## Overview\n\nThe `docs/security` module is a **documentation repository** containing security audit reports, conformance test specifications, and threat model documentation for the Harakat platform. It does not contain executable security code — instead, it documents security findings, compliance obligations, and architectural security requirements.\n\nThis module serves as the **single source of truth** for security posture, audit evidence, and remediation priorities across the HarakatOffices_Server, Harakat_AI, and StartupsPlatform services.\n\n## Purpose and Scope\n\n### Primary Objectives\n\n1. **Document security vulnerabilities** with severity ratings (Critical/High/Medium/Low)\n2. **Track remediation priorities** with actionable fix descriptions\n3. **Provide conformance test specifications** for tenant isolation verification\n4. **Maintain threat model documentation** for security engineering decisions\n\n### Scope Coverage\n\n| Component | Coverage |\n|-----------|----------|\n| HarakatOffices_Server | Full audit coverage |\n| Harakat_AI | Full audit coverage |\n| StartupsPlatform | Full audit coverage |\n| Infrastructure | Docker, secrets, logging |\n\n### Document Types\n\n```mermaid\ngraph TD\n A[Security Docs Module] --> B[Audit Reports]\n A --> C[Conformance Tests]\n A --> D[Threat Models]\n \n B --> B1[AUDIT_REPORT.md]\n B --> B2[Top 10 Prioritized Fixes]\n \n C --> C1[ab-isolation-conformance.md]\n C --> C2[Self-check Scripts]\n \n D --> D1[codex_security_audit.md]\n D --> D2[Trust Boundaries]\n```\n\n## Key Components\n\n### 1. AUDIT_REPORT.md\n\nThe primary security audit document covering four main areas:\n\n#### 1.1 Sync Data Pipeline\n\nDocuments issues in the Drive → ParsedDocument → KnowledgeNode → PageIndexTree pipeline:\n\n| Issue | Severity | Location |\n|-------|----------|----------|\n| Plaintext OAuth tokens & passwords | Critical | `prisma/schema.prisma#L1050-1051` |\n| No idempotency on re-sync | High | `knowledge.service.ts#L7` |\n| Per-section HTTP round-trip | High | `document_indexer.py#L182-216` |\n| Failure handling silently drops files | High | `google-drive.service.ts#L97-116` |\n| No backpressure on indexing queue | Medium | `indexing_workflow.py#L39` |\n| OCR lacks budget guard | Medium | `core/ocr.py` |\n| Drive heartbeat visibility | Medium | `drive-heartbeat.service.ts` |\n\n#### 1.2 Graph & Tree Construction\n\nDocuments issues in knowledge graph construction:\n\n| Issue | Severity | Location |\n|-------|----------|----------|\n| Inverted tier polarity | Critical | `knowledge.service.ts#L80-112` |\n| Tier suffix not enforced | High | `tierLevel` function |\n| No soft-delete on KnowledgeNode | Medium | N/A |\n| No edges between sections | Low | `PageIndexTree.structure` |\n| Tree-build unbounded memory | Medium | `parse_workflow.py#L454-490` |\n\n#### 1.3 Export Pipeline\n\nDocuments export-related security concerns:\n\n- Imperative scripts (`_check_*.js`, `_wipe_sync_data.js`, `_reset_sync.js`) with no auth/audit\n- Outbound email exfiltration risk via `_send_email`\n- Missing GDPR data export endpoint\n\n#### 1.4 Cybersecurity\n\nDocuments 12 security vulnerabilities:\n\n| Issue | Severity | Location |\n|-------|----------|----------|\n| No 2FA on StartupUser | Critical | `prisma/schema.prisma#L184` |\n| Admin 2FA codes stored unhashed | High | `prisma/schema.prisma#L17` |\n| No CSRF nonce on Drive OAuth | High | `google-drive.service.ts#L42` |\n| AI service trusts client startup_id | Critical | `indexing_workflow.py#L47-55` |\n| JWT secret default and rotation | Medium | N/A |\n| Service account JSON path | High | `docker-compose.yml#L57` |\n| Loose secrets in .env files | High | N/A |\n| Rate limiting is global | Medium | `rate-limit.ts` |\n| Mass-assignment risk | Medium | Controllers |\n| Prompt-injection surface | High | Agent tools |\n| No content hashing | Low | `StartupDocument` |\n| Logging of file content | Low | N/A |\n\n### 2. ab-isolation-conformance.md\n\nDefines the **A/B tenant-isolation conformance test suite** with 12 obligation rows:\n\n#### Test Structure\n\n```mermaid\ngraph LR\n A[Self-check] --> B[Ordering Model]\n A --> C[Live Lane Test]\n B --> D[CI Gate]\n C --> E[Stack Lock]\n E --> F[12 Assertions]\n```\n\n#### Obligation Table\n\n| Row | Obligation | Status |\n|-----|------------|--------|\n| 0 | `row_zero_routing_key` | ❌ FAIL |\n| 1 | `reassignment_staleness` | ❌ FAIL |\n| 2-11 | Various isolation checks | ✅ PASS |\n\n#### Key Findings\n\n- **Row 0 failure**: Token claiming another tenant is served on routes without `attachAccessClaims`\n- **Row 1 failure**: Reassigned employee reads former tenant for 7-day token lifetime\n- **11 of 12 rows conformant** with 1 pending (delegation grants require WebAuthn)\n\n### 3. codex_security_audit.md\n\nProvides the **threat model and attack surface documentation**:\n\n#### Trust Boundaries\n\n```mermaid\ngraph TD\n A[Public HTTP] --> B[Express/Prisma API]\n B --> C[Postgres/Redis]\n B --> D[AI FastAPI]\n D --> E[Privileged Workers]\n \n F[Frontend] -->|sessionStorage| B\n G[AI Service] -->|JWT| B\n```\n\n#### Attack Surface Categories\n\n| Category | Examples |\n|----------|----------|\n| Auth/session | Stale JWTs, logout not revoking |\n| Authorization/tenant isolation | IDOR on startupId, officeId, userId |\n| Files/document indexing | MIME spoofing, token in URLs |\n| AI/LLM/tools | Prompt injection, tool abuse |\n| OAuth/integrations | CSRF on callback, plaintext tokens |\n| Internal/callback/worker | Docker socket mount, service account paths |\n\n## How It Works\n\n### Audit Process Flow\n\n```mermaid\nsequenceDiagram\n participant Auditor\n participant Code\n participant Schema\n participant TestSuite\n \n Auditor->>Code: Review implementation\n Code->>Schema: Check data model\n Schema-->>Auditor: Findings\n Auditor->>TestSuite: Run conformance tests\n TestSuite-->>Auditor: Pass/Fail results\n Auditor->>AUDIT_REPORT.md: Document findings\n```\n\n### Conformance Test Execution\n\n1. **Self-check**: `python3 testpipe/isolation/selfcheck.py`\n2. **Ordering model**: `bash scripts/isolation-proof.sh`\n3. **Live lane**: `bash scripts/isolation-proof.sh --live` (requires stack lock)\n\n### Integration with Codebase\n\nThe security documentation references specific code locations:\n\n```\ndocs/security/\n├── AUDIT_REPORT.md # Main audit findings\n├── ab-isolation-conformance.md # Tenant isolation tests\n└── codex_security_audit.md # Threat model\n```\n\nThese documents reference:\n- `HarakatOffices_Server/src/` - Backend implementation\n- `Harakat_AI/` - AI service implementation\n- `prisma/schema.prisma` - Data model\n- `testpipe/isolation/` - Conformance test suite\n\n## Usage Guidelines\n\n### For Developers\n\n1. **Before implementing new features**: Review `codex_security_audit.md` threat model\n2. **When fixing vulnerabilities**: Reference `AUDIT_REPORT.md` Top 10 prioritized fixes\n3. **When adding new routes**: Ensure `attachAccessClaims` middleware is mounted\n4. **When handling secrets**: Use GCP Secret Manager, not `.env` files\n\n### For Security Engineers\n\n1. **Run conformance tests**: `python3 testpipe/isolation/selfcheck.py`\n2. **Review failed rows**: Check `ab-isolation-conformance.md` for context\n3. **Track remediation**: Use `AUDIT_REPORT.md` Top 10 list as sprint backlog\n\n### For Product Managers\n\n1. **Understand risk**: Critical/High issues affect production security\n2. **Prioritize fixes**: Top 10 list indicates effort vs. risk reduction\n3. **Compliance**: GDPR data export endpoint is a Medium priority requirement\n\n## Connection to Other Modules\n\n### Security ↔ Authentication\n\n```mermaid\ngraph LR\n A[Security Docs] --> B[StartupAuth Middleware]\n A --> C[JWT Verification]\n A --> D[2FA Implementation]\n \n B --> E[verifyStartupUser]\n C --> F[attachAccessClaims]\n D --> G[TOTP Enrollment]\n```\n\n### Security ↔ AI Services\n\n```mermaid\ngraph LR\n A[Security Docs] --> B[AI Service]\n A --> C[Tool Allowlist]\n A --> D[Prompt Injection]\n \n B --> E[Startup ID Verification]\n C --> F[_send_email]\n D --> G[User Data Delimiters]\n```\n\n### Security ↔ Data Layer\n\n```mermaid\ngraph LR\n A[Security Docs] --> B[Prisma Schema]\n A --> C[Encryption]\n A --> D[Secrets Management]\n \n B --> E[StartupUser]\n C --> F[KMS Envelope]\n D --> G[GCP Secret Manager]\n```\n\n## Top 10 Prioritized Fixes\n\nFrom `AUDIT_REPORT.md`, the highest priority remediations:\n\n1. **KMS-envelope OAuth tokens, Zoho password, refresh tokens**\n2. **Fix tier polarity** (inverted RBAC)\n3. **TOTP 2FA on StartupUser signup**\n4. **AI service: assert startup_id against JWT before any tool call**\n5. **Outbound email recipient allowlist + side-effect tool approvals**\n6. **Bulk knowledge-graph upsert + transactional sync**\n7. **Hash 2FA codes; add CSRF nonce on Drive OAuth callback**\n8. **Move service-account JSON out of submodule; secrets via GCP Secret Manager**\n9. **Soft-delete knowledge nodes; reconcile on sync; content-hash dedup**\n10. **Per-user rate limits on side-effect tools; OCR budget cap per tenant**\n\n## Maintenance\n\n### Update Frequency\n\n- **AUDIT_REPORT.md**: Quarterly or after major releases\n- **ab-isolation-conformance.md**: After each tenant isolation change\n- **codex_security_audit.md**: When threat model assumptions change\n\n### Evidence Storage\n\nRaw test output is stored in:\n- `.sdd-work/vendor-extraction/T7.5-evidence/isolation-proof-live-run.txt`\n\n### Version Tracking\n\nEach document includes:\n- Date of audit\n- Server commit hash\n- Database version\n- Tenant IDs used in testing\n\n---\n\n**Note**: This documentation module is read-only. Security fixes are implemented in the referenced code locations, not in this module. The module serves as the audit trail and specification for security engineering work.","docs":"# docs\n\n\n\n# docs\n\nThe `docs` module serves as the central knowledge repository for the Harakat platform, bridging infrastructure planning, operational execution, and developer resources. It defines the lifecycle of the `HarakatOffices_Server` environment, from hardware capacity estimation to security conformance and deployment procedures.\n\n## Infrastructure & Operations\n\nThe operational backbone of the platform is defined in the **Deployment** and **Capacity** modules.\n* **Capacity Planning**: The [Capacity](capacity.md) module establishes the single source of truth for hardware procurement, analyzing token economics to determine the machine configuration required for target user counts.\n* **Deployment Procedures**: The [Deployment](deployment.md) module tracks manual intervention points and schema evolution for the `HarakatOffices_Server` container. While Docker handles code updates, this module documents the security migrations and data integrity checks required on the deployed VM.\n* **Security**: The [Security](security.md) module acts as the audit trail for the platform, documenting vulnerability findings and compliance obligations for `HarakatOffices_Server` and `Harakat_AI`.\n\n## Data & Intelligence\n\nData handling and intelligence capabilities are governed by the **Personas**, **Retrieval**, and **AutoML** modules.\n* **Personas**: The [Personas](personas.md) module replaces legacy registries, serving as the single source of truth for test tenants. Every test persona is defined in a dedicated `persona.md` file, ensuring consistency across pipelines.\n* **Retrieval**: The [Retrieval](retrieval.md) module implements a vectorless, hierarchical pipeline using Meilisearch and AI-generated summaries. It supports optional hybrid vector capabilities for multilingual or scanned-image retrieval.\n* **AutoML**: The [AutoML](automl.md) module defines the design for Self-Building Predictive Capabilities, allowing the assistant to identify learnable patterns in tenant data without exposing ML terminology to users.\n\n## Verification & Reference\n\nQuality assurance and developer guidance are centralized in the **Formal** and **Reference** modules.\n* **Formal Verification**: The [Formal](formal.md) module provides a bounded executable model for verifying tenant-resolution ordering. It implements a state machine that enumerates interleavings of tenant resolution steps against concurrent world events to assert seven security invariants.\n* **Reference Library**: The [Reference](reference.md) module contains implementation examples (e.g., Google LiveAPI integration) and procedure specifications (e.g., Material Request Form workflows) for extending platform capabilities.\n\n## System Workflow\n\nThe following diagram illustrates how these sub-modules interact to support the platform lifecycle:\n\n```mermaid\nflowchart TD\n subgraph Planning\n Cap[Capacity Planning]\n Auto[AutoML Design]\n end\n\n subgraph Execution\n Dep[Deployment Procedures]\n Sec[Security Audit]\n end\n\n subgraph Data & Logic\n Per[Personas]\n Ret[Retrieval Pipeline]\n For[Formal Verification]\n end\n\n subgraph Reference\n Ref[Reference Examples]\n end\n\n Cap -->|Hardware Config| Dep\n Auto -->|Feature Logic| Ret\n Per -->|Test Data| Ret\n For -->|Security Invariants| Dep\n Dep -->|Operational State| Sec\n Ref -->|Integration Patterns| Auto\n```\n\n## Integration Points\n\n* **Security & Deployment**: The [Formal](formal.md) module's state machine verifies tenant resolution logic, feeding security invariants into the [Deployment](deployment.md) manual intervention checklist.\n* **Data & Retrieval**: [Personas](personas.md) provide the test data required to validate the [Retrieval](retrieval.md) pipeline, while [AutoML](automl.md) designs define the predictive patterns the retrieval system may eventually support.\n* **Reference & Development**: The [Reference](reference.md) module provides the code samples (e.g., `google-liveapi-example.py`) that developers use to implement the capabilities defined in [AutoML](automl.md) and [Retrieval](retrieval.md).","erp-harakat-backend-erp-harakat-backend":"# erp-harakat-backend — erp-harakat-backend\n\n\n\n# erp-harakat-backend\n\n## Overview\n\nThe `erp-harakat-backend` module defines the runtime environment for the Odoo 19 ERP application. It is not a Python application logic module but rather a containerized service definition responsible for hosting the Odoo server, managing dependencies, and exposing the API to external clients.\n\nThis module encapsulates the Odoo 19 source code, system-level dependencies, and configuration required to run the backend service. It does not contain internal business logic execution flows; instead, it orchestrates the Odoo process (`odoo-bin`) to handle requests.\n\n## Infrastructure Stack\n\nThe service is built using a Docker container based on the `python:3.12-slim-bookworm` image. The build process installs specific system dependencies required by Odoo for PDF generation, database connectivity, and image processing.\n\n### System Dependencies\nThe following packages are installed at build time to support Odoo functionality:\n* **PDF Generation:** `wkhtmltopdf`\n* **Database Client:** `postgresql-client`\n* **Image Processing:** `libjpeg-dev`, `libfreetype6-dev`, `fonts-noto-cjk`\n* **XML/HTML Parsing:** `libxml2-dev`, `libxslt1-dev`\n* **LDAP Support:** `libldap2-dev`, `libsasl2-dev`\n* **Utilities:** `curl`, `ca-certificates`, `libmagic1`\n\n### Odoo Installation\nThe Odoo source code is vendored into the container at `/opt/erp/odoo`. The installation process performs an editable install:\n```bash\npip install --no-cache-dir -e /opt/erp/odoo\n```\nThis ensures that changes to the vendored source are reflected in the running environment without rebuilding the image.\n\n## Configuration\n\nThe service behavior is controlled by `/etc/odoo/odoo.conf`. Key configuration parameters include:\n\n| Parameter | Value | Description |\n| :--- | :--- | :--- |\n| `addons_path` | `/opt/erp/odoo/addons,/mnt/extra-addons` | Defines the search path for Odoo modules. Custom addons are mounted at `/mnt/extra-addons`. |\n| `data_dir` | `/var/lib/odoo` | Directory for storing database files and logs. |\n| `without_demo` | `all` | Prevents the installation of demo data during startup. |\n| `list_db` | `False` | Disables the database listing feature in the web interface. |\n| `proxy_mode` | `True` | Enables proxy mode for the web server. |\n\n### Database Connection\nDatabase credentials are not hardcoded. The `odoo.conf` file explicitly comments that `db_host`, `db_user`, and `db_password` are sourced from environment variables at runtime:\n* `HOST`\n* `USER`\n* `PASSWORD`\n\nDevelopers must ensure these environment variables are set when deploying the container to establish a connection to the PostgreSQL database.\n\n## Runtime & Entry Point\n\nThe container runs as the non-root user `erp`. The entrypoint is defined in the `Dockerfile` to execute the Odoo binary:\n\n```bash\nENTRYPOINT [\"python3\", \"/opt/erp/odoo/odoo-bin\"]\nCMD [\"-c\", \"/etc/odoo/odoo.conf\"]\n```\n\n* **Entry Point:** `python3 /opt/erp/odoo/odoo-bin`\n* **Command:** `-c /etc/odoo/odoo.conf`\n\nThis configuration ensures the Odoo server starts with the specified configuration file. The `odoo-bin` script handles the initialization of the WSGI server and the application logic.\n\n## Network & Security\n\n* **Exposed Port:** `8069` (HTTP)\n* **User:** The process runs under the `erp` user (`USER erp`).\n* **Security:** The `proxy_mode` setting in `odoo.conf` is enabled, which is recommended for production environments to handle reverse proxy headers correctly.\n\n## Architecture\n\nThe following diagram illustrates the relationship between the external client, the backend container, and the database.\n\n```mermaid\ngraph TD\n Client[External Client] -->|HTTP 8069| Container[erp-harakat-backend Container]\n Container -->|Process| Odoo[Odoo 19 Process (odoo-bin)]\n Odoo -->|DB Connection| Postgres[(PostgreSQL)]\n Container -.->|Mounts| Addons[/mnt/extra-addons]\n```\n\n### Component Responsibilities\n\n1. **External Client:** Initiates HTTP requests to port 8069.\n2. **erp-harakat-backend Container:** Hosts the Odoo process, manages the Python environment, and serves as the network boundary.\n3. **Odoo 19 Process:** Executes the business logic and API endpoints defined in the vendored source.\n4. **PostgreSQL:** Stores persistent data. Connection details are injected via environment variables.\n5. **Custom Addons:** Located at `/mnt/extra-addons`, these are mounted into the container to extend functionality without modifying the base image.","erp-harakat-backend-scripts":"# erp-harakat-backend — scripts\n\n\n\n# erp-harakat-backend/scripts\n\nThis module contains utility scripts for database migration, tenant isolation, and branding cleanup during the transition from Odoo to the custom ERP stack. The scripts are designed to be idempotent where possible and prioritize data integrity through transactional safety mechanisms (savepoints/rollbacks).\n\n## Overview\n\nThe scripts support the \"Startup-19\" migration workflow, specifically isolating Company 1 (LifeSpace/Harakat) from a multi-tenant Odoo instance. The workflow consists of three main components:\n\n1. **`debrand.sh`**: Cleans up the codebase branding and module names.\n2. **`tenant19_scrub.py`**: Isolates Company 1 in a database clone by removing all other tenants' data.\n3. **`tenant19_manifest.py`**: Generates a checksum manifest to verify data integrity between the source and scrubbed databases.\n\n## File Descriptions\n\n### `debrand.sh`\n\nA Bash script responsible for renaming and updating branding references within the `custom_addons` directory. It ensures the codebase reflects the new ERP identity without touching the Odoo framework namespace.\n\n**Key Operations:**\n* **Directory Renaming:** Renames `isomorphic_bridge` to `erp_bridge` if the old directory exists.\n* **Manifest Updates:** Modifies `$ADDONS/erp_bridge/__manifest__.py` to replace \"Isomorphic UI Bridge\" with \"ERP Bridge\" and updates the example URL to `https://harakat.tech`.\n* **Reference Replacement:** Recursively searches `custom_addons` for references to `isomorphic_bridge` and replaces them with `erp_bridge`.\n\n**Idempotency:**\nThe script checks for the existence of `$ADDONS/isomorphic_bridge` before attempting to move it, ensuring it can be run multiple times without error.\n\n### `tenant19_scrub.py`\n\nA Python script executed via the Odoo shell against a `tenant_19` CLONE. It performs a destructive scrub of the database to remove all data belonging to companies other than `KEEP_COMPANY` (1).\n\n**Safety Mechanisms:**\n* **Savepoints:** Uses `cr.execute(\"SAVEPOINT ...\")` and `ROLLBACK TO SAVEPOINT` for every model deletion and user removal. If a deletion fails, only the specific row is rolled back.\n* **Dry Run:** Supports a `DRY_RUN` flag to preview deletions without committing changes.\n* **Verification Gates:** Before committing, it verifies that no foreign data remains and that only Company 1 exists.\n\n**Execution Flow:**\nThe script follows a strict 9-step process to handle foreign key dependencies:\n1. **Pass-1:** Deletes company-scoped rows on every model.\n2. **Pass-2:** Deletes shared rows attributed to foreign users.\n3. **Attachments/Mail:** Removes foreign attachments and cancels pending outgoing mail.\n4. **Users:** Deactivates and deletes foreign users.\n5. **FK Break:** Updates `res_company` nullable foreign keys to NULL to prevent FK errors during company deletion.\n6. **Company Deletion:** Deletes the remaining companies.\n7. **Pass-3:** Deletes config rows (calendars, sequences) freed by company deletion.\n8. **Verification:** Checks for zero foreign data and zero active foreign users.\n9. **Commit:** Sets tenant identity parameters (`harakat.startup_id`, `database.uuid`) and commits.\n\n**Key Functions:**\n* `delete_company_rows(model)`: Handles bulk deletion of rows belonging to removed companies with savepoint protection.\n* `company_models()`: Returns a list of non-transient, non-abstract models that have a `company_id` field.\n\n### `tenant19_manifest.py`\n\nA Python script executed via the Odoo shell to generate a preservation manifest. It is run on both the source `erp` DB and the scrubbed `tenant_19` DB to compare record counts and ID checksums.\n\n**Key Operations:**\n* **Record Counting:** Counts records for a predefined list of `MODELS` (e.g., `sale.order`, `account.move`, `harakat.document.dispatch`).\n* **ID Checksums:** Generates a SHA16 digest of sorted record IDs for each model to ensure no data was lost or altered.\n* **State Analysis:** For `account.move`, it breaks down records by state and total amount.\n* **User Verification:** Counts retained users and generates a login checksum.\n\n**Output:**\nPrints a JSON object containing counts, ID digests, and state breakdowns for comparison.\n\n## Migration Workflow\n\nThe scripts are used in a specific sequence to ensure a clean migration from the Odoo environment to the isolated ERP tenant.\n\n```mermaid\nflowchart LR\n A[Codebase Prep] -->|Run debrand.sh| B[Cleaned Codebase]\n B -->|Clone DB| C[tenant_19 Clone]\n C -->|Run tenant19_scrub.py| D[Isolated Company 1]\n D -->|Run tenant19_manifest.py| E[Source DB]\n E -->|Compare Manifests| F{Integrity Check}\n F -->|Pass| G[Migration Complete]\n F -->|Fail| H[Rollback/Debug]\n```\n\n## Technical Details\n\n### Odoo Shell Usage\nAll Python scripts (`tenant19_scrub.py`, `tenant19_manifest.py`) are designed to be run via the Odoo shell:\n```bash\nodoo -d <database_name> -i <module> -u <module> --shell <script_path>\n```\nThey rely on `env` (the Odoo environment) and `env.cr` (the database cursor).\n\n### Data Integrity Guards\nIn `tenant19_scrub.py`, specific business logic guards are respected during deletion:\n* **Lifecycle Guards:** For models like `sale.order`, the script attempts to cancel the record (`action_cancel` or `button_cancel`) before deletion to bypass \"cannot delete a sent quotation\" constraints.\n* **Foreign References:** If a row is referenced by retained data, the deletion is caught by the savepoint and logged in `skipped`.\n\n### Configuration Parameters\nUpon successful scrubbing, the following parameters are set in `ir.config_parameter`:\n* `harakat.startup_id`: Set to `\"19\"`.\n* `database.uuid`: Set to a new UUID4.\n\n### Model Lists\n* **`MODELS` (Manifest):** Includes core Odoo models (`res.partner`, `sale.order`) and custom models (`harakat.document.dispatch`, `planning.slot`).\n* **`ATTRIBUTED` (Scrub):** Includes shared models that may be owned by foreign users (`res.partner`, `knowledge.article`, `crm.competitor`).\n\n## Error Handling\n* **`debrand.sh`:** Uses `set -euo pipefail` to exit immediately on error.\n* **`tenant19_scrub.py`:** If verification gates fail (foreign data remains, FK violations), the script executes `cr.rollback()` and exits without committing changes.\n* **`tenant19_manifest.py`:** Prints `absent: True` for models not found in the environment, allowing for easy diffing of schema changes.","erp-harakat-backend":"# erp-harakat-backend\n\n\n\n# erp-harakat-backend\n\n## Overview\n\nThe `erp-harakat-backend` module defines the runtime environment for the Odoo 19 ERP application. It is not a Python application logic module but rather a containerized service definition responsible for hosting the Odoo server, managing dependencies, and exposing the API to external clients.\n\nThis module encapsulates the Odoo 19 source code, system-level dependencies, and configuration required to run the backend service. It does not contain internal business logic execution flows; instead, it orchestrates the Odoo process (`odoo-bin`) to handle requests.\n\n## Infrastructure Stack\n\nThe service is built using a Docker container based on the `python:3.12-slim-bookworm` image. The build process installs specific dependencies to support the Odoo runtime and custom extensions.\n\n## Sub-Modules\n\nThe backend relies on supporting modules to manage the environment and data integrity:\n\n- **[custom_addons](custom_addons.md)**: Contains the custom business logic and extensions for the ERP stack.\n- **[scripts](scripts.md)**: Provides utility scripts for database migration, tenant isolation, and branding cleanup.\n\n## Workflow Integration\n\nThe `scripts` module supports the \"Startup-19\" migration workflow, specifically isolating Company 1 (LifeSpace/Harakat) from a multi-tenant Odoo instance. Key scripts include `debrand.sh` for codebase cleanup, `tenant19_scrub.py` for database cloning, and `tenant19_manifest.py` for configuration generation. These scripts ensure data integrity through transactional safety mechanisms (savepoints/rollbacks) before the `erp-harakat-backend` service initializes the Odoo process.\n\n## Architecture\n\n```mermaid\ngraph TD\n A[Migration Scripts] -->|Prepare Environment| B_erp-harakat-backend[\"B(erp-harakat-backend)\"]\n B -->|Hosts| C[Odoo 19 Server]\n B -->|Loads| D[custom_addons]\n C -->|API| E[External Clients]\n```","harakat-admin-docs":"# Harakat_Admin — docs\n\n\n\n# Learning Hub API Integration\n\n## Overview\n\nThe Learning Hub API Integration module provides a complete backend and frontend solution for managing educational content within the Harakat Admin system. It enables administrators to create, update, and delete courses, manage course materials, and track startup enrollments and progress.\n\nThe module is built using **Next.js** (Frontend), **Express** (Backend), **Prisma** (ORM), and **PostgreSQL**. It enforces strict data integrity through database constraints and middleware-based authentication.\n\n## Architecture\n\nThe system follows a standard RESTful architecture with a clear separation between the client (Next.js Admin), the API layer (Express), and the data layer (PostgreSQL).\n\n### System Flow\n\n```mermaid\nsequenceDiagram\n participant Admin as Admin UI\n participant Client as API Client<br/>(lib/api/learning.ts)\n participant Server as Express Server<br/>(routes/learning.routes.ts)\n participant Controller as Controller<br/>(modules/learning/*.controller.ts)\n participant DB as Prisma Client<br/>(PostgreSQL)\n\n Admin->>Client: API Call (e.g., createCourse)\n Client->>Server: HTTP POST /api/learning/courses\n Server->>Controller: Route Handler\n Controller->>DB: Prisma Transaction\n DB-->>Controller: Data\n Controller-->>Server: Response\n Server-->>Client: JSON Response\n Client-->>Admin: UI Update\n```\n\n## Database Schema\n\nThe module relies on three core models defined in `prisma/schema.prisma`. All models are managed via the `harakatoffices_db` PostgreSQL instance.\n\n### Course Model\nRepresents the educational content available in the hub.\n\n| Field | Type | Description |\n| :--- | :--- | :--- |\n| `id` | `Int` | Primary Key |\n| `title` | `String` | Course title |\n| `category` | `String` | Content category |\n| `description` | `String` | Detailed description |\n| `instructor` | `String` | Instructor name |\n| `level` | `CourseLevel` | BEGINNER, INTERMEDIATE, ADVANCED |\n| `duration` | `String` | Estimated duration |\n| `credits` | `Int` | Academic credits |\n| `status` | `CourseStatus` | DRAFT, ACTIVE, ARCHIVED |\n| `rating` | `Float` | Average rating |\n\n**Relationships:**\n- One-to-Many with `CourseEnrollment`\n- One-to-Many with `CourseMaterial`\n\n### CourseEnrollment Model\nTracks which startups are enrolled in which courses.\n\n| Field | Type | Description |\n| :--- | :--- | :--- |\n| `id` | `Int` | Primary Key |\n| `courseId` | `Int` | FK to Course |\n| `startupId` | `Int` | FK to Startup |\n| `officeId` | `Int` | FK to Office |\n| `progress` | `Int` | 0-100% completion |\n| `status` | `EnrollmentStatus` | IN_PROGRESS, COMPLETED, DROPPED |\n| `enrolledAt` | `DateTime` | Enrollment timestamp |\n| `completedAt` | `DateTime` | Completion timestamp |\n\n**Constraints:**\n- **Unique:** `courseId` + `startupId` (Prevents duplicate enrollments).\n- **Auto-Complete:** Logic in `updateEnrollment` sets status to `COMPLETED` if `progress` reaches 100%.\n\n### CourseMaterial Model\nStores file references for course content.\n\n| Field | Type | Description |\n| :--- | :--- | :--- |\n| `id` | `Int` | Primary Key |\n| `courseId` | `Int` | FK to Course |\n| `fileName` | `String` | Local filename |\n| `fileUrl` | `String` | Public URL |\n| `fileSize` | `Int` | File size in bytes |\n| `uploadedAt` | `DateTime` | Upload timestamp |\n\n**Constraints:**\n- **Cascade Delete:** Materials are deleted when the associated course is deleted.\n\n## Backend Implementation\n\n### Controllers\n\nControllers are located in `src/modules/learning/`. They handle business logic and database interactions.\n\n#### `courses.controller.ts`\nManages CRUD operations for courses.\n\n- **`getCourses()`**: Fetches courses with optional filters (`status`, `category`, `instructor`, `search`).\n- **`getCourseById(id)`**: Retrieves a single course including associated materials and enrollment counts.\n- **`createCourse(data)`**: Creates a new course record.\n- **`updateCourse(id, data)`**: Updates course metadata.\n- **`deleteCourse(id)`**: Deletes a course. **Validation:** Returns 400 if the course has active enrollments.\n- **`addCourseMaterials(courseId, materials)`**: Batch adds file references to a course.\n- **`deleteCourseMaterial(courseId, materialId)`**: Removes a specific material.\n\n#### `enrollments.controller.ts`\nManages startup enrollment tracking.\n\n- **`getEnrollments()`**: Lists enrollments with filters (`courseId`, `startupId`, `officeId`, `status`).\n- **`getEnrollmentById(id)`**: Fetches a specific enrollment record.\n- **`createEnrollment(data)`**: Registers a startup in a course. **Validation:** Checks existence of Course, Startup, and Office.\n- **`updateEnrollment(id, data)`**: Updates progress or status. Triggers auto-completion logic if `progress === 100`.\n- **`deleteEnrollment(id)`**: Removes an enrollment record.\n\n### Routes\n\nRoutes are defined in `src/routes/learning.routes.ts` and registered at `/api/learning` in `src/app.ts`. All endpoints require authentication via the `requireAuth` middleware.\n\n#### Course Endpoints\n| Method | Endpoint | Description |\n| :--- | :--- | :--- |\n| `GET` | `/api/learning/courses` | List courses |\n| `GET` | `/api/learning/courses/:id` | Get single course |\n| `POST` | `/api/learning/courses` | Create course |\n| `PUT` | `/api/learning/courses/:id` | Update course |\n| `DELETE` | `/api/learning/courses/:id` | Delete course |\n| `POST` | `/api/learning/courses/:id/materials` | Add materials |\n| `DELETE` | `/api/learning/courses/:id/materials/:materialId` | Delete material |\n\n#### Enrollment Endpoints\n| Method | Endpoint | Description |\n| :--- | :--- | :--- |\n| `GET` | `/api/learning/enrollments` | List enrollments |\n| `GET` | `/api/learning/enrollments/:id` | Get single enrollment |\n| `POST` | `/api/learning/enrollments` | Create enrollment |\n| `PUT` | `/api/learning/enrollments/:id` | Update enrollment |\n| `DELETE` | `/api/learning/enrollments/:id` | Delete enrollment |\n\n## Frontend Integration\n\n### API Client\nThe API client is defined in `lib/api/learning.ts`. It provides type-safe wrappers around the HTTP requests.\n\n#### `coursesApi`\n- `list(filters?)`: Fetches courses. Supports query params for filtering.\n- `getById(id)`: Fetches a specific course.\n- `create(data)`: Submits a new course.\n- `update(id, data)`: Updates an existing course.\n- `delete(id)`: Removes a course.\n- `addMaterials(id, materials)`: Adds file references.\n- `deleteMaterial(courseId, materialId)`: Removes a file reference.\n\n#### `enrollmentsApi`\n- `list(filters?)`: Fetches enrollments.\n- `getById(id)`: Fetches a specific enrollment.\n- `create(data)`: Registers an enrollment.\n- `update(id, data)`: Updates progress/status.\n- `delete(id)`: Removes an enrollment.\n\n### Components\n\n#### `app/admin/learning-hub/page.tsx`\nThe main dashboard page for the Learning Hub.\n- **State Management:** Uses local state to manage the list of courses and enrollments.\n- **Search:** Implements debounced search (300ms delay) on the `title` field.\n- **Tabs:** Switches between \"Courses\" and \"Enrollments\" views.\n- **Error Handling:** Displays toast notifications for API failures.\n- **Auto-Reload:** Triggers a re-fetch of data after successful mutations.\n\n#### `components/learning-hub/AddCourseDialog.tsx`\nA modal component for creating new courses.\n- **Props:** Accepts `onSave: (data: CreateCourseData) => void`.\n- **Validation:** Validates required fields before submission.\n- **Reset:** Clears form state upon successful save.\n\n#### `components/learning-hub/ViewCourseDialog.tsx`\nA modal for viewing and editing course details.\n- **Props:** Accepts `onEdit`, `onDelete`, and course data.\n- **Actions:** Includes a destructive \"Delete\" button with a confirmation dialog.\n\n#### `components/learning-hub/tabs/EnrollmentsTab.tsx`\nDisplays the enrollment list.\n- **Status Styling:** Renders red badges for `dropped` status.\n- **Progress:** Displays completion percentage.\n\n## Data Integrity & Security\n\n### Authentication\nAll API routes are protected by the `requireAuth` middleware. Unauthenticated requests are rejected before reaching the controller logic.\n\n### Validation\n1. **Database Constraints:**\n - Unique constraint on `CourseEnrollment` (`courseId` + `startupId`).\n - Cascade delete on `CourseMaterial`.\n2. **Business Logic:**\n - Course deletion is blocked if `enrollments.length > 0`.\n - Enrollment progress is clamped to 0-100 range.\n - Auto-completion triggers when `progress` hits 100.\n\n### Error Handling\n- **Backend:** Controllers wrap database operations in `try-catch` blocks. Errors are returned as JSON with descriptive messages.\n- **Frontend:** API client errors are caught and mapped to user-friendly toast notifications.\n\n## Usage Examples\n\n### Create a Course\n```bash\nPOST /api/learning/courses\nContent-Type: application/json\n\n{\n \"title\": \"Advanced TypeScript\",\n \"category\": \"Programming\",\n \"instructor\": \"John Doe\",\n \"duration\": \"8h 30m\",\n \"credits\": 25,\n \"level\": \"advanced\",\n \"status\": \"active\",\n \"description\": \"Deep dive into TypeScript...\"\n}\n```\n\n### List Courses with Filters\n```bash\nGET /api/learning/courses?search=typescript&status=active\n```\n\n### Create Enrollment\n```bash\nPOST /api/learning/enrollments\nContent-Type: application/json\n\n{\n \"courseId\": 1,\n \"startupId\": 1,\n \"officeId\": 1\n}\n```\n\n### Update Enrollment Progress\n```bash\nPUT /api/learning/enrollments/1\nContent-Type: application/json\n\n{\n \"progress\": 75\n}\n```\n\n## Testing\n\n### Manual Testing Checklist\n- [ ] Create a course and verify it appears in the list.\n- [ ] Attempt to delete a course with active enrollments (expect 400 error).\n- [ ] Create an enrollment and verify the unique constraint prevents duplicates.\n- [ ] Update enrollment progress to 100% and verify status changes to `COMPLETED`.\n- [ ] Search courses with debounced input.\n- [ ] Verify toast notifications appear on API errors.\n\n## Future Enhancements\n\n### Phase 2 (Recommended)\n- **File Upload:** Integrate actual file storage (e.g., AWS S3) for `CourseMaterial`.\n- **Certificates:** Generate and issue certificates upon course completion.\n- **Analytics:** Dashboard for instructor performance and enrollment completion rates.\n\n### Phase 3 (Advanced)\n- **Prerequisites:** Define required courses before enrolling.\n- **Assessments:** Add quizzes and grading logic.\n- **Recommendations:** ML-based course suggestions based on user history.\n\n## Notes for Contributors\n1. **Type Safety:** Ensure all new API endpoints have corresponding interfaces in `lib/api/learning.ts`.\n2. **Migration:** Any schema changes require a new Prisma migration (`prisma migrate dev`).\n3. **Performance:** Database queries should utilize indexes on `courseId`, `startupId`, and `status` fields.\n4. **Security:** Do not bypass `requireAuth` middleware in new routes.","harakat-admin-e2e":"# Harakat_Admin — e2e\n\n\n\n# Harakat_Admin — e2e\n\nThis module contains the end-to-end (E2E) test suite for the `Harakat_Admin` application. It validates the Admin console's UI states, route behavior, error handling, and authentication flows using Playwright.\n\nThe suite is designed to verify that the application behaves correctly under specific conditions (found records, missing records, permission denials, server outages) and that the shell and session management function as intended.\n\n## Architecture\n\nThe test harness is built around a custom fixture defined in `console.ts`. This fixture manages the browser session, injects a valid operator token, and intercepts all API calls to return deterministic responses based on the test scenario.\n\n### Test Execution Flow\n\nWhen a test runs, the `open` fixture initializes the environment. It injects the operator session into `sessionStorage` and registers a route handler that intercepts API requests.\n\n```mermaid\nsequenceDiagram\n participant Test as Test Runner\n participant Fixture as open() Fixture\n participant Browser as Playwright Browser\n participant Mock as answer() Handler\n participant Server as API Origin\n\n Test->>Fixture: open(path, scenario)\n Fixture->>Browser: addInitScript (Session)\n Fixture->>Browser: route(API_ORIGIN/**)\n Browser->>Mock: page.route()\n Mock->>Mock: fixtureFor() / answer()\n Mock-->>Browser: JSON Response (200/403/500)\n Browser->>Test: DOM / Text\n Test->>Test: Assertions\n```\n\n### Key Components\n\n#### 1. Console Fixtures (`console.ts`)\nThe core of the test suite is the `ConsoleFixtures` interface, which extends the base Playwright test.\n\n* **`open(path, scenario?)`**: The primary entry point for tests.\n * Injects the `OPERATOR` token into `sessionStorage` via `addInitScript`.\n * Registers a catch-all route handler for `${API_ORIGIN}/**`.\n * Sets the `scenario` (default: `ok`).\n * Waits for the page to render (`[data-page-frame]`, `[data-not-found]`, or `h1`).\n* **`answer(route, scenario)`**: Determines the response based on the `scenario`.\n * **`ok`**: Returns a well-shaped JSON body from `FIXTURES` (longest prefix match).\n * **`denied`**: Returns `403` with a specific message.\n * **`outage`**: Returns `500` with a specific message.\n * **`malformed`**: Returns `200` with a JSON structure that causes a client-side crash (e.g., string instead of array).\n* **`visibleText(page)`**: A helper that normalizes the page's `innerText` into a single string for assertion. This ensures tests check *what the operator sees*, not internal state.\n* **`apiCalls`**: A fixture array that logs every API request made during the test.\n\n#### 2. Test Suites\n\nThe module is divided into three main spec files, each targeting specific invariants.\n\n##### `records.spec.ts`\nValidates detail routes for specific resources (Support Tickets, Marketplace Agents, Learning Courses, Services).\n\n* **Route Existence**: Asserts that detail routes render a frame (`[data-page-frame]`) and have a heading, distinguishing them from Next.js default 404s.\n* **Absence Handling**:\n * **`get-404`**: For resources with a `get-one` route, verifies the server returns a 404 for missing IDs.\n * **`not-in-list`**: For resources without a `get-one` route (e.g., Providers), verifies the list endpoint returns a 404 for missing IDs.\n* **Error States**:\n * **Denied (403)**: Must mention permissions, never \"not found\", and never offer a \"Try again\".\n * **Outage (500)**: Must mention server failure, offer a \"Try again\", and retain the record's ID in the heading.\n * **Non-numeric ID**: Must refuse without calling the server (e.g., `/admin/support/banana`).\n* **Linking**: Verifies that list pages link to their respective detail routes.\n\n##### `routes.spec.ts`\nValidates general admin routes and the application shell.\n\n* **Rendering**: Asserts every route renders exactly one `<h1>` with the correct page name.\n* **Error Distinction**:\n * **Denied vs. Outage**: Ensures the text content differs between 403 and 500 states.\n * **Malformed**: Ensures a 200 response with invalid JSON shape (e.g., `data: \"unexpected\"`) does not cause a white screen (Next.js crash).\n* **Figures**: Asserts that counts (e.g., \"Total Companies 0\") are not displayed confidently under 403/500 states; they should render as `—`.\n* **Shell**:\n * **Unauthenticated**: Redirects to `/login` without rendering the shell frame.\n * **Navigation**: Ensures all nav links resolve to valid routes (status < 400).\n\n##### `session.spec.ts`\nValidates the authentication and logout flow.\n\n* **Server Revocation**: Verifies that clicking \"Logout\" sends a `POST /api/auth/logout` request with the `Bearer` token.\n* **Client Clearing**:\n * Clears `sessionStorage` (`harakat_admin_session`).\n * Writes a `localStorage` entry (`harakat_admin_logout_at`) to broadcast the logout to other tabs.\n* **Failure Handling**:\n * If the logout request fails (aborted), the client must still clear the session to prevent the operator from being trapped with a live credential.\n* **Cross-Tab**: Ensures the logout signal is broadcast via `localStorage` so other tabs are notified of the session end.\n\n## Critical Invariants\n\nThe test suite enforces several strict rules derived from the application's register and previous bug fixes (e.g., `VER2`, `FIX4`).\n\n1. **403 vs. 500 Distinction**: A permission denial (403) must never offer a \"Try again\" link, as retrying a denial is futile. A server outage (500) must offer a \"Try again\" link.\n2. **Empty vs. Missing**: \"No companies yet\" (empty list) must be distinguishable from \"Could not load companies\" (outage).\n3. **Logout Revocation**: Signing out must delete the session row on the server, not just clear the browser. A failed network request during logout must still clear the local session.\n4. **Route Linking**: Every list route must link to its detail routes. A route with no caller is considered incomplete.\n5. **Malformed JSON**: The application must handle a 200 response with an unexpected JSON shape gracefully (e.g., `data: \"unexpected\"` instead of `data: []`) without crashing to a white screen.\n\n## Configuration\n\nThe tests rely on the `playwright.config` file for the `API_ORIGIN` constant. This ensures that API mocking targets the correct base URL.\n\n* **`SESSION_KEY`**: `\"harakat_admin_session\"`\n* **`OPERATOR`**:\n * `token`: `\"e2e.admin.token\"`\n * `email`: `\"operator@harakat.test\"`\n * `role`: `\"super_admin\"`\n* **`MALFORMED`**: A predefined JSON object used to trigger client-side crashes in the `malformed` scenario.\n\n## Contributing\n\nWhen adding new tests:\n1. **Use `open`**: Always use the `open` fixture to handle session injection and API mocking.\n2. **Assert Visible Text**: Use `visibleText(page)` for text assertions to ensure you are checking the rendered DOM, not internal state.\n3. **Check `apiCalls`**: Use the `apiCalls` fixture to verify that specific endpoints were called or not called (e.g., non-numeric IDs should not trigger API calls).\n4. **Scenario Selection**: Use the `scenario` argument (`\"ok\"`, `\"denied\"`, `\"outage\"`, `\"malformed\"`) to control the API response without modifying the server.","harakat-admin-hooks":"# Harakat_Admin — hooks\n\n\n\n# Harakat_Admin — Hooks\n\nThis module encapsulates shared React hooks for the Harakat Admin interface. It centralizes logic for responsive design, authentication lifecycle management, robust data fetching with race condition prevention, and notification handling.\n\n## Overview\n\nThe hooks in this module address common architectural challenges in the admin dashboard:\n* **Race Conditions:** `useResource` prevents stale data overwrites during rapid state updates.\n* **Session Consistency:** `useAuthCheck` ensures cross-tab synchronization for logout events.\n* **UI State:** `use-toast` and `useIsMobile` provide standardized UI feedback and layout detection.\n\n## Data Fetching: `useResource`\n\nThe `useResource` hook is the primary mechanism for fetching data in the admin interface. It was refactored to solve race conditions where multiple rapid fetches could overwrite newer data with older responses.\n\n### Implementation Details\n\n* **Generation Counter:** Every fetch run increments a `generation` ref. Before updating state, the hook checks if the current `generation` matches the one that initiated the fetch. If not, the response is discarded.\n* **Abort Control:** Uses `AbortController` to cancel in-flight requests when dependencies change.\n* **Stale State:** When `loading` is true but `data` exists, the `stale` flag is set. This allows the UI to render existing data with a visual indicator rather than blanking the screen during a refresh.\n* **Debouncing:** Supports `debounceMs` to throttle fetches based on dependency changes.\n\n### API\n\n```typescript\nexport function useResource<T>(\n fetcher: (signal: AbortSignal) => Promise<T>,\n deps: unknown[],\n options: UseResourceOptions = {}\n): ResourceState<T>\n```\n\n**Returns:** `ResourceState<T>`\n* `data`: The fetched data.\n* `error`: Error object if the fetch failed.\n* `status`: HTTP status code if the error is an `ApiError`.\n* `loading`: Boolean indicating if a request is in flight.\n* `stale`: Boolean indicating if the current data is being refreshed.\n* `reload`: Function to trigger a new fetch.\n* `setData`: Function to update local state without a network call.\n\n### Execution Flow\n\nThe hook ensures that only the most recent request can update state.\n\n```mermaid\nsequenceDiagram\n participant Hook as useResource Hook\n participant Fetch as fetcher()\n participant State as React State\n\n Hook->>Hook: run()\n Hook->>Hook: generation++\n Hook->>Fetch: fetch(signal)\n Fetch-->>Hook: Response\n Hook->>Hook: Check generation\n alt Generation Match\n Hook->>State: setData(result)\n else Generation Mismatch\n Hook->>Hook: Ignore result\n end\n```\n\n### Integration Points\n\n`useResource` is the data layer for the following components:\n* **MarketplaceAgentPage** (`marketplace/[id]/page.tsx`)\n* **CoursePage** (`learning-hub/[id]/page.tsx`)\n* **CompaniesPage** (`admin/companies/page.tsx`)\n* **AdminDashboard** (`app/admin/page.tsx`)\n* **LearningHub** (`admin/learning-hub/page.tsx`)\n* **ShadowPanel** (`components/governance/shadow-panel.tsx`)\n* **GovernanceConsole** (`components/governance/governance-console.tsx`)\n* **PromptInspector** (`components/governance/prompt-inspector.tsx`)\n* **RevisionHistory** (`components/governance/revision-history.tsx`)\n* **UsersTab** (`settings/tabs/UsersTab.tsx`)\n* **TenantsView** (`components/packs/packs-console.tsx`)\n* **VesselTemplatesPage** (`admin/vessel-templates/page.tsx`)\n* **SupportTicketPage** (`support/[id]/page.tsx`)\n* **CompanyDetailPage** (`companies/[id]/page.tsx`)\n* **ServicesManagementPage** (`admin/services/page.tsx`)\n* **MarketplaceManagementPage** (`admin/marketplace/page.tsx`)\n* **ServiceProviderPage** (`services/[id]/page.tsx`)\n* **PacksConsole** (`components/packs/packs-console.tsx`)\n* **SupportPage** (`admin/support/page.tsx`)\n* **CreditsTab** (`settings/tabs/CreditsTab.tsx`)\n* **MarketplaceAgentPage** (`marketplace/[id]/page.tsx`)\n\n## Authentication: `useAuthCheck`\n\nThis hook manages the authentication lifecycle, specifically handling token expiration and cross-tab session synchronization.\n\n### Key Functions\n\n* **`markLoginSuccess()`**: Resets the expiration timer and flags when a user logs in. Should be called immediately after a successful login or 2FA verification.\n* **`handleTokenExpiration()`**: Triggered on HTTP 401 errors.\n * **Grace Period:** Ignores expiration triggers within 5 seconds of login (`LOGIN_GRACE_PERIOD`) to prevent false positives.\n * **Single Execution:** Uses a global flag (`isHandlingExpiration`) to ensure the logout flow runs only once per session expiry.\n * **Cross-Tab Sync:** Calls `endSession()` to broadcast a logout event via `localStorage` (`LOGOUT_BROADCAST_KEY`), ensuring all tabs sign out simultaneously.\n* **`useAuthCheck()`**: Sets up a `storage` event listener to detect logouts initiated in other tabs.\n\n### Cross-Tab Synchronization\n\nThe hook listens for `StorageEvent` changes. Because `storage` events only fire for `localStorage` changes across tabs, `endSession()` writes a specific key (`LOGOUT_BROADCAST_KEY`) to `localStorage` to trigger the listener in other tabs.\n\n### Integration Points\n\n* **AdminLayout** (`app/admin/layout.tsx`): Wraps the admin interface to ensure auth checks are active.\n* **handleLogin** (`app/login/page.tsx`): Calls `markLoginSuccess` upon successful login.\n* **handleVerify2FA** (`app/login/page.tsx`): Calls `markLoginSuccess` upon 2FA verification.\n\n## Notifications: `use-toast`\n\nA custom toast notification system inspired by `react-hot-toast`. It manages a singleton state of toasts using a reducer pattern.\n\n### Configuration\n\n* **`TOAST_LIMIT`**: Set to `1`. Only the most recent toast is displayed.\n* **`TOAST_REMOVE_DELAY`**: `1000000` ms (1000 seconds). Default timeout for auto-dismissal.\n\n### API\n\n```typescript\nexport function useToast()\nexport function toast(props: Toast)\n```\n\n**`useToast()`** returns:\n* `state`: Current toast state.\n* `toast`: Function to create a new toast.\n* `dismiss`: Function to dismiss a toast by ID.\n\n**`toast()`** returns:\n* `id`: Unique identifier for the toast.\n* `dismiss`: Function to dismiss the specific toast.\n* `update`: Function to update the toast properties.\n\n### Architecture\n\nThe hook uses a global `memoryState` and a `listeners` array. When `toast` is called, it dispatches an action to the reducer, updates `memoryState`, and notifies all listeners. This pattern allows multiple components to subscribe to the toast state without direct state coupling.\n\n### Integration Points\n\n* **useAuthCheck**: Uses `react-hot-toast` directly for specific auth errors, but `use-toast` is available for general UI feedback.\n\n## Utilities: `useIsMobile`\n\nA simple hook for detecting mobile devices based on a viewport breakpoint.\n\n### Configuration\n\n* **`MOBILE_BREAKPOINT`**: `768` px.\n\n### API\n\n```typescript\nexport function useIsMobile()\n```\n\n**Returns:** `boolean`\n* `true` if `window.innerWidth < 768`.\n* `false` otherwise.\n\n### Implementation\n\nUses `window.matchMedia` to listen for viewport changes. It initializes the state immediately and updates on `change` events.\n\n## Module Dependencies\n\n* **React**: `useState`, `useEffect`, `useCallback`, `useRef`.\n* **Next.js**: `useRouter`.\n* **External**: `react-hot-toast` (used in `useAuthCheck`), `@/lib/auth/session` (used in `useAuthCheck`), `@/lib/api/errors` (used in `useResource`).","harakat-admin-styles":"# Harakat_Admin — styles\n\n\n\n# Harakat_Admin — styles\n\n## Overview\n\nThe `globals.css` module serves as the central configuration file for the application's visual design system. It leverages **Tailwind CSS v4** to define global color tokens, typography settings, and base layer resets. This file does not contain runtime logic; instead, it acts as a static stylesheet that initializes the theme context for the entire application.\n\n## Theme System & Color Tokens\n\nThe module implements a comprehensive color system using the **OKLCH** color space, which provides better perceptual uniformity compared to traditional RGB or HSL.\n\n### Light Mode\nDefault color values are defined in the `:root` selector. These variables are used for the standard application interface.\n\n```css\n:root {\n --background: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --primary: oklch(0.205 0 0);\n /* ... additional tokens ... */\n}\n```\n\n### Dark Mode\nDark mode values are defined within the `.dark` selector. This ensures that when the application's dark mode class is active, the CSS variables automatically update to high-contrast dark values.\n\n```css\n.dark {\n --background: oklch(0.145 0 0);\n --foreground: oklch(0.985 0 0);\n --primary: oklch(0.985 0 0);\n /* ... additional tokens ... */\n}\n```\n\n### Custom Variants\nThe `@custom-variant dark` directive enables the use of the `dark:` modifier in Tailwind utility classes (e.g., `dark:bg-background`).\n\n## Tailwind v4 Integration\n\nThis module utilizes the native Tailwind v4 CSS-first configuration approach.\n\n### `@theme inline`\nThe `@theme inline` directive maps the CSS custom properties defined in `:root` and `.dark` directly to Tailwind's utility class system. This allows developers to use semantic class names (e.g., `bg-background`, `text-foreground`) instead of hardcoded hex codes.\n\n**Example Usage:**\n```html\n<div class=\"bg-background text-foreground\">\n <!-- Renders using --background and --foreground variables -->\n<\/div>\n```\n\n### Font Configuration\nTypography is configured via CSS custom properties referencing external font assets:\n- `--font-sans`: Mapped to `var(--font-geist-sans)`\n- `--font-mono`: Mapped to `var(--font-geist-mono)`\n\nDevelopers must ensure these font assets are loaded in the application entry point (e.g., `index.html` or `layout.tsx`) for these variables to resolve correctly.\n\n## Global Resets & Base Layer\n\nThe `@layer base` directive applies global styles that cascade over the entire application.\n\n### Border & Outline\nAll elements inherit a border color defined by `--border` and an outline style defined by `--ring`.\n```css\n* {\n @apply border-border outline-ring/50;\n}\n```\n\n### Body Styling\nThe `body` element is explicitly styled to use the background and foreground colors defined in the theme.\n```css\nbody {\n @apply bg-background text-foreground;\n}\n```\n\n## Architecture & Execution Flow\n\nThis module is a **static configuration asset**. It does not execute logic, nor does it make outgoing or incoming calls during runtime. Its purpose is to be processed by the build toolchain (e.g., Vite, Next.js) and injected into the final HTML/CSS bundle.\n\n### Theme Resolution Flow\nThe following diagram illustrates how the CSS variables defined in this module are resolved by Tailwind utilities.\n\n```mermaid\nflowchart LR\n subgraph CSS Variables\n A[:root] -->|Light Mode| B[--background]\n C[.dark] -->|Dark Mode| D[--background]\n end\n\n subgraph Tailwind Utilities\n E[bg-background] -->|Resolves to| B\n F[text-foreground] -->|Resolves to| G[--foreground]\n end\n\n B --> H[Rendered Color]\n D --> H\n G --> H\n```\n\n## Usage Guidelines\n\n1. **Color Changes**: To modify the application's color palette, update the `oklch` values in the `:root` or `.dark` sections.\n2. **Dark Mode**: Ensure the application's root component or layout toggles the `dark` class on the `<html>` or `<body>` tag to activate dark mode variables.\n3. **Utility Classes**: Prefer semantic Tailwind classes (e.g., `border-border`) over raw CSS values to maintain consistency with the theme tokens.\n4. **Font Loading**: Verify that `geist-sans` and `geist-mono` are available in the project's asset pipeline before relying on the `@theme inline` font mappings.","harakat-admin-types":"# Harakat_Admin — types\n\n\n\n# Harakat_Admin — types\n\nThis module defines the TypeScript interfaces and type aliases used throughout the Harakat Admin backend. It standardizes data structures for authentication, platform configuration, service management, and API communication.\n\n## File Organization\n\nThe module is split into two files to separate API response contracts from internal state definitions:\n\n* **`index.ts`**: Primary export file. Contains core entity types (`Admin`, `Agent`, `Service`), API response wrappers (`LoginResponse`, `SettingsResponse`), and utility types (`ApiResult`).\n* **`settings.ts`**: Contains internal state types, permission matrices, and notification preferences.\n\n## Core Type Definitions\n\n### Authentication & Admin\nDefines the structure for administrative users and their roles.\n\n* **`Admin`** (`index.ts`): Represents a full administrative entity retrieved from the database.\n * `id`: Unique numeric identifier.\n * `name`: Optional display name.\n * `email`: Unique login identifier.\n * `role`: Defines access level (see **Critical Implementation Notes**).\n * `createdAt`: ISO timestamp of account creation.\n* **`AdminUser`** (`settings.ts`): A simplified internal representation of an admin, used for state management.\n * `name`: Required (unlike `Admin` where it is nullable).\n* **`AdminRole`**:\n * **`index.ts`**: `\"SUPER_ADMIN\" | \"ADMIN\" | \"MANAGER\"`\n * **`settings.ts`**: `\"super_admin\" | \"admin\"`\n * *Note: See **Critical Implementation Notes** below regarding casing and value consistency.*\n\n### Platform Configuration\nDefines the global settings for the Harakat platform.\n\n* **`PlatformSettings`** (`index.ts`): API response version. Includes metadata like `id` and `updatedAt`.\n* **`PlatformSettings`** (`settings.ts`): Internal state version. Excludes database metadata fields.\n* **`PermissionsMatrix`** (`settings.ts`): Defines granular permission flags for different admin roles.\n* **`NotificationPreferences`** (`settings.ts`): User-specific notification toggles (email, pending, system).\n\n### Services & Agents\nTypes for the marketplace or service catalog.\n\n* **`Agent`** (`index.ts`): Represents an AI agent or service provider.\n * `price`: Optional cost associated with the agent.\n* **`Service`** (`index.ts`): Represents a general service offering.\n * `price`: Optional cost associated with the service.\n\n### API Response Patterns\nStandardized shapes for API interactions to ensure consistent error handling and data parsing.\n\n* **`LoginResponse`** (`index.ts`):\n * `ok`: Boolean flag for success.\n * `accessToken`: JWT or session token.\n * `admin`: Nested object containing admin details.\n * `requires2FA`: Optional boolean for 2FA enforcement.\n * `tempToken`: Optional temporary session token.\n* **`SettingsResponse`** (`index.ts`):\n * `ok`: Boolean flag for success.\n * `settings`: The `PlatformSettings` object.\n* **`ErrorResponse`** (`index.ts`):\n * `error`: Error code or identifier.\n * `message`: Human-readable error string.\n * `details`: Optional array of specific validation errors.\n* **`ApiResult<T>`** (`index.ts`):\n * Utility type: `Promise<T | ErrorResponse>`.\n * Used to type API functions that return either a success payload or an error object.\n\n## Critical Implementation Notes\n\n### 1. `AdminRole` Inconsistency\nThere is a discrepancy in the `AdminRole` type definition between `index.ts` and `settings.ts`.\n\n* **`index.ts`** uses uppercase values: `\"SUPER_ADMIN\" | \"ADMIN\" | \"MANAGER\"`.\n* **`settings.ts`** uses lowercase values: `\"super_admin\" | \"admin\"`.\n\nDevelopers must ensure they are using the correct file for their context:\n* Use **`index.ts`** types when handling API responses or database records.\n* Use **`settings.ts`** types when managing internal application state or permissions.\n* *Recommendation*: Align these definitions to a single source of truth to prevent runtime casting errors.\n\n### 2. `PlatformSettings` Metadata\nThe `PlatformSettings` interface differs between files regarding metadata:\n* **`index.ts`** includes `id` and `updatedAt`.\n* **`settings.ts`** omits these fields.\n\nThis suggests `index.ts` is intended for API payloads (where database IDs are required), while `settings.ts` is intended for internal state (where IDs may be irrelevant).\n\n## Type Hierarchy\n\nThe following diagram illustrates the relationship between the primary API response types and the core entity types they contain.\n\n```mermaid\nclassDiagram\n class ApiResult~T~ {\n +Promise<T | ErrorResponse>\n }\n class LoginResponse {\n +ok: boolean\n +accessToken: string\n +admin: Admin\n }\n class SettingsResponse {\n +ok: boolean\n +settings: PlatformSettings\n }\n class Admin {\n +id: number\n +role: AdminRole\n +email: string\n }\n class PlatformSettings {\n +platformName: string\n +maintenanceMode: boolean\n }\n class ErrorResponse {\n +error: string\n +message: string\n }\n\n ApiResult~T~ --> ErrorResponse\n LoginResponse --> Admin\n SettingsResponse --> PlatformSettings\n```\n\n## Usage Examples\n\n### Handling API Results\nWhen calling an API endpoint, use `ApiResult` to type the return value:\n\n```typescript\nimport { ApiResult, LoginResponse } from './types';\n\nasync function login(email: string, password: string): Promise<ApiResult<LoginResponse>> {\n // Implementation details\n return { ok: true, accessToken: \"...\" };\n}\n```\n\n### Accessing Admin Data\nWhen parsing a `LoginResponse`, destructure the nested `admin` object:\n\n```typescript\nimport { LoginResponse } from './types';\n\nconst response: LoginResponse = {\n ok: true,\n accessToken: \"token\",\n admin: { id: 1, email: \"admin@example.com\", role: \"ADMIN\", name: null }\n};\n\nif (response.ok) {\n const { id, role } = response.admin;\n // role is typed as AdminRole\n}\n```","harakat-admin":"# Harakat_Admin\n\n\n\n# Harakat_Admin\n\nThe **Harakat_Admin** module serves as the central administrative interface for the Harakat platform, enabling management of educational content, startup enrollments, and system governance. Built on a **Next.js** frontend and **Express** backend, it enforces strict data integrity via **Prisma** and **PostgreSQL**.\n\n## Architecture & Stack\n\nThe system follows a standard RESTful architecture with a clear separation between the client (`app`), the API layer (`lib`), and the data layer (`docs`). Visual consistency is managed through `styles`, while shared logic is encapsulated in `hooks`.\n\n## Core Sub-modules\n\n* **`hooks`**: Centralizes critical React logic including `useResource` for race-condition-free data fetching and `useAuthCheck` for cross-tab session synchronization. These hooks power key views such as `AdminDashboard`, `CoursePage`, and `CompaniesPage`.\n* **`docs`**: Defines the Learning Hub API Integration, outlining the RESTful architecture connecting the client to the Express API layer.\n* **`e2e`**: Validates the application's UI states and authentication flows using Playwright, ensuring consistency across the `app` and `components` layers.\n* **`styles`**: Manages the visual design system using Tailwind CSS v4 and OKLCH color tokens in `globals.css`.\n* **`types`**: Standardizes TypeScript interfaces for entities like `Admin`, `Agent`, and `Service`, ensuring type safety across API responses and internal state.\n\n## Integration Workflows\n\nData flows from the `app` pages through `hooks` (e.g., `useResource`) to the `lib` API layer, adhering to contracts defined in `types`. The `e2e` suite verifies these interactions, while `styles` ensures consistent rendering.\n\n```mermaid\ngraph TD\n subgraph Frontend\n App[app]\n Hooks[hooks]\n Styles[styles]\n Components[components]\n end\n\n subgraph Backend\n Lib[lib]\n Docs[docs]\n end\n\n subgraph Testing\n E2E[e2e]\n end\n\n subgraph Data\n DB[(PostgreSQL)]\n end\n\n App --> Hooks\n Hooks --> Lib\n Lib --> Docs\n Docs --> DB\n E2E -.-> App\n Styles -.-> App\n Components -.-> Hooks\n```\n\n## Key Data Flows\n\n* **Authentication**: `useAuthCheck` manages session consistency across tabs, triggering `endSession()` via `localStorage` when `AdminLayout` detects token expiration.\n* **Data Fetching**: `useResource` prevents stale data overwrites during rapid state updates, utilized by `MarketplaceAgentPage` and `LearningHub`.\n* **Error Handling**: `types` defines `MalformedPayloadError` contracts, which are caught by `readList` in `AdminDashboard` and `CompaniesPage` to ensure graceful degradation.","harakat-ai-capabilities":"# Harakat_AI — capabilities\n\n\n\n# Harakat_AI — Capabilities Module\n\nThis module manages the lifecycle of learned capabilities within the Harakat platform. It provides three primary interfaces:\n1. **Client Helpers**: Direct wrappers for the server-side API to manage capability creation, specification, and training.\n2. **Definition Chat**: Utilities for validating and summarizing capability definitions during conversational interactions.\n3. **Augmentation Framework**: A pluggable system for generating synthetic data variants to improve model training.\n\n## Module Architecture\n\nThe module is split into three logical sub-modules, each handling a distinct aspect of capability management.\n\n```mermaid\ngraph TD\n Tools[core/tools.py]\n Capabilities[Harakat_AI/capabilities]\n \n subgraph Capabilities\n Client[client.py<br/>Lifecycle API]\n Def[definition_chat.py<br/>Validation & Drafts]\n Aug[augmentation.py<br/>Synthetic Data]\n end\n \n Tools -->|Propose/Train/Upsert| Client\n Tools -->|Validate/Summarize| Def\n Tools -->|Generate Variants| Aug\n \n Client -->|HTTP| Server[Offices Server]\n Aug -->|HTTP| Server\n Def -->|Dataclass| Client\n```\n\n## 1. Capability Lifecycle (`client.py`)\n\nThis file contains the HTTP client wrappers for the server-side capability API. These functions are the entry point for agents to interact with the capability registry.\n\n### Lifecycle Operations\n* **`propose_capability`**: Creates a new capability in `IN_DEFINITION` status.\n * **Required**: `name`, `description`, `category`, `permitted_action_types`.\n * **Optional**: `assistant_id`, `access_tier`, `branch_scope`.\n * **Action Types**: Must be a subset of `ALLOWED_ACTION_TYPES` (e.g., `score`, `flag`, `draft_email`).\n* **`upsert_capability_spec`**: Updates the technical specification of an existing capability.\n * **Required**: `capability_id`, `prediction_target`, `signal_columns`.\n * **Optional**: `decision_threshold`, `audit_cadence`, `notes`.\n* **`start_capability_training`**: Triggers the server-side learning sandbox.\n * **Parameters**: `capability_id`, `force` (bool).\n * **Timeout**: 45.0s (longer than standard ops due to training init).\n* **`list_capabilities` / `list_opportunities`**: Query endpoints for discovery.\n * `list_capabilities`: Filters by `status`, `assistant_id`, `limit`.\n * `list_opportunities`: Filters by `dismissed`, `accepted`, `limit`.\n\n### Error Handling\nAll client functions use `httpx.AsyncClient` with `resp.raise_for_status()`. They return the JSON response body directly. If an HTTP error occurs, an exception is raised.\n\n## 2. Definition & Validation (`definition_chat.py`)\n\nThis module bridges conversational inputs with the strict data structures required by the server. It ensures that chat-derived definitions are valid before being persisted.\n\n### `CapabilityDefinitionDraft`\nA dataclass representing a capability in progress. It normalizes incoming data (handling `permittedActionTypes` vs `permitted_action_types` casing differences).\n\n* **`from_mapping`**: Converts a raw dictionary (from chat or API) into a `CapabilityDefinitionDraft`.\n* **`missing_definition_fields`**: Returns a list of required fields that are empty or invalid.\n * Checks for `name`, `description`, `prediction_target`, `signal_columns`, `permitted_action_types`.\n * Validates `permitted_action_types` against `ALLOWED_ACTION_TYPES`.\n* **`summarize_definition_draft`**: Generates a human-readable string for tool output or user display.\n * Formats signals and actions as comma-separated lists.\n * Defaults to \"not set yet\" for missing values.\n\n### Constants\n* **`ALLOWED_ACTION_TYPES`**: `{\"score\", \"flag\", \"draft_email\", \"send_email\", \"modify_record\"}`. Used to validate permitted actions during definition.\n\n## 3. Augmentation Framework (`augmentation.py`)\n\nThis module implements a pluggable framework for generating synthetic data variants for active capabilities. It is designed to be \"smoke-friendly\": if no generator is registered for a category, the framework skips gracefully without crashing.\n\n### Core Concepts\n* **`GeneratorFn`**: An async callable `Callable[[GeneratorContext], Awaitable[list[AugmentedSample]]]`.\n* **`GeneratorContext`**: Passed to the generator. Contains `auth_token`, `capability`, `spec`, `recent_real_samples`, and `target_variant_count`.\n* **`AugmentedSample`**: The output variant. Contains `sample` (dict) and optional `prompt_text`.\n* **`GenerationOutcome`**: A dataclass returned by the framework to report success/failure metrics without raising exceptions.\n\n### Registration\nGenerators are registered via `register_augmentation_generator(category, version, generator)`.\n* **Scoping**: Generators are scoped by `(category, version)`.\n* **Selection**: `_pick_generator` selects the latest version registered for a category.\n* **Safety**: Duplicate registration raises `ValueError`.\n\n### Execution Flow\nThe main entry point is `generate_augmentation_samples_for_capability`. It follows this logic:\n1. **Fetch Capability**: Retrieves capability details. If failed, returns `GenerationOutcome` with `skipped_reason`.\n2. **Check Category**: If no category exists, skips.\n3. **Pick Generator**: Looks up the generator for the category. If none found, skips.\n4. **Fetch Samples**: Retrieves recent real samples from the server.\n5. **Generate**: Calls the registered `GeneratorFn`.\n6. **Enqueue**: Iterates through generated variants and posts them to the server's enqueue endpoint.\n7. **Report**: Returns `GenerationOutcome` with counts of requested, produced, and enqueued variants, plus any errors.\n\n### Batch Processing\n`generate_augmentation_samples_for_capabilities` iterates over a list of `capability_ids` serially. This ensures predictable DB and LLM load.\n\n### Diagram: Augmentation Flow\n```mermaid\nsequenceDiagram\n participant Agent\n participant Framework as generate_augmentation_samples_for_capability\n participant Server as Harakat Server\n participant Gen as Registered Generator\n\n Agent->>Framework: generate_augmentation_samples_for_capability(cap_id)\n Framework->>Server: GET /capabilities/{cap_id}\n Server-->>Framework: Capability Data\n Framework->>Framework: _pick_generator(category)\n alt Generator Found\n Framework->>Server: GET /augmentation/recent-real-samples\n Server-->>Framework: Real Samples\n Framework->>Gen: Generate Variants(samples)\n Gen-->>Framework: AugmentedSamples\n loop For each variant\n Framework->>Server: POST /augmentation/enqueue\n Server-->>Framework: Success\n end\n Framework-->>Agent: GenerationOutcome(success=true)\n else No Generator\n Framework-->>Agent: GenerationOutcome(skipped=true)\n end\n```\n\n## 4. Integration with Core Tools\n\nThe `capabilities` module is primarily consumed by `core/tools.py`. The call graph indicates the following integration points:\n\n* **Definition Phase**:\n * `_propose_predictive_capability` calls `missing_definition_fields` and `summarize_definition_draft` to validate chat inputs before calling `propose_capability`.\n * `_update_predictive_capability_spec` calls `from_mapping` to parse updates and `upsert_capability_spec` to persist them.\n* **Discovery Phase**:\n * `_list_predictive_capabilities` calls `list_capabilities`.\n * `_list_capability_opportunities` calls `list_opportunities`.\n* **Training Phase**:\n * `_start_predictive_capability_learning` calls `start_capability_training`.\n* **Augmentation Phase**:\n * While not explicitly shown in the provided call graph, the augmentation framework is designed to be invoked by a scheduler or tool that manages active capability maintenance.\n\n## 5. Extensibility Guidelines\n\n### Adding a New Generator\nTo add a new augmentation strategy:\n1. Implement a function matching the `GeneratorFn` signature.\n2. Register it using `register_augmentation_generator(category=\"your_category\", version=\"1.0\", generator=your_func)`.\n3. Ensure the function returns a list of `AugmentedSample` objects.\n4. Handle transient errors internally; the framework expects the generator to be pure with respect to inputs.\n\n### Adding a New Client Endpoint\nIf the server API changes:\n1. Update the corresponding function in `client.py`.\n2. Ensure `_headers` is used for authentication.\n3. Update `__init__.py` exports if the function is public.\n\n### Adding a New Definition Field\n1. Add the field to `CapabilityDefinitionDraft`.\n2. Update `from_mapping` to handle the new key.\n3. Add validation logic to `missing_definition_fields`.\n4. Update `summarize_definition_draft` to display the new field.","harakat-ai-docs":"# Harakat_AI — docs\n\n\n\n# Harakat_AI — docs Module\n\n## Overview\n\nThe `docs` module contains the developer documentation for the Harakat AI Runtime. This module provides the reference material for backend engineers, AI engineers, and maintainers who need to understand, extend, or contribute to the AI system.\n\n**Location:** `Harakat_AI/docs/`\n\n**Purpose:** To provide a living blueprint for the AI runtime architecture, agent development workflow, and system integration patterns.\n\n---\n\n## Documentation Files\n\n| File | Purpose | Target Audience |\n|------|---------|-----------------|\n| `AGENT_DEVELOPMENT_GUIDE.md` | Complete workflow for adding agents and capabilities | Backend/AI engineers |\n| `AI_SETUP_GUIDE.md` | Local and production setup instructions | DevOps, new hires |\n| `AI_USAGE_GUIDE.md` | Runtime API and integration patterns | API consumers |\n\n---\n\n## Module Structure\n\n```text\nHarakat_AI/\n └─ docs/\n ├─ AGENT_DEVELOPMENT_GUIDE.md ← Primary developer reference\n ├─ AI_SETUP_GUIDE.md ← Infrastructure setup\n └─ AI_USAGE_GUIDE.md ← Runtime API reference\n```\n\n---\n\n## Core Documentation: Agent Development Guide\n\nThe `AGENT_DEVELOPMENT_GUIDE.md` is the primary reference for building AI agents. It documents the 9-step lifecycle:\n\n```mermaid\nflowchart LR\n A[Define Agent] --> B[Create Folder]\n B --> C[Write Manifest]\n C --> D[Implement Handler]\n D --> E[Register with UV]\n E --> F[Sync to Platform]\n F --> G[Test End-to-End]\n G --> H[Enable for Offices]\n H --> I[Monitor Usage]\n```\n\n### Key Components Documented\n\n#### 1. Agent Manifest (`agent.json`)\n\nDefines agent metadata and capabilities:\n\n```json\n{\n \"name\": \"MarketingAgent\",\n \"key\": \"marketing\",\n \"category\": \"business\",\n \"version\": \"1.0.0\",\n \"workspace\": \"expert\",\n \"capabilities\": [\n {\n \"key\": \"marketing.research\",\n \"displayName\": \"Market Research\",\n \"status\": \"ACTIVE\"\n }\n ]\n}\n```\n\n#### 2. Agent Handler (`handler.py`)\n\nEntry point for task execution:\n\n```python\ndef handle(task: Dict[str, Any]) -> Dict[str, Any]:\n capability = task.get(\"capability\")\n if capability == \"marketing.research\":\n return run_market_research(task)\n elif capability == \"marketing.social_media\":\n return run_social_media(task)\n return {\"status\": \"failed\", \"error\": f\"Unknown capability: {capability}\"}\n```\n\n#### 3. Workspace Manager (`src/runtime/uv/workspace_manager.py`)\n\nDynamic agent loading:\n\n```python\nclass WorkspaceManager:\n def _load_agents(self):\n registry = {}\n for folder in os.listdir(AGENTS_DIR):\n manifest_path = os.path.join(AGENTS_DIR, folder, \"agent.json\")\n if os.path.isfile(manifest_path):\n with open(manifest_path) as f:\n manifest = json.load(f)\n registry[manifest[\"key\"]] = {\n \"manifest\": manifest,\n \"path\": os.path.join(AGENTS_DIR, folder, \"handler.py\")\n }\n return registry\n```\n\n#### 4. UV Controller (`src/runtime/uv/controller.py`)\n\nTask execution orchestration:\n\n```python\nclass UVController:\n def execute_task(self, task):\n space, agent = self.manager.resolve_workspace(task.agent)\n handler_path = agent[\"path\"]\n spec = importlib.util.spec_from_file_location(\"agent_handler\", handler_path)\n module = importlib.util.module_from_spec(spec)\n spec.loader.exec_module(module)\n return module.handle(task.dict())\n```\n\n---\n\n## Platform Integration\n\nThe documentation specifies the database schema integration with HarakatOffices_Server:\n\n### Database Tables Referenced\n\n| Table | Purpose |\n|-------|---------|\n| `Agent` | Agent metadata |\n| `AgentCapability` | Capability definitions |\n| `OfficeCapabilityAccess` | Office-level access control |\n| `AiTask` | Task execution records |\n| `AiTaskEvent` | Task event logging |\n| `AIOutput` | Task output storage |\n| `UsageRecord` | Usage tracking |\n\n### Sync Endpoint\n\n```typescript\nPOST /internal/ai/agents/sync\n{\n \"name\": \"MarketingAgent\",\n \"key\": \"marketing\",\n \"capabilities\": [...],\n \"version\": \"1.0.0\"\n}\n```\n\n---\n\n## Runtime Execution Flow\n\n```mermaid\nsequenceDiagram\n participant OfficeProvider\n participant HarakatOffices_Server\n participant AI_Runtime\n participant Agent_Handler\n\n OfficeProvider->>HarakatOffices_Server: POST /ai/tasks\n HarakatOffices_Server->>HarakatOffices_Server: Create AiTask (ACCEPTED)\n HarakatOffices_Server->>AI_Runtime: POST /run\n AI_Runtime->>AI_Runtime: Resolve workspace\n AI_Runtime->>Agent_Handler: Execute handler\n Agent_Handler-->>AI_Runtime: Return output\n AI_Runtime->>HarakatOffices_Server: PATCH /ai/tasks/:requestId\n HarakatOffices_Server->>HarakatOffices_Server: Update AiTask (SUCCEEDED)\n HarakatOffices_Server->>HarakatOffices_Server: Create AIOutput, AiTaskEvent\n```\n\n---\n\n## Usage Patterns\n\n### Task Request Format\n\n```json\n{\n \"requestId\": \"...\",\n \"officeId\": 12,\n \"agent\": \"marketing\",\n \"taskType\": \"GENERATE\",\n \"payload\": {...}\n}\n```\n\n### Response Format\n\n```json\n{\n \"status\": \"succeeded\",\n \"data\": {\n \"summary\": \"...\",\n \"sources\": []\n },\n \"credits\": 10\n}\n```\n\n---\n\n## Security & Tenancy\n\nAll tasks must include:\n\n- `officeId` (required)\n- `startupId` (optional, for multi-tenant isolation)\n\nThe runtime rejects tasks without `officeId` at the entry point (`src/runtime/main.py`).\n\n---\n\n## Contributing to Documentation\n\nWhen adding new documentation:\n\n1. **Update `AGENT_DEVELOPMENT_GUIDE.md`** for agent-related changes\n2. **Update `AI_SETUP_GUIDE.md`** for infrastructure changes\n3. **Update `AI_USAGE_GUIDE.md`** for API changes\n4. **Add code examples** that match actual implementation\n5. **Reference actual function names** and class names\n\n---\n\n## Related Modules\n\n| Module | Relationship |\n|--------|--------------|\n| `HarakatOffices_Server` | Receives task requests, syncs agents |\n| `OfficeProvider` | Triggers AI tasks from UI |\n| `src/runtime/uv/` | Core runtime logic |\n| `agents/` | Agent implementations |\n\n---\n\n## Quick Reference\n\n| Task | Reference |\n|------|-----------|\n| Add new agent | `AGENT_DEVELOPMENT_GUIDE.md` → Section 3 |\n| Setup locally | `AI_SETUP_GUIDE.md` → Section 2 |\n| API endpoints | `AI_USAGE_GUIDE.md` → Section 2 |\n| Database schema | `AGENT_DEVELOPMENT_GUIDE.md` → Section 7 |\n| Security rules | `AGENT_DEVELOPMENT_GUIDE.md` → Section 11 |","harakat-ai-envelopes":"# Harakat_AI — envelopes\n\n\n\n# Harakat_AI/envelopes\n\nThe `envelopes` module defines the standardized data contract used to transport results from specialist agents to the composer and planner components. It ensures that disparate output shapes from various specialists can be stitched together mechanically without requiring the consumer to guess at incompatible structures.\n\n## Overview\n\nThis module provides a shared result envelope system. Every specialist returns `ResultEnvelope` instances, allowing the composer/planner to process context uniformly. The module is self-contained regarding execution logic (no internal or outgoing calls), serving primarily as a schema definition and utility layer.\n\n### Key Responsibilities\n1. **Standardization:** Enforces a consistent structure (`ResultEnvelope`) across all specialist outputs.\n2. **Metadata Tracking:** Captures source references (`SourceRef`), confidence scores, and tiering.\n3. **Context Rendering:** Provides a deterministic string representation for planner context via `envelope_to_context_line`.\n\n## Core Concepts\n\n### Envelope Kinds\nThe `EnvelopeKind` literal type categorizes the nature of the data being returned. This allows the consumer to route or prioritize data based on its semantic type.\n\n| Kind | Description |\n| :--- | :--- |\n| `context` | General context information. |\n| `action` | Actionable items or commands. |\n| `procedure` | Step-by-step procedural data. |\n| `doc_ref` | References to documentation. |\n| `capability_invocation` | Invocations of system capabilities. |\n| `retrieval_trace` | Trace breadcrumbs emitted by `docs_orchestrator` (TOC → FTS → rerank → drill) with latency and candidate counts. |\n\n### Data Models\n\n#### `SourceRef`\nA Pydantic model representing a reference to a specific item within a store.\n\n```python\nclass SourceRef(BaseModel):\n storeId: str\n itemId: str\n```\n\n#### `ResultEnvelope`\nThe primary data structure returned by specialists. It wraps the payload data with metadata required for processing.\n\n```python\nclass ResultEnvelope(BaseModel):\n kind: EnvelopeKind\n data: dict[str, Any] = Field(default_factory=dict)\n source: SourceRef\n tier: str\n confidence: float = Field(ge=0.0, le=1.0)\n```\n\n**Field Details:**\n* `kind`: The type of envelope (see `EnvelopeKind`).\n* `data`: A dictionary containing the actual payload. Common keys include `title`, `name`, `summary`, `content`, or `description`.\n* `source`: The `SourceRef` identifying where the data originated.\n* `tier`: A string categorization of the result quality or priority.\n* `confidence`: A float between 0.0 and 1.0 indicating the reliability of the result.\n\n## Utility Functions\n\n### `envelope_to_context_line`\nConverts a `ResultEnvelope` into a compact, deterministic string for planner context. This is useful for logging or displaying a summary of the result in a UI.\n\n**Logic:**\n1. **Title:** Extracts `title` from `data`, falling back to `name`, then `source.itemId`.\n2. **Body:** Extracts `summary` from `data`, falling back to `content`, then `description`.\n3. **Prefix:** Constructs `[kind:storeId/itemId]`.\n4. **Output:**\n * If `body` exists: `{prefix} {title}: {body}`\n * Otherwise: `{prefix} {title}`\n\n## Architecture\n\nThe module acts as the interface layer between the **Specialist** (producer) and the **Composer/Planner** (consumer).\n\n```mermaid\nsequenceDiagram\n participant Specialist\n participant Envelope\n participant Composer\n\n Specialist->>Envelope: Create ResultEnvelope\n Note over Specialist,Envelope: Enforces Pydantic Schema\n Specialist->>Composer: Return ResultEnvelope\n Composer->>Envelope: Read kind, confidence, data\n Composer->>Composer: Stitch context mechanically\n```\n\n## Integration\n\n### For Specialists\nWhen returning results, ensure the output conforms to `ResultEnvelope`:\n1. Instantiate `SourceRef` with valid `storeId` and `itemId`.\n2. Set `kind` to the appropriate `EnvelopeKind`.\n3. Populate `data` with relevant payload (e.g., `title`, `summary`).\n4. Assign a `tier` and `confidence` score.\n\n### For Composers/Planners\nWhen consuming results:\n1. Iterate over the list of `ResultEnvelope` objects.\n2. Use `envelope_to_context_line` for quick context inspection.\n3. Filter or prioritize based on `confidence` and `tier`.\n4. Access specific content via `envelope.data`.\n\n## Dependencies\n* `pydantic`: Used for `BaseModel` definitions and field validation (e.g., `confidence` range).\n* `typing`: Used for type hints (`Literal`, `Any`, `dict`).\n\n## Notes\n* **No Execution Logic:** This module contains no business logic execution flows. It is purely a data contract and utility layer.\n* **Trace Breadcrumbs:** The `retrieval_trace` kind is specifically designed for the `docs_orchestrator` to emit loop traces (TOC → FTS → rerank → drill) for expandable \"How I found this\" footers.","harakat-ai-kubernetes":"# Harakat_AI — kubernetes\n\n\n\n# Harakat_AI — kubernetes\n\n## Overview\n\nThe `kubernetes` module within the `Harakat_AI` project contains Infrastructure-as-Code (IaC) manifests used to deploy and manage containerized workloads on a Kubernetes cluster. This specific module is responsible for defining the desired state of the application infrastructure, ensuring consistency across development, staging, and production environments.\n\n## Module Purpose\n\nThe primary purpose of this module is to provide declarative configuration for Kubernetes resources. Unlike executable code, this module does not contain runtime logic, functions, or classes. Instead, it serves as a static definition of the application's deployment topology.\n\n### Execution Model\n\nAs indicated by the execution flow analysis:\n* **Internal Calls:** None.\n* **Outgoing Calls:** None.\n* **Incoming Calls:** None.\n* **Execution Flows:** No execution flows detected.\n\nThis confirms that the module operates as a configuration artifact rather than a software component. It is processed by external orchestration tools (e.g., `kubectl`, Helm, or CI/CD pipelines) to interact with the Kubernetes API Server.\n\n## Key Components\n\n### `deployment.yaml`\n\nLocated at `Harakat_AI/kubernetes/deployment.yaml`, this file defines the Kubernetes Deployment resource.\n\n* **Function:** Specifies the desired state of the application pods, including image references, resource limits, and scaling policies.\n* **Integration:** This file is the entry point for the application lifecycle within the cluster. It is typically version-controlled alongside the application source code.\n* **Usage:** Applied to the cluster using standard Kubernetes CLI commands or integrated into deployment pipelines.\n\n## Architecture and Integration\n\nThe `kubernetes` module acts as the bridge between the application code and the orchestration layer. It does not execute logic itself but defines the environment in which the application logic runs.\n\n### Deployment Flow\n\nThe following diagram illustrates how the `deployment.yaml` file interacts with the Kubernetes ecosystem:\n\n```mermaid\nsequenceDiagram\n participant DevOps as CI/CD Pipeline\n participant YAML as deployment.yaml\n participant K8s as Kubernetes API Server\n participant Pods as Application Pods\n\n DevOps->>YAML: Validate Manifest\n DevOps->>K8s: Apply Manifest (kubectl apply)\n K8s->>Pods: Create/Update Pods\n Pods-->>K8s: Report Status\n```\n\n## Usage Guidelines\n\n1. **Validation:** Before applying changes, validate the YAML syntax and Kubernetes schema compliance.\n2. **Version Control:** Treat `deployment.yaml` as source code. Changes should be committed to the repository with corresponding code changes.\n3. **Environment Specifics:** While this module provides the core deployment structure, environment-specific variables (e.g., secrets, image tags) should be managed via Kubernetes Secrets or external configuration management tools to maintain security and flexibility.\n4. **No Runtime Logic:** Do not expect this module to perform logic. All orchestration is handled by the Kubernetes control plane based on the definitions in this file.\n\n## Maintenance\n\n* **Updates:** Modify the `deployment.yaml` to update container images, resource requests, or scaling parameters.\n* **Rollbacks:** Use `kubectl rollout undo` or revert the `deployment.yaml` to a previous commit to restore the previous state.\n* **Monitoring:** Monitor the `Pods` status reported back to the `Kubernetes API Server` to ensure the desired state defined in `deployment.yaml` is achieved.","harakat-ai-mcp-client":"# Harakat_AI — mcp_client\n\n\n\n# Harakat_AI — mcp_client Module\n\nThis module provides the client-side interface for invoking Model Context Protocol (MCP) tools via the HarakatOffices_Server proxy. It encapsulates authentication, circuit-breaking logic, and credential management interactions, ensuring that the AI service does not expose credentials or directly dial external MCP endpoints.\n\n## Architecture Overview\n\nThe module operates as a thin client layer. All external MCP endpoints are accessed through the server-side proxy (`HarakatOffices_Server`). This architecture ensures that:\n1. **Credentials** remain encrypted at rest on the server and are never exposed to the agent process.\n2. **Audit** is handled server-side (persisting `McpInvocation` rows).\n3. **Policy** enforcement (tenancy, rate limiting) is centralized on the server.\n\nThe client's primary responsibility is to bundle tool arguments, forward the user's JWT, and parse the structured response into a typed result.\n\n### Component Breakdown\n\n| File | Purpose | Key Exports |\n| :--- | :--- | :--- |\n| `client.py` | Core invocation logic and result types. | `invoke_mcp`, `McpInvocationResult` |\n| `circuit_breaker.py` | Local-side circuit breaker to prevent proxy hammering. | `LocalBreaker` |\n| `credential_vault.py` | Admin-facing wrappers for credential management. | `register_credential`, `list_credentials`, `revoke_credential` |\n| `__init__.py` | Module exports. | All public symbols |\n\n## Circuit Breaker Logic\n\nTo prevent the AI service from hammering the server proxy when the server is in a failure state, a local circuit breaker (`LocalBreaker`) is implemented per `mcp_agent_id`.\n\n### State Machine\n\nThe breaker follows a standard three-state pattern:\n1. **CLOSED**: Normal operation. Requests are allowed.\n2. **OPEN**: Requests are rejected immediately.\n3. **HALF_OPEN**: Testing phase after cooldown. Requests are allowed to test stability.\n\n### Configuration\n\nThe local breaker mirrors the server defaults to ensure consistent behavior:\n* **Failure Threshold**: 5 consecutive failures.\n* **Cooldown Period**: 30 seconds.\n\n### Implementation Details\n\nThe `LocalBreaker` class manages state transitions internally.\n* `should_allow()`: Checks if the current state permits a request. It triggers `_maybe_transition()` to move from OPEN to HALF_OPEN if the cooldown has elapsed.\n* `record_failure()`: Increments the failure count. If the threshold is met, the state transitions to OPEN. If called during HALF_OPEN, it immediately reverts to OPEN.\n* `record_success()`: Resets the state to CLOSED and clears the failure count.\n\n**Note:** The server-side breaker is authoritative. This local breaker is a fast-fail layer to amortize network round-trips when the server returns `CIRCUIT_OPEN`.\n\n## Core Invocation API\n\nThe primary entry point for invoking MCP tools is `invoke_mcp`.\n\n### Function Signature\n\n```python\nasync def invoke_mcp(\n *,\n auth_token: str,\n mcp_agent_id: int,\n tool_name: str | None,\n arguments: dict[str, Any],\n caller_assistant_id: int | None = None,\n timeout_seconds: float = 35.0,\n) -> McpInvocationResult\n```\n\n### Parameters\n\n* `auth_token`: The user's JWT. Required for authorization.\n* `mcp_agent_id`: Unique identifier for the MCP agent. Used to retrieve the specific `LocalBreaker`.\n* `tool_name`: Optional name of the MCP tool to invoke.\n* `arguments`: Dictionary of arguments to pass to the tool.\n* `caller_assistant_id`: Optional ID of the assistant making the call.\n* `timeout_seconds`: HTTP client timeout (default 35.0s).\n\n### Return Value\n\nReturns a `McpInvocationResult` dataclass. Callers should branch on `result.success` rather than catching exceptions.\n\n```python\n@dataclass\nclass McpInvocationResult:\n success: bool\n status: str # e.g., \"SUCCESS\", \"CIRCUIT_OPEN\", \"TIMEOUT\"\n http_status: int | None # Outer HTTP status from proxy\n data: Any | None # Parsed MCP response\n invocation_id: int | None # Server-side audit row ID\n error_message: str | None\n latency_ms: int | None\n```\n\n### Execution Flow\n\nThe following sequence diagram illustrates the flow of `invoke_mcp`, including the interaction with the local circuit breaker.\n\n```mermaid\nsequenceDiagram\n participant Client as AI Service\n participant Breaker as LocalBreaker\n participant Proxy as Server Proxy\n participant MCP as External MCP\n\n Client->>Breaker: should_allow()\n alt Breaker is OPEN\n Breaker-->>Client: False\n Client->>Client: Return McpInvocationResult(status=\"CIRCUIT_OPEN\")\n else Breaker is CLOSED/HALF_OPEN\n Client->>Proxy: POST /api/startup/mcp/{id}/invoke\n Proxy->>MCP: Forward Request\n MCP-->>Proxy: Response\n Proxy-->>Client: Response\n Client->>Breaker: record_success() or record_failure()\n Client-->>Client: Return McpInvocationResult\n end\n```\n\n### Error Handling\n\nNetwork errors, timeouts, and server-side breaker opens are mapped to `success=False`.\n* **TIMEOUT**: Triggered by `httpx.TimeoutException`.\n* **FAILED**: Triggered by `httpx.HTTPError` or non-2xx HTTP status.\n* **CIRCUIT_OPEN**: Triggered when `LocalBreaker` state is OPEN.\n* **REJECTED**: Triggered if `auth_token` is missing.\n\n## Credential Management\n\nThe `credential_vault` module provides typed wrappers for server-side credential management. This is intended for platform tooling (admin wizards, setup scripts) rather than runtime agent logic. Agents should use `invoke_mcp` for tool execution.\n\n### Credential Types\n\n```python\nCredentialType = Literal[\"API_KEY\", \"OAUTH_BEARER\", \"BASIC_AUTH\", \"CUSTOM\"]\n```\n\n### Available Functions\n\n* `list_credentials(auth_token: str)`: Retrieves a list of `CredentialMetadata` objects.\n* `register_credential(auth_token, mcp_agent_id, credential_type, payload)`: Registers or rotates a credential. Returns metadata only; the server never echoes back plaintext or ciphertext.\n* `revoke_credential(auth_token, mcp_agent_id)`: Revokes a credential by ID. Returns `True` on success (200 OK).\n\n### Metadata Structure\n\n```python\n@dataclass\nclass CredentialMetadata:\n id: int\n mcp_agent_id: int\n credential_type: str\n created_at: str\n revoked_at: str | None\n```\n\n## Integration Notes\n\n* **Breaker Initialization**: `LocalBreaker` instances are cached in a global dictionary `_BREAKERS` keyed by `mcp_agent_id`. This ensures a consistent state per agent across multiple invocations.\n* **Server Dependency**: The client relies on `HARAKAT_API_URL` from `core.config`. Ensure this environment variable is set correctly.\n* **Audit**: The `invocation_id` in `McpInvocationResult` links to the server-side audit log. Use this for debugging or compliance tracking.","harakat-ai-providers":"# Harakat_AI — providers\n\n\n\n# Harakat_AI — providers\n\n## Overview\n\nThe `providers` module implements a pluggable LLM provider system that enables swapping inference backends via environment configuration. All providers conform to a unified interface, allowing the rest of the codebase to remain provider-agnostic.\n\n**Key Design Goals:**\n- **Provider Agnosticism**: Core workflows use `get_provider()` or `LLMProvider` interface, not concrete implementations\n- **Environment-Driven Swapping**: Change `LLM_PROVIDER` in `.env` to switch backends without code changes\n- **Unified Data Models**: `ChatMessage`, `ChatResponse`, and `ContentPart` provide consistent message formatting across providers\n- **Sync/Async Parity**: All providers implement both synchronous and asynchronous chat interfaces\n\n## Architecture\n\n```mermaid\ngraph TD\n A[get_provider] --> B{Registry Lookup}\n B -->|name| C[Import Module]\n C --> D[Instantiate Provider]\n D --> E[chat/achat/astream]\n E --> F[Provider-Specific API]\n F --> G[OpenAI SDK / Vertex SDK / Groq SDK]\n```\n\n## Core Interfaces\n\n### `LLMProvider` (base.py)\n\nAll providers must implement this abstract base class. It defines three methods:\n\n| Method | Description |\n|--------|-------------|\n| `chat(messages, *, temperature, max_tokens, **kwargs)` | Synchronous chat completion |\n| `achat(messages, *, temperature, max_tokens, **kwargs)` | Asynchronous chat completion |\n| `astream(messages, *, temperature, max_tokens, **kwargs)` | Asynchronous streaming |\n\n**Common Parameters:**\n- `messages: list[ChatMessage]` — Input conversation history\n- `temperature: float` — Sampling temperature (default: 0.7)\n- `max_tokens: int` — Maximum output tokens (default: 2048)\n- `**kwargs` — Provider-specific overrides\n\n### Data Models\n\n#### `ChatMessage`\n```python\n@dataclass\nclass ChatMessage:\n role: str # \"system\" | \"user\" | \"assistant\"\n content: str | list[ContentPart] = \"\" # text or multimodal parts\n```\n\n#### `ContentPart`\n```python\n@dataclass\nclass ContentPart:\n type: str # \"text\" | \"inline_data\"\n text: str | None = None # For type=\"text\"\n data: bytes | None = None # For type=\"inline_data\" (raw bytes)\n mime_type: str | None = None # For type=\"inline_data\"\n```\n\n#### `ChatResponse`\n```python\n@dataclass\nclass ChatResponse:\n content: str\n model: str\n usage: dict[str, int] | None = None\n raw: Any = None\n```\n\n## Provider Registry\n\n### `__init__.py`\n\nThe registry maps provider names to module/class pairs:\n\n```python\n_REGISTRY: dict[str, tuple[str, str]] = {\n \"gemini\": (\".gemini_provider\", \"GeminiProvider\"),\n \"google_ai_studio\": (\".gemini_provider\", \"GeminiProvider\"),\n \"openai\": (\".openai_provider\", \"OpenAIProvider\"),\n \"vertex_ai\": (\".vertex_ai\", \"VertexAIProvider\"),\n \"groq\": (\".groq_provider\", \"GroqProvider\"),\n \"nemotron\": (\".nemotron_provider\", \"NemotronProvider\"),\n}\n```\n\n### `get_provider()`\n\nFactory function that returns an initialized provider instance:\n\n```python\ndef get_provider(name: str | None = None, *, model: str | None = None) -> LLMProvider:\n \"\"\"Return an initialised provider. Falls back to Gemini if unknown.\"\"\"\n```\n\n**Behavior:**\n1. Reads `LLM_PROVIDER` from environment if `name` not provided\n2. Defaults to `\"gemini\"` if unknown provider name\n3. Optionally passes `model` parameter to provider constructor\n4. Returns provider instance\n\n**Usage:**\n```python\nfrom Harakat_AI.providers import get_provider\n\n# Use default (Gemini)\nprovider = get_provider()\n\n# Explicit provider\nprovider = get_provider(\"openai\")\n\n# With custom model\nprovider = get_provider(\"vertex_ai\", model=\"gemini-2.0-flash\")\n```\n\n### `__getattr__`\n\nSupports direct class imports:\n\n```python\nfrom Harakat_AI.providers import OpenAIProvider\n```\n\n## Provider Implementations\n\n### `OpenAIProvider` (openai_provider.py)\n\nStandard OpenAI SDK wrapper.\n\n**Environment Variables:**\n- `OPENAI_API_KEY` — OpenAI API key\n- `OPENAI_MODEL` — Model name (default: `gpt-4o-mini`)\n\n**Notes:**\n- Uses `openai` SDK (already in requirements.txt)\n- Supports standard OpenAI chat completions API\n- No special auth handling required\n\n### `GeminiProvider` (gemini_provider.py)\n\nLightweight bridge for Google AI Studio via OpenAI-compatible endpoint.\n\n**Environment Variables:**\n- `GEMINI_API_KEY` or `GOOGLE_API_KEY` — API key\n- `GEMINI_BASE_URL` — Base URL (default: `https://generativelanguage.googleapis.com/v1beta/openai`)\n- `GEMINI_MODEL` or `HERMES_MODEL` — Model name (default: `gemini-3.5-flash`)\n\n**Special Handling:**\n- Detects Vertex AI endpoint (`aiplatform.googleapis.com`) and switches to OAuth token auth\n- Refreshes credentials before every call when using Vertex\n- Prefixes model name with `google/` for Vertex OpenAI-compatible endpoint\n\n**Auth Flow:**\n```python\ndef _refresh_auth(self) -> None:\n if not self._is_vertex:\n return\n # Load service account credentials\n # Refresh token if expired\n # Update both sync and async client api_key\n```\n\n### `VertexAIProvider` (vertex_ai.py)\n\nNative Vertex AI SDK for full Gemini support including multimodal input.\n\n**Environment Variables:**\n- `VERTEX_SERVICE_ACCOUNT_JSON` — Path to service account JSON (default: `./service-account.json`)\n- `VERTEX_PROJECT_ID` — GCP project ID\n- `VERTEX_REGION` — Region (default: `global`)\n- `VERTEX_MODEL` — Model name (default: `gemini-3.5-flash`)\n- `VERTEX_THINKING_LEVEL` — Optional: `minimal` | `low` | `medium` | `high`\n\n**Key Features:**\n- Native support for multimodal content (text, images, PDFs, audio, video)\n- Separates system instructions from conversation contents\n- Handles Gemini 3.x parameter changes (temperature/top_p deprecated)\n- Provides `extract_text_from_file()` for document text extraction\n\n**Message Formatting:**\n```python\ndef _to_contents(self, messages: list[ChatMessage]) -> tuple[str | None, list[Content]]:\n # Accumulates system messages into system_instruction\n # Converts user/assistant messages to Content objects\n```\n\n**Response Parsing:**\n```python\ndef _parse_response(self, resp: Any) -> ChatResponse:\n # Handles empty text on MAX_TOKENS, SAFETY, thinking-only completions\n # Returns placeholder strings for empty responses\n```\n\n### `GroqProvider` (groq_provider.py)\n\nFast inference via Groq SDK.\n\n**Environment Variables:**\n- `GROQ_API_KEY` — Groq API key\n- `GROQ_MODEL` — Model name (default: `llama-3.3-70b-versatile`)\n\n**Notes:**\n- Requires `pip install groq`\n- Does not offer embeddings — use `OpenAIProvider` for those\n- Lazy imports to avoid dependency on groq package\n\n### `NemotronProvider` (nemotron_provider.py)\n\nDigitalOcean GenAI inference endpoint.\n\n**Environment Variables:**\n- `DO_MODEL_ACCESS_KEY` — DigitalOcean model access key\n- `NEMOTRON_MODEL` — Model name (default: `nvidia-nemotron-3-super-120b`)\n\n**Notes:**\n- Uses OpenAI-compatible API at `https://inference.do-ai.run/v1`\n- Default temperature is 0.3 (more deterministic)\n- Uses 60s timeout for both sync and async clients\n\n## Integration Points\n\n### Workflows\n\n| Workflow | Usage |\n|----------|-------|\n| `draft_onboarding_governance` | `get_provider()` |\n| `compress_day` | `achat()` |\n| `extract_memories` | `achat()` |\n| `draft_governance_artifact` | `get_provider()`, `achat()` |\n| `generate_mom_structure` | `get_provider()`, `achat()` |\n| `propose_autoload` | `get_provider()`, `achat()` |\n| `summarize_conversation` | `get_provider()`, `achat()` |\n| `note_title` | `achat()` |\n| `enhance_transcript_with_gemini` | `achat()` |\n| `parse_workflow` | `get_provider()` |\n| `feed_proposals` | `achat()` |\n\n### Core Modules\n\n| Module | Usage |\n|--------|-------|\n| `tool_agent.py` | `get_provider()`, `achat()` |\n| `utility_llm.py` | `achat()`, `get_provider()` |\n| `post_meeting.py` | `get_provider()`, `achat()` |\n| `transcription.py` | `achat()` |\n| `document_indexer.py` | `extract_text_from_file()` |\n\n## Usage Patterns\n\n### Basic Chat\n\n```python\nfrom Harakat_AI.providers import get_provider\nfrom Harakat_AI.providers.base import ChatMessage\n\nprovider = get_provider()\n\nmessages = [\n ChatMessage(role=\"system\", content=\"You are a helpful assistant.\"),\n ChatMessage(role=\"user\", content=\"What is the capital of France?\"),\n]\n\nresponse = provider.chat(messages)\nprint(response.content)\n```\n\n### Streaming\n\n```python\nasync def stream_response():\n provider = get_provider()\n messages = [ChatMessage(role=\"user\", content=\"Tell me a story\")]\n \n async for chunk in provider.astream(messages):\n print(chunk, end=\"\", flush=True)\n```\n\n### Multimodal (Vertex AI Only)\n\n```python\nfrom Harakat_AI.providers import VertexAIProvider\nfrom Harakat_AI.providers.base import ContentPart\n\nprovider = VertexAIProvider()\n\n# Create multimodal message\ncontent = [\n ContentPart(type=\"text\", text=\"Extract text from this image\"),\n ContentPart(type=\"inline_data\", data=image_bytes, mime_type=\"image/png\"),\n]\n\nmessages = [ChatMessage(role=\"user\", content=content)]\nresponse = provider.chat(messages)\n```\n\n### Document Text Extraction\n\n```python\nfrom Harakat_AI.providers import VertexAIProvider\n\nprovider = VertexAIProvider()\ntext = await provider.extract_text_from_file(\n file_bytes=pdf_bytes,\n mime_type=\"application/pdf\",\n prompt=\"Extract all text content from this document.\"\n)\n```\n\n## Provider Selection Strategy\n\n| Use Case | Recommended Provider |\n|----------|---------------------|\n| Fast inference, cost-sensitive | `groq` |\n| Standard OpenAI models | `openai` |\n| Google AI Studio / Vertex | `gemini` or `vertex_ai` |\n| Native Gemini with multimodal | `vertex_ai` |\n| DigitalOcean models | `nemotron` |\n\n## Troubleshooting\n\n### Authentication Errors\n\n**GeminiProvider:**\n- Ensure `GEMINI_API_KEY` or `GOOGLE_API_KEY` is set\n- For Vertex, verify `VERTEX_SERVICE_ACCOUNT_JSON` path and service account permissions\n\n**GroqProvider:**\n- Install groq package: `pip install groq`\n- Set `GROQ_API_KEY`\n\n**NemotronProvider:**\n- Set `DO_MODEL_ACCESS_KEY`\n- Verify DigitalOcean inference endpoint is accessible\n\n### Model Name Issues\n\n**Vertex AI:**\n- Gemini 3.x models require `google/` prefix when using Vertex OpenAI-compatible endpoint\n- Check `VERTEX_MODEL` format matches provider expectations\n\n**GeminiProvider:**\n- Model names starting with `gemini-3` are detected as 3.x family\n- Temperature parameter is ignored for 3.x models (use system instructions instead)\n\n### Empty Responses\n\n**Vertex AI:**\n- `__HERMES_EMPTY_COMPLETION__` indicates thinking-only completion\n- `__HERMES_MALFORMED_FUNCTION_CALL__` indicates tool call parsing error\n- Check `finish_reason` in `response.raw` for diagnostics\n\n## Extending the System\n\n### Adding a New Provider\n\n1. Create provider module in `Harakat_AI/providers/`\n2. Implement `LLMProvider` interface (`chat`, `achat`, `astream`)\n3. Register in `_REGISTRY` in `__init__.py`:\n ```python\n _REGISTRY[\"my_provider\"] = (\".my_provider\", \"MyProvider\")\n ```\n4. Add to `_EXPORTS` for direct imports\n5. Update `__all__` list\n\n### Custom Message Formatting\n\nOverride `_fmt()` method in provider to customize message serialization:\n\n```python\ndef _fmt(self, messages: list[ChatMessage]) -> list[dict]:\n # Custom formatting logic\n return [{\"role\": m.role, \"content\": m.text_content} for m in messages]\n```\n\n### Custom Response Parsing\n\nOverride `_parse_response()` (Vertex AI) or response extraction logic to handle provider-specific response structures.","harakat-ai-rust-ingest":"# Harakat_AI — rust-ingest\n\n\n\n# harakat-ingest\n\n## Overview\n\nThe `harakat-ingest` module is a Rust-based document extraction service designed to run as a short-lived subprocess. Its primary purpose is to ingest various document formats (CSV, DOCX, XLSX, PDF) and extract structured text content into a standardized JSON format.\n\nThe module is engineered for **memory efficiency** (reclaiming resources immediately after extraction) and **output parity** (matching the text shape of the existing Python extractors in `workflows/parse_workflow.py`). It is invoked by the Python service via subprocess to offload heavy lifting without maintaining long-running native dependencies.\n\n## Architecture & Execution Flow\n\nThe module consists of a CLI binary (`harakat-ingest`) and a library crate (`harakat_ingest`). The CLI acts as a dispatcher, routing file paths and format kinds to specific extraction handlers.\n\n### Execution Sequence\n\n1. **Invocation:** The Python service calls `harakat-ingest` via `subprocess.run` with `--kind` (format) and `--input` (path).\n2. **Dispatch:** `main.rs` parses arguments and calls the corresponding `extract` function (e.g., `xlsx::extract`, `docx::extract`).\n3. **Extraction:** The handler reads the file, parses the content, and constructs `ExtractOutput`.\n4. **Serialization:** `ExtractOutput::print_stdout` serializes the result to a single JSON line.\n5. **Reclamation:** The Rust process exits, freeing memory.\n\n```mermaid\nsequenceDiagram\n participant Python as Python Service\n participant CLI as harakat-ingest (main.rs)\n participant Handler as Extractor (csv/docx/xlsx/pdf)\n participant Output as output.rs\n\n Python->>CLI: subprocess.run([--kind, --input])\n CLI->>Handler: extract(path, name)\n Handler->>Handler: Parse (zip/xml/csv/pdfium)\n Handler->>Output: Return ExtractOutput\n Output->>CLI: print_stdout()\n CLI->>Python: JSON stdout\n CLI->>CLI: exit(0)\n```\n\n### CLI Dispatch Logic\n\nThe `main` function in `src/main.rs` matches the `--kind` argument to the appropriate module:\n\n```rust\nlet result: anyhow::Result<ExtractOutput> = match cli.kind.as_str() {\n \"xlsx\" => xlsx::extract(&cli.input),\n \"docx\" => docx::extract(&cli.input),\n \"csv\" => csv::extract(&cli.input, &cli.name),\n #[cfg(feature = \"pdf\")]\n \"pdf_text\" => pdf::extract(&cli.input),\n other => Err(anyhow::anyhow!(\"unsupported kind: {other}\")),\n};\n```\n\n## Core Data Structures\n\nAll extractors return a unified `ExtractOutput` defined in `src/output.rs`. This ensures consistent serialization regardless of the input format.\n\n### `Page`\n\nRepresents a single page of extracted content.\n* `page`: 1-based integer index.\n* `text`: The extracted string content.\n\n```rust\npub struct Page {\n pub page: u32,\n pub text: String,\n}\n```\n\n### `ExtractOutput`\n\nThe container for the extraction result.\n* `pages`: Vector of `Page` objects.\n* `parse_method`: String identifier (e.g., `\"calamine\"`, `\"pdfium\"`, `\"csv\"`).\n\n```rust\npub struct ExtractOutput {\n pub pages: Vec<Page>,\n pub parse_method: String,\n}\n```\n\n## Format Handlers\n\n### CSV (`src/csv.rs`)\n\n* **Handler:** `csv::extract`\n* **Dependencies:** `csv`, `anyhow`\n* **Behavior:**\n * Reads file with `utf-8-sig` semantics (strips BOM, lossy decode).\n * Skips empty cells and fully blank rows.\n * Truncates output at 5000 lines to prevent memory bloat.\n * Output format:\n ```text\n CSV: <name>\n Columns: <col1> | <col2>\n ----------------------------------------\n Row 2: <col1>: <val1> | <col2>: <val2>\n ```\n* **Key Logic:** `decode_utf8_sig_lossy` handles BOM stripping.\n\n### DOCX (`src/docx.rs`)\n\n* **Handler:** `docx::extract`\n* **Dependencies:** `zip`, `quick-xml`, `anyhow`\n* **Behavior:**\n * Treats DOCX as a ZIP archive.\n * Parses `word/document.xml` using `quick-xml`.\n * **Excludes tables:** Paragraphs inside `<w:tbl>` are ignored to match Python's `body-level only` logic.\n * Concatenates paragraphs with `\\n\\n`.\n* **Key Logic:** `body_paragraphs` tracks `tbl_depth` to filter out table content.\n\n### XLSX (`src/xlsx.rs`)\n\n* **Handler:** `xlsx::extract`\n* **Dependencies:** `calamine`, `anyhow`\n* **Behavior:**\n * Uses `calamine` for streaming, low-memory parsing.\n * Iterates sheets; each sheet becomes a `Page`.\n * Skips empty sheets and fully blank rows.\n * **Date Handling:** `Data::DateTime` is converted to `YYYY-MM-DD HH:MM:SS` to match `openpyxl`'s `data_only` output.\n * **Number Formatting:** `fmt_num` strips trailing `.0` for whole numbers to match Python stringification.\n* **Key Logic:** `cell_to_string` handles type conversion (Float, Int, Bool, DateTime).\n\n### PDF (`src/pdf.rs`)\n\n* **Handler:** `pdf::extract`\n* **Dependencies:** `pdfium-render` (Optional feature `pdf`)\n* **Behavior:**\n * Binds to system `libpdfium` at runtime.\n * Extracts text per page.\n * **Normalization:** Converts CRLF to LF to match PyMuPDF's `get_text(\"text\")` output.\n* **Key Logic:** `Pdfium::bind_to_system_library` requires `libpdfium.so` on the loader path.\n\n## Testing & Parity Verification\n\nThe module's correctness is validated against the Python extractors in `workflows/parse_workflow.py`.\n\n### Golden Tests (`golden/`)\n\n1. **`run_golden.py`**:\n * Runs against fixtures in `golden/fixtures/`.\n * Compares normalized text (`norm()`) between Python and Rust outputs.\n * Exits 0 only if page counts and text match exactly.\n * Prints unified diffs on failure.\n\n2. **`pdf_parity_probe.py`**:\n * Generates a specific multi-page PDF with two-column layouts.\n * Compares PyMuPDF vs. `pdfium` (Rust) output.\n * Calculates Jaccard similarity and character ratios.\n * Used for Phase 2 parity verdicts regarding reading order.\n\n### Unit Tests (`tests/`)\n\n* **`tests/cli.rs`**: Verifies unsupported kinds exit with non-zero status.\n* **`tests/xlsx.rs`**: Verifies `xlsx::extract` output format (headers, row numbering, blank cell skipping).\n\n## Build & Configuration\n\n### Features\n\n* `pdf`: Enables `pdfium-render` dependency and `src/pdf` module.\n * **Requirement:** `libpdfium.so` must be available on the loader path at runtime.\n * **Default:** Disabled (lean build).\n\n### Dependencies\n\n* **Core:** `clap` (CLI), `serde`/`serde_json` (Serialization), `anyhow` (Error handling).\n* **Formats:**\n * `csv`: CSV parsing.\n * `zip` + `quick-xml`: DOCX parsing.\n * `calamine`: XLSX parsing.\n * `pdfium-render`: PDF parsing (optional).\n\n### Release Profile\n\nOptimized for performance and size:\n* `opt-level = 3`\n* `lto = true`\n* `strip = true`\n\n## Integration with Python Service\n\nThe Python service invokes the Rust binary as a subprocess. If the Rust process exits with a non-zero code, the Python service treats the extraction as failed and falls back to its native implementation.\n\n```python\n# Example invocation pattern (from golden/run_golden.py)\nout = subprocess.run(\n [BIN, \"--kind\", kind, \"--input\", str(path), \"--name\", path.name],\n capture_output=True,\n check=True,\n)\nreturn json.loads(out.stdout)[\"pages\"]\n```\n\n## Contribution Guidelines\n\n1. **Parity First:** Any new format handler must match the Python output format exactly (line endings, whitespace, data types).\n2. **Memory Safety:** Handlers should avoid holding large file handles open longer than necessary.\n3. **Error Handling:** Use `anyhow::Result` and ensure `main.rs` exits with code 1 on error.\n4. **Testing:** Add unit tests in `tests/` and update `golden/fixtures/` if output format changes.","harakat-ai-src":"# Harakat_AI — src\n\n\n\n# Harakat_AI Runtime Module\n\n## Overview\nThe `Harakat_AI/src/runtime` module serves as the execution engine for AI tasks within the Harakat ecosystem. It exposes a REST API to accept task requests, routes them to specific agent workspaces based on the agent identifier, executes the logic, and reports completion status back to the Harakat orchestration layer.\n\n## Architecture\nThe runtime follows a layered architecture:\n1. **API Layer**: `main.py` handles HTTP requests and response serialization.\n2. **Controller Layer**: `UVController` manages the lifecycle of a task execution.\n3. **Workspace Layer**: `WorkspaceManager` resolves the appropriate execution environment (Space) based on the agent type.\n4. **Executor Layer**: Specific `Space` classes (e.g., `ExpertSpace`, `VirtualAssistantSpace`) contain the actual logic or delegate to external services.\n\n### Execution Flow\n```mermaid\nsequenceDiagram\n participant Client\n participant API as FastAPI (/run)\n participant Ctrl as UVController\n participant WM as WorkspaceManager\n participant Space as Space (Executor)\n participant Harakat as Harakat API\n\n Client->>API: POST /run (AITask)\n API->>Ctrl: execute_task(task)\n Ctrl->>WM: resolve_workspace(agent)\n WM->>Space: run(task)\n Space-->>Ctrl: result\n Ctrl->>Harakat: PATCH /ai/task/complete\n Harakat-->>Ctrl: 200 OK\n Ctrl-->>API: result\n API-->>Client: result\n```\n\n## Key Components\n\n### FastAPI Application (`runtime/main.py`)\nThe entry point for the runtime service.\n\n* **`app`**: A `FastAPI` instance configured with the title \"Harakat AI Runtime\".\n* **`AITask`**: Pydantic model defining the input payload:\n * `requestId`: Unique identifier for the task.\n * `officeId`: Integer identifier for the office.\n * `agent`: String identifier for the target agent (e.g., \"assistant\", \"marketing\").\n * `taskType`: String describing the task type.\n * `payload`: Dictionary containing task-specific data.\n* **`/run` (POST)**:\n * Accepts an `AITask` instance.\n * Calls `UVController().execute_task(task)`.\n * **Callback Logic**: After execution, it attempts to notify the Harakat orchestration layer via a PATCH request to `{HARAKAT_API_URL}/ai/task/complete` with the status \"SUCCEEDED\" and the result.\n * **Environment Variables**: Requires `HARAKAT_API_URL` and `HARAKAT_API_KEY` to function. If missing, a warning is logged and the callback is skipped.\n\n### UV Controller (`runtime/uv/controller.py`)\nThe controller orchestrates the execution logic.\n\n* **`UVController`**:\n * **`__init__`**: Initializes a `WorkspaceManager` instance.\n * **`execute_task(task)`**:\n 1. Calls `self.manager.resolve_workspace(task.agent)` to get the appropriate `Space` instance.\n 2. Invokes `space.run(task)` and returns the result.\n\n### Workspace Manager (`runtime/uv/workspace_manager.py`)\nManages the registry of available agent workspaces and handles path resolution for internal agent imports.\n\n* **`WorkspaceManager`**:\n * **`__init__`**: Instantiates `VirtualAssistantSpace`, `ExpertSpace`, and `PricingSpace` and stores them in a `self.spaces` dictionary.\n * **`resolve_workspace(agent)`**: Maps the `agent` string to a specific workspace:\n * `\"assistant\"` or `\"va\"` → `VirtualAssistantSpace`\n * `\"marketing\"` or `\"finance\"` → `ExpertSpace`\n * `\"pricing\"` → `PricingSpace`\n * *Error*: Raises `ValueError` for unknown agents.\n * **Path Resolution**: Modifies `sys.path` to include the `agents` directory located at `BASE_DIR/agents`. This allows `ExpertSpace` to import internal agent modules (e.g., `Harakat_AI.agents.MarketingAgent.agent`).\n\n### Executors (`runtime/uv/executor.py`)\nContains the concrete implementations of the workspaces.\n\n* **`VirtualAssistantSpace`**:\n * **`run(task)`**: Returns a static response indicating the workspace and a generic output message.\n* **`ExpertSpace`**:\n * **`run(task)`**: Routes based on `task.agent.lower()`:\n * `\"virtual-ea\"`: Sends a POST request to `http://localhost:8080/run` with the task payload. Returns the JSON response or an error object if the request fails.\n * `\"marketing\"`: Imports and executes `Harakat_AI.agents.MarketingAgent.agent.run(task.payload)`.\n * *Default*: Returns a failure status with an error message.\n* **`PricingSpace`**:\n * **`run(task)`**: Returns a static response estimating 15 credits.\n\n## Configuration\nThe runtime relies on the following environment variables:\n\n| Variable | Description | Required |\n| :--- | :--- | :--- |\n| `HARAKAT_API_URL` | Base URL for the Harakat orchestration API. | Yes (for callback) |\n| `HARAKAT_API_KEY` | Bearer token for authenticating with the Harakat API. | Yes (for callback) |\n\n## Integration Points\n* **Harakat Orchestration**: The runtime acts as a worker node. It receives tasks and reports completion via the `/ai/task/complete` endpoint.\n* **External Microservices**: The `ExpertSpace` class supports delegating specific tasks (e.g., `virtual-ea`) to external Docker microservices running on `localhost:8080`.\n* **Internal Agents**: The `ExpertSpace` class supports direct imports of internal agent logic (e.g., `MarketingAgent`), provided the `agents` directory is correctly mounted in the runtime environment.\n\n## Error Handling\n* **Unknown Agent**: If `resolve_workspace` cannot map the `agent` string, a `ValueError` is raised.\n* **External Service Failure**: If the `virtual-ea` HTTP request fails, `ExpertSpace` returns a JSON object with `status: \"failed\"` and the error message.\n* **Callback Failure**: If the Harakat API callback fails (e.g., network error), a warning is printed to the console, but the task result is still returned to the client.","harakat-ai-workers":"# Harakat_AI — workers\n\n\n\n# Harakat_AI.workers.document_indexer\n\nThe `document_indexer` module implements the core ingestion pipeline for the Harakat Knowledge Graph. It is designed as an asynchronous background worker that accepts document jobs, retrieves files from external sources, extracts text using appropriate methods (Gemini OCR, pdfplumber, or native parsers), structures the content into a semantic tree using PageIndex, and persists the resulting sections into the backend Knowledge Graph.\n\n## Overview\n\nThe module handles the full lifecycle of document indexing:\n1. **Ingestion:** Securely downloads files from external URLs.\n2. **Extraction:** Converts binary files into text using MIME-type-aware strategies.\n3. **Structuring:** Generates a hierarchical section tree via PageIndex.\n4. **Persistence:** Upserts section nodes into the Knowledge Graph.\n5. **Reporting:** Updates the execution queue status upon completion or failure.\n\nThe module is intended to be invoked via FastAPI background tasks:\n```python\nfrom workers.document_indexer import index_document\nasyncio.create_task(index_document(job))\n```\n\n## Architecture\n\nThe indexing process follows a linear pipeline with specific fallback logic for text extraction.\n\n```mermaid\nflowchart TD\n Start[Start index_document] --> Download[_download_file]\n Download --> Extract{Select Extractor}\n Extract -->|Image| Gemini[extract_text_gemini]\n Extract -->|PDF| CheckPDF{Born-digital?}\n CheckPDF -->|Yes| PdfPlumber[_extract_text_pdfplumber]\n CheckPDF -->|No| Gemini\n Extract -->|Office/Plain| Native[_OFFICE_EXTRACTORS]\n Gemini --> Build[_build_page_index]\n PdfPlumber --> Build\n Native --> Build\n Build --> Upsert[_upsert_knowledge_nodes]\n Upsert --> Queue[Update Queue Status]\n Queue --> End[Return Result]\n```\n\n## Core Components\n\n### `IndexingJob`\nA dataclass representing a pending indexing task. It encapsulates the necessary metadata to retrieve and process a document.\n\n```python\nclass IndexingJob:\n document_id: int\n startup_id: int\n file_url: str\n filename: str\n access_tier: str\n auth_token: str\n queue_id: int | None\n```\n\n### `index_document(job)`\nThe primary entry point. It is an `async` function that never raises exceptions; instead, it logs errors and returns a result dictionary.\n\n**Execution Flow:**\n1. **Download:** Calls `_download_file` to retrieve content.\n2. **Extraction:** Determines the MIME type and selects the appropriate extractor (`_extract_text_gemini`, `_extract_text_pdfplumber`, or `_OFFICE_EXTRACTORS`).\n3. **Indexing:** Calls `_build_page_index` to generate section nodes.\n4. **Upsert:** Calls `_upsert_knowledge_nodes` to persist data.\n5. **Status:** Calls `_update_queue_status` to report completion.\n\n### Text Extraction Strategy\nThe module employs a tiered extraction strategy to balance speed and accuracy.\n\n| File Type | Primary Method | Fallback |\n| :--- | :--- | :--- |\n| **Image** | `VertexAIProvider` (Gemini) | N/A |\n| **PDF** | `pdfplumber` (Born-digital) | `VertexAIProvider` (Scanned) |\n| **Office** | `docx` / `openpyxl` | N/A |\n| **Plain** | UTF-8 Decode | N/A |\n\n**PDF Handling Logic:**\n1. The module attempts `pdfplumber` first for speed.\n2. If the extracted text is less than 200 characters, it assumes the PDF is scanned and falls back to `Gemini` (`_extract_text_gemini`).\n3. `_extract_text_gemini` calls `VertexAIProvider.extract_text_from_file`. If this fails, it falls back to `pdfplumber`.\n\n**Security Enhancements:**\n* **Redirects:** `_download_file` explicitly refuses redirects to prevent token leakage via re-direction.\n* **Secrets:** The `auth_token` is passed as a `secret` to `egress_request`, preventing it from appearing in logs or error strings.\n* **Byte Cap:** The response content is capped to prevent memory exhaustion from hostile endpoints.\n\n### PageIndex Integration\nThe `_build_page_index` function converts extracted text into a structured format.\n1. Writes text to a temporary Markdown file.\n2. Initializes `PageIndexClient` using the `VERTEX_MODEL`.\n3. Retrieves the document structure.\n4. **Fallback:** If PageIndex fails, it returns a single flat node containing the first 8000 characters of the text to ensure the document remains searchable.\n\n### Knowledge Graph Upsert\nThe `_upsert_knowledge_nodes` function POSTs section nodes to the backend API (`/api/startup/knowledge/graph/node`).\n\n**Payload Structure:**\n```json\n{\n \"kind\": \"document_section\",\n \"externalId\": \"doc-{doc_id}-sec-{order}\",\n \"internalId\": <int: document_id>,\n \"name\": \"<section title>\",\n \"summary\": \"<summary>\",\n \"accessTier\": \"A\",\n \"metadata\": {\n \"level\": <int>,\n \"order\": <int>,\n \"content_preview\": \"<first 400 chars>\",\n \"filename\": \"<original filename>\"\n }\n}\n```\n*Note: `internalId` is sent as an integer. Sending a stringified ID previously caused 500 errors.*\n\n## Security & Configuration\n\n### Environment Variables\nThe module relies on the following configuration:\n* `HARAKAT_API_URL`: Base URL for the backend API.\n* `VERTEX_SERVICE_ACCOUNT_JSON`: Path to the Google Cloud service account JSON.\n* `VERTEX_MODEL`: The model identifier for Vertex AI (e.g., `gemini-1.5-pro`).\n* `PAGEINDEX_MODEL`: The model identifier for PageIndex (defaults to `vertex_ai/{VERTEX_MODEL}`).\n\n### Egress Policy\nAll external requests are guarded by `core.security.egress.policies.document_download_policy`. This ensures that URLs are validated before the worker attempts to fetch them.\n\n## Error Handling\nThe module follows a \"fail-soft\" strategy.\n* **Exceptions:** Caught at the `index_document` level.\n* **Logging:** Errors are logged with `logger.error` and `logger.warning` depending on severity.\n* **Queue Status:** If a `queue_id` is present, the status is updated to `\"failed\"` with the error message.\n* **Result:** Returns a dictionary containing `document_id` and either `sections_indexed` or `error`.\n\n## Dependencies\n* **Internal:** `core.config`, `core.security.egress`, `providers.vertex_ai`.\n* **External:** `httpx`, `pdfplumber`, `docx`, `openpyxl`.\n* **Sub-repo:** `PageIndex` (imported dynamically via `sys.path` modification).","harakat-ai":"# Harakat_AI\n\n\n\n# Harakat_AI\n\n## Overview\nThe `Harakat_AI` module group serves as the central orchestration layer for the AI runtime, managing task execution, agent logic, knowledge ingestion, and infrastructure deployment. It bridges high-level API requests with specialized agent workspaces, LLM inference backends, and data processing pipelines.\n\n## Architecture\n\n### Runtime Execution\nThe execution engine resides in the `src` module, exposing a REST API that routes incoming tasks to specific agent workspaces via `WorkspaceManager`. This layer manages the lifecycle of task execution, from request handling to completion reporting.\n\n### Agent & Tooling\nAgents interact with the system through standardized data contracts defined in `envelopes`, ensuring disparate outputs can be stitched together by the composer and planner. For external tooling, the `mcp_client` module provides a secure proxy interface for Model Context Protocol (MCP) tools, handling authentication and audit logging without exposing credentials to the agent process.\n\n### Knowledge & Data\nData ingestion is handled by the `workers/document_indexer`, which processes files and structures content for the Knowledge Graph. Heavy extraction tasks are offloaded to the `rust-ingest` subprocess for memory efficiency. The `capabilities` module manages the lifecycle of learned skills, while the `providers` module abstracts LLM inference backends, allowing runtime swapping via environment configuration.\n\n### Infrastructure & Documentation\nDeployment is managed through `kubernetes` manifests, ensuring consistent infrastructure across environments. Developer guidance is provided in the `docs` module, covering agent development workflows and system setup.\n\n## Integration Flow\n\n1. **Task Submission:** Requests enter via the `src` runtime API.\n2. **Dispatch:** The runtime routes tasks to `agents` based on workspace requirements.\n3. **Inference & Tools:** Agents utilize `providers` for LLM calls and `mcp_client` for external tool access.\n4. **Data Processing:** Background `workers` ingest and structure data, potentially using `rust-ingest` for parsing.\n5. **Standardization:** All agent outputs conform to `envelopes` for unified consumption.\n\n```mermaid\ngraph TD\n API[Runtime API (src)] -->|Routes Task| Runtime[Workspace Manager]\n Runtime -->|Dispatches| Agents[Agent Logic]\n Agents -->|Inference| Providers[LLM Providers]\n Agents -->|Tools| MCP[mcp_client Proxy]\n Agents -->|Data| Envelopes[Result Envelopes]\n Workers[Document Indexer] -->|Ingests| Rust[rust-ingest]\n Workers -->|Stores| KG[Knowledge Graph]\n Infrastructure[Kubernetes] -->|Deploys| All[All Components]\n```\n\n## Sub-Modules\n\n* [src](src.md): Runtime execution engine and API layer.\n* [providers](providers.md): Pluggable LLM backend interface.\n* [workers](workers.md): Background document indexing and ingestion.\n* [mcp_client](mcp_client.md): Secure MCP tool invocation.\n* [envelopes](envelopes.md): Standardized data contracts for agent communication.\n* [capabilities](capabilities.md): Lifecycle management for learned skills.\n* [kubernetes](kubernetes.md): Infrastructure-as-Code manifests.\n* [rust-ingest](rust-ingest.md): High-performance document extraction.\n* [docs](docs.md): Developer reference and guides.\n* [agents](agents.md): Agent logic and workflows.\n* [bench](bench.md): Benchmarking utilities.\n* [core](core.md): Core system logic.\n* [scripts](scripts.md): Utility scripts.\n* [tests](tests.md): Test suites.\n* [workflows](workflows.md): Workflow definitions.\n* [erp-mcp](erp-mcp.md): ERP-specific MCP integration.\n* [erp-skills](erp-skills.md): ERP-specific skills.","harakat-kernel-dev":"# Harakat_Kernel — dev\n\n\n\n# Harakat_Kernel — dev\n\nThis module provides the development environment infrastructure and launcher scripts for the `kernel-server` binary. It is designed to run an isolated, non-production stack that mirrors the production architecture without sharing resources or ports with the live Harakat stack.\n\n## Overview\n\nThe `dev` module serves two primary functions:\n1. **Infrastructure Provisioning:** Manages Docker containers for Postgres and OpenBao required by the kernel server during development.\n2. **Process Launching:** Provides cross-platform scripts (`run-kernel.ps1`, `run-kernel.sh`) to load environment variables and execute the `kernel-server` binary.\n\nUnlike the production stack, this environment is deliberately isolated. Starting or stopping these services does not affect the live stack and requires no stack lock.\n\n## Architecture\n\nThe module consists of four key files:\n* `docker-compose.dev.yml`: Defines the containerized services.\n* `kernel.env.example`: Template for local environment configuration.\n* `run-kernel.ps1`: Windows launcher script.\n* `run-kernel.sh`: Linux launcher script.\n\n### Infrastructure Isolation\n\nThe dev stack uses distinct ports and container names to prevent conflicts with the live stack:\n\n| Component | Dev Port | Live Port | Container Name |\n| :--- | :--- | :--- | :--- |\n| Postgres | 5442 | 5432 | `harakat-kernel-dev-pg` |\n| OpenBao | 8210 | 8200 | `harakat-kernel-dev-openbao` |\n\n**OpenBao Configuration:**\nThe OpenBao service runs in dev mode (`server -dev`) with an in-memory backend and auto-unsealed state. The root token is `root`. **Never** place real tenant keys in this environment.\n\n**Database Persistence:**\nThe Postgres volume `kernel_dev_pgdata` is marked as `external: true`. This allows the volume to be restored onto a new machine by matching mount paths, a requirement following the 2026-07-27 move.\n\n## Configuration\n\n### Environment Variables\n\nDevelopers must create a local file named `.env.kernel.local` (gitignored) based on `kernel.env.example`. This file is sourced by the launcher scripts.\n\n**Critical Security Constraints:**\n* **Secret Split:** `KERNEL_GATEWAY_SECRET` and `KERNEL_SYSTEM_SECRET` must be **distinct** random values. The kernel refuses to boot if they are identical.\n* **System Secret:** If `KERNEL_SYSTEM_SECRET` is unset or empty, the `/system/execute` endpoint remains dark (fail-closed).\n* **Delegation:** If `KERNEL_DELEGATION_URL` is set, `KERNEL_INTERNAL_AUTH` must be at least 32 characters and match the server's value. A mismatch causes the kernel to refuse booting to prevent opaque 401 errors during delegated calls.\n\n**Key Variables:**\n* `KERNEL_BIND`: Address for the kernel server (default `127.0.0.1:8300`).\n* `DATABASE_URL`: Connection string for the dev Postgres instance.\n* `KERNEL_TENANTS`: Tenant ID (e.g., `19`).\n* `KERNEL_ENTITLEMENTS`: Semicolon-separated list of tenant:key pairs.\n* `KERNEL_AUTHORITY`: Authority assertion version (leave empty until server proxy threading is complete).\n\n### Launcher Scripts\n\nBoth scripts perform the following steps:\n1. Validate the existence of `.env.kernel.local`.\n2. Export all `KEY=VALUE` pairs from the file into the process environment.\n3. Determine the binary path based on the `--release` flag (or default to debug).\n4. Verify the binary exists.\n5. Execute the binary in the foreground.\n\n**Windows (`run-kernel.ps1`):**\n* Requires PowerShell.\n* Supports `-Release` switch.\n* Checks for `target\\release\\kernel-server.exe` or `target\\debug\\kernel-server.exe`.\n\n**Linux (`run-kernel.sh`):**\n* Requires Bash.\n* Supports `--release` flag.\n* Checks for `target/$profile/kernel-server`.\n\n## Execution Flow\n\nThe following diagram illustrates the startup sequence when running the kernel in development.\n\n```mermaid\nsequenceDiagram\n participant Dev as Developer\n participant Script as run-kernel.sh/.ps1\n participant Env as .env.kernel.local\n participant Bin as kernel-server\n participant Docker as Docker Compose\n\n Dev->>Script: Run script\n Script->>Env: Load variables\n Script->>Script: Validate Binary Exists\n Script->>Docker: Ensure Stack Running (5442/8210)\n Script->>Bin: Execute Binary\n Bin->>Docker: Connect to Postgres (5442)\n Bin->>Docker: Connect to OpenBao (8210)\n Bin-->>Dev: Kernel Running\n```\n\n## Usage\n\n### Prerequisites\n1. Ensure Docker is running.\n2. Ensure the dev stack is up:\n ```bash\n docker compose -f dev/docker-compose.dev.yml up -d\n ```\n3. Build the kernel binary:\n ```bash\n cargo build -p kernel-server\n # or\n cargo build --release -p kernel-server\n ```\n\n### Running the Kernel\n**Windows:**\n```powershell\npowershell -File dev\\run-kernel.ps1\n# For release binary:\npowershell -File dev\\run-kernel.ps1 -Release\n```\n\n**Linux:**\n```bash\nbash dev/run-kernel.sh\n# For release binary:\nbash dev/run-kernel.sh --release\n```\n\n## Troubleshooting & Notes\n\n### Stopping the Kernel\nDo **not** stop the kernel by killing the port owner (e.g., `kill -9` on port 8300). This is a Docker landmine that can leave containers in a broken state. Instead, stop the process by PID or use `Ctrl+C` in the terminal running the script.\n\n### Database Recovery\nIf the `kernel_dev_pgdata` volume is lost, it can be recovered by matching the mount path on a new machine. The volume is named `harakat_kernel_dev_pgdata` and is external.\n\n### Delegation Failures\nIf delegation tokens are refused:\n1. Check `KERNEL_DELEGATION_URL` is set.\n2. Verify `KERNEL_INTERNAL_AUTH` is at least 32 characters.\n3. Ensure `KERNEL_INTERNAL_AUTH` matches the server's configuration exactly.\n4. If `KERNEL_DELEGATION_URL` is set but `KERNEL_INTERNAL_AUTH` is missing/short, the kernel will refuse to boot to prevent misconfiguration from appearing as an outage.\n\n### Authority Version\nThe `KERNEL_AUTHORITY` variable is currently empty. The server proxy does not yet thread `harakat_authority_version` for `/execute` and `/system/execute` mutations. Leave this empty until that threading logic is implemented.","harakat-kernel-harakat-kernel":"# Harakat_Kernel — Harakat_Kernel\n\n\n\n# Harakat Kernel Workspace\n\n## Overview\n\nThe Harakat Kernel is a Rust-based application framework designed to serve as the backend for an ERP system, replacing Odoo. It operates on a \"kernel-first\" architecture where business logic is compiled into Rust crates (Layer 1) while tenant-specific customizations are handled via interpreted data overlays (Layer 2).\n\nThe workspace is structured as a monorepo containing internal crates, business applications, and ETL tools. All components share a common dependency tree and security policy enforced via `deny.toml`.\n\n## Architecture\n\nThe system is divided into two distinct layers that interact at specific chokepoints.\n\n### Layer 1: Compiled App Framework\nThis layer consists of Rust crates implementing the `App` trait. Models and behaviors are declared using attribute macros (`#[model]`, `#[field]`, `#[computed]`, `#[state_machine]`, `#[sealed]`, `#[tier]`). These macros emit both the runtime code and the UI manifest/agent-tool metadata, ensuring parity by construction.\n\n### Layer 2: Interpreted Tenant Customization\nThis layer governs everything a tenant or agent authors. It is data-driven, not code-driven. Custom fields, relabels, expressions, and automations are stored and resolved against the base schema. The \"Base Schema ⊕ Tenant Overlay\" acts as the wall between the two layers.\n\n### The Four Planes\nFour security and operational planes cut through both layers at chokepoints. Apps cannot opt out of these planes:\n\n1. **Security:** P1 spine adapters (`canSee` port), OpenFGA, delegation, SPIFFE, OpenBao sealing.\n2. **Commercial:** Entitlements and metering.\n3. **Monitoring:** Tracing and watchdogs.\n4. **Scalability:** `tenant_id`-first keys, no cross-tenant transactions, stateless processes.\n\n## Workspace Structure\n\nThe workspace is organized into three primary directories:\n\n```text\nHarakat_Kernel/\n├── crates/ # Internal libraries\n│ ├── kernel-core # Frozen contract layer\n│ ├── kernel-macros # Proc-macros\n│ ├── kernel-storage # SQLX Postgres executor\n│ ├── kernel-seal # OpenBao crypto\n│ ├── kernel-events # Outbox dispatcher\n│ ├── kernel-authz # Security adapters\n│ ├── kernel-expr # Expression language\n│ ├── kernel-overlay # Schema resolver\n│ ├── kernel-api # Axum gateway\n│ ├── kernel-server # Bootstrapping binary\n│ └── kernel-testkit # Fakes and fixtures\n├── apps/ # Business applications\n│ ├── helpdesk # K1 pilot\n│ ├── crm # Customer relationship management\n│ ├── finance # Accounting\n│ └── ... # 30+ other apps\n└── tools/ # ETL and testing harnesses\n ├── diff-harness # Record/replay vs live\n └── etl-* # Data migration tools\n```\n\n## Core Crates\n\n### `kernel-core`\nThe frozen contract layer. Defines traits, ports, `TenantCtx`, `Value`, and `EventEnvelope`. Changes are only permitted via WS-0 RFC and version bumps.\n\n### `kernel-macros`\nProvides proc-macros that emit descriptors and manifests. Used by apps to declare models and fields.\n\n### `kernel-storage`\nHandles SQLX Postgres interactions. Implements a tenant-sealed executor with a single audited mutation path.\n\n### `kernel-seal`\nImplements OpenBao Transit envelope crypto. Bit-compatible with the TypeScript `kms:v1` implementation.\n\n### `kernel-events`\nManages the transactional outbox (row + audit + outbox in one tx), consumer cursors, watchdogs, and metering.\n\n### `kernel-authz`\nImplements spine adapters for authorization, including `canSee`, OpenFGA integration, and SPIFFE verification.\n\n### `kernel-overlay`\nResolves the base schema against tenant overlays. Handles custom fields and automation interpretation.\n\n### `kernel-api`\nThe Axum-based gateway. Exposes `/execute` endpoints, middleware planes, and manifest serving.\n\n### `kernel-server`\nThe binary entry point. Handles configuration, wiring, and bootstrapping.\n\n## Security & Compliance\n\n### Cryptography Policy\nThe workspace enforces a strict **rustls-only** policy. No OpenSSL, native-tls, or schannel dependencies are permitted.\n\n* **Enforcement:** `deny.toml` explicitly bans `openssl`, `openssl-sys`, and `native-tls`.\n* **Dependencies:** `sqlx` and `reqwest` are configured with `tls-rustls-ring-webpki` and `rustls-tls` features respectively.\n* **Verification:** Gate proofs run against real Postgres and real OpenBao (dev) instances; no mocks are allowed in gate proofs.\n\n### Registry Hot-Swap\nThe system uses `arc-swap` for lock-free registry hot-swapping. This allows entities to join the live registry without a redeploy, ensuring readers always load a consistent snapshot.\n\n## Data & Events\n\n### Transactional Outbox\nA single event stream is maintained via a Postgres transactional outbox. Each transaction includes the data row, audit log, and outbox message in a single atomic operation.\n\n### Tenant Isolation\nAll database keys are `tenant_id`-first. Cross-tenant transactions are prohibited to ensure isolation.\n\n## Development Workflow\n\n### Branching Rules\n* `main`: Contains merged known-good code only.\n* `rust-kernel`: Program work happens on this branch.\n* **Commit Discipline:** Commit at every green checkpoint. Never end a session uncommitted. No destructive git commands.\n\n### Building\n* **Bare-metal Windows:** Requires stable MSVC toolchain.\n* **DB-less Builds:** Use `SQLX_OFFLINE=true` to utilize the committed `.sqlx` query cache.\n* **Integration Tests:** Require a running Postgres instance and an OpenBao dev server.\n\n### Testing\n* **Unit:** Standard Rust unit tests.\n* **Integration:** Requires Postgres + OpenBao.\n* **Diff Harness:** `tools/diff-harness` records/replays state against live Odoo to verify parity.\n\n## Architecture Diagram\n\nThe following diagram illustrates the relationship between the Kernel Layers, the Four Planes, and the Workspace components.\n\n```mermaid\ngraph TD\n subgraph \"Layer 1: Compiled Framework\"\n App[App Trait]\n Macros[Proc-Macros]\n Core[kernel-core]\n end\n\n subgraph \"Layer 2: Interpreted Customization\"\n Overlay[kernel-overlay]\n Data[Tenant Data]\n end\n\n subgraph \"Four Planes\"\n Sec[Security: OpenFGA, OpenBao]\n Comm[Commercial: Metering]\n Mon[Monitoring: Tracing]\n Scal[Scalability: tenant_id keys]\n end\n\n subgraph \"Workspace\"\n Crates[crates/]\n Apps[apps/]\n Tools[tools/]\n end\n\n App --> Core\n Macros --> App\n Core --> Sec\n Core --> Comm\n Core --> Mon\n Core --> Scal\n Overlay --> Data\n Apps --> Core\n Apps --> Overlay\n Tools --> Apps\n```\n\n## Git Rules\n\nThe meta-repo's `docs/git-rules.md` binds this repository. Adherence is mandatory:\n1. Commit at every green checkpoint.\n2. Never end a session uncommitted.\n3. No destructive git commands ever.","harakat-kernel-scripts":"# Harakat_Kernel — scripts\n\n\n\n# Harakat_Kernel/scripts\n\nThis module contains shell scripts that enforce architectural boundaries and data integrity gates within the Harakat Kernel repository. These scripts operate as static analysis tools and runtime verification gates, ensuring that `sqlx` dependencies remain confined to kernel-owned system-table crates and that database migrations function correctly for both fresh and existing databases.\n\n## Architectural Context\n\nThe scripts enforce two critical laws defined in `docs/contracts.md`:\n\n1. **WS-B (sqlx Ban):** `sqlx` is banned from tenant application data paths. Tenant data must flow through `kernel-storage`'s `TenantExecutor`. Only specific kernel crates are allowed to use `sqlx` directly.\n2. **Boot Gate:** The kernel database must be able to boot from a fresh state and maintain integrity for existing states. This guards against defects in migration ordering and schema generation (specifically regarding `allocation_rule_line` and descriptor indexes).\n\n## Script: check-sqlx-boundary.sh\n\n`check-sqlx-boundary.sh` is a static analysis gate that scans the repository for unauthorized usage of the `sqlx` crate.\n\n### Purpose\nEnsures `sqlx` is not used in `apps/`, `tools/`, or non-allowlisted `crates/`. It prevents tenant applications from bypassing `kernel-storage`'s `TenantExecutor`.\n\n### Allowlist\nThe script defines a hardcoded allowlist of crates permitted to use `sqlx`. Any crate outside this list is scanned for violations.\n\n```bash\nALLOWLIST=(\n \"crates/kernel-storage\"\n \"crates/kernel-events\"\n \"crates/kernel-overlay\"\n \"crates/kernel-testkit\"\n \"crates/kernel-server\"\n \"crates/kernel-integration\"\n)\n```\n\n*Note: `kernel-integration` is included as it contains the integrator's evidence crate (G2+ probes) that inspect kernel columns directly.*\n\n### Scanning Logic\nThe script performs the following steps:\n\n1. **Root Resolution:** Resolves the repository root relative to the script's location.\n2. **Manifest Scan:** Iterates through `Cargo.toml` files in `crates/`, `apps/`, and `tools/`.\n3. **Source Scan:** Iterates through `src/`, `tests/`, `examples/`, and `benches/` directories within each crate.\n4. **Filtering:**\n * Ignores comment lines in TOML (`#`).\n * Ignores comment lines in Rust (`//`).\n * Matches `sqlx` in dependency lines or feature references.\n5. **Violation Handling:** Offenders are collected in the `offenders` array.\n\n### Execution Flow\nThe script uses a linear scan with conditional branching based on the `is_allowed` function.\n\n```mermaid\nflowchart TD\n Start[Start Script] --> Resolve[Resolve Repo Root]\n Resolve --> Loop[Iterate Manifests]\n Loop --> CheckAllowed{Is Crate Allowed?}\n CheckAllowed -->|No| ScanFiles[Scan Cargo.toml & src/**/*.rs]\n ScanFiles --> FoundSqlx{Found sqlx?}\n FoundSqlx -->|Yes| AddOffender[Add to offenders array]\n FoundSqlx -->|No| Loop\n CheckAllowed -->|Yes| Loop\n AddOffender --> Loop\n Loop --> EndScan[End Scan]\n EndScan --> CheckOffenders{Offenders > 0?}\n CheckOffenders -->|Yes| Fail[Exit 1: Print Offenders]\n CheckOffenders -->|No| Pass[Exit 0: OK]\n```\n\n### Exit Codes\n* **0:** Success. `sqlx` is confined to the allowlist.\n* **1:** Failure. `sqlx` found in a non-allowlisted crate. Prints offending file paths and line numbers to stderr.\n\n## Script: migrate-gate.sh\n\n`migrate-gate.sh` is a runtime gate that verifies the kernel's database migration logic. It ensures that a fresh database can be created and migrated, and that an existing database can boot without data loss.\n\n### Purpose\nThis script addresses historical defects (as of 2026-08-03) where:\n* `accounts` V5 was a bare `ALTER TABLE allocation_rule_line` that failed to create the table when `ALLOCATION_ENGINE` was off.\n* Descriptor indexes were emitted before app migrations, causing boot failures (42703) on older schemas.\n\n### Test Requirements\nThe script enforces that specific tests must pass. Renaming or ignoring these tests causes the gate to fail.\n\n```bash\nEXPECTED=(\n \"fresh_db_migrates_with_the_allocation_engine_off\"\n \"fresh_db_migrates_with_the_allocation_engine_on\"\n \"engine_switched_on_after_an_engine_off_database_is_complete\"\n \"existing_pre_p3_database_boots_and_keeps_its_rows\"\n \"migrate_is_idempotent_across_boots\"\n \"fresh_db_boot_is_green\"\n \"upgrade_from_old_layout_is_seamless\"\n \"the_two_halves_compose_to_the_whole_table_ddl\"\n \"the_columns_half_emits_no_index_and_the_index_half_no_table\"\n)\n```\n\n### Execution Logic\n1. **Environment:** Requires `Postgres` at `TEST_DATABASE_URL` (default: `postgres://kernel:kernel@127.0.0.1:5442/kernel_test`).\n2. **Live Requirement:** Sets `G_REQUIRE_LIVE=1` to ensure tests fail if Postgres is unavailable, rather than skipping silently.\n3. **Test Execution:**\n * Runs `kernel-integration` tests: `migrate_ordering_pg`, `employees_split_pg`.\n * Runs `kernel-storage` library tests: `ddl::`.\n4. **Verification:**\n * Checks exit codes of `cargo test` commands.\n * Parses output to verify every test in `EXPECTED` reported `ok`.\n * Fails if any test is missing, renamed, or ignored.\n\n### Usage\nRun from the repository root or any directory:\n\n```bash\nbash scripts/migrate-gate.sh\n```\n\n### Exit Codes\n* **0:** All expected tests passed.\n* **1:** `cargo test` failed, or expected tests were not found in the output.\n\n## Integration\n\nThese scripts are designed to be run independently but are typically integrated into CI pipelines or local pre-commit hooks.\n\n* **check-sqlx-boundary.sh:** Should be run before committing changes to `Cargo.toml` or `src/**/*.rs` files to prevent architectural drift.\n* **migrate-gate.sh:** Should be run during the CI build phase to ensure database compatibility before merging changes to the schema.\n\nBoth scripts resolve the repository root dynamically, allowing them to be executed from any working directory.","harakat-kernel":"# Harakat_Kernel\n\n\n\n# Harakat_Kernel\n\n## Overview\n\nThe Harakat Kernel is a Rust-based application framework designed to serve as the backend for an ERP system, replacing Odoo. It operates on a \"kernel-first\" architecture where business logic is compiled into Rust crates (Layer 1) while tenant-specific customizations are handled via interpreted data overlays (Layer 2). The workspace is structured as a monorepo containing internal crates, business applications, and ETL tools, all sharing a common dependency tree and security policy enforced via `deny.toml`.\n\n## Sub-Module Integration\n\nThe module group coordinates the lifecycle of the kernel through specialized sub-modules that enforce boundaries and provide infrastructure:\n\n* **Infrastructure & Execution:** The [Harakat_Kernel — dev](dev.md) module provisions isolated Docker containers for Postgres and OpenBao and provides cross-platform launcher scripts to execute the `kernel-server` binary. This ensures the development stack mirrors production architecture without sharing resources.\n* **Architectural Enforcement:** The [Harakat_Kernel — scripts](scripts.md) module acts as a verification gate, enforcing architectural laws such as the `sqlx` ban on tenant application data paths and validating database migrations for both fresh and existing databases.\n* **Business Logic & Crates:** The [Harakat_Kernel — apps](apps.md) and [Harakat_Kernel — crates](crates.md) sub-modules contain the compiled business logic. These components interact with core kernel state management via `kernel-core`, `kernel-storage`, and `kernel-api`.\n* **Support & Documentation:** The [Harakat_Kernel — tools](tools.md) and [Harakat_Kernel — docs](docs.md) sub-modules support the build pipeline and provide reference material for the framework.\n\n## Data Flow and Dependencies\n\nBusiness logic modules (`accounts`, `payroll`, `purchase`, `crm`) rely heavily on core kernel components for state management and access control. Key interactions include:\n\n* **State Management:** Functions such as `apply_child_writes` and `run_foreign_lifecycle` in `kernel-storage` interface with `LogicCtx` and `Mutation` models defined in `kernel-core`.\n* **Access Control:** Authorization flows derive `AccessClaims` from `kernel-authz` and `kernel-core`, ensuring tenant isolation (e.g., `one_tenant_s_rollup_never_sees_another_tenant_s_children`).\n* **API State:** Application logic queries `ApiConfig` and `ApiState` from `kernel-api` to manage configuration and runtime state.\n\n## Architecture\n\n```mermaid\ngraph TD\n subgraph Development\n A[Harakat_Kernel — dev] -->|Provisioning| B_kernel-server[\"B(kernel-server)\"]\n end\n\n subgraph Enforcement\n C[Harakat_Kernel — scripts] -->|Validation| D[Apps & Crates]\n end\n\n subgraph Core Logic\n D -->|Business Logic| E[Harakat_Kernel — apps]\n D -->|Internal Crates| F[Harakat_Kernel — crates]\n end\n\n subgraph Kernel Core\n E -->|State & Mutations| G[kernel-core]\n E -->|Storage| H[kernel-storage]\n E -->|API| I[kernel-api]\n end\n\n B -.->|Runs| D\n C -.->|Enforces| D\n```","harakat-landing-harakat-landing":"# Harakat_Landing — Harakat_Landing\n\n\n\n# Harakat_Landing\n\n## Overview\nThe `Harakat_Landing` module is a Next.js 14 standalone application serving as the primary landing page for the Harakat project. It utilizes a multi-stage Docker build process to optimize production performance and includes server-side capabilities for contact form handling via Zoho SMTP.\n\n## Architecture & Build Process\nThe application is built using **Next.js 14.2.25** with **pnpm** as the package manager. The build pipeline is defined in `Dockerfile` using a multi-stage approach to minimize the final image size.\n\n### Build Stages\n1. **Base**: Installs Node.js 20 and activates `pnpm`.\n2. **Deps**: Installs production dependencies using `pnpm install --frozen-lockfile`.\n3. **Build**: Copies source code and `.env` files, then runs `pnpm build`. This generates the `.next/standalone` output.\n4. **Runner**: Copies the standalone build and static assets into a minimal Node.js image. It runs as a non-root user (`nextjs`) and exposes port 3000.\n\n### Execution Flow\nThe module does not contain internal logic execution flows detectable via static analysis; it functions primarily as a build configuration and entry point. The runtime behavior is driven by the Next.js standalone server and a custom `server.js` entry point for API/SMTP handling.\n\n```mermaid\nflowchart TD\n A[Source Code] -->|pnpm install| B[Dependencies]\n B -->|pnpm build| C[.next/standalone]\n C -->|COPY| D[Docker Runner Image]\n D -->|CMD| E[node server.js]\n E -->|Serve| F[Port 3000]\n E -->|Handle| G[Contact Form / SMTP]\n```\n\n## Configuration\n\n### Next.js Configuration (`next.config.mjs`)\nThe `next.config.mjs` file configures the application for production deployment and legacy routing.\n\n* **Output Mode**: `output: 'standalone'` enables the standalone output format required for the Docker runner.\n* **Image Optimization**: `images.unoptimized: true` disables automatic image optimization.\n* **Redirects**: Temporary redirects are configured for legacy paths:\n * `/about` → `/company/about`\n * `/experience` → `/contact`\n * `/solutions` → `/platform`\n* **Security Headers**: Configures `Content-Type` for `/.well-known/apple-app-site-association` to `application/json` to support iOS passkeys and universal links.\n\n### Environment Variables\n* **Build Time**: `NEXT_PUBLIC_*` variables are read automatically by Next.js during the build process.\n* **Runtime**: The Dockerfile comments indicate that Zoho SMTP credentials are passed as runtime environment variables (not prefixed with `NEXT_PUBLIC_`) to the container.\n\n## Dependencies\nThe module relies on a specific set of libraries for UI, animation, and backend functionality.\n\n### UI & Styling\n* **Tailwind CSS v4**: Configured via `@tailwindcss/postcss` with `new-york` style from Shadcn UI.\n* **Shadcn UI**: Uses Radix UI primitives (e.g., `@radix-ui/react-dialog`, `@radix-ui/react-select`).\n* **Icons**: `lucide-react`.\n\n### Animation & 3D\n* **GSAP**: `@gsap/react` and `gsap` for animations.\n* **Framer Motion**: `framer-motion` and `motion`.\n* **Three.js**: `@react-three/fiber` and `three` for 3D elements.\n\n### Backend & Forms\n* **Nodemailer**: `nodemailer` for email handling.\n* **Zod**: `zod` for schema validation.\n* **React Hook Form**: `react-hook-form` and `@hookform/resolvers` for form management.\n\n### Utilities\n* **Date Handling**: `date-fns`, `react-day-picker`.\n* **Charts**: `recharts`.\n* **Analytics**: `@vercel/analytics`.\n\n## Runtime Behavior\nIn production, the application runs as a non-root user (`nextjs`) within the Docker container.\n\n1. **Static Assets**: Served from `/app/.next/static`.\n2. **Standalone App**: Served from `/app/.next/standalone`.\n3. **API/SMTP**: The `server.js` entry point handles server-side requests, specifically the contact form submission which routes to Zoho SMTP.\n4. **Port**: Listens on `0.0.0.0:3000`.\n\n## Development Scripts\nThe `package.json` defines the following scripts for local development:\n\n* `pnpm dev`: Starts the development server on port 3003.\n* `pnpm build`: Builds the production standalone output.\n* `pnpm start`: Starts the production server on port 3003.\n* `pnpm lint`: Runs ESLint.\n\n## Security Considerations\n* **Apple App Site Association**: Explicitly configured to serve JSON content type to ensure iOS devices correctly associate the domain with the app.\n* **User Permissions**: The production runner uses a dedicated system user (`nodejs`) to limit file system access.\n* **Environment Isolation**: Sensitive SMTP credentials are excluded from the build output and injected at runtime via Docker environment variables.","harakat-landing-hooks":"# Harakat_Landing — hooks\n\n\n\n# Harakat_Landing — Hooks\n\nThis module provides custom React hooks for managing UI state within the `Harakat_Landing` application. It includes functionality for responsive design detection (`use-mobile.ts`) and a client-side toast notification system (`use-toast.ts`).\n\n## Overview\n\nThe module is designed to handle lightweight, client-side state management without external state libraries. It relies on React's `useState` and `useEffect` hooks, along with a custom reducer pattern for toast notifications.\n\n## Mobile Detection\n\nThe `use-mobile.ts` file provides a hook to detect if the current viewport width is below a specific breakpoint.\n\n### `useIsMobile`\n\nA custom hook that returns a boolean indicating whether the device is mobile.\n\n**Signature:**\n```typescript\nexport function useIsMobile(): boolean\n```\n\n**Behavior:**\n- **Breakpoint:** Uses `MOBILE_BREAKPOINT` set to `768`.\n- **Initial State:** Returns `false` until the `useEffect` runs and sets the initial value based on `window.innerWidth`.\n- **Updates:** Listens to `window.matchMedia` changes to update the state dynamically when the viewport resizes.\n- **Cleanup:** Removes the event listener on unmount.\n\n**Usage:**\n```typescript\nconst isMobile = useIsMobile();\n```\n\n## Toast Notification System\n\nThe `use-toast.ts` file implements a client-side toast notification system inspired by `react-hot-toast`. It manages the state of active toasts, allowing components to trigger notifications and dismiss them programmatically.\n\n### Key Components\n\n#### `toast` Function\nThe primary API for creating a toast notification.\n\n**Signature:**\n```typescript\nfunction toast(props: Toast)\n```\n\n**Returns:**\nAn object containing methods to control the toast:\n- `id`: Unique identifier for the toast.\n- `dismiss`: Function to dismiss the specific toast.\n- `update`: Function to update the toast properties.\n\n**Execution Flow:**\n1. Calls `genId()` to generate a unique ID.\n2. Dispatches an `ADD_TOAST` action via `dispatch`.\n3. Returns the control object.\n\n#### `useToast` Hook\nThe consumer hook for accessing the toast state and actions.\n\n**Signature:**\n```typescript\nfunction useToast()\n```\n\n**Returns:**\n- `toasts`: Array of active toast objects.\n- `toast`: The `toast` function described above.\n- `dismiss`: Function to dismiss a toast by ID or all toasts.\n\n**State Management:**\n- Uses a custom listener pattern (`listeners` array) to propagate state changes from the `memoryState` to the hook.\n- Updates `memoryState` via the `dispatch` function.\n\n### State Management Architecture\n\nThe toast system uses a reducer pattern to manage state transitions.\n\n**Constants:**\n- `TOAST_LIMIT`: Set to `1`. Only one toast is allowed to be visible at a time.\n- `TOAST_REMOVE_DELAY`: Set to `1000000` (1000 seconds). Defines the timeout for auto-removal after dismissal.\n\n**Actions:**\n- `ADD_TOAST`: Adds a new toast to the state, respecting the `TOAST_LIMIT`.\n- `UPDATE_TOAST`: Updates properties of an existing toast.\n- `DISMISS_TOAST`: Closes the toast and schedules removal via `addToRemoveQueue`.\n- `REMOVE_TOAST`: Removes the toast from the state array.\n\n**Reducer Logic:**\n- `reducer` handles the switch statement for actions.\n- In the `DISMISS_TOAST` case, it calls `addToRemoveQueue` to schedule the removal timeout.\n- `addToRemoveQueue` ensures only one timeout exists per toast ID to prevent duplicate removals.\n\n## Toast Lifecycle\n\nThe following diagram illustrates the internal execution flow of a toast notification from creation to removal.\n\n```mermaid\ngraph TD\n A[toast() API Call] --> B[genId]\n B --> C[dispatch ADD_TOAST]\n C --> D[reducer]\n D --> E[State Update]\n \n F[dismiss() API Call] --> G[dispatch DISMISS_TOAST]\n G --> H[addToRemoveQueue]\n H --> I[setTimeout]\n I --> J[dispatch REMOVE_TOAST]\n \n E -.-> K[Listeners Update]\n J -.-> K\n```\n\n## Integration\n\n### Dependencies\n- **React:** `react` (for `useState`, `useEffect`).\n- **UI Components:** `@/components/ui/toast` (for `ToastProps`, `ToastActionElement`).\n\n### Client-Side Requirement\nThe `use-toast.ts` file is marked with `'use client'`. This hook and its associated state cannot be used in server components. Ensure the toast provider (imported from `@/components/ui/toast`) is rendered in the root client component to render the actual toast UI.\n\n### Configuration\nTo modify the behavior of the mobile detection or toast system, update the constants at the top of their respective files:\n- `MOBILE_BREAKPOINT` in `use-mobile.ts`.\n- `TOAST_LIMIT` and `TOAST_REMOVE_DELAY` in `use-toast.ts`.","harakat-landing-lib":"# Harakat_Landing — lib\n\n\n\n# Harakat_Landing — lib\n\n## Overview\n\nThe `lib` module within `Harakat_Landing` provides a centralized utility for managing CSS class names. It abstracts the complexity of merging multiple class sources (strings, arrays, objects) into a single, conflict-free string. This is essential for maintaining clean, conditional styling in the application's React components.\n\n## API Reference\n\n### `cn`\n\nA variadic utility function for merging class names.\n\n**Signature**\n```typescript\nexport function cn(...inputs: ClassValue[]): string\n```\n\n**Parameters**\n| Name | Type | Description |\n| :--- | :--- | :--- |\n| `...inputs` | `ClassValue[]` | Variable arguments representing class values. Can be strings, arrays of strings, or objects with class keys. |\n\n**Returns**\n| Type | Description |\n| :--- | :--- |\n| `string` | A single string containing the merged, deduplicated CSS class names. |\n\n**Behavior**\nThe function accepts any number of arguments. It first processes the inputs through `clsx` to handle conditional logic (e.g., `className={cn('base', isActive && 'active')}`), then passes the result to `tailwind-merge` to resolve conflicts between Tailwind utility classes.\n\n## Implementation Details\n\nThe module consists of a single exported function, `cn`. It does not contain internal logic branches or state management. Its execution flow is a direct composition of two external library calls.\n\n**Execution Flow**\n1. **Input Collection:** The function collects all arguments passed via the spread operator.\n2. **Conditional Merging:** `clsx` processes the inputs to handle boolean logic and array flattening.\n3. **Conflict Resolution:** `tailwind-merge` processes the result to ensure Tailwind utility classes do not override each other (e.g., `p-4` vs `p-8`).\n4. **Output:** Returns the final merged string.\n\n```mermaid\nflowchart LR\n A[Inputs] --> B_clsx[\"B(clsx)\"]\n B --> C[twMerge]\n C --> D[Final String]\n```\n\n## Dependencies\n\nThis module relies on two external packages for its functionality:\n\n1. **`clsx`**: Used for merging class names with conditional logic support.\n2. **`tailwind-merge`**: Used to resolve conflicts between Tailwind CSS utility classes.\n\n## Integration\n\nThe `cn` function is designed to be imported and used throughout the `Harakat_Landing` application. It replaces standard `className` prop usage to ensure consistent styling behavior across components.\n\n**Example Usage**\n```typescript\nimport { cn } from '@/lib/utils'\n\nfunction Button({ variant = 'primary', children }) {\n return (\n <button className={cn(\n 'px-4 py-2 rounded',\n variant === 'primary' && 'bg-blue-500 text-white',\n variant === 'secondary' && 'bg-gray-500 text-gray-100'\n )}>\n {children}\n <\/button>\n )\n}\n```\n\n## Module Statistics\n\n* **Internal Calls:** None\n* **Outgoing Calls:** None (Directly calls external libraries only)\n* **Incoming Calls:** None (Static analysis indicates no internal module dependencies)\n* **Execution Flows:** Linear (Input → `clsx` → `tailwind-merge` → Output)","harakat-landing-public":"# Harakat_Landing — public\n\n\n\n# Harakat_Landing — public\n\n## Overview\nThe `Harakat_Landing — public` module serves as the static asset and configuration layer for the Harakat Solutions landing page. It contains no executable logic, server-side functions, or database interactions. Its primary responsibility is to provide structured metadata, Progressive Web App (PWA) configuration, and static content required for the frontend to render the public-facing interface.\n\nThis module is designed for high performance and SEO optimization, ensuring the browser can immediately access necessary configuration and schema data without server-side processing delays.\n\n## File Inventory\n\n### `about.txt`\n**Purpose:** Static content source for company information and product descriptions.\n**Format:** Plain text / Markdown.\n**Usage:**\n- Serves as the source of truth for company overview, leadership, and product details.\n- Typically processed by the build pipeline or CMS to generate HTML content blocks.\n- Contains key differentiators, search query optimization, and integration capabilities.\n\n**Key Content Sections:**\n- **Company Overview:** Harakat Solutions, AI Business Intelligence Platform.\n- **Core Products:**\n - `Harakat@Offices`: Operations Management, Workflow Automation.\n - `Harakat@Marketing`: Marketing Automation, Campaign Management.\n - `Harakat@Finance`: Financial Management, Forecasting.\n- **Leadership:** Ahmad Yasin (Business Development), Ahmad Tarek (Technical).\n- **Contact:** `talktous@harakat.tech`, `+962 7 7932 2179`.\n\n### `ai-context.json`\n**Purpose:** JSON-LD structured data for SEO and AI engine indexing.\n**Format:** JSON.\n**Usage:**\n- Embedded in the `<head>` of the main HTML document.\n- Defines the `Organization`, `WebSite`, `SoftwareApplication`, and `Product` entities.\n- Enables rich snippets in search results (e.g., star ratings, pricing, descriptions).\n\n**Schema Entities:**\n- **Organization:** `https://harakat.tech/#organization`\n - `name`: \"Harakat Solutions\"\n - `foundingDate`: \"2024\"\n - `foundingLocation`: Amman, Jordan\n - `serviceArea`: GeoCircle (Amman, 20,000,000m radius)\n- **WebSite:** `https://harakat.tech/#website`\n - `potentialAction`: SearchAction targeting `https://harakat.tech/?s={search_term_string}`\n- **SoftwareApplication:** `https://harakat.tech/#software`\n - `applicationCategory`: \"BusinessApplication\"\n - `offers`: AggregateOffer (Currency: USD)\n- **Products:**\n - `Harakat@Marketing`: `https://harakat.tech/solutions/marketing#product` (Rating: 4.8)\n - `Harakat@Finance`: `https://harakat.tech/solutions/finance#product` (Rating: 4.9)\n\n### `manifest.json`\n**Purpose:** PWA (Progressive Web App) configuration.\n**Format:** JSON.\n**Usage:**\n- Allows the site to be installed on mobile devices as a standalone app.\n- Defines visual identity and behavior when installed.\n\n**Configuration Details:**\n- `name`: \"Harakat - The Intelligent Workspace for Offices & Enterprises\"\n- `short_name`: \"Harakat\"\n- `start_url`: \"/\"\n- `display`: \"standalone\"\n- `theme_color`: \"#5dad89\"\n- `background_color`: \"#0a0f0a\"\n\n## Execution Flow & Architecture\n\n### Execution Model\nThis module contains **no execution flows**.\n- **Internal Calls:** None.\n- **Outgoing Calls:** None.\n- **Incoming Calls:** None.\n- **Server-Side Logic:** None.\n\nThe module functions as a static resource set. The web server (e.g., Nginx, Apache, or a static host like Vercel/Netlify) serves these files directly to the client. The frontend application consumes these files to populate the DOM and metadata.\n\n### Data Consumption\n1. **Browser Load:** The browser requests `index.html`.\n2. **Metadata Injection:** The build process or runtime script injects `ai-context.json` into the HTML `<head>`.\n3. **PWA Registration:** The browser reads `manifest.json` to register the app for installation.\n4. **Content Rendering:** The frontend fetches or renders content derived from `about.txt`.\n\n## Integration Points\n\n### Frontend Integration\nDevelopers integrating this module should ensure:\n1. **Schema Injection:** The `ai-context.json` content is serialized and placed within the `<script type=\"application/ld+json\">` tag in the main layout.\n2. **Manifest Linking:** A link to `manifest.json` must be present in the `<head>`:\n ```html\n <link rel=\"manifest\" href=\"/manifest.json\">\n ```\n3. **Content Processing:** The `about.txt` file should be processed by the build system to generate the necessary HTML sections for the landing page.\n\n### External Dependencies\n- **Schema.org:** Relies on standard JSON-LD vocabulary.\n- **PWA Standards:** Relies on the Web App Manifest specification.\n- **Static Hosting:** Requires a static file server capable of serving JSON and TXT files with correct MIME types (`application/ld+json`, `text/plain`, `application/json`).\n\n## Architecture Diagram\n\nThe following diagram illustrates the static asset structure and how the browser consumes these files.\n\n```mermaid\ngraph TD\n Browser[Browser / Client]\n Server[Static Web Server]\n \n subgraph Public_Module [Harakat_Landing — public]\n About[about.txt<br/>Static Content]\n Context[ai-context.json<br/>SEO Schema]\n Manifest[manifest.json<br/>PWA Config]\n end\n \n subgraph Frontend [Main Application]\n HTML[HTML Layout]\n DOM[DOM Renderer]\n end\n \n Server -->|Serves| Browser\n Browser -->|Fetches| About\n Browser -->|Fetches| Context\n Browser -->|Fetches| Manifest\n Context -->|Injected into| HTML\n Manifest -->|Linked to| HTML\n About -->|Processed into| HTML\n HTML -->|Populates| DOM\n```\n\n## Maintenance & Updates\n\n### Updating Content\n- **`about.txt`:** Edit the text file directly. Ensure formatting remains consistent for any build scripts that parse this file.\n- **`ai-context.json`:** Update JSON values directly. Validate against the JSON-LD Playground to ensure schema validity before deployment.\n- **`manifest.json`:** Update icon paths or colors if the design system changes. Ensure `icons` array references valid image paths.\n\n### Version Control\n- Treat these files as critical assets.\n- Changes to `ai-context.json` may affect SEO indexing; test changes in a staging environment.\n- Changes to `manifest.json` may affect PWA installation behavior on user devices.\n\n## Troubleshooting\n\n| Issue | Potential Cause | Resolution |\n| :--- | :--- | :--- |\n| **PWA not installing** | `manifest.json` not linked or invalid | Verify `<link rel=\"manifest\">` is in `<head>` and JSON is valid. |\n| **Rich Snippets missing** | `ai-context.json` not embedded | Ensure JSON-LD script is present in the HTML head. |\n| **Content not rendering** | `about.txt` not processed | Check build pipeline for static content processing steps. |\n| **404 on assets** | Incorrect MIME types | Ensure server returns `application/json` for `.json` files. |","harakat-landing-styles":"# Harakat_Landing — styles\n\n\n\n# Harakat_Landing — styles\n\n## Overview\n\nThe `globals.css` module serves as the central configuration point for the application's visual design system. It defines the global color palette, typography, and theming logic using CSS custom properties and Tailwind CSS directives. This file ensures consistent styling across the `Harakat_Landing` application, supporting both light and dark modes.\n\n## Purpose\n\nThis module establishes the foundational design tokens required by the rest of the application. It does not contain executable logic but rather configures the styling engine (Tailwind CSS) to render the UI components correctly.\n\nKey responsibilities include:\n- Defining the color system using the OKLCH color space.\n- Configuring Tailwind's design system via `@theme inline`.\n- Enabling dark mode support through CSS custom variants.\n- Applying global resets and base styles to the document body.\n\n## Theming System\n\nThe module utilizes CSS custom properties (variables) to manage colors. These variables are defined in two contexts: `:root` for the light theme and `.dark` for the dark theme.\n\n### Color Palette\nThe color system is built using `oklch` values, which provide better perceptual uniformity compared to traditional RGB or HSL. Key tokens include:\n- `--background`: Primary background color.\n- `--foreground`: Primary text color.\n- `--primary`: Main action color (buttons, links).\n- `--card`: Container background color.\n- `--sidebar`: Specific tokens for sidebar components.\n\n### Dark Mode Support\nDark mode is implemented using a custom variant selector:\n```css\n@custom-variant dark (&:is(.dark *));\n```\nWhen the `.dark` class is applied to the `<html>` or `<body>` element, the CSS variables defined within the `.dark` block override the `:root` values.\n\n## Tailwind Configuration\n\nThe `@theme inline` directive maps the CSS variables to Tailwind's utility class system. This allows developers to use utility classes like `bg-background`, `text-foreground`, or `border-border` directly in HTML components.\n\n### Mapped Tokens\nThe following Tailwind design tokens are configured:\n- **Colors:** `background`, `foreground`, `card`, `popover`, `primary`, `secondary`, `muted`, `accent`, `destructive`, `border`, `input`, `ring`, `chart-1` through `chart-5`, and `sidebar` variants.\n- **Radius:** `radius-sm`, `radius-md`, `radius-lg`, `radius-xl` derived from the `--radius` variable.\n- **Fonts:** `font-sans` and `font-mono` mapped to `--font-geist-sans` and `--font-geist-mono`.\n\n## Global Styles\n\nThe `@layer base` block applies styles to the entire document before component-specific styles are loaded.\n\n- **Borders:** All elements (`*`) receive the `border-border` color and an outline ring with 50% opacity.\n- **Body:** The `<body>` element is set to use the `background` color and `foreground` text color.\n\n## Usage Guidelines\n\nDevelopers should use the Tailwind utility classes defined in this module rather than hardcoding colors.\n\n### Example Usage\n```html\n<!-- Light Mode -->\n<div class=\"bg-background text-foreground p-4\">\n Content\n<\/div>\n\n<!-- Dark Mode -->\n<div class=\"dark bg-background text-foreground p-4\">\n Content\n<\/div>\n```\n\n### Theme Customization\nTo modify the color palette, update the `:root` or `.dark` CSS variables in `globals.css`. Changes will automatically propagate to all Tailwind utility classes referencing those tokens.\n\n## Architecture Flow\n\nThe following diagram illustrates how the configuration flows from the CSS file to the rendered DOM.\n\n```mermaid\nflowchart LR\n Root[\":root CSS Variables\"] --> Theme[\"@theme inline\"]\n Theme --> Tailwind[Tailwind Utility Classes]\n Tailwind --> DOM[DOM Elements]\n DarkMode[\".dark Class\"] -.->|Overrides| Root\n```\n\n## Dependencies\n\n- **Tailwind CSS:** Loaded via `@import 'tailwindcss';`.\n- **Tw Animate CSS:** Loaded via `@import 'tw-animate-css';` for animation utilities.\n- **Geist Fonts:** Referenced in `@theme inline` for `--font-geist-sans` and `--font-geist-mono`.","harakat-landing":"# Harakat_Landing\n\n\n\n# Harakat_Landing\n\nThe `Harakat_Landing` module is a Next.js 14 standalone application serving as the primary landing page for the Harakat project. It utilizes a multi-stage Docker build process to optimize production performance and includes server-side capabilities for contact form handling via Zoho SMTP.\n\n## Architecture\n\nThe application follows a layered architecture designed for performance, SEO, and maintainability.\n\n* **Static & Configuration:** The `public` module provides structured metadata, PWA configuration, and static content required for the frontend to render the public-facing interface without server-side processing delays.\n* **Design System:** The `styles` module establishes foundational design tokens (color palette, typography) using CSS custom properties and Tailwind CSS directives.\n* **Utilities:** The `lib` module offers centralized utilities, such as the `cn` function, to merge class names conflict-free across components.\n* **State Management:** The `hooks` module handles lightweight client-side state, including responsive design detection (`use-mobile`) and toast notifications (`use-toast`).\n* **UI & Routing:** The `components` and `app` modules implement the user interface, utilizing the design system and utilities defined in the lower layers.\n* **Server Logic:** API routes handle server-side tasks, such as email processing via Zoho SMTP.\n\n## Key Workflows\n\n### Styling & Theming\nThe `styles` module defines global CSS variables and Tailwind directives. Components in the `components` module rely on the `cn` utility from `lib` to apply these styles dynamically, ensuring consistent rendering across light and dark modes.\n\n### User Interaction & State\nUI components (e.g., `HomePage`, `Hero`, `Carousel`) interact with the `hooks` module to manage state. For instance, the `use-toast` hook manages notification queues via a custom reducer, while `use-mobile` adjusts layout behavior based on viewport width.\n\n### Form Handling\nContact form submissions flow from the `app` pages through API routes. The `api/send-email/route.ts` endpoint handles the request, utilizing utilities like `isRateLimited` and `escapeHtml` to secure the data before processing via Zoho SMTP.\n\n## Module Relationships\n\n```mermaid\nflowchart TD\n subgraph StaticLayer [\"Static & Config\"]\n Public[public]\n Styles[styles]\n Lib[lib]\n end\n\n subgraph LogicLayer [\"Logic & State\"]\n Hooks[hooks]\n API[api]\n end\n\n subgraph PresentationLayer [\"UI & Routing\"]\n App[app]\n Components[components]\n end\n\n Public -->|Metadata/SEO| App\n Styles -->|Design Tokens| Components\n Lib -->|Class Utilities| Components\n Hooks -->|State Management| Components\n Components -->|Server Actions| API\n API -->|Zoho SMTP| External[External Services]\n```","harakat-office-app":"# Harakat_Office — app\n\n\n\n# Harakat_Office App Module Documentation\n\n## Overview\n\nThe Harakat_Office app module provides a project management cockpit for coordinating work across teams. It implements a multi-tenant project workspace with board views, milestones, deliverables, asks, member management, and audit trails. The application is built with Next.js 15 App Router, Next-Intl for internationalization, and uses a 2FA authentication system.\n\n## Architecture\n\n```mermaid\ngraph TD\n A[LocaleLayout] --> B[AppLayout]\n B --> C[ProjectsPage]\n B --> D[ProjectDetailPage]\n B --> E[LoginPage]\n C --> F[vendorsApi.listProjects]\n D --> G[useProjectData]\n E --> H[useAuth]\n H --> I[login/completeTwoFactor]\n```\n\n### Layout Hierarchy\n\n```\nLocaleLayout ([locale]/layout.tsx)\n├── Providers (components/providers.tsx)\n│ ├── NextIntlClientProvider\n│ └── App Router Providers\n└── AppLayout ([locale]/(app)/layout.tsx)\n ├── TopBar (components/shell/top-bar.tsx)\n ├── main (content area)\n └── AppFooter (components/shell/app-footer.tsx)\n```\n\n## Authentication Flow\n\nThe authentication system implements two-factor authentication (2FA) with email-based OTP codes.\n\n### State Machine\n\n```mermaid\nstateDiagram-v2\n [*] --> Loading\n Loading --> Authenticated[\"Authenticated:\"] isAuthenticated\n Loading --> Redirect[\"Redirect:\"] !isAuthenticated\n Authenticated --> Loading[\"Loading:\"] router.replace\n Loading --> LoginPage[\"LoginPage:\"] /login route\n LoginPage --> Credentials[\"Credentials:\"] email + password\n Credentials --> Challenge[\"Challenge:\"] needs-2fa\n Challenge --> LoginPage[\"LoginPage:\"] backToCredentials\n Challenge --> Verified[\"Verified:\"] code verified\n Verified --> Authenticated[\"Authenticated:\"] router.replace\n```\n\n### Key Functions\n\n**`useAuth`** (`@/lib/auth-context`)\n- `login(email, password)` → Returns `needs-2fa` challenge or direct authentication\n- `completeTwoFactor(challengeToken, code)` → Validates OTP and completes login\n- `isAuthenticated` → Boolean flag for auth state\n- `isLoading` → Loading state for auth check\n\n**`LoginPage`** (`[locale]/login/page.tsx`)\n- Manages credential submission and 2FA challenge\n- Stores credentials in `credentialsRef` (never drives renders)\n- Handles resend cooldown with 30-second timer\n- Uses `react-hook-form` for form validation\n\n**`TwoFactorStep`** (component within LoginPage)\n- Renders OTP input with Latin digits (LTR pinned)\n- Manages resend cooldown countdown\n- Handles 2FA verification errors (401 covers wrong/expired code)\n\n### Authentication Guard\n\n**`AppLayout`** (`[locale]/(app)/layout.tsx`)\n```typescript\nReact.useEffect(() => {\n if (!isLoading && !isAuthenticated) {\n router.replace(\"/login\");\n }\n}, [isLoading, isAuthenticated, router]);\n```\n\nRedirects unauthenticated users to `/login` after auth state stabilizes.\n\n## Project Management\n\n### Projects List Page\n\n**`ProjectsPage`** (`[locale]/(app)/projects/page.tsx`)\n\n**State Types:**\n```typescript\ntype LoadState =\n | { kind: \"loading\" }\n | { kind: \"not-enabled\" }\n | { kind: \"error\" }\n | { kind: \"ready\"; projects: ProjectListItem[] };\n```\n\n**Execution Flow:**\n1. `load()` callback fetches projects via `vendorsApi.listProjects()`\n2. Sets loading state, then resolves to ready/error/not-enabled\n3. Renders appropriate UI based on state kind\n\n**Key Components:**\n- `PageHeader` - Title, subtitle, and create action\n- `CreateProjectDialog` - Modal for new project creation\n- `ProjectStatusBadge` - Visual status indicator\n- `EmptyState` - When no projects exist\n- `ErrorState` - For API failures with retry\n\n**Project Card Data:**\n- `name` - Project title\n- `description` - Optional description\n- `status` - ARCHIVED, ACTIVE, etc.\n- `memberCount` - Number of team members\n- `openAsks` - Count of pending requests\n- `createdAt` - ISO timestamp\n\n### Project Detail Page\n\n**`ProjectDetailPage`** (`[locale]/(app)/projects/[id]/page.tsx`)\n\n**ID Conversion Boundary:**\n```typescript\nconst id = Number(params.id); // String route param → Int entity id\n```\n\n**Data Loading:**\n- Uses `useProjectData(id)` hook from `@/lib/use-project-data`\n- Returns `board`, `detail`, `milestones`, `deliverables`, `asks`, `audit`\n- Handles loading, error, and not-enabled states\n\n**Tab Navigation:**\n```typescript\nTabs defaultValue=\"board\"\n├── board → BoardTab\n├── milestones → MilestonesTab\n├── deliverables → DeliverablesTab\n├── asks → AsksTab\n├── members → MembersTab\n└── audit → AuditTab\n```\n\n**Error States:**\n- `not-enabled` → `NotEnabledState`\n- `error` or missing data → `ErrorState` with retry\n- Invalid ID → `ErrorState` with back link\n\n**ProjectActions** (`components/project/project-actions.tsx`)\n- Action buttons for project management\n- `onDone` callback triggers data refresh\n\n## Key Components\n\n### Common UI Components\n\n| Component | Path | Purpose |\n|-----------|------|---------|\n| `Card` | `components/ui/card.tsx` | Container with border and padding |\n| `Skeleton` | `components/ui/skeleton.tsx` | Loading state placeholders |\n| `Button` | `components/ui/button.tsx` | Primary/secondary action buttons |\n| `Input` | `components/ui/input.tsx` | Form inputs with validation |\n| `Label` | `components/ui/label.tsx` | Form field labels |\n| `Tabs` | `components/ui/tabs.tsx` | Tab navigation system |\n| `ErrorState` | `components/common/states.tsx` | Error display with retry |\n| `NotEnabledState` | `components/common/states.tsx` | Feature disabled indicator |\n| `EmptyState` | `components/common/empty-state.tsx` | Empty list placeholder |\n\n### Project-Specific Components\n\n| Component | Path | Props |\n|-----------|------|-------|\n| `BoardTab` | `components/board/board-tab.tsx` | `board`, `projectId`, `members`, `onRefresh` |\n| `MilestonesTab` | `components/project/milestones-tab.tsx` | `projectId`, `milestones`, `members`, `onRefresh` |\n| `DeliverablesTab` | `components/project/deliverables-tab.tsx` | `projectId`, `deliverables`, `members`, `onRefresh` |\n| `AsksTab` | `components/project/asks-tab.tsx` | `projectId`, `asks`, `members`, `loadError`, `onRefresh` |\n| `MembersTab` | `components/project/members-tab.tsx` | `projectId`, `members`, `onRefresh` |\n| `AuditTab` | `components/project/audit-tab.tsx` | `audit`, `loadError`, `onRefresh` |\n\n### Shell Components\n\n| Component | Path | Purpose |\n|-----------|------|---------|\n| `TopBar` | `components/shell/top-bar.tsx` | Navigation header |\n| `AppFooter` | `components/shell/app-footer.tsx` | Page footer |\n| `LocaleSwitcher` | `components/shell/locale-switcher.tsx` | Language selection |\n| `ThemeToggle` | `components/shell/theme-toggle.tsx` | Light/dark mode switch |\n\n## State Management\n\n### Client-Side State\n\n**`ProjectsPage`** - Manages project list state:\n```typescript\nconst [state, setState] = React.useState<LoadState>({ kind: \"loading\" });\n```\n\n**`LoginPage`** - Manages auth flow state:\n```typescript\nconst [formError, setFormError] = React.useState<string | null>(null);\nconst [challenge, setChallenge] = React.useState<Challenge | null>(null);\nconst credentialsRef = React.useRef<LoginForm | null>(null);\n```\n\n**`ProjectDetailPage`** - Uses `useProjectData` hook for server state:\n```typescript\nconst data = useProjectData(id);\n// data.status: \"loading\" | \"error\" | \"not-enabled\" | \"ready\"\n```\n\n### Server-Side State\n\n**`LocaleLayout`** - Manages locale and direction:\n```typescript\nconst { locale } = await params;\nconst dir = localeDirection[locale as Locale];\n```\n\n## Internationalization\n\n### Next-Intl Integration\n\n**`LocaleLayout`** (`[locale]/layout.tsx`)\n- Validates locale against `routing.locales`\n- Sets `setRequestLocale(locale)` for client hydration\n- Passes `locale` and `dir` to HTML element\n- Uses `NextIntlClientProvider` for client-side translations\n\n**Translation Keys:**\n- `guard` - Auth guard messages\n- `login` - Login form and 2FA\n- `projects` - Project list and actions\n- `project` - Project detail labels\n- `app` - App metadata\n- `common` - Shared UI labels\n\n### RTL Support\n\n```typescript\n// ProjectDetailPage - BackLink\nclassName=\"rtl:rotate-180\"\n\n// LoginPage - OTP input\ndir=\"ltr\" // Always Latin digits\n```\n\n## Styling & Theme\n\n### CSS Variables\n\n**Light Theme (Default):**\n```css\n--brand-paper: #f6f5f0\n--brand-ink: #0a2118\n--brand-green: #2f8a63\n--brand-forest: #0f5537\n```\n\n**Dark Theme:**\n```css\n--background: #0b1712\n--foreground: #eef1ec\n--primary: #3ba173\n```\n\n### Signal Colors\n\nEach color has a single semantic meaning:\n- `--success` - Completion, positive states\n- `--warning` - Caution, pending items\n- `--danger` - Errors, destructive actions\n- `--info` - Informational messages\n\n### Utility Classes\n\n```css\n.panel {\n background: var(--card);\n border: 1px solid var(--border);\n border-radius: var(--radius);\n}\n\n.tnum {\n font-variant-numeric: tabular-nums;\n}\n```\n\n## API Integration\n\n### Vendors API\n\n**`vendorsApi`** (`@/lib/api/vendors.ts`)\n- `listProjects()` → Returns `ProjectListItem[]`\n- Used by `ProjectsPage` for project enumeration\n\n### Client API\n\n**`@/lib/api/client.ts`**\n- `isNotEnabled(err)` → Detects feature disabled errors\n- `ApiError` → Error type with `status` property\n\n### Project Data Hook\n\n**`useProjectData`** (`@/lib/use-project-data.ts`)\n- Fetches project details, board, milestones, deliverables, asks, audit\n- Returns unified data structure with status tracking\n- Handles refresh via `data.refresh` callback\n\n## Error Handling\n\n### Error States\n\n| State | Trigger | Component |\n|-------|---------|-----------|\n| `loading` | Initial fetch | `Skeleton` |\n| `error` | API failure | `ErrorState` |\n| `not-enabled` | Feature disabled | `NotEnabledState` |\n| `empty` | No data | `EmptyState` |\n\n### Error Recovery\n\n- `ErrorState` provides `onRetry` callback\n- `2FA` failures trigger resend button\n- `401` errors show generic message (wrong/expired code indistinguishable)\n\n### Form Validation\n\n**`react-hook-form`** integration:\n```typescript\n{\n required: tCommon(\"requiredField\"),\n pattern: {\n value: /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/,\n message: tCommon(\"requiredField\"),\n }\n}\n```\n\n## Cross-Community Dependencies\n\n### `cn` Utility\n\nMultiple components use `cn` from `StartupsPlatform/lib/utils.ts`:\n- `ProjectsPage` → `CreateProjectDialog` → `cn`\n- `ProjectDetailPage` → `ErrorState` → `cn`\n- `LoginPage` → `LocaleSwitcher` → `cn`\n\n### Dialog Portal\n\n**`ProjectsPage`** → `CreateProjectDialog` → `DialogPortal`\n- Modal dialogs use portal mounting\n- `DialogContent` and `DialogOverlay` from `components/ui/dialog.tsx`\n\n## Contributing Guidelines\n\n### Adding New Tabs\n\n1. Create tab component in `components/project/[tab-name]-tab.tsx`\n2. Accept props: `projectId`, `data`, `members`, `onRefresh`\n3. Add tab trigger in `ProjectDetailPage`\n4. Add translation keys in `project` namespace\n\n### Adding New States\n\n1. Extend `LoadState` type in `ProjectsPage`\n2. Add conditional rendering for new state kind\n3. Create corresponding state component in `components/common/states.tsx`\n\n### Adding New API Endpoints\n\n1. Add to `vendorsApi` in `@/lib/api/vendors.ts`\n2. Handle errors with `isNotEnabled()` check\n3. Update `LoadState` types if needed\n\n### Theme Customization\n\n1. Modify CSS variables in `globals.css`\n2. Ensure signal colors maintain semantic meaning\n3. Test both light and dark modes\n\n## Performance Considerations\n\n- `useProjectData` hook manages server state efficiently\n- Skeleton loading prevents layout shift\n- `cn` utility minimizes class string concatenation\n- `credentialsRef` avoids unnecessary re-renders in login flow\n- `cooldown` timer uses `useEffect` cleanup for interval\n\n## Security Notes\n\n- Credentials stored in `credentialsRef` never drive renders\n- OTP codes are 6 numeric digits (Latin)\n- 2FA challenge tokens are single-use\n- 30-second resend cooldown prevents abuse\n- `401` errors don't distinguish between wrong code and expired challenge","harakat-office-harakat-office":"# Harakat_Office — Harakat_Office\n\n\n\n# Harakat_Office Configuration Module\n\n## Overview\nThe `Harakat_Office` module serves as the foundational configuration layer for the Next.js application. It does not contain business logic or API endpoints; instead, it defines the runtime environment, internationalization (i18n) strategy, security policies, and build tooling required for the application to function.\n\nThis module consists primarily of configuration files (`next.config.mjs`, `middleware.ts`, `tsconfig.json`) and dependency definitions (`package.json`).\n\n## Architecture\n\n### Internationalization (i18n)\nThe application uses `next-intl` to manage localization. The setup is split between the middleware and the Next.js configuration.\n\n1. **Middleware (`middleware.ts`)**:\n * Imports `createMiddleware` from `next-intl/middleware`.\n * Passes the routing configuration from `./i18n/routing` to the middleware.\n * **Matcher**: The `config` object defines the `matcher` array. It intercepts all pathnames except:\n * API routes (`/api`)\n * Next.js internals (`/_next`, `/_vercel`)\n * Static files (files containing a dot, e.g., `favicon.ico`)\n\n2. **Next.js Configuration (`next.config.mjs`)**:\n * Imports `createNextIntlPlugin` from `next-intl/plugin`.\n * Initializes the plugin with the request handler from `./i18n/request.ts`.\n * Wraps the default `nextConfig` with `withNextIntl`.\n\n### Security Headers\nThe `next.config.mjs` file applies security headers globally to all requests via the `headers` async function.\n\n```javascript\nheaders: async () => [\n {\n source: \"/(.*)\",\n headers: [\n { key: \"X-Content-Type-Options\", value: \"nosniff\" },\n { key: \"X-Frame-Options\", value: \"DENY\" },\n { key: \"X-XSS-Protection\", value: \"1; mode=block\" },\n { key: \"Referrer-Policy\", value: \"strict-origin-when-cross-origin\" },\n { key: \"Permissions-Policy\", value: \"geolocation=(), microphone=(), camera=()\" },\n ],\n },\n]\n```\n\n### Build & Tooling\n* **TypeScript (`tsconfig.json`)**:\n * Configures `paths` to map `@/*` to `./*`.\n * Enables `strict` mode and `isolatedModules`.\n * Includes the Next.js plugin for type checking.\n* **Styling (`postcss.config.mjs`)**:\n * Configures Tailwind CSS v4 via `@tailwindcss/postcss`.\n* **Dependencies (`package.json`)**:\n * Defines scripts for development (`dev`), building (`build`), and linting (`lint`).\n * Includes a custom script `check:i18n` to validate internationalization files.\n\n## Request Lifecycle\n\nWhen a request is made to the application, the following flow occurs regarding the configuration module:\n\n1. **Routing**: The `next-intl` middleware intercepts the request based on the `matcher` defined in `middleware.ts`.\n2. **Localization**: The middleware determines the locale and redirects or rewrites the URL if necessary.\n3. **Rendering**: The request proceeds to the Next.js router, which applies the security headers defined in `next.config.mjs`.\n\n```mermaid\nsequenceDiagram\n participant Client\n participant Middleware\n participant NextJS\n participant App\n\n Client->>Middleware: Request\n Middleware->>Middleware: Check Matcher\n alt Excluded Path\n Middleware-->>Client: Pass Through\n else Included Path\n Middleware->>Middleware: Apply Locale\n Middleware-->>NextJS: Rewritten URL\n end\n NextJS->>App: Render Page\n NextJS-->>Client: Response + Security Headers\n```\n\n## Key Components\n\n### `middleware.ts`\n* **Function**: `createMiddleware(routing)`\n* **Purpose**: Handles URL rewriting and locale detection.\n* **Config**: `matcher` excludes API and static assets to prevent i18n interference.\n\n### `next.config.mjs`\n* **Function**: `withNextIntl(nextConfig)`\n* **Purpose**: Integrates `next-intl` into the Next.js build process.\n* **Settings**:\n * `outputFileTracingRoot`: Set to `__dirname` to isolate the tracing root for monorepo compatibility.\n * `images.unoptimized`: Set to `true` to disable Next.js image optimization.\n * `eslint.ignoreDuringBuilds`: Set to `true` to allow builds to proceed despite linting errors.\n\n### `package.json`\n* **Scripts**:\n * `dev`: Runs `next dev` on port 3005.\n * `build`: Runs `next build`.\n * `start`: Runs `next start` on port 3005.\n * `check:i18n`: Executes `node scripts/check-i18n.mjs`.\n\n## Execution Flow\nThe module itself contains no runtime execution logic. Its \"execution\" is static configuration applied at build time or request interception time.\n\n* **Build Time**: `next.config.mjs` and `tsconfig.json` are read by the Next.js compiler and TypeScript compiler respectively.\n* **Runtime**: `middleware.ts` is executed by the Next.js server for every incoming HTTP request matching the `matcher`.\n\n## Contributing Guidelines\n1. **i18n**: Any changes to routing or locale handling must be reflected in `middleware.ts` and `./i18n/routing`.\n2. **Security**: Do not remove security headers defined in `next.config.mjs` without a security review.\n3. **Paths**: Use the `@/*` alias defined in `tsconfig.json` for imports.\n4. **Linting**: ESLint is ignored during builds (`ignoreDuringBuilds: true`), but `npm run lint` should be run before committing.","harakat-office-i18n":"# Harakat_Office — i18n\n\n\n\n# Harakat_Office — i18n\n\nThis module configures internationalization (i18n) for the Harakat_Office application using the `next-intl` library. It centralizes locale definitions, handles server-side request configuration for locale detection, and provides locale-aware navigation utilities for the client.\n\n## Overview\n\nThe module consists of three core files:\n1. **`routing.ts`**: Defines supported locales, default behavior, and text direction.\n2. **`request.ts`**: Configures server-side locale resolution and message loading.\n3. **`navigation.ts`**: Wraps Next.js navigation APIs to ensure locale prefixes are preserved.\n\nTogether, these files ensure that all user interactions and server responses respect the selected language (English or Arabic) and maintain correct URL structures.\n\n## Routing Configuration\n\nThe routing configuration is defined in `routing.ts`. This file serves as the single source of truth for supported languages and URL structure.\n\n```typescript\nexport const routing = defineRouting({\n locales: [\"en\", \"ar\"],\n defaultLocale: \"en\",\n localePrefix: \"always\",\n});\n```\n\n### Key Settings\n* **`locales`**: An array of supported language codes. Currently supports `en` (English) and `ar` (Arabic).\n* **`defaultLocale`**: The fallback locale if no specific locale is detected in the request. Defaults to `en`.\n* **`localePrefix`**: Set to `\"always\"`. This enforces the `/{locale}` prefix on all URLs (e.g., `/en/about`, `/ar/about`).\n\n### Type Definitions\n* **`Locale`**: A type alias derived from `routing.locales`. This ensures type safety when referencing language codes throughout the application.\n* **`localeDirection`**: A record mapping locales to their text direction (`\"ltr\"` or `\"rtl\"`). This is essential for rendering Arabic content correctly.\n\n## Request Configuration\n\nServer-side locale detection is handled in `request.ts`. This file implements `getRequestConfig` from `next-intl/server`.\n\n### Execution Flow\nWhen a request is made to the server, the following logic determines the active locale:\n\n1. **Request Locale**: The `requestLocale` parameter is extracted from the incoming request headers.\n2. **Validation**: `hasLocale(routing.locales, requested)` checks if the requested locale is valid.\n3. **Fallback**: If the requested locale is invalid, `routing.defaultLocale` is used.\n4. **Message Loading**: The corresponding translation file (`../messages/${locale}.json`) is dynamically imported.\n\n```typescript\nexport default getRequestConfig(async ({ requestLocale }) => {\n const requested = await requestLocale;\n const locale = hasLocale(routing.locales, requested)\n ? requested\n : routing.defaultLocale;\n\n return {\n locale,\n messages: (await import(`../messages/${locale}.json`)).default,\n };\n});\n```\n\n### Architecture Diagram\nThe following diagram illustrates how a request is processed to determine the locale and load translations.\n\n```mermaid\nsequenceDiagram\n participant Client\n participant Server\n participant RequestConfig\n participant Routing\n participant Messages\n\n Client->>Server: HTTP Request\n Server->>RequestConfig: getRequestConfig(requestLocale)\n RequestConfig->>Routing: hasLocale(requested, locales)\n alt Valid Locale\n RequestConfig->>RequestConfig: Use requested locale\n else Invalid Locale\n RequestConfig->>Routing: Get defaultLocale\n RequestConfig->>RequestConfig: Use default locale\n end\n RequestConfig->>Messages: Import messages/${locale}.json\n RequestConfig-->>Server: { locale, messages }\n Server-->>Client: Rendered Response\n```\n\n## Navigation Utilities\n\nClient-side navigation is handled in `navigation.ts`. It uses `createNavigation` from `next-intl/navigation` to wrap standard Next.js navigation functions.\n\n### Why Use Wrappers?\nUsing raw `next/navigation` exports (e.g., `next/link`) can result in broken links or incorrect redirects when the locale prefix (`/{locale}`) is missing. The wrappers in this module ensure that all navigation actions respect the `localePrefix: \"always\"` setting defined in `routing.ts`.\n\n### Exported Functions\n* **`Link`**: A wrapper around `next/link`. Use this for all internal links to ensure the locale prefix is included.\n* **`redirect`**: A wrapper around `next/redirect`. Ensures redirects preserve the locale.\n* **`usePathname`**: Hook to retrieve the current pathname including the locale prefix.\n* **`useRouter`**: Hook to access the router instance with locale-aware methods.\n* **`getPathname`**: Utility function to get the current pathname.\n\n### Usage Example\n```typescript\nimport { Link, useRouter } from \"@/i18n/navigation\";\n\nexport default function Page() {\n const router = useRouter();\n\n // Correct: Preserves /en or /ar prefix\n return (\n <Link href=\"/about\">About<\/Link>\n );\n}\n```\n\n## Integration with the Codebase\n\n### Message Files\nThe `request.ts` module expects translation files located in `../messages/`. The filename must match the locale code (e.g., `en.json`, `ar.json`).\n\n### Component Usage\nWhen building components that require locale-specific behavior:\n1. Import `localeDirection` from `routing` to apply CSS classes for RTL support.\n2. Import `Link` from `navigation` instead of `next/link`.\n3. Use `useRouter` or `usePathname` to handle programmatic navigation.\n\n### Type Safety\nImport the `Locale` type from `routing` to ensure consistency across the application:\n\n```typescript\nimport type { Locale } from \"@/i18n/routing\";\n```","harakat-office-lib":"# Harakat_Office — lib\n\n\n\n# Harakat_Office — lib\n\nThis module encapsulates the client-side logic for the Harakat Office application. It provides a typed REST client, authentication management, project data fetching, and utility functions for formatting and localization. The module is designed to mirror the backend's `StartupsPlatform` pattern while maintaining its own token keys and login routes.\n\n## Architecture\n\nThe module follows a layered architecture:\n1. **Network Layer (`client.ts`)**: Handles HTTP requests, token injection, and error handling.\n2. **API Layer (`auth.ts`, `vendors.ts`)**: Typed wrappers for specific endpoints.\n3. **State Layer (`auth-context.tsx`)**: Manages global authentication state and session persistence.\n4. **Data Layer (`use-project-data.ts`)**: Custom hooks for fetching project-specific data.\n5. **Utilities (`format.ts`, `vendor-codes.ts`, `utils.ts`)**: Helpers for formatting, code mapping, and class merging.\n\n```mermaid\nsequenceDiagram\n participant UI\n participant Context as AuthContext\n participant Hook as useProjectData\n participant API as vendorsApi/authApi\n participant Client as apiClient\n participant Server\n\n UI->>Context: useAuth()\n Context->>Client: request()\n Client->>Server: HTTP Request (Bearer Token)\n Server-->>Client: Response\n Client-->>Context: Update Session/User\n Context-->>UI: User State\n UI->>Hook: useProjectData(id)\n Hook->>API: listAsks, getBoard, etc.\n API->>Client: apiClient.get/post\n Client->>Server: HTTP Request\n Server-->>Client: Response\n Client-->>Hook: Data\n Hook-->>UI: ProjectData\n```\n\n## API Client & Network Layer\n\nThe core of the module is `client.ts`, which defines the `apiClient` singleton and the `request` function.\n\n### Configuration\n* **API URL**: Determined by `process.env.NEXT_PUBLIC_API_URL` or defaults to `http://localhost:5000` in development.\n* **Token Storage**: Uses `sessionStorage` with keys `officeAccessToken` and `officeUser`.\n* **Locale**: Detects the active locale (`en` or `ar`) from the URL pathname to ensure redirects and formatting remain consistent.\n\n### Request Handling\nThe `request` function handles all HTTP interactions:\n1. **Authentication**: Automatically attaches the `Authorization: Bearer <token>` header if a token exists in `sessionStorage`.\n2. **Error Handling**:\n * **401 Unauthorized**: If the request is not to a login endpoint and the status is 401, the client clears the session and redirects the user to the login page (`/${currentLocale()}/login`).\n * **404 Not Found**: Checks for the specific error string `\"not enabled\"` to determine if the vendors platform is disabled.\n * **Other Errors**: Extracts error messages from the response body (`message`, `error`, or `msg`) and throws an `ApiError`.\n3. **Response Parsing**: Handles 204 No Content responses by returning an empty object.\n\n### API Methods\nThe `apiClient` object exposes standard HTTP methods:\n* `get<T>(path)`: Fetches data.\n* `post<T>(path, body)`: Sends POST requests with JSON stringified bodies.\n* `patch<T>(path, body)`: Sends PATCH requests.\n* `delete<T>(path)`: Sends DELETE requests.\n\n## Authentication\n\nAuthentication is split between the raw API calls (`auth.ts`) and the React Context (`auth-context.tsx`).\n\n### API Layer (`auth.ts`)\n* `login(email, password)`: Initiates the login process. Returns a `LoginResponse`.\n* `complete2FA(challengeToken, code)`: Completes the 2FA challenge using the token from the initial login response and the OTP code.\n\n### Context Layer (`auth-context.tsx`)\nThe `AuthProvider` wraps the application to provide the `useAuth` hook.\n* **State Management**: Tracks `user` and `isLoading` state.\n* **Session Persistence**:\n * On mount, it checks `sessionStorage` for existing tokens and user data.\n * The `storeSession` function is the single source of truth for writing a session (both initial login and 2FA completion).\n* **Login Flow**:\n 1. Calls `authApi.login`.\n 2. If `response.token` and `response.user` exist, it stores the session and returns `{ kind: \"signed-in\" }`.\n 3. If `response.requires2FA` is true, it returns `{ kind: \"needs-2fa\", challengeToken: ... }` without persisting a session.\n 4. Throws an error on failure.\n* **2FA Completion**: Calls `authApi.complete2FA`. If successful, it calls `storeSession` to finalize the login.\n\n## Vendor Data & Hooks\n\n### API Layer (`vendors.ts`)\nThis module exposes the `vendorsApi` object, wrapping endpoints under `/api/vendors`.\n* **Projects**: `listProjects`, `createProject`, `getProject`, `updateProject`.\n* **Members**: `inviteMember`, `removeMember`.\n* **Milestones**: `createMilestone`, `updateMilestone`.\n* **Deliverables**: `createDeliverable`, `updateDeliverable`.\n* **Notes**: `addNote` (Coordinator-authored only).\n* **Asks**: `listAsks`, `createAsk`.\n* **Board & Audit**: `getBoard`, `getAudit`.\n\n### Data Hook (`use-project-data.ts`)\nThe `useProjectData` hook is the primary entry point for project details in the UI.\n* **Parallel Fetching**: Uses `Promise.allSettled` to fetch `board`, `detail`, `asks`, and `audit` simultaneously.\n* **Error Tolerance**:\n * **Critical Errors**: If `board` or `detail` fails (and is not \"not enabled\"), the status becomes `error`.\n * **Non-Critical Errors**: If `asks` or `audit` fail, the status remains `ready`, but specific error flags (`asksError`, `auditError`) are set to `true`.\n * **Platform Disabled**: If any request returns a 404 with the `\"not enabled\"` error, the status becomes `not-enabled`.\n* **Refresh**: The `refresh` callback re-fetches all data, resetting the status to `loading` first.\n\n## Utilities & Localization\n\n### Formatting (`format.ts`)\nProvides locale-aware formatting functions.\n* **Numbering**: Uses Latin digits (`nu-latn`) for consistency across Arabic and English locales.\n* **Date/Time**:\n * `formatDate`: Formats ISO strings to `YYYY MMM DD`.\n * `formatDateTime`: Includes hours and minutes.\n * `formatRelative`: Returns relative time (e.g., \"2 days ago\") using `Intl.RelativeTimeFormat`.\n * `daysUntil`: Returns the number of days remaining until a date.\n * `isOverdue`: Checks if a date has passed.\n* **Display Name**: `displayName` handles null/undefined values by returning a neutral dash (`—`).\n\n### Vendor Codes (`vendor-codes.ts`)\nMaps server-generated frozen strings to i18n message keys.\n* **Suppression Reasons**: Maps `Ask.suppressionReason` values (e.g., `\"Withheld by the vendor's policy\"`) to keys like `\"withheldByPolicy\"`. Returns `null` for unknown values to allow raw rendering.\n* **Audit Actions**: Maps `AuditEvent.action` values (e.g., `\"project.created\"`) to keys like `\"projectCreated\"`.\n* **Lookup**: Uses `Map` objects for O(1) lookup performance.\n\n### Class Merging (`utils.ts`)\n* `cn(...inputs)`: A wrapper around `clsx` and `tailwind-merge` for combining class names.\n\n## Error Handling & Security\n\n### Session Security\n* **Token Expiry**: The `request` function in `client.ts` automatically clears `sessionStorage` and redirects to the login page upon receiving a 401 response (excluding login endpoints).\n* **2FA Flow**: The `auth-context` ensures that a session is never partially written. If the first login leg returns a challenge, no token is stored until `completeTwoFactor` succeeds.\n\n### Error Classification\n* `ApiError`: Custom error class extending `Error` with `status` and `data` properties.\n* `isNotEnabled`: Helper function to detect if the vendors platform is disabled (404 with specific error string).\n\n### Data Integrity\n* **Partial Updates**: The `updateProject` and `updateMilestone` functions rely on the server's behavior where only present keys are updated, preventing unintended side effects (e.g., renaming a project does not change its status).\n* **Free-Text Passthrough**: In `vendor-codes.ts`, unknown server strings are returned as `null` from lookup functions, allowing the UI to render the raw string in a quarantine state rather than mislabeling it.","harakat-office-messages":"# Harakat_Office — messages\n\n\n\n# Harakat_Office — messages\n\n## Overview\n\nThe `Harakat_Office — messages` module serves as the localization (i18n) layer for the Harakat Office application. It provides all user-facing text strings in two supported languages: English (`en.json`) and Arabic (`ar.json`).\n\nThis module is a static data resource. It contains no internal logic, functions, or execution flows. Its sole purpose is to store translatable keys and values that are consumed by the application's UI components to render text dynamically based on the user's locale.\n\n## File Structure\n\nThe module consists of two JSON files located in the `messages` directory:\n\n* `messages/en.json`: English localization strings.\n* `messages/ar.json`: Arabic localization strings.\n\nBoth files share an identical key structure to ensure consistency across languages.\n\n## Data Schema & Patterns\n\nThe JSON structure is organized into nested objects representing specific UI contexts. Each key maps to a string value.\n\n### Key Naming Convention\nKeys follow a hierarchical naming convention: `context.subcontext.key`.\n* **Context:** The top-level domain (e.g., `login`, `projects`, `common`).\n* **Subcontext:** A specific section within the domain (e.g., `login.twoFactorTitle`).\n* **Key:** The specific UI element text (e.g., `login.submit`).\n\n### Interpolation\nStrings may contain placeholders for dynamic data. These are denoted by curly braces `{}`.\n* **Examples:** `{email}`, `{name}`, `{date}`, `{time}`, `{count}`.\n* **Usage:** The application's i18n engine replaces these placeholders with actual values at runtime.\n\n### Pluralization\nThe module supports ICU-style pluralization for dynamic counts. This is critical for accurate localization of numbers.\n* **Syntax:** `{count, plural, =0 {zero} one {one} other {other}}`\n* **Examples:**\n * `projects.memberCount`\n * `projects.openAsks`\n * `board.chainEvents`\n * `milestones.milestonesDone`\n\n### Error Codes & Audit Actions\nSpecific sections handle system-level feedback and audit logging:\n* `vendorCodes.suppression`: Defines reasons why a vendor's response might be suppressed (e.g., `withheldByPolicy`, `linkRevoked`).\n* `vendorCodes.auditAction`: Defines actions recorded in the audit trail (e.g., `projectCreated`, `askFired`).\n\n## Domain Breakdown\n\nThe following sections define the scope of the localization data:\n\n### Application Core\n* `app`: Application name and tagline.\n* `common`: Generic UI actions (Save, Cancel, Loading, Error).\n* `locale`: Language switching options.\n* `footer`: Legal disclaimers and posture statements.\n\n### Authentication\n* `login`: Fields for email, password, and two-factor verification.\n* `notEnabled`: Messages when the platform is disabled for an organization.\n* `guard`: Session checking status.\n\n### Project Management\n* `projects`: List view of coordinated projects.\n* `project`: Single project view, including editing and archiving.\n* `board`: The \"Holdup board\" displaying vendor status and signals.\n* `members`: Vendor invitation and revocation management.\n* `audit`: The immutable audit trail log.\n\n### Coordination Tools\n* `milestones`: Project timeline tracking.\n* `deliverables`: Expected outputs and status.\n* `asks`: Questions sent to vendor assistants.\n* `notes`: Internal coordinator notes attached to projects or vendors.\n\n## Integration & Usage\n\nThis module is consumed by the application's UI layer. While the module itself contains no logic, the application uses the keys defined here to render text.\n\n### Execution Flow\nBased on the call graph analysis, this module has **no internal execution flows**. It does not make outgoing calls, nor does it receive incoming calls. It is a passive data store.\n\n1. **Initialization:** The application loads `messages/en.json` or `messages/ar.json` based on the user's browser locale.\n2. **Rendering:** UI components request strings using the key paths (e.g., `t('login.submit')`).\n3. **Substitution:** The i18n engine resolves placeholders (e.g., `{email}`) and plural forms (e.g., `{count, plural...}`).\n\n### Connection to Codebase\nThe module connects to the rest of the codebase via the **UI Layer**. Any component requiring text must reference a key from this module. There are no direct dependencies on other logic modules within this file.\n\n## Maintenance Guidelines\n\nWhen adding new strings to this module, adhere to the following rules:\n\n1. **Consistency:** Ensure the key path exists in both `en.json` and `ar.json`.\n2. **Placeholders:** Use `{key}` for dynamic values. Do not hardcode values.\n3. **Pluralization:** If a string depends on a count, use the ICU plural format.\n4. **Context:** Group related strings under the same context (e.g., all login strings under `login`).\n5. **Audit Actions:** New actions that modify the system state must be added to `vendorCodes.auditAction` to ensure they are logged correctly.\n\n## Localization Architecture\n\nThe following diagram illustrates how this module fits into the broader application architecture.\n\n```mermaid\nflowchart TD\n App[Application UI] -->|Requests Text| I18n[Translation Engine]\n I18n -->|Loads| EN[en.json]\n I18n -->|Loads| AR[ar.json]\n EN -->|Provides| App\n AR -->|Provides| App\n App -->|Logs| Audit[Audit Trail]\n Audit -->|Reads| EN\n Audit -->|Reads| AR\n```\n\n* **Application UI:** Components that render text.\n* **Translation Engine:** Resolves keys to values and handles interpolation/pluralization.\n* **en.json / ar.json:** The static data sources in this module.\n* **Audit Trail:** Reads from this module to display localized audit messages.","harakat-office-scripts":"# Harakat_Office — scripts\n\n\n\n# Harakat_Office/scripts/check-i18n.mjs\n\n## Overview\n`check-i18n.mjs` is a standalone validation script located within the `Harakat_Office/scripts` directory. Its primary responsibility is to enforce consistency between the English (`en`) and Arabic (`ar`) message catalogs. It ensures that every user-facing string key exists in both languages with an identical hierarchical path, preventing translation drift.\n\n## Purpose\nThis script is critical for maintaining localization integrity. It verifies that:\n1. **Key Parity:** The set of keys in `en.json` matches the set of keys in `ar.json`.\n2. **Structural Integrity:** Nested objects are flattened into consistent dot-notation paths.\n3. **Count Consistency:** The total number of keys in both catalogs is identical.\n\nIf discrepancies are found, the script exits with a non-zero status code to signal a build or deployment failure.\n\n## Dependencies\nThe script relies exclusively on Node.js built-in modules:\n* `node:fs` (via `readFileSync`)\n* `node:url` (via `fileURLToPath`)\n* `node:path` (via `dirname`, `join`)\n\nIt does not import any external packages or other project modules.\n\n## Core Components\n\n### `load(locale)`\nReads and parses the JSON message catalog for a specific locale.\n* **Input:** `locale` (string, e.g., `\"en\"` or `\"ar\"`).\n* **Path:** Constructs the path `messages/{locale}.json` relative to the script's directory.\n* **Output:** A parsed JavaScript object representing the message catalog.\n\n### `flatten(obj, prefix = \"\")`\nA recursive helper function that converts a nested object structure into a flat array of string paths.\n* **Logic:** Iterates through object entries. If a value is a non-array object, it recurses with the current key appended to the `prefix`. If the value is a primitive, it pushes the full path to the output array.\n* **Output:** A sorted array of dot-notation strings (e.g., `[\"app.title\", \"app.settings.language\"]`).\n\n### Main Execution Logic\nThe script orchestrates the validation process:\n1. Loads both `en` and `ar` catalogs.\n2. Flattens both into sorted arrays.\n3. Converts arrays to Sets for efficient lookup.\n4. Identifies keys missing in either language.\n5. Compares the total key counts.\n6. Logs results and exits with code `1` on failure or `0` on success.\n\n## Execution Flow\n\nThe script follows a linear validation pipeline. It loads data, normalizes the structure, compares the sets, and reports the outcome.\n\n```mermaid\nflowchart TD\n Start[Start Script] --> LoadEN[Load messages/en.json]\n LoadEN --> FlattenEN[Flatten EN Keys]\n LoadEN --> LoadAR[Load messages/ar.json]\n LoadAR --> FlattenAR[Flatten AR Keys]\n \n FlattenEN --> SortEN[Sort EN Array]\n FlattenAR --> SortAR[Sort AR Array]\n \n SortEN --> CreateSetEN[Create EN Set]\n SortAR --> CreateSetAR[Create AR Set]\n \n CreateSetEN --> Compare[Compare Sets]\n CreateSetAR --> Compare\n \n Compare --> CheckMissing{Missing Keys?}\n CheckMissing -- Yes --> LogError[Log Missing Keys]\n CheckMissing -- No --> CheckCount{Counts Match?}\n \n LogError --> ExitFail[Exit Code 1]\n CheckCount -- No --> LogCountError[Log Count Mismatch]\n CheckCount -- Yes --> LogSuccess[Log Parity OK]\n LogCountError --> ExitFail\n LogSuccess --> ExitSuccess[Exit Code 0]\n```\n\n## Usage\n\nTo run the validation script, execute it via Node.js from the project root or the scripts directory:\n\n```bash\nnode scripts/check-i18n.mjs\n```\n\n### Output Behavior\n* **Success:** Prints `i18n parity OK — en and ar match.` and exits with code `0`.\n* **Failure:** Prints specific error messages (e.g., `Missing in ar: [...]`) or `Key counts differ.` and exits with code `1`.\n\n## Integration with Codebase\n* **Incoming Calls:** None. This script is not imported or called by other modules.\n* **Outgoing Calls:** None. It does not trigger other scripts or external services.\n* **Data Flow:** Reads from the `messages` directory (relative to the script location) and writes to `stdout`.\n\n## Maintenance Notes\n* **File Paths:** The script assumes the message files are located at `messages/en.json` and `messages/ar.json` relative to the `scripts` directory.\n* **Recursive Flattening:** When adding new nested message keys, ensure the JSON structure is preserved. The `flatten` function handles arbitrary nesting depth automatically.\n* **Sorting:** Both key lists are sorted before comparison to ensure deterministic output during debugging.","harakat-office-types":"# Harakat_Office — types\n\n\n\n# Harakat_Office — types\n\n## Overview\n\nThis module (`vendors.ts`) defines the shared TypeScript type contracts for the **Coordinator Cockpit** API (`/api/vendors/*`). It serves as the single source of truth for the shapes the server returns to the client.\n\n**Critical Constraints:**\n* **Server Sync:** The server module is built in parallel. This file must be kept in lockstep with the server implementation.\n* **ID Handling:** All IDs are `number` (Prisma `Int` autoincrement primary keys). Route parameters arriving from the URL are strings and **must** be parsed with `Number()` at the boundary before being passed into these shapes or the API client.\n* **No Execution:** This module contains no logic, only type definitions. It is imported by other modules to validate data structures.\n\n## Core Constants\n\nThe following types define the allowed values for status, roles, and actor kinds across the system.\n\n```typescript\nexport type ProjectStatus = \"ACTIVE\" | \"ARCHIVED\";\nexport type MemberRole = \"COORDINATOR\" | \"VENDOR\";\nexport type MemberStatus = \"INVITED\" | \"ACTIVE\" | \"REVOKED\";\nexport type MilestoneStatus = \"PENDING\" | \"IN_PROGRESS\" | \"BLOCKED\" | \"DONE\";\nexport type AskStatus =\n | \"PENDING\"\n | \"ANSWERED\"\n | \"SUPPRESSED\"\n | \"UNANSWERED\"\n | \"FAILED\";\nexport type ActorKind = \"HUMAN\" | \"AGENT\" | \"SYSTEM\";\nexport type NoteSource = \"COORDINATOR\" | \"VENDOR_ASSISTANT\" | \"VENDOR_HUMAN\";\n```\n\n**Note on `NoteSource`:**\n* `COORDINATOR`: Notes written by the platform owner.\n* `VENDOR_ASSISTANT`: The vendor's assistant answered over the link.\n* `VENDOR_HUMAN`: A person at the vendor answered it themselves (v1 answer leg).\n* *Quarantine:* Both vendor sources are cross-company text and stay quarantined; the cockpit labels which one you are reading.\n\n## Authentication & Session\n\nThis section defines the shapes for user authentication, including standard login and 2FA flows.\n\n### OfficeUser\nRepresents an authenticated user. Includes a nested `startup` object for context.\n\n```typescript\nexport interface OfficeUser {\n id: number;\n name: string;\n email: string;\n role: string;\n level: number;\n startupId: number;\n startup: {\n id: number;\n name: string;\n [key: string]: unknown;\n };\n}\n```\n\n### Login Flows\nThe login process is conditional based on 2FA configuration.\n\n1. **Initial Request (`POST /api/startup-auth/login`):**\n * Returns `LoginResponse`.\n * **Success:** Contains `token` and `user`.\n * **2FA Challenge:** If 2FA is enabled, returns `requires2FA: true` and `challengeToken`. The `token` and `user` are **absent** in this case.\n * **Failure:** Returns `ok: false` with an `error` string.\n\n2. **2FA Completion (`POST /api/startup-auth/login/2fa`):**\n * Requires `{ challengeToken, code }`.\n * Returns `TwoFactorLoginResponse`.\n * **Success:** Mirrors the non-2FA branch (`{ ok, token, user }`).\n * **Failure:** Returns 401 with an `error` string.\n * **Timing:** Challenge JWT lives 15 minutes; emailed 6-digit code lives 10 minutes.\n\n3. **Client-Side Result (`AuthContext.login()`):**\n * Resolves to `LoginResult`.\n * `signed-in`: Session written to `sessionStorage`.\n * `needs-2fa`: Returns `challengeToken` for the user to complete.\n\n```typescript\nexport interface LoginResponse {\n ok: boolean;\n token?: string;\n user?: OfficeUser;\n requires2FA?: boolean;\n challengeToken?: string;\n message?: string;\n error?: string;\n}\n\nexport interface TwoFactorLoginResponse {\n ok: boolean;\n token?: string;\n user?: OfficeUser;\n message?: string;\n error?: string;\n}\n\nexport type LoginResult =\n | { kind: \"signed-in\" }\n | { kind: \"needs-2fa\"; challengeToken: string; message?: string };\n```\n\n## Project Management\n\nDefines structures for projects, members, milestones, and deliverables.\n\n### Project Structures\n* `ProjectListItem`: Summary view (includes `memberCount`, `openAsks`).\n* `ProjectDetail`: Full view (includes `description`, `status`).\n* `ProjectListResponse` / `ProjectResponse`: Wrapper interfaces for API endpoints.\n\n```typescript\nexport interface ProjectListItem {\n id: number;\n name: string;\n description: string | null;\n status: ProjectStatus;\n memberCount: number;\n openAsks: number;\n createdAt: string;\n}\n\nexport interface ProjectDetail {\n id: number;\n name: string;\n description: string | null;\n status: ProjectStatus;\n createdAt: string;\n}\n```\n\n### Members\nRepresents a user's relationship to a project.\n\n* **`startupName`**: Nullable. Derived from the joined `Startup` row (`?? null`).\n* **`invitedEmail`**: Nullable. Server field name is `invitedEmail` (request body field is `inviteEmail`).\n* **`linkTokenId`**: Nullable. Link to `DelegationToken`.\n\n```typescript\nexport interface Member {\n id: number;\n startupId: number;\n startupName: string | null;\n invitedEmail?: string | null;\n role: MemberRole;\n status: MemberStatus;\n linkTokenId?: number | null;\n invitedAt?: string | null;\n joinedAt?: string | null;\n revokedAt?: string | null;\n}\n```\n\n### Milestones & Deliverables\n* `Milestone`: Tracks progress (`status`, `dueAt`, `completedAt`). `responsibleMemberId` is nullable.\n* `Deliverable`: Tracks provided items (`providedAt`, `note`).\n\n```typescript\nexport interface Milestone {\n id: number;\n title: string;\n description: string | null;\n status: MilestoneStatus;\n dueAt: string | null;\n completedAt: string | null;\n responsibleMemberId: number | null;\n updatedAt: string;\n}\n\nexport interface Deliverable {\n id: number;\n name: string;\n dueAt: string | null;\n providedAt: string | null;\n note: string | null;\n responsibleMemberId: number | null;\n}\n```\n\n## Communication & Status\n\n### Asks\nQuestions sent to members.\n\n* `targetMemberId`: The recipient.\n* `status`: Tracks lifecycle (`PENDING`, `ANSWERED`, `SUPPRESSED`, etc.).\n* `suppressionReason`: Why an ask was suppressed.\n\n```typescript\nexport interface Ask {\n id: number;\n targetMemberId: number;\n question: string;\n status: AskStatus;\n answerText: string | null;\n suppressionReason: string | null;\n createdAt: string;\n respondedAt: string | null;\n expiresAt: string | null;\n}\n```\n\n### Status Notes\nRows from `CoordinationStatusNote`.\n\n* **`source`**: Hardcoded to `\"COORDINATOR\"` on the server side when created by the coordinator.\n* **`memberId`**: `null` indicates the note is about the project as a whole.\n\n```typescript\nexport interface StatusNote {\n id: number;\n projectId: number;\n memberId: number | null;\n source: NoteSource;\n content: string;\n askId: number | null;\n createdAt: string;\n}\n```\n\n## Board & Signals\n\nThe \"Holdup Board\" aggregates member status and signals.\n\n### Member Signals\nAggregated metrics for a member.\n* **Deliverables:** `deliverablesDue` (outstanding only, `providedAt == null`) is **DISJOINT** from `deliverablesProvided`.\n\n```typescript\nexport interface MemberSignals {\n milestonesTotal: number;\n milestonesDone: number;\n milestonesOverdue: number;\n deliverablesDue: number;\n deliverablesProvided: number;\n lastUpdateAt: string | null;\n unansweredAsks: number;\n suppressedAsks: number;\n}\n```\n\n### Board Member\nCombines member identity with their current signals and latest narration.\n\n```typescript\nexport interface BoardMember {\n id: number;\n startupId: number;\n startupName: string | null;\n role: MemberRole;\n status: MemberStatus;\n narratedLatest: NarratedLatest | null;\n signals: MemberSignals;\n}\n```\n\n## Audit & Errors\n\n### Audit Events\nImmutable log of actions.\n\n* `actorKind`: `HUMAN`, `AGENT`, or `SYSTEM`.\n* `hash`: Used for chain verification.\n\n```typescript\nexport interface AuditEvent {\n seq: number;\n actorKind: ActorKind;\n action: string;\n payload: Record<string, unknown>;\n createdAt: string;\n hash: string;\n}\n```\n\n### Errors\n* `NotEnabledError`: Returned when a platform flag is off.\n\n```typescript\nexport interface NotEnabledError {\n error: \"not enabled\";\n}\n```\n\n## Integration & Usage Guidelines\n\n### 1. Boundary Parsing\nWhen receiving data from the URL (e.g., `/api/vendors/:id`), the parameter `id` arrives as a string.\n* **Action:** Parse immediately with `Number(id)`.\n* **Reason:** All internal IDs are `number` (Prisma `Int`). Passing strings to these types will cause type errors.\n\n### 2. Server-Client Sync\nThis file is the contract. If the server adds a field to `ProjectDetail`, this file must be updated.\n* **Warning:** Do not assume optional fields are always present. Check for `null` or `undefined` (e.g., `startupName`, `invitedEmail`).\n\n### 3. Authentication Logic\nWhen handling `LoginResponse`:\n* Do not assume `ok: true` means the user is signed in.\n* Check for `token` and `user` existence.\n* If `requires2FA` is true, redirect to the 2FA flow using `challengeToken`.\n\n## Data Flow: Authentication\n\nThe following diagram illustrates the conditional flow of the authentication process defined in `LoginResponse` and `TwoFactorLoginResponse`.\n\n```mermaid\nsequenceDiagram\n participant Client\n participant API\n participant DB\n\n Client->>API: POST /api/startup-auth/login\n API->>DB: Check User & 2FA Config\n alt 2FA Enabled\n API-->>Client: { ok: true, requires2FA: true, challengeToken: \"...\" }\n Client->>Client: Prompt for Code\n Client->>API: POST /api/startup-auth/login/2fa\n API->>DB: Verify Code\n alt Code Valid\n API-->>Client: { ok: true, token: \"...\", user: {...} }\n else Code Invalid\n API-->>Client: { ok: false, error: \"...\" }\n end\n else 2FA Disabled\n API-->>Client: { ok: true, token: \"...\", user: {...} }\n end\n```","harakat-office":"# Harakat_Office\n\n\n\n# Harakat_Office Module Group\n\n## Overview\n\nThe **Harakat_Office** module group implements a multi-tenant project management cockpit designed to coordinate work across teams. Built on Next.js 15 with the App Router, it provides a secure environment featuring 2FA authentication, multi-language support (English/Arabic), and comprehensive project tracking including milestones, deliverables, and audit trails.\n\n## Architecture\n\nThe module group follows a layered architecture where configuration and data contracts define the boundaries for the application logic and UI.\n\n* **Configuration & Contracts:** The `[Harakat_Office](Harakat_Office.md)` module establishes the runtime environment and security policies. Shared TypeScript contracts are defined in `[types](types.md)`, ensuring the client and server remain in sync.\n* **Localization:** Internationalization is managed centrally by the `[i18n](i18n.md)` module, which configures `next-intl` and enforces URL prefixes. Static translation strings are stored in `[messages](messages.md)` and validated by `[scripts](scripts.md)`.\n* **Application Logic:** The `[app](app.md)` module orchestrates routing and layout (`LocaleLayout`, `AppLayout`). It delegates data fetching to the `[lib](lib.md)` module, which handles API clients (`vendorsApi`), authentication state (`auth-context.tsx`), and custom hooks (`useProjectData`).\n* **User Interface:** The `[components](components.md)` module renders the UI. It consumes data from the library layer and handles user interactions through dialogs, tabs, and forms.\n\n## Key Workflows\n\n### Authentication\nUser sessions are managed through the `LoginPage` in the `[app](app.md)` module. Upon login, the `useAuth` hook in `[lib](lib.md)` manages the session and triggers the `completeTwoFactor` flow. The `LocaleLayout` wraps the application with necessary providers (`Providers`) to ensure global state and localization context are available.\n\n### Project Management\nThe `ProjectsPage` lists available workspaces using `vendorsApi.listProjects`. When a user navigates to a specific project, `ProjectDetailPage` loads data via `useProjectData`. This page aggregates multiple sub-modules to display project-specific information:\n* **Audit:** `AuditTab` renders audit logs.\n* **Deliverables:** `DeliverablesTab` manages task status and triggers `AddDeliverableDialog`.\n* **Asks:** `AsksTab` allows team members to request resources.\n* **Milestones:** `MilestonesTab` tracks project timelines.\n\n### Localization\nAll user-facing text is sourced from `[messages](messages.md)`. The `[i18n](i18n.md)` module ensures that navigation and routing preserve locale prefixes (e.g., `/en/projects`). The `check-i18n.mjs` script in `[scripts](scripts.md)` enforces key parity between English and Arabic catalogs to prevent translation drift.\n\n## Module Interaction Flow\n\n```mermaid\ngraph TD\n Config[Harakat_Office Config] -->|Defines Env & i18n| App[App Module]\n App -->|Uses| Lib[Lib Module]\n App -->|Renders| Comp[Components Module]\n Lib -->|Fetches Data| API[External API]\n Lib -->|Manages State| Auth[Auth Context]\n Comp -->|Consumes| Lib\n Comp -->|Uses| Msg[Messages]\n i18n[i18n Module] -->|Configures| App\n i18n -->|Provides| Msg\n Scripts[Scripts] -->|Validates| Msg\n```\n\n## Sub-Modules\n\n* **[app](app.md)**: Core application router, layouts, and page definitions.\n* **[components](components.md)**: Reusable UI elements, dialogs, and tab interfaces.\n* **[i18n](i18n.md)**: Internationalization configuration and routing logic.\n* **[lib](lib.md)**: API clients, authentication hooks, and data utilities.\n* **[messages](messages.md)**: Static translation files for supported locales.\n* **[Harakat_Office](Harakat_Office.md)**: Next.js configuration, middleware, and build settings.\n* **[scripts](scripts.md)**: Validation tools for localization integrity.\n* **[types](types.md)**: Shared TypeScript type definitions for API contracts.","harakatmobile-assets":"# HarakatMobile — assets\n\n\n\n# HarakatMobile — assets\n\n## Overview\nThe `assets` module manages static resource configurations for the application. This documentation covers `icon.json` (`HarakatMobile/assets/expo.icon/icon.json`), which defines the visual rendering properties for the Expo Icon component.\n\nUnlike dynamic modules, this asset configuration does not contain executable logic. It serves as a data source for the rendering engine to determine icon appearance, layering, and platform compatibility.\n\n## Configuration Schema\nThe `icon.json` file utilizes a JSON structure to define icon properties. The following keys control the asset's behavior:\n\n### `fill`\nDefines the color or gradient applied to the icon.\n* **`automatic-gradient`**: Specifies an extended-srgb color value (`0.00000,0.47843,1.00000,1.00000`).\n\n### `groups`\nDefines the composition of the icon using layered images.\n* **`layers`**: An array of image definitions.\n * **`image-name`**: Reference to the underlying asset file (e.g., `expo-symbol 2.svg`, `grid.png`).\n * **`name`**: Logical identifier for the layer.\n * **`position`**: Transforms applied to the layer.\n * **`scale`**: Uniform scaling factor.\n * **`translation-in-points`**: X and Y offset coordinates.\n* **`shadow`**: Visual effects applied to the group.\n * **`kind`**: Shadow type (e.g., `neutral`).\n * **`opacity`**: Shadow transparency (0.5).\n* **`translucency`**: Blending properties.\n * **`enabled`**: Boolean flag.\n * **`value`**: Opacity level (0.5).\n\n### `supported-platforms`\nRestricts or enables the icon based on the target device.\n* **`circles`**: List of platforms supporting circular icon shapes (e.g., `watchOS`).\n* **`squares`**: Platforms supporting square icon shapes (e.g., `shared`).\n\n## Runtime Behavior\nThis module operates as a passive configuration file.\n* **Execution Flows:** No execution flows are detected. The file is loaded by the asset manager at runtime but does not trigger internal logic.\n* **Dependencies:** No internal calls, outgoing calls, or incoming calls are associated with this file. It relies entirely on the Expo Icon rendering engine to interpret the JSON structure.\n\n## Architecture\nThe following diagram illustrates the data structure hierarchy defined within the configuration file.\n\n```mermaid\ngraph TD\n A[icon.json] --> B_fill[\"B(fill)\"]\n A --> C_groups[\"C(groups)\"]\n A --> D_supported-platforms[\"D(supported-platforms)\"]\n C --> E_layers[\"E(layers)\"]\n E --> F_image-name[\"F(image-name)\"]\n E --> G_position[\"G(position)\"]\n C --> H_shadow[\"H(shadow)\"]\n C --> I_translucency[\"I(translucency)\"]\n```\n\n## Integration\nDevelopers should ensure that the referenced image assets (`expo-symbol 2.svg`, `grid.png`) exist in the corresponding asset directories. Changes to this JSON file will affect the visual output of the icon component without requiring code recompilation, provided the asset manager supports dynamic asset loading.\n\n## Modification Guidelines\nWhen modifying this configuration:\n1. Ensure `image-name` values match existing asset filenames.\n2. Verify `supported-platforms` aligns with the app's target deployment targets.\n3. Adjust `translation-in-points` carefully to maintain alignment with the design system.","harakatmobile-harakatmobile":"# HarakatMobile — HarakatMobile\n\n\n\n# HarakatMobile Module Documentation\n\n## Overview\n\nThe **HarakatMobile** module is the primary client application for the Harakat workspace, built as an Expo React Native application. It serves as the entry point for user interaction, handling authentication, biometric security, offline capabilities, and core workspace features (Dashboard, Agent Board, Notifications, Settings).\n\nThis module is configured for store submission (iOS App Store and Google Play) but requires owner activation for credentials and final verification. It relies on external services for API communication, push notifications, and secure storage.\n\n## Technology Stack\n\nThe application utilizes the following core technologies and dependencies defined in `package.json`:\n\n* **Framework:** React Native (0.86.0) via Expo SDK 57.\n* **Language:** TypeScript (Strict mode enabled).\n* **Navigation:** `expo-router` (Typed routes enabled).\n* **State & Storage:** `@react-native-async-storage/async-storage`, `expo-secure-store`.\n* **Authentication:** `expo-local-authentication` (Biometrics), `react-native-passkeys` (Passkeys).\n* **Networking:** `@react-native-community/netinfo` (Offline detection).\n* **Media:** `expo-audio`, `expo-image-picker`, `expo-document-picker`.\n* **Notifications:** `expo-notifications`.\n\n## Configuration\n\nConfiguration is centralized in `app.json` and `eas.json`.\n\n### App Configuration (`app.json`)\n\nThe `app.json` file defines the bundle identifiers, permissions, and native plugin configurations.\n\n* **Bundle Identifier / Package:** `tech.harakat.app` (iOS and Android).\n* **URL Scheme:** `harakat` (Used for deep linking).\n* **API Endpoint:** Configured via `extra.apiUrl` as `https://api.useharakat.com`.\n* **Web Credentials:** `app.useharakat.com` (Associated domains for iOS and Android app links).\n* **Permissions:**\n * **Biometrics:** `NSFaceIDUsageDescription`, `android.permission.USE_BIOMETRIC`.\n * **Media:** Camera, Microphone, Photo Library (Required for document scanning and voice notes).\n * **Push:** `aps-environment=production` entitlement.\n\n### Build Configuration (`eas.json`)\n\nBuild profiles are managed via EAS CLI.\n\n* **Development:** `developmentClient: true`, `distribution: internal`.\n* **Internal:** `distribution: internal`, `channel: internal`.\n* **Production:** `autoIncrement: true`, `channel: production`.\n\n**Submit Profiles:**\n* **iOS:** Requires `appleId`, `ascAppId`, and `appleTeamId` placeholders.\n* **Android:** Requires `serviceAccountKeyPath` and targets the `internal` track.\n\n## Architecture & Execution Flow\n\nWhile internal function call graphs are not exposed at this module level, the application follows a standard Expo Router architecture. The entry point is `expo-router/entry`, which initializes the navigation stack.\n\n### Feature Structure\n\nBased on the verification checklist, the application is organized into the following primary tabs and flows:\n\n1. **Authentication:** Password login, Passkey registration/login, Biometric app-lock.\n2. **Dashboard:** Widget rendering, offline handling.\n3. **Agent Board:** Lane/card management, chat sheet, offline outbox.\n4. **Notifications:** Feed items, preferences, deep-link handling.\n5. **Settings:** Profile, appearance, security, session, governance.\n\n### High-Level Flow\n\n```mermaid\ngraph TD\n A[App Launch] --> B{Auth Check}\n B -->|Offline| C[Show Cached Data]\n B -->|Online| D[Refresh Token Rotation]\n D --> E[Load Dashboard/Agent Board]\n E --> F{User Action}\n F -->|Biometric| G[Local Auth]\n F -->|Deep Link| H[Open Specific Tab]\n F -->|Push| I[Notification Handler]\n G --> E\n H --> E\n I --> E\n E --> J[Offline Mode Trigger]\n J --> K[Queue Actions]\n K --> L[Reconnect]\n L --> M[Flush Outbox]\n```\n\n## Native Integration\n\n### iOS Specifics\n* **Face ID:** Enabled via `NSFaceIDUsageDescription`.\n* **Associated Domains:** `applinks:app.useharakat.com` and `webcredentials:app.useharakat.com`.\n* **Entitlements:** `aps-environment` set to `production`.\n\n### Android Specifics\n* **Biometrics:** `USE_BIOMETRIC` and `USE_FINGERPRINT` permissions.\n* **Intent Filters:** Configured for `app.useharakat.com` with `BROWSABLE` category.\n* **Adaptive Icon:** Defined with foreground/background layers.\n\n## Security & Credentials\n\nSecurity is managed through a combination of native modules and environment variables.\n\n### Secure Storage\n* **Sensitive Data:** Handled by `expo-secure-store`.\n* **Refresh Tokens:** Rotated upon app restart (verified via `MOBILE_REFRESH_ENABLED=on`).\n\n### Passkeys & WebAuthn\n* **RP ID:** `app.harakat.tech`.\n* **Origins:** `WEBAUTHN_ORIGIN` must include `app.harakat.tech` and `apk-key-hash` for Android.\n* **Well-Known Files:** Credentials and fingerprints must be updated in `store/credentials-and-wellknown.md`.\n\n### Offline Mode\n* **Detection:** `@react-native-community/netinfo`.\n* **Behavior:** Caches data, queues supported actions, and flushes the outbox upon reconnection.\n\n## Development Workflow\n\n### Prerequisites\n* Node.js/npm matching `package-lock.json`.\n* EAS CLI (`npx eas`).\n* Physical iOS and Android devices (required for biometric and deep-link verification).\n\n### Local Development\n1. **Install Dependencies:**\n ```bash\n npm install\n ```\n2. **Start Metro:**\n ```bash\n npm start\n ```\n3. **Build Development Client:**\n ```bash\n npx eas build --profile development --platform ios\n npx eas build --profile development --platform android\n ```\n *Note: Expo Go is insufficient for final verification of native modules.*\n\n### Verification\nBefore submission, the following manual checks must pass on physical devices:\n* **Auth:** Password login survives restart; Passkey login works for `app.harakat.tech`.\n* **Biometrics:** App-lock locks after 30s backgrounding; unlocks via Face ID/Touch ID.\n* **Offline:** Dashboard loads cached data; Agent Board preserves outbox state.\n* **Deep Links:** Push notifications open expected tabs.\n* **Layout:** iPad split-width and Android tablet layouts render correctly.\n\n### Build & Submit\n1. **Internal Build:**\n ```bash\n npx eas build --profile internal --platform ios\n npx eas build --profile internal --platform android\n ```\n2. **Submit:**\n ```bash\n npx eas submit --profile internal --platform ios\n npx eas submit --profile internal --platform android\n ```\n\n## Store Submission\n\nThe `store/` folder contains the source of truth for submission answers.\n\n* **Privacy:** `app-store-privacy.md`, `play-data-safety.md`, `ios-privacy-manifest.md`.\n* **Assets:** `assets-spec.md` (sizes, colors, slots).\n* **Credentials:** `credentials-and-wellknown.md` (Apple Team ID, SHA-256 fingerprint).\n\n**Owner Activation Steps:**\n1. Replace placeholder art in `assets/images/*` and `assets/expo.icon/`.\n2. Run `npx eas credentials` for Apple distribution.\n3. Update `eas.json` submit placeholders (`<APPLE_ID>`, `<ASC_APP_ID>`, etc.).\n4. Redeploy web hosts after updating well-known files.\n5. Set production env flags (`MOBILE_REFRESH_ENABLED`, `PUSH_ENABLED`, `FCM_PROJECT_ID`).\n6. Complete App Store privacy and Google Play Data Safety forms.\n\n## Scripts\n\nCommon development and validation scripts defined in `package.json`:\n\n* `npm start`: Starts Metro bundler.\n* `npm test`: Runs i18n checks, harness self-tests, Jest, and icon/OTA safety checks.\n* `npm run lint`: Runs Expo lint.\n* `npm run check:i18n`: Validates internationalization.\n* `npm run check:icons`: Validates asset integrity.\n* `npm run check:ota-safe`: Validates Over-The-Air update safety.\n\n## Troubleshooting\n\n* **Build Failures:** Verify `eas.json` placeholders are replaced before running `eas build --profile production`.\n* **Deep Link Failures:** Ensure `app.useharakat.com` is added to `WEBAUTHN_ORIGIN` and associated domains in `app.json`.\n* **Push Notifications:** Verify `FCM_PROJECT_ID` and `FCM_SERVICE_ACCOUNT_PATH` are set in production environment variables.\n* **Biometric Errors:** Ensure `NSFaceIDUsageDescription` is present in `Info.plist` (derived from `app.json`) and Android permissions are granted.","harakatmobile-ios":"# HarakatMobile — ios\n\n\n\n# HarakatMobile — ios\n\n## Overview\n\nThe `HarakatMobile — ios` module is the native iOS implementation of the Harakat application. It serves as the container for the React Native application, utilizing the Expo SDK to manage the app lifecycle, native permissions, and deep linking. The project is structured as a standard Xcode project (`Harakat.xcodeproj`) with CocoaPods integration for dependency management.\n\n## Architecture\n\nThe module follows the standard Expo Dev Client architecture. The Swift `AppDelegate` acts as the bridge between the iOS system and the React Native JavaScript runtime.\n\n### Initialization Flow\n\nWhen the application launches, the system invokes `application(_:didFinishLaunchingWithOptions:)` in `AppDelegate`. This method initializes the `ExpoReactNativeFactory` and starts the React Native bridge.\n\n```mermaid\nsequenceDiagram\n participant System\n participant AppDelegate\n participant ReactNativeDelegate\n participant RNFactory\n participant JSRuntime\n\n System->>AppDelegate: application(_:didFinishLaunchingWithOptions:)\n AppDelegate->>ReactNativeDelegate: bundleURL()\n ReactNativeDelegate->>RNFactory: startReactNative()\n RNFactory->>JSRuntime: Initialize JS Bundle\n JSRuntime-->>RNFactory: Ready\n RNFactory-->>AppDelegate: didFinishLaunching\n AppDelegate-->>System: true\n```\n\n## Key Components\n\n### AppDelegate.swift\n\nThe `AppDelegate` class is the primary entry point for the iOS application. It extends `ExpoAppDelegate` and manages the following responsibilities:\n\n* **App Lifecycle:** Initializes the React Native environment via `ExpoReactNativeFactory`.\n* **Deep Linking:** Handles URL schemes and Universal Links via `application(_:open:options:)` and `application(_:continue:userActivity:)`.\n* **Window Management:** Creates the `UIWindow` and injects the React Native factory.\n\n#### Bundle Resolution\nThe `ReactNativeDelegate` subclass handles the resolution of the JavaScript bundle URL. It distinguishes between development and production environments:\n\n* **Debug:** Returns the virtual Metro entry URL (`.expo/.virtual-metro-entry`).\n* **Release:** Returns the pre-bundled `main.jsbundle` from the app bundle.\n\n### Configuration Files\n\n#### Info.plist\nLocated at `Harakat/Info.plist`, this file defines the app's metadata and permissions.\n\n* **Bundle Identifier:** `tech.harakat.app`\n* **Deployment Target:** iOS 16.4\n* **Permissions:**\n * `NSCameraUsageDescription`: Required for document photography.\n * `NSMicrophoneUsageDescription`: Required for voice notes.\n * `NSPhotoLibraryUsageDescription`: Required for image attachments.\n * `NSFaceIDUsageDescription`: Required for biometric authentication.\n* **Universal Links:** Configured for `app.useharakat.com`.\n* **URL Schemes:** `harakat` and `tech.harakat.app`.\n\n#### Expo.plist\nLocated at `Harakat/Supporting/Expo.plist`, this file configures OTA updates.\n\n* **Enabled:** `true`\n* **Check On Launch:** `ALWAYS`\n* **Update URL:** `https://u.expo.dev/730a0f9d-bd80-4cc6-b732-3353bd6d2e5a`\n\n### Build System\n\n#### Podfile\nThe `Podfile` manages CocoaPods dependencies and React Native integration.\n\n* **Engine:** Hermes is enabled (`expo.jsEngine: \"hermes\"`).\n* **Deployment Target:** iOS 16.4.\n* **Frameworks:** Uses `use_frameworks!` with dynamic linkage.\n* **Autolinking:** Configured via `expo-modules-autolinking` to ensure native modules are linked correctly.\n\n#### Xcode Project Settings\nDefined in `project.pbxproj`:\n\n* **Swift Version:** 5.0\n* **Optimization:** `-Onone` (Debug) / Standard (Release).\n* **Bitcode:** Disabled.\n* **Code Signing:** `iPhone Developer` identity.\n* **Asset Catalog:** `expo` is used as the app icon name.\n\n## Resources\n\n### Assets\n* **Images.xcassets:** Contains the app icon (`expo.icon`) and splash screen assets.\n* **SplashScreen.storyboard:** Defines the launch screen layout.\n * **Background:** Dark gray (`#032F2F` approx).\n * **Logo:** Centered `SplashScreenLogo` image.\n\n### Supporting Files\n* **Harakat-Bridging-Header.h:** Empty bridging header for Swift/Objective-C interoperability.\n* **Harakat.entitlements:** Defines entitlements for Associated Domains (`applinks:app.useharakat.com`).\n\n## Development Workflow\n\n1. **Dependencies:** Run `pod install` in the `ios` directory to sync CocoaPods dependencies.\n2. **Environment:** The project relies on `.xcode.env` and `.xcode.env.local` for bundling configuration, sourced by the \"Bundle React Native code and images\" build phase.\n3. **Debugging:**\n * **Debug Mode:** Uses the virtual Metro entry for hot reloading.\n * **Release Mode:** Bundles the JavaScript into `main.jsbundle`.\n4. **Updates:** OTA updates are managed via the `Expo.plist` configuration. The app checks for updates on launch.\n\n## Security & Permissions\n\nThe app requests specific permissions defined in `Info.plist`:\n\n| Permission | Key | Description |\n| :--- | :--- | :--- |\n| Camera | `NSCameraUsageDescription` | Photograph documents for assistant. |\n| Microphone | `NSMicrophoneUsageDescription` | Send voice notes. |\n| Photo Library | `NSPhotoLibraryUsageDescription` | Attach images to messages. |\n| Face ID | `NSFaceIDUsageDescription` | Unlock app and protect workspace. |\n\nNetwork security is configured via `NSAppTransportSecurity`, allowing local networking but requiring HTTPS for external connections (`NSAllowsArbitraryLoads` is `false`).","harakatmobile-store":"# HarakatMobile — store\n\n\n\n# HarakatMobile — Store Readiness Module\n\n## Overview\n\nThe `store` module contains the configuration, compliance artifacts, and activation runbooks required to submit the Harakat Mobile application (`1.0.0`) to the Apple App Store and Google Play Store. This module does not contain runtime business logic; it serves as the bridge between the application build and the respective app store review processes.\n\nThe module relies on the Expo Application Services (EAS) configuration (`app.json`, `eas.json`) and external web hosts to validate app links, push notifications, and WebAuthn credentials.\n\n## Architecture & Dependencies\n\nThis module is configuration-driven. It does not execute internal logic but defines the environment for the build pipeline.\n\n### Core Configuration\n- **`app.json`**: Defines EAS build profiles (`development`, `internal`, `production`), app links, associated domains, and asset paths.\n- **`eas.json`**: Defines EAS submit profiles (`internal`, `production`) and placeholder strings for credentials.\n- **`assets/images/*`**: Contains raster assets (icons, splash, notification) required for store listings.\n\n### External Dependencies\nThe module requires specific files to be deployed to web hosts to function correctly during store submission:\n- **Apple App Site Association (AASA)**: `https://app.harakat.tech/.well-known/apple-app-site-association`\n- **Android Asset Links**: `https://app.harakat.tech/.well-known/assetlinks.json`\n- **Firebase Cloud Messaging (FCM)**: Configured via environment variables on the production server.\n\n### Execution Flow\nThere are no internal execution flows or runtime calls within this module. The \"execution\" occurs during the EAS build and submit processes triggered by the owner.\n\n```mermaid\nflowchart TD\n A[Developer Config] -->|app.json, eas.json| B_EAS[\"B(EAS\"] Build Pipeline)\n B -->|Credentials| C[Web Hosts]\n C -->|AASA, Asset Links| D[App Store / Play Store]\n B -->|Assets| E[Store Submission]\n E -->|Review| F[Store Approval]\n C -->|WebAuthn, Push| G[Production Server]\n```\n\n## Configuration Files\n\n### Privacy & Compliance\nThis module maintains the answers required for store privacy labels. These must match the actual behavior of the production build.\n\n- **`app-store-privacy.md`**: Defines the App Store Connect privacy nutrition label answers.\n - **Tracking**: Declared as `No`.\n - **Data Collected**: Email Address, Name, Device ID (Push Token), Crash Data (conditional).\n - **Purpose**: All data is declared for `App Functionality`.\n- **`play-data-safety.md`**: Defines the Google Play Data Safety form answers.\n - **Data Types**: Personal Info (Email, Name), Device IDs (Push Token).\n - **Security**: Data encrypted in transit; deletion path available via support/admin.\n- **`ios-privacy-manifest.md`**: Documents the expected `PrivacyInfo.xcprivacy` content generated by EAS.\n - **API Categories**: `UserDefaults`, `FileTimestamp`, `DiskSpace`, `SystemBootTime` (Standard Expo reasons).\n\n### Asset Specification\n- **`assets-spec.md`**: Defines the required brand assets.\n - **Brand Colors**: Ink (`#0A2E1E`), Green Mark (`#359167`), Shadda Accent (`#D2C49E`).\n - **Required Slots**: App Icon (1024x1024), iOS Icon Composer, Android Adaptive (Foreground/Background/Monochrome), Splash, Favicon, Notification Icon.\n - **Current State**: Contains Expo scaffold placeholders. Real brand art must be produced before submission.\n\n### Credentials & Well-Known Runbook\n- **`credentials-and-wellknown.md`**: Owner-only activation steps.\n - **Apple**: Run `npx eas credentials --platform ios`. Replace `<APPLE_TEAM_ID>` in AASA files.\n - **Android**: Run `npx eas credentials --platform android`. Replace `<SHA256_CERT_FINGERPRINT>` in Asset Links files.\n - **WebAuthn**: Set `WEBAUTHN_RP_ID=app.harakat.tech` and `WEBAUTHN_ORIGIN` with `apk-key-hash`.\n - **Push/Refresh**: Set `MOBILE_REFRESH_ENABLED=on` and `PUSH_ENABLED=on` on the production server.\n\n## Deployment & Activation Workflow\n\nThe following workflow outlines the steps required to move from a local build to a store submission.\n\n### 1. Configuration & Credentials\nBefore building, the owner must generate credentials and update the web hosts.\n\n1. **Generate Credentials**:\n ```bash\n npx eas credentials --platform ios\n npx eas credentials --platform android\n ```\n2. **Update Web Hosts**:\n - Replace `<APPLE_TEAM_ID>` in `StartupsPlatform/public/.well-known/apple-app-site-association`.\n - Replace `<SHA256_CERT_FINGERPRINT>` in `StartupsPlatform/public/.well-known/assetlinks.json`.\n - Redeploy both `app.harakat.tech` and `Harakat_Landing` hosts.\n3. **Server Environment**:\n - Configure production server environment variables:\n - `WEBAUTHN_RP_ID=app.harakat.tech`\n - `MOBILE_REFRESH_ENABLED=on`\n - `PUSH_ENABLED=on`\n - `FCM_PROJECT_ID=<FCM_PROJECT_ID>`\n\n### 2. Asset Production\nReplace placeholder assets with final brand art.\n- **iOS**: Update `assets/expo.icon/` bundle.\n- **Android**: Update `assets/images/android-icon-foreground.png`, `android-icon-background.png`, `android-icon-monochrome.png`.\n- **Notifications**: Create `assets/images/notification-icon.png` (White silhouette on transparent).\n\n### 3. Build & Verification\n1. **Internal Build**: Run `npx eas build --platform ios --profile internal` and `--platform android --profile internal`.\n2. **Physical Verification**: Install on physical devices to verify:\n - App links resolve correctly.\n - Push notifications deliver.\n - WebAuthn passkeys validate.\n3. **TestFlight / Internal Testing**: Submit to respective internal testing tracks.\n\n### 4. Submission\n1. **Fill Placeholders**: Update `eas.json` with:\n - `<APPLE_ID>`\n - `<ASC_APP_ID>`\n - `<APPLE_TEAM_ID>`\n - `<GOOGLE_PLAY_SERVICE_ACCOUNT_JSON_PATH>`\n2. **Submit**: Run `npx eas submit --platform ios --profile production` and `--platform android --profile production`.\n\n## Owner Responsibilities\n\nThe following tasks are deferred to the owner and are not part of the standard developer workflow:\n\n1. Produce and replace real brand raster assets.\n2. Run `npx eas credentials` for Apple and Android signing.\n3. Backfill well-known files in both web hosts.\n4. Configure production server env for WebAuthn, mobile refresh, and push.\n5. Build internal iOS and Android apps with EAS.\n6. Install on physical devices and complete manual verification.\n7. Submit to TestFlight and Google Play internal testing.\n\n## Compliance Notes\n\n- **Data Deletion**: Users must be able to request account deletion via Harakat support or workspace-admin. This path must remove account profile data, active sessions, refresh tokens, and server-side workspace records.\n- **Diagnostics**: Crash and performance data are only declared if enabled in the production build.\n- **Third-Party Ads**: Do not select Third-Party Advertising or Marketing purposes unless the production server adds those features later.","harakatmobile":"# HarakatMobile\n\n\n\n# HarakatMobile Module\n\n## Overview\n\nThe **HarakatMobile** module is the primary client application for the Harakat workspace, built as an Expo React Native application. It serves as the entry point for user interaction, handling authentication, biometric security, offline capabilities, and core workspace features (Dashboard, Agent Board, Notifications, Settings).\n\nThe module is structured to support store submission (iOS App Store and Google Play) while relying on external services for API communication, push notifications, and secure storage. It integrates native iOS capabilities with a JavaScript runtime to deliver a responsive, secure user experience.\n\n## Architecture\n\nThe application follows a layered architecture where the native container manages the environment, and the core logic handles data and UI.\n\n* **Native Container:** The `ios` module wraps the React Native application using the Expo SDK, managing the `AppDelegate` lifecycle, native permissions, and deep linking.\n* **Core Logic:** The `src` module contains the business logic, including resilient stream connections, authentication token management, and offline synchronization.\n* **UI & Assets:** Static resources are defined in `assets`, while interactive components (e.g., `AskSheet`, `GovernanceScreen`) reside in `src/components`.\n* **Deployment:** The `store` module configures the build pipeline and compliance artifacts required for App Store and Play Store submission.\n\n## Key Workflows\n\n### Authentication & Security\nUser sessions are managed through the `lib/auth/token-store.ts`, which provides access tokens to the `lib/api/client.ts`. Security features, such as passkey support, are validated in `lib/auth/passkeys.ts` and exposed via the `security.tsx` settings screen.\n\n### Data Synchronization\nThe application maintains data integrity through a resilient stream architecture. The `lib/stream/connection.ts` manages connection states, utilizing `lib/stream/backoff.ts` for reconnection logic and `lib/stream/stall-watchdog.ts` to monitor stream health. Data is persisted locally via `lib/offline/outbox.ts` and `lib/offline/read-cache.ts` when connectivity is lost.\n\n### Internationalization & Rendering\nText rendering and directionality are controlled by the `src/i18n` context. The `direction.ts` module determines the active layout direction, influencing components like `ThemedText` and routing logic in `src/i18n/routing.ts`.\n\n### Build & Validation\nPre-deployment validation is handled by scripts in `scripts/`. These include `check-i18n.js` for catalog validation, `harness-selftest.mjs` for self-tests, and `rtl-render-check.mjs` for right-to-left rendering verification.\n\n## Module Relationships\n\n```mermaid\ngraph TD\n subgraph Native Layer\n iOS[HarakatMobile — ios]\n end\n\n subgraph Application Layer\n App[HarakatMobile — src]\n Assets[HarakatMobile — assets]\n Scripts[HarakatMobile — scripts]\n end\n\n subgraph Deployment Layer\n Store[HarakatMobile — store]\n end\n\n iOS -->|Wraps | App\n App -->|Uses | Assets\n App -->|Executes | Scripts\n App -->|Configured by | Store\n Store -->|Validates | Scripts\n```\n\n## Sub-Modules\n\n* **[HarakatMobile — assets](assets.md)**: Manages static resource configurations, including `icon.json` for visual rendering properties.\n* **[HarakatMobile — ios](ios.md)**: Native iOS implementation utilizing the Expo SDK and Xcode project structure.\n* **[HarakatMobile — scripts](scripts.md)**: Build and validation scripts for i18n checks, self-tests, and RTL rendering verification.\n* **[HarakatMobile — src](src.md)**: Core application logic, including stream connections, authentication, offline caching, and UI components.\n* **[HarakatMobile — store](store.md)**: Configuration and compliance artifacts for App Store and Google Play submission.","harakatoffices-server-docs":"# HarakatOffices_Server — docs\n\n\n\n# HarakatOffices_Server — docs Module\n\n## Overview\n\nThe `docs` module contains comprehensive documentation for the HarakatOffices_Server application, covering authentication flows, service management, database storage, and deployment procedures. This documentation serves as the primary reference for developers working on the backend server.\n\n## Documentation Structure\n\n```\ndocs/\n├── 2FA_TESTING_GUIDE.md # Two-Factor Authentication testing procedures\n├── HERMES_BACKEND_ROLLOUT.md # Backend deployment and rollout procedures\n├── PROVIDER_SERVICES_FLOW_DIAGRAM.md # Visual flow for service management\n├── PROVIDER_SERVICES_STORAGE.md # Database storage details for provider services\n├── SERVICES_STORAGE_QUICK_REF.md # Quick reference for service storage locations\n├── SERVICE_STORAGE_COMPLETE_GUIDE.md # Complete guide for service storage\n└── TWO_FACTOR_AUTH_GUIDE.md # 2FA setup and configuration guide\n```\n\n## Key Documentation Files\n\n### 1. Two-Factor Authentication Documentation\n\n**Files**: `2FA_TESTING_GUIDE.md` and `TWO_FACTOR_AUTH_GUIDE.md`\n\nThese documents cover the complete 2FA implementation including:\n\n- **Email Configuration**: SMTP setup for Gmail, Mailtrap, SendGrid, Mailgun, and AWS SES\n- **Database Schema**: 2FA fields added to the `Admin` table (`twoFactorEnabled`, `twoFactorCode`, `twoFactorExpiry`)\n- **API Endpoints**:\n - `POST /api/settings/toggle-2fa` - Enable/disable 2FA\n - `GET /api/settings/2fa-status` - Check 2FA status\n - `POST /api/auth/verify-2fa` - Verify 2FA code\n\n**Code References**:\n- Controller: `src/modules/admin/auth.controller.ts`\n- Email Service: `src/core/services/email.service.ts`\n- Frontend: `app/login/page.tsx` and `app/admin/settings/page.tsx`\n\n**Execution Flow**:\n\n```mermaid\nsequenceDiagram\n participant User\n participant Frontend\n participant Backend\n participant EmailService\n participant Database\n\n User->>Frontend: Login with email/password\n Frontend->>Backend: POST /api/auth/login\n Backend->>Database: Check user credentials\n Backend->>Database: Check twoFactorEnabled\n alt 2FA Enabled\n Backend->>EmailService: Send verification code\n EmailService->>Database: Store code + expiry\n EmailService->>User: Send email with 6-digit code\n User->>Frontend: Enter verification code\n Frontend->>Backend: POST /api/auth/verify-2fa\n Backend->>Database: Verify code\n Backend->>Frontend: Login success\n else 2FA Disabled\n Backend->>Frontend: Login success\n end\n```\n\n### 2. Provider Services Documentation\n\n**Files**: `PROVIDER_SERVICES_FLOW_DIAGRAM.md`, `PROVIDER_SERVICES_STORAGE.md`, `SERVICES_STORAGE_QUICK_REF.md`, `SERVICE_STORAGE_COMPLETE_GUIDE.md`\n\nThese documents cover the service management system for external providers (companies/freelancers).\n\n**Database Schema**:\n\n```prisma\nmodel ProviderService {\n id Int @id @default(autoincrement())\n providerId Int\n name String\n description String?\n creditCost Int\n provider Provider @relation(fields: [providerId], references: [id], onDelete: Cascade)\n}\n```\n\n**API Endpoints**:\n\n| Action | Method | Endpoint | Controller Function |\n|--------|--------|----------|---------------------|\n| Add Service | POST | `/api/admin/providers/:id/services` | `addProviderService()` |\n| View Services | GET | `/api/admin/providers/:id/services` | `getProviderServices()` |\n| Update Service | PUT | `/api/admin/providers/:id/services/:serviceId` | `updateProviderService()` |\n| Delete Service | DELETE | `/api/admin/providers/:id/services/:serviceId` | `deleteProviderService()` |\n\n**Service Management Flow**:\n\n```mermaid\nflowchart TD\n A[Harakat Admin UI] --> B[Edit Company Dialog]\n B --> C[Add Service Form]\n C --> D[POST /api/admin/providers/:id/services]\n D --> E[providers.controller.ts]\n E --> F[ProviderService.create()]\n F --> G[PostgreSQL Database]\n G --> H[Success Response]\n H --> I[Frontend Update]\n```\n\n**Key Distinctions**:\n\n| Table | Purpose | Used By |\n|-------|---------|---------|\n| `ProviderService` | Services offered by external providers | Harakat Admin marketplace |\n| `Service` | Platform-wide service definitions | Office capabilities |\n| `OfficeService` | Services enabled for specific offices | Office approvals |\n\n### 3. Hermes Backend Rollout Documentation\n\n**File**: `HERMES_BACKEND_ROLLOUT.md`\n\nThis document covers the additive deployment of new backend features:\n\n**New Features Added**:\n- Canonical agent directory\n- Scenario run management\n- Scheduled agent jobs\n- Audit ingestion\n- MCP catalog\n- Docker session infrastructure\n\n**Deployment Order**:\n\n```mermaid\nflowchart LR\n A[1. Database Migration] --> B[2. Generate Prisma Client]\n B --> C[3. Deploy API with New Routes]\n C --> D[4. Deploy Workers with ENABLE_QUEUE_WORKERS=true]\n D --> E[5. Enable WORKER_SCHEDULER_ENABLED in Staging]\n```\n\n**Safety Features**:\n- Migration only adds tables, indexes, foreign keys\n- Existing `AssistantScenarioRun` and `AssistantScheduledTask` paths remain readable\n- New MCP invocation uses server-derived JWT claims\n- Agent session Docker plans default to secure settings (`NetworkMode=none`, `ReadonlyRootfs=true`, `CapDrop=ALL`)\n\n**Rollback Procedure**:\n1. Disable workers: `ENABLE_QUEUE_WORKERS=false`\n2. Cancel pending BullMQ `scheduled-agent-*` jobs\n3. Redeploy previous API image\n4. Leave additive tables in place (inert for previous API)\n\n## Codebase Integration\n\n### Database Layer\n\nAll documentation references the Prisma schema located at `prisma/schema.prisma`. Key models include:\n\n- `Admin` - User accounts with 2FA support\n- `Provider` - External service providers (companies/freelancers)\n- `ProviderService` - Services offered by providers\n- `Service` - Platform-wide service definitions\n- `OfficeService` - Office-approved services\n\n### API Layer\n\nDocumentation references the following controller files:\n\n- `src/modules/admin/providers/providers.controller.ts` - Provider service CRUD operations\n- `src/modules/admin/auth.controller.ts` - Authentication and 2FA handling\n- `src/core/services/email.service.ts` - Email sending functionality\n\n### Frontend Integration\n\n- `Harakat_Admin/components/marketplace/` - Admin panel UI for service management\n- `app/login/page.tsx` - Login flow with 2FA support\n- `app/admin/settings/page.tsx` - Settings page with 2FA toggle\n\n## Contributing to Documentation\n\n### Adding New Documentation\n\n1. Create a new `.md` file in the `docs/` directory\n2. Follow existing documentation style (headings, code blocks, Mermaid diagrams)\n3. Reference actual function names, class names, and file paths\n4. Include code examples where applicable\n5. Link to related documentation files\n\n### Updating Existing Documentation\n\n- Update code examples to match current implementation\n- Add troubleshooting sections for common issues\n- Include security considerations for sensitive features\n- Document API rate limits and error responses\n\n### Documentation Best Practices\n\n- **Accuracy**: Verify all code snippets against the actual implementation\n- **Completeness**: Cover normal flows, error cases, and edge cases\n- **Clarity**: Use Mermaid diagrams for complex flows (5-10 nodes max)\n- **Searchability**: Use consistent headings and terminology\n- **Versioning**: Include last updated dates and version numbers\n\n## Quick Reference\n\n### Common Commands\n\n```bash\n# Database operations\nnpx prisma migrate dev\nnpx prisma generate\nnpx prisma studio\n\n# Server operations\npnpm dev\npnpm build\n```\n\n### Testing 2FA\n\n```bash\n# Test SMTP connection\ncd HarakatOffices_Server\nnpx tsx src/core/services/email.service.ts\n\n# Check 2FA status via API\ncurl http://localhost:5000/api/settings/2fa-status \\\n -H \"Authorization: Bearer <token>\"\n```\n\n### Database Queries\n\n```typescript\n// Get provider with services\nconst provider = await prisma.provider.findUnique({\n where: { id: 1 },\n include: { services: true },\n});\n\n// Get all services for a provider\nconst services = await prisma.providerService.findMany({\n where: { providerId: 1 },\n orderBy: { id: \"desc\" },\n});\n```\n\n## Related Modules\n\n- **Harakat_Admin** - Frontend application\n- **HarakatOffices_Server** - Backend API server\n- **Database** - PostgreSQL with Prisma ORM\n- **Email Service** - SMTP-based email delivery\n\n---\n\n**Last Updated**: October 30, 2025 \n**Documentation Version**: 1.0","harakatoffices-server-scripts":"# HarakatOffices_Server — scripts\n\n\n\n# HarakatOffices_Server/scripts\n\nThis module contains operational scripts, integration tests, and data maintenance utilities. These scripts are not part of the production API surface but are essential for development validation, database backfills, and manual operational tasks. They rely heavily on the Prisma client and core service modules (e.g., `weekly-rollup.service`, `chat-protocol`, `tool-registry`).\n\n## Categories\n\nScripts are organized into four functional categories:\n\n1. **Protocol & Access Validation:** Unit tests for core protocol helpers and access control logic.\n2. **Board & Weekly Rollup Backfills:** One-time data migrations to enforce weekly thread structures.\n3. **Operational & Testing Utilities:** Tools for forcing job queues, seeding data, and running integration tests.\n4. **Infrastructure & Schema Testing:** Bash scripts for validating database constraints against throwaway schemas.\n\n## Protocol & Access Validation\n\nThese scripts verify that internal protocol helpers and access control logic behave as expected without external dependencies.\n\n### `b3_create_sentinel_check.ts`\nValidates the server-side wiring for the `__CREATE__` protocol sentinel. It ensures that creation kickoffs are parsed correctly and do not appear as visible chat bubbles.\n\n* **Key Logic:**\n * Calls `isProtocolSentinel` to verify the `__CREATE__` prefix is recognized.\n * Calls `parseCreationSentinel` to extract `kind` and `scopeHint`.\n * Verifies normalization (e.g., `\"SKILL\"` → `\"skill\"`).\n * Ensures malformed JSON or unknown kinds return `null`.\n* **Dependencies:** `modules/startup/chat-protocol`.\n* **Usage:**\n ```bash\n cd HarakatOffices_Server && npx tsx scripts/b3_create_sentinel_check.ts\n ```\n\n### `test-mcp-access.ts`\nTests the MCP access control logic, specifically tier requirements and startup visibility.\n\n* **Key Logic:**\n * Uses `deriveAccessKey` to generate mock claims.\n * Asserts `canUseMinTier` behavior based on user level.\n * Verifies `explainMcpInvocationRejection` returns correct error messages for tier, startup, and agent mismatches.\n* **Dependencies:** `core/access-key`, `modules/tool-registry/access`.\n* **Usage:**\n ```bash\n npx tsx scripts/test-mcp-access.ts\n ```\n\n### `verify-url-normalizer.ts`\nA manual verification runner for the `normalizeMeetingUrl` function. It executes `__verifyNormalizer` to ensure invariants hold.\n\n* **Dependencies:** `modules/meeting/url-normalizer`.\n* **Usage:**\n ```bash\n npx tsx scripts/verify-url-normalizer.ts\n ```\n\n## Board & Weekly Rollup Backfills\n\nThese scripts perform one-time data migrations to enforce the \"One Assistant Thread Per User Per Week\" rule (R4-1) and standardize naming. They operate within database transactions to ensure atomicity.\n\n### `merge-weekly-threads.ts`\nEnforces a single durable assistant thread per user per ISO week. It groups conversations by `(startupId, startupUserId, weekKey)` and merges sources into a target.\n\n* **Key Logic:**\n * **Plan Phase:** `buildPlans` iterates over all startups and conversations. It groups conversations by week and identifies a target (preferably the one already tagged with `weekKey`).\n * **Apply Phase:** `applyPlan` executes a transaction that:\n 1. Updates `conversationMessage`, `assistantTask`, `conversationCheckpoint`, `scenario`, `usageEvent`, `agentCreditLog`, `assistantFeedback`, `eriRun`, and `actionPreview` to point to the target conversation ID.\n 2. Updates `conversationLifecycleEvent` to link `previousConversationId` to the target.\n 3. Deletes source conversations.\n 4. Updates the target with `weekKey` and `isActiveWeek`.\n * **Safety:** Defaults to dry-run (`--apply` required to mutate). Verifies message count is lossless.\n* **Dependencies:** `modules/board/weekly-rollup.service` (for `currentWeekKey`).\n* **Usage:**\n ```bash\n # Dry-run\n npx tsx scripts/merge-weekly-threads.ts\n # Apply to specific startup\n npx tsx scripts/merge-weekly-threads.ts --startup 19 --apply\n ```\n\n### `merge-weekly-conversations.ts`\nA backfill script to merge existing conversations into per-ISO-week rolling threads. It is less granular than `merge-weekly-threads.ts` and focuses on the `conversation` table directly.\n\n* **Key Logic:**\n * Groups conversations by ISO week of `createdAt` (tenant timezone).\n * Keeps the earliest conversation in each week as the target.\n * Moves messages and deletes source conversations.\n * Nulls out legacy `voice.local` audio URLs.\n* **Dependencies:** `modules/board/weekly-rollup.service`.\n* **Usage:**\n ```bash\n # Requires environment variables: MERGE_STARTUP_ID, MERGE_USER_ID, MERGE_TZ\n npx tsx scripts/merge-weekly-conversations.ts\n ```\n\n### `retitle-weekly-threads.ts`\nStandardizes the `title` field for weekly threads. Replaces raw keys or first-message slices with human-readable names (e.g., \"Week of Jul 6\").\n\n* **Key Logic:**\n * Filters conversations where `weekKey` is set and `agentId` is 1.\n * Calls `weeklyThreadTitle` to generate the new name.\n * Updates the `title` field.\n* **Dependencies:** `modules/board/weekly-rollup.service`.\n* **Usage:**\n ```bash\n # Dry-run\n npx tsx scripts/retitle-weekly-threads.ts\n # Apply\n npx tsx scripts/retitle-weekly-threads.ts --apply\n ```\n\n## Operational & Testing Utilities\n\n### `board-v2-selftest.ts`\nA comprehensive integration test suite for the Board v2 features. It creates a throwaway startup, runs controller tests, and cleans up.\n\n* **Key Logic:**\n * **Fixture:** `createFixture` creates a startup, users, agent, and conversation.\n * **Cleanup:** `cleanup` deletes the startup and agent in the `finally` block.\n * **Test Cases:**\n * Verifies `BOARD_V2` flag off behavior (returns disabled envelopes).\n * Tests `updateConversationWeekNotesController` roundtrip.\n * Tests `editConversationMessageController` (user message edit truncates downstream).\n * Tests permission denial for non-owners.\n * Tests `getOrCreateActiveWeeklyConversation` idempotency.\n* **Dependencies:** `src/core/config/prisma`, `src/modules/startup/startup.controller`, `src/modules/board/weekly-rollup.service`.\n* **Usage:**\n ```bash\n npx tsx scripts/board-v2-selftest.ts\n ```\n\n### `force-transcript-batch.ts`\nManually enqueues a `transcript_batch` job in the `ExecutionQueue` table. Bypasses the planner cron, useful for testing the worker or when the cron is not registered.\n\n* **Key Logic:**\n * Validates meetings exist and belong to a single startup.\n * Checks `transcriptStatus` is null (not already processed).\n * Sets `transcriptStatus` to `pending` and assigns a `transcriptBatchId`.\n * Mints callback tokens via `mintMeetingCallbackToken`.\n * Creates the `ExecutionQueue` row with `scheduledAt = now`.\n* **Dependencies:** `src/middleware/meeting-callback-auth`, `src/core/config/env`.\n* **Usage:**\n ```bash\n npx tsx scripts/force-transcript-batch.ts <meetingId> [<meetingId> ...]\n ```\n\n### `seed-tool-registry.ts`\nSyncs the `ToolRegistration` table from a JSON manifest.\n\n* **Key Logic:**\n * Reads a JSON file (e.g., `Harakat_AI/tool_manifest.json`).\n * Calls `bulkUpsertCatalog` to upsert tools.\n * Idempotent: re-running updates existing entries.\n* **Dependencies:** `modules/tool-registry/tool-registry.service`.\n* **Usage:**\n ```bash\n npx ts-node scripts/seed-tool-registry.ts ../Harakat_AI/tool_manifest.json\n ```\n\n## Infrastructure & Schema Testing\n\n### `procedure-assignee-live.sh`\nA Bash script that creates a throwaway database schema (structure only, no data) from a live source database to test constraints and triggers.\n\n* **Key Logic:**\n * Reads `DATABASE_URL` from `.env.local` or `.env`.\n * Uses `pg_dump --schema-only` to extract schema.\n * Creates a new database `procedure_assignee_sdd_test`.\n * Runs `procedure-assignee-live-test.ts` against this schema.\n * Drops the test database on exit.\n* **Purpose:** Ensures that tests pass against a schema with real constraints (CHECK, triggers) rather than a `db-push` schema which lacks them.\n* **Usage:**\n ```bash\n bash scripts/procedure-assignee-live.sh\n ```\n\n## Architecture & Execution Flow\n\nScripts in this module primarily interact with the database via the Prisma client (`prisma`). They are designed to be idempotent where possible (e.g., merge scripts check for existing tags) and safe (e.g., `board-v2-selftest.ts` cleans up fixtures).\n\nThe following diagram illustrates the execution flow of the most complex backfill script, `merge-weekly-threads.ts`.\n\n```mermaid\nflowchart TD\n Start[main] --> Build[buildPlans]\n Build --> Check{Plans > 0?}\n Check -- No --> Exit[Exit]\n Check -- Yes --> Apply[applyPlan]\n Apply --> Loop{More Plans?}\n Loop -- Yes --> Apply\n Loop -- No --> Verify[Verify Message Count]\n Verify --> Exit\n Build --> Group[Group by User/Week]\n Group --> Select[Select Target]\n Select --> Update[Update Tables]\n Update --> Delete[Delete Sources]\n Update --> SetTags[Set weekKey/isActiveWeek]\n```\n\n## Safety & Best Practices\n\n1. **Transactions:** Scripts that modify data (e.g., `merge-weekly-threads.ts`, `merge-weekly-conversations.ts`) wrap changes in `prisma.$transaction` to ensure atomicity.\n2. **Dry-Run Defaults:** Backfill scripts default to dry-run mode (`--apply` required) to prevent accidental data loss.\n3. **Cleanup:** Integration tests (`board-v2-selftest.ts`) explicitly clean up created resources in a `finally` block.\n4. **Environment Variables:** Scripts rely on specific env vars (e.g., `BOARD_V2`, `MERGE_STARTUP_ID`). Ensure these are set before execution.\n5. **Schema Consistency:** `procedure-assignee-live.sh` ensures tests run against a schema with constraints, preventing false positives from `db-push` environments.","harakatoffices-server-tools":"# HarakatOffices_Server — tools\n\n\n\n# Tenant Migration Tools\n\nThis module provides the infrastructure to migrate a tenant's **parsed corpus** and **knowledge graph** from a source Harakat Postgres instance to a target instance where the tenant account already exists.\n\nIt is designed for scenarios such as moving data from a local development environment to production, or consolidating data between environments. It does **not** migrate tenant configuration, governance, users, or conversations.\n\n## Architecture\n\nThe migration process is split into three distinct phases: **Export**, **Transport**, and **Import**.\n\n1. **Export (`export.sh`):** Extracts specific tables from the source database into CSV files.\n2. **Transport:** The CSV directory is moved to the target host.\n3. **Import (`import.sh` + `import.sql`):** Loads the CSVs into the target database, remapping primary keys to avoid collisions.\n\n### Data Flow\n\n```mermaid\nflowchart LR\n subgraph Source\n DB[Postgres DB]\n Export[export.sh]\n end\n subgraph Transport\n Files[CSV Directory]\n end\n subgraph Target\n Import[import.sh]\n SQL[import.sql]\n DB_Tgt[Postgres DB]\n Meili[Meilisearch]\n end\n\n DB -->|1. Export CSVs| Export\n Export -->|2. Transport| Files\n Files -->|3. Load| Import\n Import -->|4. Transform| SQL\n SQL -->|5. Upsert| DB_Tgt\n DB_Tgt -->|6. Reindex| Meili\n```\n\n## Core Components\n\n### 1. Export Script (`export.sh`)\n\nGenerates a portable directory of CSV files containing the tenant's knowledge data.\n\n* **Input:** `SRC_STARTUP_ID` (Source tenant ID), optional `SRC_PSQL` (direct psql command).\n* **Output:** A directory (e.g., `tenant_export_19/`) containing:\n * One CSV per table (`KnowledgeNode.csv`, `ParsedDocument.csv`, etc.).\n * `manifest.csv`: Row counts per table.\n * `SOURCE_MIGRATION.txt`: Prisma migration state for schema parity checks.\n\n**Key Behavior:**\n* Uses explicit column lists (not `SELECT *`) to prevent column-order drift issues.\n* Excludes `SearchIndexState` and `OcrBatchItem` as they are transient or tied to the source instance.\n* Includes `TenantTOC` to avoid re-running the `/parse/tenant-toc` LLM call on the target.\n\n### 2. Import Script (`import.sh`)\n\nOrchestrates the loading of CSVs into the target database.\n\n* **Input:** Path to export directory, `TARGET_STARTUP_ID`.\n* **Modes:**\n * **Container Mode:** Copies files into the DB container (`DB_CONTAINER`) and runs `psql` inside. Recommended for production.\n * **Direct Mode:** Uses `DATABASE_URL` or `TGT_PSQL` to run `psql` on the host.\n* **Safety:** Runs `import.sql` within a transaction (`BEGIN/COMMIT`). If any step fails, the entire import is rolled back.\n\n### 3. SQL Import Logic (`import.sql`)\n\nHandles the heavy lifting of data transformation.\n\n* **ID Remapping:** Primary keys are global sequences and cannot be reused. The script builds temporary maps (`_node_map`, `_pd_map`) to translate Source IDs to Target IDs.\n* **Upsert Strategy:** Uses `ON CONFLICT` clauses to update existing rows or insert new ones based on unique constraints (e.g., `(startupId, externalId)` for nodes).\n* **Idempotency:** Safe to run multiple times. Re-running will update existing data rather than duplicating it.\n\n## Supported Tables\n\nThe following tables are migrated. All foreign keys are translated through the ID maps.\n\n| Table | Keyed/Remapped By | Notes |\n| :--- | :--- | :--- |\n| `KnowledgeNode` | `(startupId, externalId)` | Linchpin of the graph. |\n| `KnowledgeEdge` | Endpoints via Node Map | Deduped on `(startupId, sourceId, targetId, relation)`. |\n| `ParsedDocument` | `nodeId` | Upserted by unique `nodeId`. |\n| `PageIndexTree` | `nodeId` | Upserted by unique `nodeId`. |\n| `FolderRollup` | `nodeId` | Upserted by unique `nodeId`. |\n| `MultimodalDescription` | `nodeId` + `parsedDocumentId` | |\n| `DocumentAbstract` | `nodeId` + `parsedDocumentId` | |\n| `TenantTOC` | `startupId` | Migrated verbatim to skip LLM generation. |\n\n## Excluded Data\n\nThe following data is **not** migrated and must be handled separately or regenerated:\n\n* **`SearchIndexState`**: Contains `meiliDocId` embeds pointing to source node IDs. After import, the target must reindex Meilisearch (zero LLM cost).\n* **`OcrBatchItem`**: Transient batch-OCR staging data.\n* **Tenant Config:** `Startup`, `StartupUser`, `DriveIntegration`, governance, conversations, and usage stats are assumed to exist on the target.\n\n## Usage\n\n### 1. Export (Source)\n\nRun on the source machine where the tenant data exists.\n\n```bash\ncd HarakatOffices_Server/tools/tenant-migrate\nSRC_STARTUP_ID=19 ./export.sh ./tenant_export_19\n```\n\n* **Transport:** Copy the entire `./tenant_export_19` directory to the target host.\n\n### 2. Import (Target)\n\nRun on the target machine where the tenant account exists.\n\n```bash\ncd HarakatOffices_Server/tools/tenant-migrate\nDATABASE_URL=\"postgresql://harakat:I87ui87u.@db:5432/harakatoffices_db\" \\\n ./import.sh /path/to/tenant_export_19 19\n```\n\n* **Verification:** The script prints the mapped node/parsed-doc counts and final row counts per table.\n\n### 3. Post-Import (Target)\n\nAfter the SQL import completes, the search index must be updated.\n\n1. **Reindex Meilisearch:** Copy the migrated abstracts, rollups, and TOC text into the search engine.\n2. **Cost:** This is a data copy operation. **Zero LLM calls** are made.\n3. **Note:** `TenantTOC` is already migrated, so the `/parse/tenant-toc` LLM call is skipped.\n\n## Technical Details\n\n### ID Remapping Strategy\n\nSince primary keys are global sequences, direct insertion of source IDs will fail or collide. The import logic follows this flow:\n\n1. **Load Staging:** Data is loaded into temporary tables (`_imp_node`, `_imp_parsed`, etc.).\n2. **Build Node Map:**\n * Iterates through `KnowledgeNode` CSV.\n * Matches on `(target startupId, externalId)`.\n * Fallback: If `externalId` is NULL, matches on `(target startupId, kind, name)`.\n * If no match found, inserts a new row and captures the new ID.\n * Stores mapping in `_node_map(old_id -> new_id)`.\n3. **Build Parsed Doc Map:**\n * Similar logic for `ParsedDocument`, keyed by `nodeId`.\n4. **Translate FKs:**\n * Dependent tables (`KnowledgeEdge`, `MultimodalDescription`, etc.) join against these maps to replace source IDs with target IDs.\n * Uses `ON CONFLICT` to handle existing data safely.\n\n### Schema Parity\n\nThe export script records the source Prisma migration state in `SOURCE_MIGRATION.txt`. The import script checks this to warn if the target schema drifts. Column-order drift is handled by explicit column lists in the CSVs, but missing columns will cause the import to fail loudly.\n\n### Branch ID Caveat\n\nThe `branchId` on enrichment tables (`MultimodalDescription`, `DocumentAbstract`, `FolderRollup`) is carried verbatim from the source. This is a soft reference (no DB FK). If the target tenant's `StartupBranch` IDs differ from the source, branch-scoped redaction may be incorrect. If branches differ, `branchId` should be remapped or nullified after import.\n\n## Troubleshooting\n\n* **Import Fails:** Check `SOURCE_MIGRATION.txt` against the target DB migration state.\n* **Search Returns No Results:** Ensure the Meilisearch reindex step is completed after import.\n* **Duplicate Data:** Ensure `TARGET_STARTUP_ID` is passed correctly. The script ignores the source `startupId` in the CSV and writes everything under the target ID.","harakatoffices-server-uploads":"# HarakatOffices_Server — uploads\n\n\n\n# HarakatOffices_Server — uploads\n\n## Overview\n\nThe `uploads` module serves as the persistent storage layer for unstructured data within the `HarakatOffices_Server` application. It functions as a static file system directory rather than a logic-processing module. There are no internal execution flows, function calls, or class definitions associated with this module; it relies on the underlying operating system file system for persistence.\n\nThis directory is intended to hold raw artifacts generated by external processes, user uploads, or system initialization scripts. The server does not process these files internally; it provides the physical location where data is retained for retrieval by other services or manual inspection.\n\n## Storage Layout\n\nThe module organizes files into subdirectories based on their purpose or origin. The current structure is defined by the following hierarchy:\n\n```mermaid\ngraph TD\n Root[HarakatOffices_Server]\n Uploads[uploads]\n Startup[startup-documents]\n File1[agent-1784109977231-79664509.txt]\n File2[file-1786628806636-722721294.txt]\n\n Root --> Uploads\n Uploads --> Startup\n Startup --> File1\n Startup --> File2\n```\n\n## File Inventory\n\nThe following files are currently present within the `startup-documents` subdirectory. These files contain metadata and project specifications.\n\n### `agent-1784109977231-79664509.txt`\n* **Location:** `uploads/startup-documents/`\n* **Content:** `p1 test`\n* **Purpose:** Placeholder or test artifact for agent initialization.\n\n### `file-1786628806636-722721294.txt`\n* **Location:** `uploads/startup-documents/`\n* **Content:**\n ```text\n Al Reem tower — reception fit-out\n Site survey 2026-08-12\n 18 Lm partition, oak veneer feature wall.\n ```\n* **Purpose:** Site survey documentation for the Al Reem tower project. Includes specific material specifications (oak veneer) and dates.\n\n## Integration & Access\n\nSince this module contains no internal logic, integration is handled by external components that read from or write to the file system paths.\n\n* **Read Access:** External services or scripts must access the file system directly or via a mounted volume to retrieve file contents.\n* **Write Access:** Uploads are typically triggered by external client applications or background workers. The server does not validate or transform data upon receipt; it persists the file to the designated path.\n* **Dependencies:** This module has no outgoing or incoming internal calls. It is a leaf node in the application's dependency graph.\n\n## Maintenance & Notes\n\n* **File Naming:** Files utilize a timestamp-based naming convention (e.g., `agent-<timestamp>-<id>.txt`). This ensures uniqueness and chronological ordering.\n* **Cleanup:** As there is no internal logic to manage file lifecycle, external processes are responsible for archiving or deleting old files to prevent storage bloat.\n* **Permissions:** Ensure the application user has read/write permissions on the `uploads` directory to prevent write failures during initialization or data ingestion.\n* **Security:** Since this directory stores raw data, ensure access controls are applied at the file system level to prevent unauthorized modification of startup documents.","harakatoffices-server":"# HarakatOffices_Server\n\n\n\n# HarakatOffices_Server\n\nThe `HarakatOffices_Server` module constitutes the backend infrastructure for the HarakatOffices application. It orchestrates core business logic, tenant data management, and operational maintenance through specialized sub-modules. While the core application logic resides in `src`, the surrounding modules provide the necessary environment, validation, and data handling layers.\n\n## Module Architecture\n\nThe server ecosystem is divided into five primary areas:\n\n* **Core Logic (`src`):** Contains the main application services, controllers, and workers (e.g., `weekly-rollup.service`, `chat-protocol`). Documentation for this module is pending generation.\n* **Documentation (`docs`):** Provides reference material for deployment and service flows, including `HERMES_BACKEND_ROLLOUT.md` and `PROVIDER_SERVICES_FLOW_DIAGRAM.md`.\n* **Operational Scripts (`scripts`):** Contains non-production utilities for database backfills, integration tests, and data maintenance (e.g., `weekly-rollup.service` validation).\n* **Migration Tools (`tools`):** Infrastructure for moving tenant corpus and knowledge graph data between environments via `export.sh` and `import.sh`.\n* **Storage (`uploads`):** A persistent static file system directory for unstructured data artifacts.\n\n## Integration and Workflows\n\nThe sub-modules function as a support layer around the core `src` logic:\n\n1. **Validation & Maintenance:** The `scripts` module validates the integrity of core services defined in `src`. For example, protocol validation scripts test access control logic, while backfill scripts enforce weekly thread structures using `weekly-rollup.service`.\n2. **Data Migration:** The `tools` module facilitates tenant consolidation. It extracts specific tables from a source database (Export) and imports them into a target instance where the tenant account already exists, ensuring the `src` services can access the migrated corpus.\n3. **Artifact Management:** The `uploads` module serves as the physical storage layer for artifacts referenced by core services. Services such as `ArtifactService` and `ArtifactRefusal` rely on this directory for persistent storage of raw data.\n4. **Deployment:** The `docs` module guides the rollout of backend changes, ensuring that updates to `src` services align with deployment procedures outlined in `HERMES_BACKEND_ROLLOUT.md`.\n\n## Service Interactions\n\nThe core `src` logic interacts extensively with internal services across the module group. Key cross-module dependencies include:\n\n* **Artifacts:** `ArtifactService` manages storage and refusal logic, interacting with `uploads` for persistence.\n* **Integrations:** `MailProvider` and `ConnectorStatus` handle external communication and validation.\n* **Capabilities & Sandbox:** `SandboxRefusal` and `CapabilityNotFoundError` manage execution environments and feature flags.\n* **ERP & Mutations:** `AnchorBridgeError` and `ProposalNotApprovableError` govern enterprise resource planning and state changes.\n\n## Architecture Diagram\n\n```mermaid\ngraph TD\n subgraph HarakatOffices_Server\n docs[docs<br/>Deployment & Reference]\n scripts[scripts<br/>Validation & Backfills]\n tools[tools<br/>Tenant Migration]\n uploads[uploads<br/>Unstructured Storage]\n src[src<br/>Core Logic & Services]\n end\n\n %% Support to Core\n docs -->|Guides Rollout| src\n scripts -->|Validates Logic| src\n tools -->|Migrates Data| src\n uploads -->|Stores Artifacts| src\n\n %% Core Internal Services\n subgraph Core_Services\n artifacts[ArtifactService]\n mail[MailProvider]\n sandbox[SandboxManager]\n erp[ERPConnections]\n capabilities[CapabilitiesService]\n end\n\n src --> artifacts\n src --> mail\n src --> sandbox\n src --> erp\n src --> capabilities\n\n %% Data Flow\n uploads -.->|Raw Data| artifacts\n tools -.->|Corpus Data| src\n```","meeting-bot-worker":"# meeting-bot-worker\n\n\n\n# meeting-bot-worker\n\nThe `meeting-bot-worker` module is a long-lived Node.js orchestrator container responsible for executing meeting recording jobs. It wraps the upstream `meet-teams-bot` recorder, managing the lifecycle of each recording session from queue claim to artifact upload and status callback.\n\n## Overview\n\nThe worker operates as a stateless orchestrator. While the underlying `meet-teams-bot` (located at `/opt/bot`) requires a virtual display and audio environment to function, the worker container is designed to be reused across multiple jobs. To achieve this, the worker explicitly tears down and rebuilds the virtual environment (Xvfb, PulseAudio, x11vnc) for every job execution.\n\n**Concurrency Model:**\n* **1 Job per Container:** The worker processes one job at a time.\n* **Scaling:** To handle concurrent meetings, scale the container service (e.g., `docker compose up --scale meeting-bot-worker=N`).\n\n## Architecture\n\nThe container image consists of two distinct layers:\n\n1. **Upstream Bot (`/opt/bot`):**\n * Contains the `meet-teams-bot` source code and dependencies.\n * Includes a generated `/start.sh` script that initializes the virtual display and audio stack.\n * The actual recording logic runs via `node build/src/main.js` inside this script.\n\n2. **Worker Orchestrator (`/worker`):**\n * Contains the Node.js application (`src/main.js`).\n * Manages database interactions, process spawning, and cloud storage uploads.\n * Activates the Google Cloud Service Account at container startup.\n\n## Job Lifecycle\n\nThe worker follows a strict lifecycle for each job:\n\n1. **Claim:** Polls the `ExecutionQueue` table for the oldest pending `meeting_bot` job using `FOR UPDATE SKIP LOCKED`.\n2. **Notify:** Patches the server callback with `status: \"joining\"`.\n3. **Execute:** Spawns the upstream bot via `/start.sh`, piping a generated `bot.config.json` to stdin.\n4. **Verify:** Checks for the existence of `output.mp4` after the bot exits.\n5. **Process:** Converts `output.wav` to 16kHz mono FLAC (best-effort).\n6. **Upload:** Copies artifacts to GCS and generates signed URLs.\n7. **Callback:** Patches the server with `status: \"recorded\"` (or `failed`) and artifact URLs.\n8. **Release:** Marks the queue row as `completed` or `failed`.\n\n```mermaid\nflowchart TD\n Start[Worker Loop] --> Poll{Poll Queue}\n Poll -->|No Job| Sleep[Sleep & Retry]\n Sleep --> Poll\n Poll -->|Job Found| Claim[Claim Job DB Lock]\n Claim --> Notify[Post Callback: joining]\n Notify --> RunBot[Spawn /start.sh]\n RunBot --> CheckArtifacts{Has MP4?}\n CheckArtifacts -->|No| Fail[Post Callback: failed]\n CheckArtifacts -->|Yes| Convert[Convert to FLAC]\n Convert --> Upload[Upload to GCS]\n Upload --> Sign[Sign URLs]\n Sign --> Callback[Post Callback: recorded]\n Callback --> Release[Release Queue]\n Release --> Start\n RunBot -->|Timeout| Fail\n Fail --> Release\n```\n\n## Key Components\n\n### Database Interaction\nThe worker uses the `pg` library to interact with the Postgres database.\n\n* **`claimNextJob()`**: Executes an `UPDATE ... RETURNING` query with `FOR UPDATE SKIP LOCKED`. This ensures that only one worker can claim a specific job ID, preventing race conditions.\n* **`releaseQueue(queueId, status, errorMsg)`**: Updates the `ExecutionQueue` status to `completed` or `failed` and records the error message if applicable.\n\n### Bot Execution\nThe worker does not run the bot directly. Instead, it spawns the `/start.sh` script generated during the Docker build.\n\n* **`runBot(payload, recordingDir)`**:\n * Constructs a `bot.config.json` via `buildBotConfig(payload)`.\n * Spawns `/start.sh` using `child_process.spawn`.\n * Pipes the config JSON to the bot's stdin.\n * Enforces a hard timeout (`BOT_HARD_TIMEOUT_MS`, default 4h 10m).\n * Waits for the process to exit with code `0`.\n\n### Artifact Processing\n* **`convertToFlac(recordingDir)`**: Uses `ffmpeg` to convert `output.wav` to `output_16k.flac`. This is a soft-fail step; if conversion fails, the worker proceeds with the MP4 and WAV.\n* **`uploadArtifacts(payload, recordingDir, flacPath)`**:\n * Iterates through candidates (`output.mp4`, `output.wav`, `output_16k.flac`, `speaker_separation.log`).\n * Uses `gcloud storage cp` (via `gsutilCopy` function) to upload files.\n * Uses `gcloud storage sign-url` (via `gcsSignUrl` function) to generate temporary access URLs.\n * *Note:* The function `gsutilCopy` is named for legacy reasons but executes `gcloud storage cp` to ensure Service Account credentials are respected.\n\n### Status Callbacks\n* **`postCallback(payload, body)`**: Sends a `POST` request to the meeting server's callback endpoint.\n * Includes `Authorization: Bearer` header using the token from the payload.\n * Throws an error if the HTTP response is not `2xx`.\n\n## Configuration\n\nThe worker relies on the following environment variables:\n\n| Variable | Default | Description |\n| :--- | :--- | :--- |\n| `DATABASE_URL` | - | Postgres connection string. |\n| `GCS_RECORDINGS_BUCKET` | `harakat-recordings-eu` | GCS bucket name for recordings. |\n| `GCS_SIGNED_URL_TTL_SECONDS` | `604800` | Duration of signed URLs (7 days). |\n| `POLL_INTERVAL_MS` | `5000` | Time between queue polls. |\n| `BOT_DIR` | `/opt/bot` | Path to the upstream bot directory. |\n| `RECORDINGS_DIR` | `/opt/bot/recordings` | Local directory for bot artifacts. |\n| `GCS_BUCKET_REGION` | `europe-west1` | Region for GCS signed URL generation. |\n| `RESOLUTION` | `1080` | Resolution for Xvfb (1080 or 720). |\n\n## Reliability & Error Handling\n\n### State Cleanup\nThe upstream bot assumes a fresh container per run. To reuse the worker container, the `/start.sh` script includes a cleanup phase:\n* Kills lingering `pulseaudio`, `Xvfb`, `x11vnc`, `unclutter`, and `ffmpeg` processes.\n* Removes stale lock files (`/tmp/.X99-lock`, etc.).\n* Re-initializes the virtual display and audio sink (`virtual_speaker.monitor`).\n\n### Timeout Handling\n* **Hard Timeout:** If the bot process exceeds `BOT_HARD_TIMEOUT_MS`, the worker sends `SIGKILL` and marks the job as failed.\n* **Artifact Validation:** If `output.mp4` is missing or smaller than 1KB, the job is marked as failed immediately, preventing a false `recorded` status.\n\n### Graceful Shutdown\nThe worker listens for `SIGINT` and `SIGTERM`. Upon receipt, it sets a `_shutdown` flag, which breaks the polling loop and exits cleanly.\n\n## Scaling\n\nTo increase throughput, scale the number of worker containers. Since the worker is single-threaded regarding job execution (one job per container), scaling horizontally is the primary method to handle concurrent meetings.\n\n```bash\ndocker compose up --scale meeting-bot-worker=4\n```\n\n## Troubleshooting\n\n* **`virtual_speaker.monitor unavailable`**: Check the `/start.sh` cleanup logic. If the previous job crashed before killing PulseAudio, the new job may fail to load the virtual sink. The script includes a retry loop for this specific case.\n* **`output.mp4 is suspiciously small`**: The bot may have exited before recording started (e.g., bad meeting URL, network issue). Check the bot logs in the container output.\n* **GCS Upload Failures**: Ensure the Service Account key mounted at `$GOOGLE_APPLICATION_CREDENTIALS` has `storage.objects.create` and `storage.objects.get` permissions. The worker uses `gcloud storage cp` to ensure credentials are active.","overview":"# Harakat — Wiki\n\n\n\n# Harakat Platform\n\nWelcome to the **Harakat** repository. This monorepo unifies a polyglot microservices stack designed for enterprise resource planning (ERP), AI orchestration, and multi-tenant project management. The platform bridges high-level API requests with specialized agent workspaces, LLM inference backends, and data processing pipelines, all governed by a central control plane.\n\n## Architecture Overview\n\nThe system is organized into distinct layers: **Control & Infrastructure**, **Frontend Applications**, **Backend Services**, and **Knowledge Management**. Traffic enters through the deployment stack, is routed by the control plane, and processed by specialized microservices.\n\n```mermaid\ngraph TD\n subgraph Control\n Root\n end\n subgraph Infra\n deploy\n end\n subgraph Frontend\n StartupsPlatform\n Harakat_Office\n HarakatMobile\n end\n subgraph Backend\n Harakat_AI\n Harakat_Kernel\n HarakatOffices_Server\n erp-harakat-backend\n end\n subgraph Knowledge\n docs\n end\n\n Root --> deploy\n deploy --> StartupsPlatform\n deploy --> Harakat_Office\n deploy --> HarakatMobile\n deploy --> Harakat_AI\n deploy --> Harakat_Kernel\n deploy --> HarakatOffices_Server\n deploy --> erp-harakat-backend\n StartupsPlatform --> Harakat_AI\n StartupsPlatform --> Harakat_Kernel\n Harakat_AI --> Harakat_Kernel\n Harakat_Office --> HarakatOffices_Server\n docs --> HarakatOffices_Server\n```\n\n## Core Modules\n\n### Control & Infrastructure\nThe **Root** module serves as the central control plane, establishing binding rules for contributors and defining the runtime environment. It unifies development policies and infrastructure orchestration. The **deploy** module manages the infrastructure stack, including secure identity, network routing (via `nginx`), and encryption across production and local environments.\n\n### Frontend Applications\n* **StartupsPlatform**: The primary Next.js 15 standalone application serving as the main interface. It handles presentation, logic, and internationalization (`next-intl`).\n* **Harakat_Office**: A multi-tenant project management cockpit built on Next.js 15, featuring 2FA authentication and comprehensive project tracking.\n* **HarakatMobile**: The Expo React Native client application, serving as the entry point for user interaction, authentication, and offline capabilities.\n\n### Backend Services\n* **Harakat_AI**: The central orchestration layer for the AI runtime. It manages task execution, agent logic, and knowledge ingestion, bridging API requests with specialized agent workspaces.\n* **Harakat_Kernel**: A Rust-based application framework serving as the backend for the ERP system. It operates on a \"kernel-first\" architecture where business logic is compiled into Rust crates.\n* **HarakatOffices_Server**: The backend infrastructure for the HarakatOffices application, orchestrating core business logic, tenant data management, and operational maintenance.\n* **erp-harakat-backend**: Defines the runtime environment for the Odoo 19 ERP application, encapsulating the server, dependencies, and API exposure.\n\n### Knowledge & Operations\nThe **docs** module serves as the central knowledge repository, bridging infrastructure planning and developer resources. It defines the lifecycle of the `HarakatOffices_Server` environment, from hardware capacity estimation to security conformance.\n\n## Key System Flows\n\n### AI Task Execution\nIncoming tasks are routed through the **StartupsPlatform** to the **Harakat_AI** module. The AI engine manages the lifecycle of task execution, routing requests to specific agent workspaces via `WorkspaceManager` and interacting with LLM inference backends.\n\n### ERP Localization\nThe platform supports bilingual content (English/Arabic). Localization flows originate from the **erp-harakat-backend** and **StartupsPlatform**, utilizing shared logic to resolve app configurations and split bilingual labels dynamically.\n\n### Deployment & Security\nAll services are provisioned through the **deploy** module. Traffic enters through `deploy/nginx`, which acts as the reverse proxy and load balancer. Identities are verified, and data is encrypted at rest to prevent configuration drift between development and production.\n\n## Getting Started\n\n1. **Review Policies**: Read the `AGENTS.md` file in the **Root** module to understand development policies and infrastructure orchestration rules.\n2. **Infrastructure Setup**: Configure your local environment using the **deploy** module's Docker build process to ensure services are provisioned correctly.\n3. **Documentation**: Refer to the **docs** module for operational execution details and developer resources.\n\nFor detailed implementation guides, navigate to the specific module pages linked above.","root-agents-md":"# Root — AGENTS.md\n\n\n\n# Root — AGENTS.md\n\n## Overview\n\n`AGENTS.md` serves as the primary instruction set and operational policy for the Harakat meta-repo. It is auto-read by `codex CLI` sessions and provided to `Claude` sessions via `CLAUDE.md`. This file defines the binding rules for Git operations, session management, code intelligence usage, and commit discipline.\n\nUnlike executable code modules, this file contains no internal execution logic. It acts as a static configuration and policy document that enforces a specific workflow for human and AI contributors.\n\n## Technical Nature\n\n* **Type:** Static Markdown Configuration File.\n* **Execution:** No internal calls, outgoing calls, or execution flows.\n* **Dependency:** Relies on external scripts (`bash scripts/...`) and the GitNexus MCP toolset.\n* **Indexing:** Indexed by GitNexus as **Harakat** (72412 symbols, 166071 relationships, 300 execution flows).\n\n## Operational Protocols\n\n### Git & Session Discipline\nThe file enforces a strict worktree-per-feature protocol to prevent concurrent session conflicts.\n\n* **Branching:** One feature = one branch = one worktree = one session.\n* **Primary Checkout:** The primary checkout must remain on `main`.\n* **Session Creation:** Use `bash scripts/new-feature.sh <branch>` to initialize a new session.\n* **Prohibited Commands:** The following Git commands are strictly forbidden:\n * `git stash`\n * `git clean`\n * `git restore`\n * `git reset --hard`\n * `git checkout` with a pathspec\n* **Recovery:** If work appears lost, stop immediately and use `reflog`, `fsck`, or snapshots.\n\n### Live Stack & Submodules\n* **Stack Locking:** Live verification (service restarts, testpipe, tenant-19 mutations) requires claiming a lock via `bash scripts/stack-lock.sh claim <name>`.\n* **Push Order:**\n 1. Submodule commit\n 2. Submodule push\n 3. Meta pointer commit\n 4. Meta push\n* **Validation:** `bash scripts/check-submodule-pins.sh` must pass before any meta push.\n\n### Commit Discipline\n* **WIP Snapshots:** Never end a session with uncommitted work. Use `wip:` snapshots, filtering out `.env*`, `*.log`, and token files from the staged list.\n* **Tested Commits:** A non-`wip:` commit requires the repo's test gate to be green in the session.\n* **Exceptions:** If tests cannot cover a change, the owner must provide explicit go-ahead. The decision must be recorded in the commit body.\n* **CI Failure:** Red CI on `main` = stop the line immediately.\n\n## GitNexus Integration\n\nThis module mandates the use of GitNexus MCP tools for all code modifications. These tools provide code intelligence, impact analysis, and safety checks.\n\n### Required Tool Usage\n\n| Tool | Purpose | Usage Pattern |\n|------|---------|---------------|\n| `impact` | Assess blast radius before editing | `impact({target: \"symbolName\", direction: \"upstream\"})` |\n| `detect_changes` | Verify scope before committing | `detect_changes({scope: \"compare\", base_ref: \"main\"})` |\n| `query` | Find execution flows by concept | `query({search_query: \"concept\"})` |\n| `context` | Get full symbol context (callers/callees) | `context({name: \"symbolName\"})` |\n| `explain` | Security review (taint findings) | `explain({target: \"fileOrSymbol\"})` |\n\n### Safety Rules\n* **MUST** run `impact` before editing any symbol. Report the blast radius (direct callers, affected processes, risk level) to the user.\n* **MUST** run `detect_changes()` before committing.\n* **MUST** warn the user if `impact` returns HIGH or CRITICAL risk.\n* **NEVER** rename symbols with find-and-replace. Use the `rename` tool which understands the call graph.\n* **NEVER** ignore HIGH or CRITICAL risk warnings from impact analysis.\n\n## Workflow\n\nThe following diagram illustrates the enforced workflow for modifying code within this repository.\n\n```mermaid\nflowchart TD\n A[Start Session] --> B{GitNexus Impact Analysis}\n B -- HIGH_CRITICAL[\"HIGH/CRITICAL\"] Risk --> C[Stop & Warn User]\n B -- Safe --> D[Edit Code]\n D --> E{Run detect_changes}\n E -- Unexpected Scope --> F[Revert/Adjust]\n E -- Expected Scope --> G[Commit]\n G --> H{CI Gate Green?}\n H -- No --> I[Stop Line]\n H -- Yes --> J[Push Order: Submodule -> Meta]\n J --> K[End Session]\n C --> L[Cleanup Transient Exhaust]\n F --> B\n I --> L\n```\n\n## Resources\n\n### GitNexus Index\n* **Overview:** `gitnexus://repo/Harakat/context`\n* **Clusters:** `gitnexus://repo/Harakat/clusters`\n* **Processes:** `gitnexus://repo/Harakat/processes`\n* **Process Trace:** `gitnexus://repo/Harakat/process/{name}`\n\n### Skill Files\n* **Exploring:** `.claude/skills/gitnexus/gitnexus-exploring/SKILL.md`\n* **Impact Analysis:** `.claude/skills/gitnexus/gitnexus-impact-analysis/SKILL.md`\n* **Debugging:** `.claude/skills/gitnexus/gitnexus-debugging/SKILL.md`\n* **Refactoring:** `.claude/skills/gitnexus/gitnexus-refactoring/SKILL.md`\n* **Guide:** `.claude/skills/gitnexus/gitnexus-guide/SKILL.md`\n* **CLI:** `.claude/skills/gitnexus/gitnexus-cli/SKILL.md`\n\n### Related Documentation\n* **Git Rules:** `docs/git-rules.md` (Binding for branching, worktree protocol, commit discipline).\n* **Architecture:** `CLAUDE.md` (Coding conventions).\n* **Workspace:** `WORKSPACE.md` (Folder definitions).\n\n## Maintenance\n\n* **Index Freshness:** If the GitNexus index is stale, run `node .gitnexus/run.cjs analyze` from the project root.\n* **Fallback:** If `.gitnexus/run.cjs` is missing, use `npx gitnexus analyze` (requires npm 11+; see #1939 for npm crash workaround).","root-deployment-md":"# Root — DEPLOYMENT.md\n\n\n\n# Harakat — Production Deployment Module\n\n## Overview\n\nThis module defines the infrastructure configuration, deployment procedures, and operational workflows for the Harakat platform. It orchestrates a multi-service architecture running on a single Google Cloud VM instance using Docker Compose. The deployment ensures isolation between services (Backend, AI, Frontends, Database) while maintaining a unified entry point via Nginx.\n\n## System Architecture\n\nThe platform utilizes a containerized microservices approach. All services communicate over an internal Docker network, while external traffic is routed through an Nginx reverse proxy.\n\n### Traffic Flow\n\n```mermaid\nflowchart TD\n Client[Client Browser] -->|HTTPS| Nginx[Nginx (443/80)]\n Nginx -->|Route: /api/*| API[Backend API (5000)]\n Nginx -->|Route: /api/ai/*| AI[AI Service (8000)]\n Nginx -->|Route: /app/*| Startups[Startups Platform (3000)]\n Nginx -->|Route: /admin/*| Admin[Admin Panel (3000)]\n Nginx -->|Route: /| Landing[Landing Site (3000)]\n API -->|DB Connection| DB[(PostgreSQL 5432)]\n AI -->|Backend API| API\n Startups -->|Backend API| API\n Admin -->|Backend API| API\n```\n\n### Service Components\n\n| Service | Container Name | Port | Responsibility |\n| :--- | :--- | :--- | :--- |\n| **Nginx** | `harakat_nginx` | 80, 443 | SSL termination, reverse proxy, routing |\n| **Backend** | `harakat_server` | 5000 | Core business logic, API endpoints |\n| **AI** | `harakat_ai` | 8000 | LLM inference, AI processing |\n| **Startups** | `harakat_startups` | 3000 | Startup platform frontend (Next.js) |\n| **Admin** | `harakat_admin` | 3000 | Admin dashboard frontend (Next.js) |\n| **Landing** | `harakat_landing` | 3000 | Public landing page (Next.js) |\n| **Database** | `harakat_db` | 5432 | PostgreSQL persistence layer |\n| **Certbot** | `certbot` | N/A | SSL certificate management |\n\n## Prerequisites\n\nBefore initiating the deployment module, ensure the following environment is prepared:\n\n- **Infrastructure:** Google Cloud VM instance (Ubuntu 22.04+ or Debian 12+).\n- **Resources:** Minimum 4 vCPU and 16 GB RAM.\n- **Networking:** Domain `harakat.tech` with DNS A records pointing to the VM's external IP.\n - `harakat.tech`\n - `app.harakat.tech`\n - `admin.harakat.tech`\n - `api.harakat.tech`\n- **Tools:** Docker, Docker Compose plugin, Git, SSH client.\n\n## Configuration Management\n\nThe deployment relies on environment variables defined in `.env` files within each service repository.\n\n### Environment Variable Hierarchy\n\n1. **`.env`**: Production values (committed to repository).\n2. **`.env.local`**: Local overrides (gitignored).\n3. **`docker-compose.yml`**: Internal service overrides (e.g., service-to-service URLs).\n\n### Critical Configuration Files\n\n- **`HarakatOffices_Server/.env`**:\n - `POSTGRES_USER`, `POSTGRES_PASSWORD`, `POSTGRES_DB`\n - `HARAKAT_AI_URL` (Overridden by Docker Compose to `http://ai:8000`)\n- **`Harakat_AI/.env`**:\n - LLM provider keys, `HARAKAT_API_URL` (Overridden to `http://server:5000`)\n- **`StartupsPlatform/.env`**:\n - `NEXT_PUBLIC_API_URL`, `NEXT_PUBLIC_LANDING_URL`\n- **`Harakat_Admin/.env`**:\n - `NEXT_PUBLIC_API_URL`\n- **`Harakat_Landing/.env`**:\n - `NEXT_PUBLIC_API_URL`, Zoho SMTP credentials\n\n### Secret Generation\n\nGenerate secure secrets before deployment:\n\n```bash\n# JWT Secret (64 hex chars)\nnode -e \"console.log(require('crypto').randomBytes(64).toString('hex'))\"\n\n# DB Password (Base64)\nopenssl rand -base64 24\n\n# AI ↔ Backend API Key (32 hex chars)\nnode -e \"console.log(require('crypto').randomBytes(32).toString('hex'))\"\n```\n\n## Deployment Workflow\n\n### 1. VM Initialization\n\nSSH into the target VM and install the container runtime:\n\n```bash\ngcloud compute ssh harakat-vm --zone=<ZONE>\nsudo apt update && sudo apt upgrade -y\ncurl -fsSL https://get.docker.com | sh\nsudo usermod -aG docker $USER\nnewgrp docker\nsudo apt install docker-compose-plugin -y\n```\n\n### 2. Repository Cloning\n\nClone the main repository, ensuring all submodules are initialized:\n\n```bash\ncd /opt\nsudo mkdir harakat && sudo chown $USER:$USER harakat\ncd harakat\ngit clone --recurse-submodules <YOUR_REPO_URL> .\n# If already cloned:\ngit submodule update --init --recursive\n```\n\n### 3. SSL Certificate Provisioning\n\nNginx requires SSL certificates. Certbot is run in a temporary container to avoid conflicts with the main stack.\n\n1. **Disable HTTPS config temporarily:**\n ```bash\n mv deploy/nginx/conf.d/01-https.conf deploy/nginx/conf.d/01-https.conf.disabled\n ```\n2. **Start Nginx (HTTP only):**\n ```bash\n docker compose up -d nginx\n ```\n3. **Request Certificates:**\n ```bash\n docker compose run --rm certbot certonly \\\n --webroot --webroot-path=/var/www/certbot \\\n --email admin@harakat.tech --agree-tos --no-eff-email \\\n -d harakat.tech -d www.harakat.tech -d app.harakat.tech \\\n -d admin.harakat.tech -d api.harakat.tech\n ```\n4. **Re-enable HTTPS config:**\n ```bash\n mv deploy/nginx/conf.d/01-https.conf.disabled deploy/nginx/conf.d/01-https.conf\n docker compose down\n ```\n\n### 4. Service Deployment\n\nBuild and start the container stack:\n\n```bash\ndocker compose build\ndocker compose up -d\ndocker compose ps\n```\n\n### 5. Database Initialization\n\nRun migrations and seed the initial admin user:\n\n```bash\ndocker compose exec server npx prisma migrate deploy\ndocker compose exec server node dist/scripts/seed-admin.js\n```\n\n## Operational Maintenance\n\n### Rebuilding Services\n\nTo rebuild a specific service without restarting the entire stack:\n\n```bash\ndocker compose build <service_name>\ndocker compose up -d <service_name>\n```\n\n### Log Management\n\nMonitor service health via Docker Compose logs:\n\n```bash\ndocker compose logs server -f --tail=100\ndocker compose logs ai -f --tail=100\n```\n\n### Database Operations\n\n**Backup:**\n```bash\ndocker compose exec db pg_dump -U harakat harakatoffices_db > backup_$(date +%Y%m%d).sql\n```\n\n**Restore:**\n```bash\ncat backup_YYYYMMDD.sql | docker compose exec -T db psql -U harakat harakatoffices_db\n```\n\n### SSL Renewal\n\nCertbot handles auto-renewal, but manual intervention is required if needed:\n\n```bash\ndocker compose run --rm certbot renew\ndocker compose exec nginx nginx -s reload\n```\n\n### Updates\n\nTo update the codebase:\n\n```bash\ncd /opt/harakat\ngit pull\ngit submodule update --init --recursive\ndocker compose build\ndocker compose up -d\n```\n\n## Troubleshooting\n\n| Issue | Diagnostic Command | Resolution |\n| :--- | :--- | :--- |\n| **Container Restarting** | `docker compose logs <service>` | Check for startup errors or resource limits. |\n| **CORS Errors** | Check `HarakatOffices_Server/.env` | Ensure `ALLOWED_ORIGINS` matches domain exactly. |\n| **502 Bad Gateway** | `docker compose ps` | Verify container is running and healthy. |\n| **SSL Expired** | `docker compose run --rm certbot renew` | Renew cert and reload Nginx. |\n| **DB Connection Refused** | `docker compose ps` | Ensure `db` container is up and ports are open. |\n| **Next.js Build Fail** | Check `next.config.mjs` | Ensure `output: 'standalone'` is set. |\n| **PostHog Not Tracking** | Check Build Args | Set `NEXT_PUBLIC_POSTHOG_KEY` as a build arg. |\n\n## Resource Limits\n\nTo prevent resource exhaustion on the VM, apply memory and CPU limits in `docker-compose.yml`:\n\n```yaml\nservices:\n db:\n deploy:\n resources:\n limits:\n memory: 2G\n cpus: \"1\"\n server:\n deploy:\n resources:\n limits:\n memory: 512M\n cpus: \"2\"\n ai:\n deploy:\n resources:\n limits:\n memory: 4G\n cpus: \"1.5\"\n startups:\n deploy:\n resources:\n limits:\n memory: 1G\n cpus: \"0.75\"\n admin:\n deploy:\n resources:\n limits:\n memory: 512M\n cpus: \"0.25\"\n landing:\n deploy:\n resources:\n limits:\n memory: 512M\n cpus: \"0.25\"\n office:\n deploy:\n resources:\n limits:\n memory: 512M\n cpus: \"0.25\"\n```\n\n## Verification Checklist\n\nAfter deployment, verify the following endpoints:\n\n- `curl https://api.harakat.tech/health` (Expected: OK)\n- `curl -I https://harakat.tech` (Expected: 200)\n- `curl -I https://app.harakat.tech` (Expected: 200)\n- `curl -I https://admin.harakat.tech` (Expected: 200)\n\nAccess the admin panel at `https://admin.harakat.tech` using credentials defined in `ADMIN_EMAIL` and `ADMIN_PASSWORD` within the `.env` file.","root-docker-compose-yml":"# Root — docker-compose.yml\n\n\n\n# Root — docker-compose.yml\n\nThis module defines the production orchestration layer for the Harakat platform. It manages the lifecycle of infrastructure services, application containers, and security components required for the system to operate.\n\n## Overview\n\nThe compose file orchestrates a polyglot stack including Node.js, Python, Go, and Rust-based services. It enforces strict security boundaries via SPIRE (identity), OpenBao (KMS), and OpenFGA (authorization).\n\nKey architectural principles enforced here:\n* **Identity-First:** Application containers (`server`, `ai`) must receive valid SPIFFE SVIDs before booting.\n* **Secret Management:** Critical secrets (e.g., `AI_HOP_SIGNING_SECRET`) are validated at compose startup via `${VAR:?}` interpolation.\n* **Network Isolation:** Platform services run on `harakat-net`; tenant relays run on `rooms-net`.\n* **Graceful Shutdown:** All long-running services use a unified `SHUTDOWN_GRACE_SECONDS` variable to prevent mid-drain kills.\n\n## Architecture Topology\n\nThe stack is divided into logical layers. The following diagram illustrates the primary service relationships and network boundaries.\n\n```mermaid\nflowchart TD\n subgraph \"Identity & Security (P1)\"\n SPIRE[SPIRE Server/Agent]\n SVID_SVR[SPIRE SVID Sidecar (Server)]\n SVID_AI[SPIRE SVID Sidecar (AI)]\n OPENBAO[OpenBao KMS]\n OPENFGA[OpenFGA AuthZ]\n end\n\n subgraph \"Data & Infrastructure\"\n DB[(Postgres: Main)]\n REDIS[Redis: Queues]\n MEILI[Meilisearch: FTS]\n QDRANT[Qdrant: Vectors]\n ERP_DB[(Postgres: Odoo)]\n end\n\n subgraph \"Application Logic\"\n SERVER[API Server]\n AI[AI Service]\n WORKER[BullMQ Worker]\n MEETING[Meeting Workers]\n end\n\n subgraph \"Frontend & Proxy\"\n NGINX[Nginx Proxy]\n STARTUPS[Startups Platform]\n ADMIN[Admin Panel]\n LANDING[Landing Page]\n end\n\n subgraph \"External / Tenant\"\n ROOMS[Rooms Relays]\n GCS[Google Cloud Storage]\n VAST[Vast.ai GPU]\n end\n\n SPIRE --> SVID_SVR\n SPIRE --> SVID_AI\n SVID_SVR --> SERVER\n SVID_AI --> AI\n SERVER --> DB\n SERVER --> REDIS\n SERVER --> MEILI\n SERVER --> OPENFGA\n SERVER --> OPENBAO\n SERVER --> NGINX\n SERVER --> AI\n AI --> DB\n AI --> REDIS\n WORKER --> DB\n WORKER --> REDIS\n WORKER --> QDRANT\n MEETING --> GCS\n MEETING --> VAST\n NGINX --> STARTUPS\n NGINX --> ADMIN\n NGINX --> LANDING\n SERVER -.->|rooms-net| ROOMS\n```\n\n## Core Infrastructure Services\n\n### Database Layer\n* **`db`**: Primary PostgreSQL 16 instance for tenant data.\n * **Volume**: `pgdata` (persistent).\n * **Network**: `harakat-net`.\n * **Healthcheck**: `pg_isready`.\n* **`openfga-db`**: Dedicated PostgreSQL instance for OpenFGA authorization data.\n * **Isolation**: Never co-mingled with `harakat_db`.\n * **Migration**: `openfga-migrate` runs once to seed the schema.\n* **`erp_db`**: Dedicated PostgreSQL instance for Odoo 19 ERP.\n * **Port**: Exposed on `127.0.0.1:5434` only.\n\n### Caching & Queues\n* **`redis`**: Redis 7 for BullMQ job queues.\n * **Persistence**: Disabled (in-memory). State is recoverable from Postgres (`KnowledgeNode` + `DocumentIndex`).\n * **Security**: Bound to `127.0.0.1:6379` (internal only).\n * **Memory**: Limited to 512MB with `noeviction` policy.\n\n### Search & Vector Stores\n* **`meilisearch`**: Full-text search (vectorless).\n * **Version**: Pinned to `v1.10`.\n * **Security**: Bound to `127.0.0.1:7700`.\n * **Data**: Stored in `meili_data`.\n* **`qdrant`**: Vector store for P2 meaning-search (ANN).\n * **Isolation**: Per-tenant collections (`startup_<id>`).\n * **Limits**: `nofile` ulimits raised to 65536 to prevent \"Too many open files\" panics.\n * **Healthcheck**: Uses binary `--version` (no `wget` in image).\n\n## Identity & Security (P1)\n\n### SPIRE (Service Identity)\nThe platform uses SPIRE for mutual TLS and workload attestation.\n1. **`spire-server`**: CA and trust root. Stores X.509/JWT SVIDs.\n2. **`spire-agent`**: Attests workloads via Docker labels (`com.harakat.workload`).\n3. **`spire-svid-server` / `spire-svid-ai`**: Sidecars that fetch and mount SVIDs (`svid.jwt`, `bundle.jwks`) to the application volumes.\n * **Mechanism**: Sidecars listen on `spire_agent_socket` and write to `svid_server` or `svid_ai` volumes.\n * **Enforcement**: `server` and `ai` services depend on these sidecars being healthy before starting.\n\n### OpenBao (KMS)\n* **`openbao`**: Self-hosted KMS for Transit Envelope Encryption.\n * **Usage**: Server wraps/unwrap data-encryption keys just-in-time.\n * **Storage**: `openbao_data` volume.\n * **Security**: Bound to `127.0.0.1:8200`.\n\n### OpenFGA (Authorization)\n* **`openfga`**: Node-graph authorization model (humans/agents/docs).\n * **Model**: Replaces flat tier-letter comparison with org-tree ancestry.\n * **Performance**: Read path measured at single-digit ms p50.\n\n## Application Services\n\n### Backend API (`server`)\n* **Role**: Main HTTP API, business logic, and orchestration.\n* **Graceful Shutdown**: Configured via `stop_grace_period` (defaults to 150s). This value is propagated to `SHUTDOWN_GRACE_SECONDS` in the environment to ensure `core/lifecycle` drains connections before Docker kills the process.\n* **Dependencies**:\n * `db`, `redis`, `meilisearch` (must be healthy).\n * `spire-svid-server` (must be healthy for identity).\n* **Secrets**:\n * `AI_HOP_SIGNING_SECRET`: Required for Server→AI hop signing. Compose fails if unset.\n * `AGENT_CAPABILITY_ENFORCEMENT`: Defaults to `on`.\n* **Networking**:\n * Exposes `5000` internally.\n * Joins `rooms-net` to reach tenant relays.\n\n### AI Service (`ai`)\n* **Role**: AI inference and processing (Python/Uvicorn).\n* **Graceful Shutdown**: Matches `server` (`SHUTDOWN_GRACE_SECONDS`).\n* **Replay Defense**: `AI_HOP_DEDUPE_PATH` (`/var/harakat/source-auth/replay.db`) stores replay claims on a volume to survive container recreation.\n* **Identity**: Receives SVID from `spire-svid-ai`.\n* **Dependencies**:\n * `server` (must be started).\n * `spire-svid-ai` (must be healthy).\n\n### Workers (`worker`)\n* **Role**: BullMQ background jobs (drive-download, parse-extract, archive-extract).\n* **Docker Socket**: Mounts `/var/run/docker.sock` to spawn `archive-sandbox` containers.\n * **Security**: Only the `worker` service mounts this socket.\n* **Shared Volumes**:\n * `sandbox_work`: Scratch space for archive extraction.\n * `parse_staging`: Shared read-only path for AI to access parsed files (Phase 4 streaming boundary).\n* **Shutdown**: Uses `stop_grace_period` to prevent job loss during redeploy.\n\n### Meeting Workers\n* **`meeting-bot-worker`**: Records meetings, uploads to GCS.\n * **DB Access**: Connects to host DB via `host.docker.internal:5433` (bypassing `harakat-net` DB).\n * **Resources**: 4GB RAM, 2 CPUs.\n* **`meeting-transcript-worker`**: Transcribes audio (Whisper/Vertex).\n * **GPU**: Rents Vast.ai GPU per batch.\n * **SSH**: Mounts SSH key for Vast tunneling.\n\n## Frontend & Proxy\n\n* **`nginx`**: Reverse proxy for all public traffic (80/443).\n * **Config**: `deploy/nginx/nginx.conf`.\n * **Dependencies**: Waits for `server`, `ai`, `startups`, `admin`, `landing`.\n* **`certbot`**: Auto-renews SSL certificates.\n* **`startups` / `admin` / `landing`**: Next.js applications.\n * **Exposure**: Exposed internally on port 3000; routed via Nginx.\n\n## Operational Considerations\n\n### Environment Variables\n* **Meta-Repo `.env`**: The primary source of truth. Compose interpolates variables from the `.env` file located beside this file.\n* **Fail-Fast**: Required variables (e.g., `AI_HOP_SIGNING_SECRET`, `MEILI_MASTER_KEY`) use `${VAR:?}` syntax. If missing, `docker compose up` aborts immediately.\n* **Service `.env`**: Services like `server` and `ai` read from their respective submodules (e.g., `./HarakatOffices_Server/.env`).\n\n### Networking\n* **`harakat-net`**: Internal network for platform services.\n* **`rooms-net`**: External network for tenant relays.\n * **Isolation**: Tenant relays join `rooms-net` but cannot resolve `harakat-net` services (e.g., `db`, `redis`).\n* **`host.docker.internal`**: Used by `meeting-bot-worker` and `meeting-transcript-worker` to reach the host-exposed Postgres port (5433) and the natively-run server (5000).\n\n### Volumes\n* **Durable**: `pgdata`, `meili_data`, `openbao_data`, `qdrant_data`, `spire_*`, `source_auth_replay`.\n* **Scratch**: `sandbox_work`, `parse_staging` (transient).\n* **Secrets**: `gcp-recordings-sa.json` mounted read-only to workers.\n\n### Graceful Shutdown Logic\nThe `stop_grace_period` is critical for long-running AI turns.\n1. **Variable**: `SHUTDOWN_GRACE_SECONDS` (default 150).\n2. **Propagation**:\n * `server`: `stop_grace_period` in compose.\n * `server`: `SHUTDOWN_GRACE_SECONDS` in env (read by `core/lifecycle`).\n * `ai`: `stop_grace_period` in compose.\n * `ai`: `--timeout-graceful-shutdown` in Dockerfile (derived from env).\n3. **Result**: Docker waits for the process to drain before sending SIGKILL.\n\n## Deployment\n\n1. **Prerequisites**:\n * Copy `.env.example` to `.env` and provision secrets (e.g., `AI_HOP_SIGNING_SECRET`).\n * Ensure `SPIRE_JOIN_TOKEN` is set for the first boot.\n2. **Start**:\n ```bash\n docker compose up -d\n ```\n3. **Build from Source**:\n * Meilisearch: `docker compose --profile build-meili-from-source up`\n * Archive Sandbox: `docker compose build archive-sandbox`\n4. **Scale**:\n * Meeting Workers: `docker compose up -d --scale meeting-bot-worker=N`\n * Transcription Workers: `docker compose up -d --scale meeting-transcript-worker=N`","root-harakat-code-workspace":"# Root — Harakat.code-workspace\n\n\n\n# Harakat.code-workspace\n\n## Overview\n`Harakat.code-workspace` is a Visual Studio Code workspace configuration file. It serves as the entry point for defining the project environment within the editor. This module is a static JSON artifact and does not contain executable logic, functions, or classes. Its primary purpose is to establish the workspace root and configure editor settings for the Harakat project.\n\n## Configuration Schema\nThe file structure follows the standard VS Code workspace schema. It defines two key properties:\n\n* **`folders`**: An array specifying the workspace folders.\n * `path`: Defines the root directory. The current configuration sets this to `.` (the directory containing the workspace file).\n* **`settings`**: An object for workspace-level settings.\n * The current configuration is an empty object `{}`, meaning no specific workspace overrides are active.\n\n## Execution Context\nThis module operates outside the standard application execution flow. It is not invoked by runtime code but is parsed by the VS Code extension host during the workspace initialization phase.\n\n* **Incoming Calls**: None. No other modules call functions within this file.\n* **Outgoing Calls**: None. This file does not import or reference other code modules.\n* **Internal Logic**: None. There are no functions, classes, or control flow statements.\n\nThe file is processed by the VS Code engine to determine the project boundaries and apply configuration values to the active editor instance.\n\n## Architecture\nThe following diagram illustrates the relationship between the workspace configuration and the VS Code environment.\n\n```mermaid\ngraph TD\n A[VS Code Extension Host] -->|Parses| B_Harakat_code-workspace[\"B(Harakat.code-workspace)\"]\n B -->|Defines Root| C[Project Directory .]\n B -->|Applies| D[Workspace Settings]\n D -->|Configures| E[Editor Instance]\n```\n\n## Maintenance\n* **Root Changes**: If the project structure moves, update the `folders[0].path` value to reflect the new relative path.\n* **Settings**: To enforce specific editor behaviors across the workspace, populate the `settings` object with valid VS Code configuration keys.","root-lifecycle-recordings-90d-json":"# Root — lifecycle-recordings-90d.json\n\n\n\n# Root — lifecycle-recordings-90d.json\n\n## Overview\n\nThe `lifecycle-recordings-90d.json` file is a configuration module located within the `Root` directory. It defines a lifecycle management policy for media recordings. This module instructs the system to automatically purge recordings that exceed a specific age threshold, ensuring storage compliance and data hygiene without requiring manual intervention.\n\n## Configuration Schema\n\nThe module consists of a single JSON object containing a `rule` array. Each rule object defines the criteria for evaluation and the subsequent action to take.\n\n```json\n{\n \"rule\": [\n {\n \"action\": { \"type\": \"Delete\" },\n \"condition\": { \"age\": 90 }\n }\n ]\n}\n```\n\n### Key Fields\n\n* **`rule`**: An array of policy objects. This module currently defines a single rule.\n* **`action`**: Specifies the operation to perform when the condition is met.\n * **`type`**: Set to `\"Delete\"`. This triggers the removal of the target resource from the system.\n* **`condition`**: Defines the criteria for triggering the action.\n * **`age`**: Set to `90`. This represents the retention period in days.\n\n## Execution Logic\n\nAlthough this module is a static configuration file and does not contain executable code, it drives the behavior of the lifecycle management engine. The system evaluates recordings against the defined rule as follows:\n\n1. **Evaluation**: The system checks the age of each recording.\n2. **Condition Check**: If the recording's age is greater than or equal to 90 days, the condition is satisfied.\n3. **Action Execution**: If the condition is satisfied, the `Delete` action is triggered.\n4. **Result**: The recording is permanently removed from the system.\n\n### Lifecycle Flow\n\nThe logical flow of the policy evaluation is depicted below:\n\n```mermaid\ngraph LR\n A[Recording Ingestion] --> B{Age Check}\n B -- Age < 90 Days --> C[Retain Recording]\n B -- Age >= 90 Days --> D[Trigger Delete Action]\n D --> E[Remove from Storage]\n```\n\n## Integration and Dependencies\n\nBased on the call graph and execution flow analysis:\n\n* **Internal Calls**: None. This module does not invoke other functions or methods within its own scope.\n* **Outgoing Calls**: None. This module does not make external API calls or network requests.\n* **Incoming Calls**: None. This module is not directly invoked by other code paths; it is consumed as a configuration artifact.\n\n### System Interaction\n\nThis configuration file is read by the lifecycle management service during initialization or scheduled policy refresh cycles. The service parses the `rule` array and applies the logic to the active dataset. Because there are no direct execution flows or dependencies, changes to this file take effect immediately upon the next policy evaluation cycle by the consuming service.\n\n## Maintenance\n\n* **Retention Period**: To change the retention period, modify the `age` value in the `condition` object.\n* **Action Type**: To change the behavior (e.g., to archive instead of delete), modify the `type` value in the `action` object.\n* **Multiple Rules**: To apply multiple policies, add additional objects to the `rule` array.","root-workspace-md":"# Root — WORKSPACE.md\n\n\n\n# Root Workspace Map\n\n## Overview\n\nThis document serves as the structural reference for the Harakat monorepo. It defines the purpose of every folder, the location of tests, and the layout of the Docker infrastructure.\n\n**Note:** This file is static documentation. It contains no executable logic, internal calls, or outgoing/incoming API calls. For architecture rules and coding standards, refer to [CLAUDE.md](CLAUDE.md).\n\n**Last Audit:** 2026-07-17\n\n## Directory Structure\n\nThe repository is organized into three primary categories: **Product Submodules**, **Vendored OSS**, and **Core Infrastructure**.\n\n```mermaid\ngraph TD\n Root[Root Workspace]\n Root --> Products[Product Submodules]\n Root --> Vendors[Vendored OSS]\n Root --> Core[Core Infrastructure]\n\n Products --> Server[HarakatOffices_Server]\n Products --> AI[Harakat_AI]\n Products --> Frontend[StartupsPlatform]\n Products --> Admin[Harakat_Admin]\n Products --> Office[Harakat_Office]\n Products --> Mobile[HarakatMobile]\n Products --> Landing[Harakat_Landing]\n\n Vendors --> Honcho[vendor/honcho]\n Vendors --> Meili[vendor/meilisearch]\n Vendors --> Bot[meet-teams-bot/]\n Vendors --> Odoo[erp-harakat-backend/odoo]\n Vendors --> PageIndex[Harakat_AI/PageIndex]\n\n Core --> Compose[docker-compose.yml]\n Core --> TestPipe[testpipe/]\n Core --> Deploy[deploy/]\n Core --> Docs[docs/]\n Core --> Archive[archive/]\n```\n\n## Git Submodules\n\nThe repository relies heavily on git submodules to manage dependencies and product code. All vendor submodules point to private forks (`AhmadYasin2/harakat-*`) rather than upstream organizations to prevent strandings from upstream rebase/branch deletes.\n\n### Product Submodules\n\n| Folder | Purpose | Notes |\n|---|---|---|\n| `HarakatOffices_Server/` | Backend source of truth. Express + Prisma. | Port 5000, `api.harakat.tech/api` |\n| `Harakat_AI/` | Stateless FastAPI agent service. | Port 8000, `api.harakat.tech/api/ai` |\n| `StartupsPlatform/` | Tenant-facing Next.js app. | `app.harakat.tech` |\n| `Harakat_Admin/` | Internal staff panel. | `admin.harakat.tech` |\n| `Harakat_Office/` | Office-tier coordinator front end. | **Registered 2026-08-06.** Previously untracked due to `.gitmodules` collision with `Harakat_Offices` (plural). |\n| `Harakat_Landing/` | Marketing site + login form. | `harakat.tech` |\n| `HarakatMobile/` | Tenant-facing mobile app (React Native / Expo). | **Registered 2026-08-03.** Gate: `npx tsc --noEmit` + `npm test` + `npm run check:rtl`. |\n\n### Vendor Submodules\n\n| Folder | Purpose | Pin/Commit |\n|---|---|---|\n| `vendor/honcho` | Fork `harakat-honcho`. | Branch `harakat-local` (v3.0.8+) |\n| `vendor/meilisearch` | Mirror `harakat-meilisearch`. | v1.10.0 (`36d8684`) |\n| `meet-teams-bot/` | Mirror `harakat-meet-teams-bot`. | Branch `harakat-main` (`7d80ef2`) |\n| `erp-harakat-backend/odoo` | Fork `harakat-odoo`. | Branch `19.0-harakat` (Odoo 19.0 snapshot) |\n| `Harakat_AI/PageIndex` | Fork-snapshot `harakat-pageindex`. | Branch `harakat-main` |\n\n## Core Infrastructure\n\n### Docker & Deployment\n\nThe production and local orchestration is managed via `docker-compose.yml`.\n\n**Key Compose Files:**\n* `docker-compose.yml`: Main stack (server, ai, frontends, `harakat_db`, `harakat_meili`, `harakat_qdrant`, `harakat_openfga`, `harakat_openbao`, spire, meeting workers).\n* `erp-harakat-backend/` compose: ERP Odoo stack (shared `harakat-erp-1` + per-tenant isolated containers).\n\n**Container Landmines:**\n* **`harakat-erp-t19-g2`**: The LIVE isolated ERP container for startup-19. Contains hotfixes (chatter gate, employee-create, partner-visibility) that are **not** in the image. A rebuild reverts them.\n* **`harakat-erp-t19-g2-preupgrade`**: Safety copy before `crm_advanced` upgrade. Do not remove until upgrade is confirmed.\n* **`erp-erp_odoo-1`**: STRAY stack on port 8069. Never use.\n* **`harakat_openbao`**: Required for corpus reads (encrypted at rest). Unseal sidecar re-unseals on restart using keys in `deploy/openbao/unseal-keys.local.*`.\n\n### Secrets & Security\n\n* **`deploy/openbao/`**: Contains unseal keys. **Gitignored.** Must be backed up off-box. Losing these orphans the encrypted corpus.\n* **`.claude/`**: Contains project settings and permission deny rules (PreToolUse hook blocks destructive git commands).\n\n### Testing & QA\n\nThe primary testing harness is located in `testpipe/`.\n\n| Path | Purpose |\n|---|---|\n| `testpipe/` | **Primary.** Live AI/agent test harness against the real stack (startup-19 as Musa). Python, run bare-metal. |\n| `testpipe/framework.py` | Core framework logic. |\n| `testpipe/harness.py` | Harness logic. |\n| `testpipe/out/` | Test output. |\n| `testpipe/logs/` | Test logs. |\n| `archive/api-testing-pipeline/` | Older Node-based scenario runner. Superseded by `testpipe/`. |\n| `.sdd-work/qa-harness-2026-06-30/` | Reusable Playwright ERP/UI harness. |\n| `StartupsPlatform/scripts/crawl-pages.cjs` | Playwright page crawler. Run against **prod build**, not dev. |\n\n**Historical Spikes:**\n* `archive/p1-spike/`: P1 access-model measurements.\n* `archive/p2-spike/`: P2 embeddings bakeoff (produced \"meaning-primary\" verdict).\n\n### Development Directories\n\n* **`.sdd-work/`**: Per-program working directories. See [.sdd-work/INDEX.md](.sdd-work/INDEX.md) for status and sizes. Handover files (`CONTINUE-*.md`) sit at the root by convention.\n* **`docs/`**: All documentation. Includes `docs/architecture/`, `docs/logs/`, `docs/next_todo.md`, `docs/security/`.\n* **`archive/`**: Graveyard for superseded work (`api-testing-pipeline/`, `p1-spike/`, `meili-migrate/`, `patches/`).\n* **`deploy/`**: Runtime config shipped with docker-compose.\n\n## Data & Dumps\n\nLarge data files are managed separately to avoid git churn.\n\n| Path | Size | Description |\n|---|---|---|\n| `C:\\Users\\LENOVO\\Desktop\\Harakat-sdd-offload-2026-07-17\\` | 7.8 GB | Offloaded 2026-07-17: all 13 `.sdd-work` pg dumps + old working dirs. |\n| `db_dumps/` | 7 MB | Oldest dumps (2026-05-26) + `backup-root-2026-04-25.sql`. |\n| `harakat-deploy-startup-19/` | 29 MB | Startup-19 deploy/restore kit. |\n\n## Local Scripts & Files\n\n* `run-local.ps1` / `run-local.cmd`: Local stack bring-up scripts.\n* `Harakat.code-workspace`: VS Code workspace file.\n* `lifecycle-recordings-90d.json`, `HarakatAICost.xlsx`: Tracked one-offs.\n* `docs/business/`: Business docs (cost model variants, persona test docs).\n\n## Execution Flow\n\nThis module (`WORKSPACE.md`) is a static documentation file. It does not contain executable logic, internal calls, or outgoing/incoming API calls. It serves as a reference for navigating the repository structure and understanding the deployment topology.","root":"# Root\n\n\n\n# Root\n\n## Overview\n\nThe **Root** module serves as the central control plane for the Harakat monorepo, unifying development policies, infrastructure orchestration, and data lifecycle management. It establishes the binding rules for human and AI contributors while defining the runtime environment for the polyglot microservices stack.\n\n## Integration & Workflow\n\nThe module group operates through a layered workflow where configuration files dictate behavior across the development and production lifecycle:\n\n* **Policy & Structure:** `AGENTS.md` acts as the primary instruction set for `codex CLI` and `Claude` sessions, enforcing Git operations and commit discipline. It relies on `WORKSPACE.md` to validate the repository layout and test locations.\n* **Local Environment:** `Harakat.code-workspace` configures the Visual Studio Code environment to align with the project root defined in `WORKSPACE.md`.\n* **Infrastructure:** `docker-compose.yml` implements the production architecture described in `DEPLOYMENT.md`. It orchestrates the polyglot stack (Node.js, Python, Go, Rust) and enforces security boundaries via SPIRE and OpenBao.\n* **Data Management:** `lifecycle-recordings-90d.json` enforces storage compliance by automatically purging media recordings exceeding the 90-day threshold within the orchestrated environment.\n\n## Architecture\n\n```mermaid\nflowchart TD\n Policy[AGENTS.md / WORKSPACE.md] -->|Defines Rules & Structure| Dev[Harakat.code-workspace]\n Dev -->|Configures Environment| Infra[docker-compose.yml]\n Infra -->|Orchestrates| Services[Backend / AI / Frontend]\n Services -->|Generates Data| Data[lifecycle-recordings-90d.json]\n Data -->|Enforces Retention| Infra\n```\n\n## Components\n\n* **[AGENTS.md](AGENTS.md)**: Operational policy and AI instruction set.\n* **[DEPLOYMENT.md](DEPLOYMENT.md)**: Infrastructure configuration and deployment procedures.\n* **[docker-compose.yml](docker-compose.yml)**: Production orchestration layer for containerized services.\n* **[WORKSPACE.md](WORKSPACE.md)**: Structural reference for the monorepo layout.\n* **[Harakat.code-workspace](Harakat.code-workspace)**: VS Code environment configuration.\n* **[lifecycle-recordings-90d.json](lifecycle-recordings-90d.json)**: Media retention policy configuration.","scripts-gpu-embed":"# scripts — gpu-embed\n\n\n\n# scripts/gpu-embed Module\n\n## Overview\n\nThe `gpu-embed` module manages GPU instances on vast.ai for running the F2LLM-v2-14B embedding model. It implements a \"money-safe\" workflow where the ledger is written before any box is used, cost ceilings are enforced as hard stops, unreachable boxes are destroyed rather than waited on, and ledger parsing errors are reported rather than silently skipped.\n\nThe module consists of three files:\n- `gpu_embed.py` - Main CLI tool with subcommands for managing GPU instances\n- `gpu_embed_selftest.py` - Self-test suite validating the four money rules\n- `onstart.sh` - Script executed on rented boxes to start vLLM\n\n## Architecture\n\n```mermaid\ngraph TD\n A[gpu_embed.py] --> B[offers]\n A --> C[create]\n A --> D[wait]\n A --> E[tunnel]\n A --> F[status]\n A --> G[destroy]\n A --> H[api calls]\n A --> I[ledger management]\n A --> J[ssh operations]\n K[gpu_embed_selftest.py] --> A\n L[onstart.sh] --> M[vLLM serve]\n```\n\n## The Four Money Rules\n\n### Rule 1: Ledger First\nThe ledger is written in the same call that creates an instance. A session that dies between \"created\" and \"recorded\" leaves a card billing with nothing on disk naming it.\n\n```python\n# In cmd_create()\nr = api(\"/asks/%d/\" % o[\"id\"], \"PUT\", {...})\ncid = r[\"new_contract\"]\nledger_append(cid, o[\"id\"], o.get(\"dph_total\") or 0)\n```\n\n### Rule 2: Ceiling Refuses\nThe `--ceiling` argument is a hard stop before any PUT. The projection is checked and exceeding the ceiling refuses.\n\n```python\nprojected = project(o.get(\"dph_total\") or 0, a.minutes)\nif projected > a.ceiling:\n raise SystemExit(\"REFUSED: projection $%.2f exceeds the ceiling $%.2f\" % (projected, a.ceiling))\n```\n\n### Rule 3: Dead Box Deadline\nEvery box gets a hard reachability deadline. Missing it means destroy, not wait. 5 of 9 boxes rented at 06:41 never accepted the account's ssh key.\n\n```python\n# In cmd_wait()\nunreachable = [i for i in want if i not in ssh_ok and i not in ready and i not in failed]\nif unreachable and (time.time() - t0) / 60 >= a.ssh_deadline:\n for iid in unreachable:\n failed[iid] = (\"ssh never answered within %.0f min — DEAD BOX\" % a.ssh_deadline)\n```\n\n### Rule 4: Report Unreadable Rows\nThe ledger file is shared with the INTEG cron, which writes its own format. A tolerant parser that skipped a foreign row would quietly not target that id for destruction.\n\n```python\n# In ledger_unreadable()\nif re.match(r\"^\\d{6,}\\b\", s) and not _ROW.match(s):\n bad.append(s[:120])\n```\n\n## Command Reference\n\n### offers\nQuery available GPU offers that meet minimum requirements.\n\n```bash\npython3 scripts/gpu-embed/gpu_embed.py offers \\\n --minutes 45 \\\n --ceiling 6.0 \\\n --min-down 2000 \\\n --min-rel 0.98 \\\n --min-vram 45000\n```\n\n**Arguments:**\n- `--minutes` - Duration to project cost (default: 45.0)\n- `--ceiling` - Maximum cost in dollars (default: 6.0)\n- `--min-down` - Minimum download speed in Mbps (default: 2000)\n- `--min-rel` - Minimum reliability score (default: 0.98)\n- `--min-vram` - Minimum VRAM in MB (default: 45000)\n\n**Returns:** List of qualifying offers sorted by price ascending.\n\n### create\nRent one GPU instance.\n\n```bash\npython3 scripts/gpu-embed/gpu_embed.py create \\\n --minutes 45 \\\n --ceiling 6.0 \\\n --gpu \"RTX 6000\" \\\n --offer 45355491\n```\n\n**Arguments:**\n- `--offer` - Rent this specific offer id (still subject to all filters)\n- `--gpu` - Prefer a card whose gpu_name contains this string\n\n**Flow:**\n1. Query offers via `offers_api()`\n2. Filter via `qualifying()` (VRAM, download, reliability)\n3. Apply `--offer` or `--gpu` filters\n4. Check projection against ceiling\n5. Call `api(\"/asks/{id}/\", \"PUT\", {...})`\n6. Append to ledger via `ledger_append()`\n\n### wait\nPoll for READY / FAILED status with a hard reachability deadline.\n\n```bash\npython3 scripts/gpu-embed/gpu_embed.py wait \\\n --timeout 1500 \\\n --poll 20 \\\n --ssh-deadline 10\n```\n\n**Arguments:**\n- `--timeout` - Maximum wait time in minutes (default: 1500)\n- `--poll` - Poll interval in seconds (default: 20)\n- `--ssh-deadline` - Minutes before declaring a box dead (default: 10)\n- `--only` - Filter to specific instance IDs\n\n**Flow:**\n1. Get list of owned instances via `ours()`\n2. Poll `instances()` API every `--poll` seconds\n3. SSH to each instance and check `/workspace/READY` or `/workspace/FAILED`\n4. If SSH times out after `--ssh-deadline`, mark as failed\n5. Return 0 if any ready, 1 otherwise\n\n### tunnel\nCreate an SSH tunnel to the instance.\n\n```bash\npython3 scripts/gpu-embed/gpu_embed.py tunnel --port 18100\n```\n\n**Arguments:**\n- `--port` - Local port for tunnel (default: 18100)\n\n**Important:** `LOCAL_PORT = 18100` is deliberately not 18000, which is the live query embedder serving the tenant's meaning leg on this host.\n\n**Flow:**\n1. Get owned instances via `ours()`\n2. For each instance, create `ssh -N -L 127.0.0.1:port:127.0.0.1:8000`\n3. Wait for `/v1/models` to respond\n4. Log to `/tmp/z12-tunnel-{id}.log`\n\n### status\nShow what is running, what it costs, and when it must die to stay in budget.\n\n```bash\npython3 scripts/gpu-embed/gpu_embed.py status --ceiling 6.0\n```\n\n**Output includes:**\n- All instances on the account\n- Spend and burn rate for owned instances\n- \"DESTROY BY\" timestamp if over budget\n\n### destroy\nDelete every box this track owns, then prove the account with a listing.\n\n```bash\npython3 scripts/gpu-embed/gpu_embed.py destroy\n```\n\n**Arguments:**\n- `--only` - Filter to specific instance IDs\n\n**Flow:**\n1. Get targets via `ours()`\n2. For each target:\n - Call `api(\"/instances/{id}/\", \"DELETE\")`\n - Call `ledger_mark_destroyed(id)`\n3. Sleep 6 seconds\n4. List remaining instances\n5. Report any still-running Z12 boxes\n6. Report any unreadable ledger rows\n\n## Ledger Management\n\nThe ledger lives at `/home/ahmad/Desktop/Harakat/.sdd-work/gpu-lane-prep/FLEET-INSTANCES.txt` and is mirrored to `.sdd-work/gpu-lane-prep/FLEET-INSTANCES.txt`.\n\n### Ledger Format\n```\n{instance_id} {created_timestamp} {offer_id} {dph} {destroyed_timestamp}\n```\n\n### Key Functions\n\n| Function | Purpose |\n|----------|---------|\n| `ledger_ids(path)` | Parse all valid rows, return list of dicts |\n| `ledger_unreadable(path)` | Return lines that look like IDs but don't parse |\n| `ours(path)` | Return IDs that this track created and hasn't destroyed |\n| `ledger_append(id, offer, dph)` | Append new instance to ledger |\n| `ledger_mark_destroyed(id)` | Mark instance as destroyed with timestamp |\n\n### Ownership Determination\nOwnership is read from the file rather than held in process memory:\n```python\ndef ours(path=None):\n return [r[\"id\"] for r in ledger_ids(path) if r[\"destroyed\"] == \"-\"]\n```\n\nA row whose `destroyed` column is not \"-\" is finished; a row that says anything else (like `NOT-OURS-Z10-WARM-BOX`) is somebody else's and is never a destroy target here.\n\n## API Integration\n\n### VAST API\n- Base URL: `https://console.vast.ai/api/v0`\n- Authentication: Bearer token from `VAST_API_KEY` environment variable or `.env.local`\n- Timeout: 90 seconds\n\n### Key API Endpoints\n- `GET /instances/` - List all instances\n- `GET /bundles/?q=...` - Query offers\n- `PUT /asks/{id}/` - Rent an instance\n- `DELETE /instances/{id}/` - Destroy an instance\n\n### Offer Query Parameters\n```python\nq = {\n \"num_gpus\": {\"eq\": 1},\n \"rentable\": {\"eq\": True},\n \"disk_space\": {\"gte\": 120},\n \"gpu_ram\": {\"gte\": min_vram_mb},\n \"order\": [[\"dph_total\", \"asc\"]],\n \"limit\": 60,\n \"type\": \"on-demand\"\n}\n```\n\n## Offer Filtering\n\nThe `qualifying()` function filters offers by:\n1. **VRAM** - Hard requirement (F2LLM-v2-14B in bfloat16 is ~28 GB)\n2. **Download speed** - Minimum `--min-down` Mbps\n3. **Reliability** - Minimum `--min-rel` score\n\n```python\ndef qualifying(offers, min_down, min_rel, min_vram_mb):\n ok = [o for o in offers\n if (o.get(\"inet_down\") or 0) >= min_down\n and (o.get(\"reliability2\") or 0) >= min_rel\n and (o.get(\"gpu_ram\") or 0) >= min_vram_mb]\n return sorted(ok, key=lambda o: o.get(\"dph_total\") or 1e9)\n```\n\nMissing fields are treated as \"does not qualify\", never as \"unknown, allow\".\n\n## Self-Test Suite\n\n`gpu_embed_selftest.py` validates the four money rules without network or GPU dependencies.\n\n### Test Categories\n\n1. **Ledger Parsing** - Validates that:\n - Well-formed rows are parsed correctly\n - Foreign id-shaped rows are reported, not skipped\n - Empty/missing files return empty lists\n - Commented IDs are not read as rows\n\n2. **Projection & Ceiling** - Validates that:\n - Cost projection is accurate\n - Ceiling enforcement works correctly\n\n3. **Offer Filtering** - Validates that:\n - VRAM requirement is enforced (24 GB card excluded for 28 GB model)\n - Slow uplinks are excluded\n - Low-reliability hosts are excluded\n - Results are sorted by price\n\n4. **Tunnel Port** - Validates that:\n - `LOCAL_PORT != 18000` (live query embedder port)\n - Port is in the fleet band (>= 18100)\n\n5. **onstart.sh** - Validates that:\n - Serves `codefuse-ai/F2LLM-v2-14B`\n - Runs as pooling model (`--runner pooling`)\n - Writes `/workspace/READY` and `/workspace/FAILED`\n - Does not serve generation models\n - Uses `--max-model-len 8192`\n\n## Integration with Codebase\n\n### External Dependencies\n- `HarakatOffices_Server/.env.local` - Contains `VAST_API_KEY`\n- `scripts/gpu-embed/onstart.sh` - Executed on rented boxes\n- `Harakat_AI/core/local_embed.py` - Client-side truncation of embeddings\n\n### Related Modules\n- `scripts/gpu-embed/gpu_embed_selftest.py` - Validates the module\n- `scripts/gpu-embed/onstart.sh` - Box startup script\n- `Harakat_AI/core/local_embed.py` - Uses the embeddings from this module\n\n### Data Flow\n```mermaid\ngraph LR\n A[User runs create] --> B[Query offers API]\n B --> C[Filter by VRAM/down/rel]\n C --> D{Check ceiling}\n D -->|Exceeds| E[Exit with error]\n D -->|OK| F[PUT /asks/{id}/]\n F --> G[Append to ledger]\n G --> H[User runs wait]\n H --> I[SSH to box]\n I --> J{Check /workspace/READY}\n J -->|Ready| K[Create tunnel]\n J -->|Failed| L[Mark destroyed]\n K --> M[User runs destroy]\n M --> N[DELETE /instances/{id}/]\n N --> O[Mark ledger destroyed]\n```\n\n## Configuration\n\n### Environment Variables\n- `VAST_API_KEY` - Vast.ai API key (or read from `.env.local`)\n\n### File Locations\n| File | Path |\n|------|------|\n| Ledger | `/home/ahmad/Desktop/Harakat/.sdd-work/gpu-lane-prep/FLEET-INSTANCES.txt` |\n| Ledger Mirror | `.sdd-work/gpu-lane-prep/FLEET-INSTANCES.txt` |\n| Env File | `/home/ahmad/Desktop/Harakat/HarakatOffices_Server/.env.local` |\n| Onstart Script | `scripts/gpu-embed/onstart.sh` |\n\n### Constants\n```python\nLOCAL_PORT = 18100 # Never 18000 (live query embedder)\nIMAGE = \"vastai/base-image:cuda-13.2.1-auto\"\nLABEL = \"harakat-Z12-embed-backlog\"\n```\n\n## Troubleshooting\n\n### Common Issues\n\n1. **No qualifying offers**\n - Check `--min-vram` (F2LLM-v2-14B needs ~28 GB)\n - Check `--min-down` (2000 Mbps recommended)\n - Check `--min-rel` (0.98 recommended)\n\n2. **Box never answers SSH**\n - Check `--ssh-deadline` (default 10 minutes)\n - Verify SSH key is correct\n - Check `--timeout` (default 1500 minutes)\n\n3. **Projection exceeds ceiling**\n - Reduce `--minutes` or increase `--ceiling`\n - Choose cheaper GPU via `--gpu` filter\n\n4. **Unreadable ledger rows**\n - Check for foreign format from INTEG cron\n - These rows are reported but not targeted for destruction\n\n### Debug Commands\n```bash\n# Check current spend\npython3 scripts/gpu-embed/gpu_embed.py status\n\n# See what's running\npython3 scripts/gpu-embed/gpu_embed.py status\n\n# Check tunnel health\ncurl http://127.0.0.1:18100/v1/models\n```\n\n## Best Practices\n\n1. **Always check status before creating** - Use `status` to see current spend and burn rate\n2. **Set realistic ceilings** - Default is $6.00 for 45 minutes\n3. **Use `--gpu` filter** - GPU names are stable, offer IDs rotate\n4. **Monitor unreachable boxes** - `--ssh-deadline` of 10 minutes is recommended\n5. **Destroy promptly** - Use `destroy` to clean up and verify account\n\n## Security Considerations\n\n- SSH keys are used for remote access\n- API key is read from environment or `.env.local`\n- Tunnel ports are isolated from live query embedder (18100 vs 18000)\n- Boxes are destroyed after use to prevent billing\n\n## Version History\n\n- **Z12, 2026-08-05** - Current version implementing the four money rules\n- **Z11** - Previous version with similar ledger parsing logic\n- **Z10** - Warm box handling (NOT-OURS-Z10-WARM-BOX)","scripts-hooks":"# scripts — hooks\n\n\n\n# scripts/hooks\n\nThis module contains Git hook scripts designed to enforce security policies and quality gates before code is committed or pushed. The scripts are located in `scripts/hooks/` and are invoked automatically by Git during the `git commit` and `git push` workflows.\n\n## Overview\n\nThe module consists of two primary scripts:\n1. **`pre-commit`**: Prevents committing files that resemble secrets or runtime exhaust (e.g., `.env`, logs, keys).\n2. **`pre-push`**: Enforces submodule pin verification and requires a \"green battery\" (test suite pass) for pushes to the `main` branch.\n\nBoth scripts are standalone Bash scripts with no internal function calls or external library dependencies beyond standard Unix utilities (`git`, `grep`, `sed`, `sort`, `bash`).\n\n## pre-commit\n\nThe `pre-commit` script blocks commits that include sensitive files. It operates on the staging area (`git diff --cached`).\n\n### Logic Flow\n\n1. **Allowance Check**: If the environment variable `HARAKAT_ALLOW_SENSITIVE` is set to `1`, the script exits immediately with success (0), allowing the commit.\n2. **Secret Detection**:\n * Retrieves the list of staged files.\n * Filters for `.env` files, excluding `.example`, `.template`, and `.sample` variants.\n * Filters for other sensitive patterns: `.log`, `id_*.pub`, `service-account*.json`, `.pem`, `.pfx`, `.dump`, `unseal`.\n3. **Blocking**:\n * If any matching files are found, the script prints a list of blocked files.\n * It suggests unstaging the files (`git rm --cached <file>`) or using the `HARAKAT_ALLOW_SENSITIVE` override.\n * Exits with status `1` to abort the commit.\n4. **Success**: If no sensitive files are found, exits with status `0`.\n\n### Code Patterns\n\n* **Staged File Retrieval**: `git diff --cached --name-only`\n* **Pattern Matching**: `grep -iE '(^|/)\\.env'` and `grep -iE '\\.log$|...\\.pem$'`\n* **Deduplication**: `sort -u`\n* **Exit Codes**: `exit 0` (success), `exit 1` (blocked)\n\n## pre-push\n\nThe `pre-push` script performs two distinct checks before allowing a push to a remote repository.\n\n### 1. Submodule Pin Verification\nIf the repository is a meta-repo (contains `.gitmodules` and `scripts/check-submodule-pins.sh`), the script runs `check-submodule-pins.sh`.\n* **Failure**: If the submodule check fails, the push is aborted with an error message.\n* **Success**: The script proceeds to the gate receipt check.\n\n### 2. Gate Receipt Check (Main Branch)\nThis check ensures that any push to `refs/heads/main` is backed by a successful \"green battery\" (test suite).\n\n* **Superproject Traversal**: The script walks up the superproject tree (`git rev-parse --show-superproject-working-tree`) to locate the root directory where `scripts/gate-receipt.sh` resides.\n* **Input**: Reads from stdin (provided by Git hook), receiving lines in the format: `<local-ref> <local-sha> <remote-ref> <remote-sha>`.\n* **Filtering**:\n * Only processes refs where `refs/heads/main` is involved (either local or remote).\n * Skips branch deletions (where `local_sha` is all zeros).\n* **Waiver Logic**:\n * If `HARAKAT_SKIP_GATE_RECEIPT=1`, the push is recorded as \"WAIVED\" and allowed.\n* **Validation**:\n * Calls `bash \"$receipt\" check \"$top\" \"$local_sha\"`.\n * If the check fails, the push is aborted.\n\n### Code Patterns\n\n* **Superproject Detection**: `git -C \"$sp\" rev-parse --show-superproject-working-tree`\n* **Stdin Reading**: `while read -r local_ref local_sha remote_ref _rest; do ... done`\n* **External Script Invocation**: `bash \"$top/scripts/check-submodule-pins.sh\"` and `bash \"$receipt\" check \"$top\" \"$local_sha\"`\n\n## Environment Variables\n\n| Variable | Scope | Description |\n| :--- | :--- | :--- |\n| `HARAKAT_ALLOW_SENSITIVE` | `pre-commit` | If set to `1`, bypasses the secret file blocking logic. |\n| `HARAKAT_SKIP_GATE_RECEIPT` | `pre-push` | If set to `1`, waives the requirement for a green battery on `main` pushes. |\n\n## Dependencies\n\nThe module relies on the following external scripts located in the repository root:\n* `scripts/check-submodule-pins.sh`: Validates submodule pins in meta-repos.\n* `scripts/gate-receipt.sh`: Validates the \"green battery\" status for `main` branch commits.\n\n## Execution Flow\n\nThe following diagram illustrates the decision logic for the `pre-push` hook, which contains the most complex branching.\n\n```mermaid\nflowchart TD\n Start[Start pre-push] --> SubmoduleCheck{Is Meta-Repo?}\n SubmoduleCheck -- Yes --> RunSubmodule[Run check-submodule-pins.sh]\n RunSubmodule -- Fail --> Abort[Push Aborted]\n RunSubmodule -- Pass --> GateCheck{Is Gate Receipt Found?}\n GateCheck -- No --> Exit[Exit 0]\n GateCheck -- Yes --> ReadStdin[Read Git Stdin]\n ReadStdin --> LoopRefs{Loop Refs}\n LoopRefs -- Not Main --> Continue[Continue Loop]\n LoopRefs -- Is Main --> CheckSha{Is Branch Deletion?}\n CheckSha -- Yes --> Continue\n CheckSha -- No --> CheckWaiver{Skip Gate Waived?}\n CheckWaiver -- Yes --> RecordWaive[Record Waived Push]\n RecordWaive --> Continue\n CheckWaiver -- No --> RunGate[bash gate-receipt.sh check]\n RunGate -- Fail --> Abort\n RunGate -- Pass --> Continue\n Continue --> End{End of Refs?}\n End -- No --> LoopRefs\n End -- Yes --> Exit\n```\n\n## Integration\n\nThese scripts are installed as Git hooks. To ensure they function correctly:\n1. **Meta-repos**: Must contain `.gitmodules` and `scripts/check-submodule-pins.sh`.\n2. **Root Scripts**: `scripts/gate-receipt.sh` must be present in the superproject root.\n3. **Permissions**: Ensure the scripts are executable (`chmod +x`).","startupsplatform-hooks":"# StartupsPlatform — hooks\n\n\n\n# StartupsPlatform — Hooks\n\nThis module provides client-side React hooks for managing UI state, real-time synchronization, authentication, and notifications within the StartupsPlatform application. It abstracts complex interactions with the backend API, browser security features, and window state into reusable, typed interfaces.\n\n## Core Utilities\n\n### Toast System (`use-toast.ts`)\nThe `use-toast.ts` file implements a custom toast notification system inspired by `react-hot-toast`. It manages a single active toast (`TOAST_LIMIT = 1`) with a long timeout (`TOAST_REMOVE_DELAY = 1000000`).\n\n**Key Components:**\n* **`toast` function**: Creates a toast instance with `id`, `dismiss`, and `update` methods. It dispatches an `ADD_TOAST` action to the reducer.\n* **`useToast` hook**: Returns the current state of toasts and the `toast` function. It subscribes to state changes via a listener array.\n* **`reducer`**: Handles state transitions (`ADD_TOAST`, `UPDATE_TOAST`, `DISMISS_TOAST`, `REMOVE_TOAST`).\n* **`dispatch`**: Updates `memoryState` and notifies all listeners.\n\n**Execution Flow:**\n1. `toast()` is called with props.\n2. `genId()` generates a unique ID.\n3. `dispatch({ type: 'ADD_TOAST', toast })` is called.\n4. `reducer` updates the state and calls `addToRemoveQueue`.\n5. `addToRemoveQueue` sets a `setTimeout` to dispatch `REMOVE_TOAST` after the delay.\n\n**Usage:**\n```typescript\nconst { toast, dismiss } = useToast();\ntoast({ title: \"Success\", description: \"Operation completed\" });\n```\n\n### Mobile Detection (`use-mobile.ts`)\nThe `useIsMobile` hook detects if the viewport width is below the mobile breakpoint (768px). It uses `window.matchMedia` to listen for changes and updates state accordingly.\n\n**Key Components:**\n* **`MOBILE_BREAKPOINT`**: Constant set to 768.\n* **`useIsMobile`**: Returns a boolean indicating mobile status.\n\n**Usage:**\n```typescript\nconst isMobile = useIsMobile();\nif (isMobile) {\n // Render mobile-specific UI\n}\n```\n\n## Real-Time Streams\n\nThe module provides two primary hooks for real-time data synchronization: `useDriveSyncSSE` and `useNotificationStream`. Both rely on the `useResilientStream` utility from `@/lib/stream` to handle connection stability.\n\n### Drive Synchronization (`use-drive-sync.ts`)\n`useDriveSyncSSE` manages the live synchronization of files and folders with the backend. It handles sync progress, queue management, and parsing events.\n\n**Key Features:**\n* **Resilience**: Implements T6.3 fixes for `EventSource` reconnection logic, including backoff, jitter, and stall detection.\n* **State Management**: Tracks `isSyncing`, `isParsing`, `syncQueue`, `currentFile`, and `editingFiles`.\n* **Events**: Listens for `SyncEvent` types like `sync_start`, `sync_file`, `parse_progress`, and `edit_detected`.\n* **Queue Fetching**: Calls `/api/startup/drives/sync/queue` to populate the initial sync queue.\n\n**Execution Flow:**\n1. `useDriveSyncSSE` initializes state.\n2. `useResilientStream` connects to `/api/startup/drives/sync/events`.\n3. `onFrame` parses incoming JSON frames.\n4. State is updated based on event type (e.g., `setIsSyncing(true)` on `sync_start`).\n5. `fetchQueue` is triggered if `sync_start` includes a `queueSize`.\n\n**Usage:**\n```typescript\nconst { isSyncing, syncQueue, parseProgress } = useDriveSyncSSE();\n```\n\n### Notification Stream (`use-notification-stream.ts`)\n`useNotificationStream` manages the live feed of notifications. It includes a replay mechanism to recover missed events during reconnection.\n\n**Key Features:**\n* **Replay**: Uses `httpReplayTransport` and `replayChannel` to fetch missed events from `/api/startup/notifications/replay`.\n* **State**: Returns `live` (connection status) and `replayGap` (indicates if a replay occurred).\n* **Events**: Listens for `notification_upserted` events.\n\n**Execution Flow:**\n1. `useNotificationStream` initializes `cursor` for replay tracking.\n2. `useResilientStream` connects to `/api/startup/notifications/stream`.\n3. `onReconnected` triggers `replayChannel` to fetch missed entries.\n4. `onEntry` applies replayed data via `apply`.\n5. `cursor` is updated to track the latest sequence.\n\n**Usage:**\n```typescript\nconst { live, replayGap } = useNotificationStream((event) => {\n // Handle notification\n});\n```\n\n## Security & Authentication\n\n### Passkey Approval (`use-passkey-approval.ts`)\n`usePasskeyApproval` handles the WebAuthn flow for approving privileged actions (e.g., sending emails, modifying records).\n\n**Key Components:**\n* **`usePasskeyApproval`**: Returns `obtain`, `prompting`, and `error`.\n* **`obtain`**: Initiates the flow by calling `webauthnApi.beginActionApproval`, then triggers `navigator.credentials.get` via `@simplewebauthn/browser`.\n* **`digestPayload`**: Computes a SHA-256 hash of the action payload to bind the passkey assertion to a specific operation.\n* **`permittedActionsRequirePasskey`**: Checks if a list of actions requires passkey approval (e.g., `send_email`, `modify_record`).\n\n**Execution Flow:**\n1. `obtain(payloadHash)` is called.\n2. `webauthnApi.beginActionApproval` returns a challenge.\n3. `startAuthentication` prompts the browser for the passkey.\n4. Response is returned as a `PasskeyApprovalRequest`.\n5. Caller forwards this to the server mutation endpoint.\n\n**Usage:**\n```typescript\nconst { obtain, prompting } = usePasskeyApproval();\nconst request = await obtain(digestPayload({ capabilityId: 1, action: \"approve\" }));\n```\n\n### Auth Context (`use-auth.ts`)\n`useAuth` is a thin re-export from `@/lib/auth-context`. It provides access to the global authentication context.\n\n**Usage:**\n```typescript\nconst { user, signOut } = useAuth();\n```\n\n## Integration & Call Graph\n\nThe hooks in this module are consumed by various components across the application.\n\n* **`useToast`**: Used by `Toaster`, `RequestSupportDialog`, `ViewTicketDialog`, `OpportunityForm`, and many page-level handlers (e.g., `handleReapply`, `confirmChangeType`).\n* **`useIsMobile`**: Used by `SidebarProvider` and `useAssistantChat` to adjust layout and behavior.\n* **`useDriveSyncSSE`**: Used by `FeedStep` and `SyncStatusBlob` to display sync status.\n* **`useNotificationStream`**: Used by `NotificationBell` to update the notification badge.\n* **`usePasskeyApproval`**: Used by `CapabilitiesPage` to handle security approvals.\n\n## Architecture\n\n### Stream Hook Architecture\nBoth `useDriveSyncSSE` and `useNotificationStream` follow a similar architecture to ensure resilience and consistency.\n\n```mermaid\nflowchart TD\n A[Component] -->|Hook| B_useDriveSyncSSE[\"B(useDriveSyncSSE\"] / useNotificationStream)\n B -->|useResilientStream| C[lib/stream]\n C -->|SSE / HTTP| D[API Endpoint]\n D -->|Events| C\n C -->|State| B\n B -->|State| A\n```\n\n### Passkey Approval Flow\nThe passkey approval process involves a handshake between the client hook, the browser, and the server.\n\n```mermaid\nsequenceDiagram\n participant Client as Client Hook\n participant Browser as Browser API\n participant Server as Server API\n\n Client->>Server: beginActionApproval\n Server-->>Client: Challenge + PayloadHash\n Client->>Browser: startAuthentication\n Browser-->>Client: Passkey Response\n Client->>Server: consumeActionApproval (Mutation)\n Server-->>Client: Success/Error\n```","startupsplatform-i18n":"# StartupsPlatform — i18n\n\n\n\n# StartupsPlatform — i18n\n\nThis module implements locale-aware internationalization (i18n) for the StartupsPlatform. It utilizes a cookie-based approach to manage language preferences (`en`, `ar`) without URL prefixing. This design avoids middleware complexity and route collisions inherent in a `[locale]` directory structure, particularly given the platform's tenant OS architecture and existing route density.\n\n## Architecture\n\nThe module consists of three primary files:\n1. **`routing.ts`**: Defines locale constants, validation logic, and directionality.\n2. **`request.ts`**: Handles server-side locale resolution and message loading.\n3. **`navigation.ts`**: Provides centralized Next.js navigation utilities.\n\n### Locale Resolution Flow\n\nThe core logic for determining the active locale resides in `request.ts` and `routing.ts`. When a request is received, the server reads the `NEXT_LOCALE` cookie. If the value is valid, it is used; otherwise, the system defaults to English (`en`).\n\n```mermaid\nflowchart TD\n A[Incoming Request] --> B[request.ts]\n B --> C{Cookie Read?}\n C -->|No| D[defaultLocale]\n C -->|Yes| E[resolveLocale]\n E --> F{isLocale?}\n F -->|Valid| G[Return Locale]\n F -->|Invalid| D\n D --> H[Load Messages]\n G --> H\n```\n\n## Core Modules\n\n### `routing.ts`\n\nThis file serves as the single source of truth for locale configuration. It exports constants and helper functions used across the application.\n\n**Constants**\n* `locales`: A tuple of supported locales (`\"en\"`, `\"ar\"`).\n* `defaultLocale`: The fallback locale (`\"en\"`).\n* `LOCALE_COOKIE`: The cookie name used to store the user's preference (`\"NEXT_LOCALE\"`).\n* `LOCALE_COOKIE_MAX_AGE`: Cookie expiration set to one year (`365` days).\n* `localeDirection`: Maps locales to text direction (`\"ltr\"` for `en`, `\"rtl\"` for `ar`).\n* `localeLabel`: Maps locales to their native names for the language switcher UI.\n* `routing`: An object conforming to the vendor cockpit's `defineRouting()` shape, explicitly setting `localePrefix: \"never\"`.\n\n**Functions**\n* `isLocale(value: unknown)`: Type guard to verify if a value is a valid supported locale.\n* `resolveLocale(value: string | null | undefined)`: The primary resolution function. It returns the provided value if valid via `isLocale`, otherwise returns `defaultLocale`.\n* `directionFor(value: string | null | undefined)`: Returns the text direction (`\"ltr\"` or `\"rtl\"`) for a given locale value.\n\n### `request.ts`\n\nThis file implements the `getRequestConfig` from `next-intl/server`. It is responsible for determining the locale and loading the corresponding message bundle for the current request.\n\n**Logic**\n1. **Cookie Retrieval**: Attempts to read the `NEXT_LOCALE` cookie using `next/headers`.\n2. **Error Handling**: Wraps cookie retrieval in a `try/catch` block. If the request scope is unavailable (e.g., static render), it defaults to the `defaultLocale`.\n3. **Resolution**: Calls `resolveLocale` from `./routing` to validate the cookie value.\n4. **Message Loading**: Dynamically imports the JSON message file from `../messages/${locale}.json`.\n5. **Fallback**: If the cookie is missing or invalid, `resolveLocale` ensures `en` is returned, preventing the app from blanking out.\n\n### `navigation.ts`\n\nThis file re-exports Next.js navigation APIs to provide a centralized entry point.\n\n**Purpose**\n* **Consistency**: Ensures all shell/chrome code uses the same navigation utilities.\n* **Future-Proofing**: Currently re-exports raw `next/link` and `next/navigation` APIs because there is no URL prefix. If the platform adopts URL-prefixed locales later, this file can be updated to `createNavigation(routing)` from `next-intl/navigation` without requiring changes at every call site.\n\n**Exports**\n* `Link`: The preferred component for client-side navigation.\n* `redirect`, `usePathname`, `useRouter`, `useSearchParams`: Utilities for programmatic navigation and state management.\n\n## Integration Patterns\n\n### ERP Localization Flow\n\nSeveral ERP-specific pages utilize a specific chain of functions to resolve labels based on the current locale. This flow is triggered by `useResolvedApp` and ensures consistency across the ERP module.\n\n**Execution Path**\n1. **Page Component**: `InvoiceOverview`, `HelpdeskPage`, `SalesPage`, `DataCyclePage`, or `MarketingCardPage`.\n2. **App Context**: `useResolvedApp` (from `erp/customization/use-resolved-app.ts`).\n3. **Resolution**: `resolveApp` (from `erp/customization/resolve.ts`).\n4. **Label Lookup**: `erpLabel` (from `erp/customization/i18n.ts`).\n5. **Bilingual Handling**: `pickBilingualLabel` (from `lib/i18n/bilingual-label.ts`).\n6. **Locale Validation**: `resolveLocale` (from `StartupsPlatform/i18n/routing.ts`).\n7. **Type Check**: `isLocale` (from `StartupsPlatform/i18n/routing.ts`).\n\nThis pattern ensures that ERP-specific labels are correctly resolved against the global i18n configuration.\n\n### Layout & UI Components\n\n* **`RootLayout`**: Uses `directionFor` from `routing.ts` to apply the correct text direction (`ltr`/`rtl`) to the document based on the resolved locale.\n* **`locale-toggle.tsx`**: Uses `resolveLocale` to determine the current state for the language switcher UI.\n* **`lib/i18n/locale-cookie.ts`**: Uses `resolveLocale` to read and manage the cookie value directly.\n\n## Configuration & Constraints\n\n* **No Middleware**: There is no `middleware.ts` in this module. `next-intl` middleware is designed for URL-segment routing (`/[locale]`), which is not used here.\n* **Cookie Storage**: The `NEXT_LOCALE` cookie is not `httpOnly`. This is intentional to allow the client-side language switcher to update the preference immediately without server round-trips.\n* **Validation**: `resolveLocale` is strict. Any unrecognized value (garbage, missing cookie) defaults to `en`. This ensures the application remains functional even if the cookie is corrupted.\n* **Route Structure**: The platform does not use `[locale]` URL segments. All routes are shared across languages, and the language is determined solely by the cookie.","startupsplatform-journeys":"# StartupsPlatform — journeys\n\n\n\n# StartupsPlatform — journeys\n\n## Overview\n\nThe `journeys` module serves as the **Journey Harness substrate**. It provides the machinery for end-to-end testing pipelines without containing the test specifications themselves.\n\nSpecs are now managed in `docs/personas/`. This folder contains the fixtures required to execute those specs: authentication, persona typing, observation logic, and virtual passkey handling.\n\n## Architecture\n\nThe module relies on a set of fixtures located in `fixtures/`. These components orchestrate the browser session, handle authentication, and capture execution findings.\n\n### Fixtures\n\n| File | Purpose |\n| :--- | :--- |\n| `fixtures/persona.ts` | Defines the `Persona` type shape. Contains no data; data is loaded from `docs/personas/`. |\n| `fixtures/auth.ts` | Handles API login to seed the browser session. |\n| `fixtures/observe.ts` | Captures findings (broken, suspect, note) during a walk. |\n| `fixtures/passkey.ts` | Provides a virtual authenticator for passkey-based actions. |\n| `fixtures/journey.ts` | Entry point. Exports `journey` and `walkAs` to initialize a test run. |\n\n## Persona Management\n\nPersonas are the identity context for every walk. They are no longer stored in this folder or `tenants.json`.\n\n### Loading\nPipelines load persona objects from `docs/personas/<slug>/persona.md`. The `walkAs` function accepts a persona object directly.\n\n### Password Rules\nAuthentication credentials are split into two categories. Do not consolidate these into a single constant.\n\n| Password | Allowed Emails |\n| :--- | :--- |\n| `HarakatTest!2607` | `coordiantor@lifespace.ae`, `e5admin@harakat.local` |\n| `Harakat#Test2026` | All other users on all tenants |\n\n## Operational Rules\n\nAdherence to these five rules is mandatory. Violations can damage live systems or produce unreliable test data.\n\n1. **Read-Only:** Do not create, edit, or delete customer data unless the pipeline explicitly states otherwise in writing.\n2. **No Service Control:** Never restart, stop, or start a service. If a service is down, report it.\n3. **Tenant Scope:** Only operate on tenants named in the walk. Never re-seed Tenant 19 (staging with real synced data).\n4. **Stack Lock:** Claim the stack lock before a run (`bash scripts/stack-lock.sh claim <name>`). Release it after. Prevents multiple agents from driving the same browser stack.\n5. **Red is Information:** A failing walk is a finding, not a failure to fix. Never edit the product to make a walk pass.\n\n## Pre-Flight Checks\n\nThe application must be running before execution. Do not start the app; verify it is up.\n\n```bash\ncurl -s -o /dev/null -w \"%{http_code}\\n\" http://localhost:3000/login\n```\n\n* **Expected:** `200`\n* **Action:** If anything else, stop and report the stack is down.\n\n### Port Constraints\nThe harness targets `http://localhost:3000`.\n* **Passkeys:** Cryptographically bound to the origin. Pointing to another port causes signature verification failures.\n* **Frontend:** `scripts/run-local.ps1` serves the frontend on a different port; ignore it for this harness.\n\n## Observation & Reporting\n\nThe harness prioritizes **findings** over simple pass/fail status.\n\n### Finding Severity\n\n| Severity | Meaning | Effect |\n| :--- | :--- | :--- |\n| **broken** | Product failure (crash, 5xx, visible error) | Fails the run |\n| **suspect** | Worked, but user struggle (slow, 4xx) | Reported only |\n| **note** | Contextual information | Reported only |\n\n### Automatic Capture\nThe `observe` fixture captures:\n* Page crashes\n* Console errors\n* Failed requests (5xx = broken, 4xx = suspect)\n* Visible error text (catches \"Success\" responses with error messages)\n\n### Manual Assertions\nWalks can request specific checks:\n* `findable(selector)`: Checks visibility and readable label.\n* `reachByClicking(selector)`: Simulates user click path. Falls back to URL if path is broken.\n* `waitForVisible(selector)`: Waits for element. >5s wait is recorded as `suspect`.\n\n### Output\n* **Machine Readable:** `journeys/_report/findings.json`\n* **Human Readable:** `journeys/_report/index.html`\n* **Artifacts:** `journeys/_artifacts/` (e.g., trace files for failed runs)\n\nTo inspect a failing trace:\n```bash\nnpx playwright show-trace journeys/_artifacts/<folder>/trace.zip\n```\n\n## Passkey Handling\n\nCertain actions require passkey approval (e.g., archiving employees, granting permissions).\n\n### Virtual Authenticator\n`fixtures/passkey.ts` implements a virtual authenticator:\n* **Real:** Generates a real software security key pair inside Chrome.\n* **Simulated:** Fakes the human finger interaction.\n* **Verification:** The server verifies signatures, challenges, origin, and replay counters exactly as for a real user.\n\n### Security Testing\nTo validate the harness, passkey walks should test:\n1. **Replay:** Attempt to reuse a used approval signature.\n2. **Tampering:** Sign for one action, claim another.\nThe server must reject both.\n\n### Lifecycle\n* Registering a key writes one row.\n* Delete the key at the end of the run.\n* Interrupted runs may leave a credential labeled `virtual-journey-harness`. This is harmless but should be noted in the report.\n\n## Writing Walks\n\nUse `fixtures/journey.ts` to define a walk.\n\n```ts\nimport { journey, expect } from \"../fixtures/journey\";\n\njourney(\"what this walk is about\", async ({ walkAs }) => {\n const { page, observe } = await walkAs(somePersona);\n\n observe.step(\"land on the dashboard\");\n await observe.visit(\"/dashboard\");\n\n observe.note(\"anything a human should know about what you saw\");\n});\n```\n\n### Best Practices\n* **Steps:** Call `observe.step(\"…\")` before every user action. This groups findings under the correct context in the report.\n* **Assertions:** You do not need `expect` for a walk to be useful. Add assertions only to pin down specific behaviors.\n* **DOM vs. UI:** Assert what the user sees, not the markup.\n * *Example:* If a walk checks for an HTML table but the product uses cards by default, the test fails even if the product is correct. Check for the \"List\" view toggle first.\n\n## Execution Flow\n\nThe following diagram illustrates the logical flow of a walk execution, from persona loading to artifact generation.\n\n```mermaid\nsequenceDiagram\n participant Pipeline\n participant Journey\n participant Auth\n participant Browser\n participant Observe\n participant Report\n\n Pipeline->>Journey: walkAs(persona)\n Journey->>Auth: Login credentials\n Auth->>Browser: Seed session\n Browser->>Browser: Navigate to URL\n loop For each step\n Browser->>Observe: Capture state\n Observe->>Observe: Check errors/visibility\n Observe->>Observe: Record finding (broken/suspect/note)\n end\n Journey->>Report: Write findings.json\n Report->>Report: Generate index.html\n```\n\n## Troubleshooting\n\n| Symptom | Likely Cause | Action |\n| :--- | :--- | :--- |\n| `Could not reach the API at http://localhost:5000` | Stack is down | Stop and report. Do not start it. |\n| `Login FAILED … Invalid credentials` | Password trap | Verify email/password against the rules above. |\n| `Persona … says role=… but server returned …` | Account drift | Fix `docs/personas/` before trusting results. |\n| Hangs on passkey step | Wrong port | Ensure target is `http://localhost:3000`. |\n| Red walk, product looks fine | Wrong assertion | Open trace (`trace.zip`) and inspect DOM/Console. |","startupsplatform-startupsplatform":"# StartupsPlatform — StartupsPlatform\n\n\n\n# StartupsPlatform\n\n## Overview\n\nThe `StartupsPlatform` module is a Next.js 15 standalone application built with Node.js 22. It serves as the primary frontend interface for the Harakat project, utilizing a strict build pipeline, comprehensive validation scripts, and a multi-stage Docker deployment strategy. The application relies heavily on `next-intl` for internationalization and `shadcn/ui` for component design.\n\n## Build & Deployment\n\n### Node Version Enforcement\nThe build process enforces **Node.js 22** (`node:22-alpine`). This is a load-bearing requirement driven by `pnpm@11`'s usage of the `node:sqlite` builtin module, which is only available in Node 22+. The Dockerfile explicitly pins `pnpm` to `10.20.0` to avoid breaking builds caused by newer versions importing incompatible modules.\n\n```dockerfile\nRUN corepack enable && corepack prepare pnpm@10.20.0 --activate\n```\n\n### Multi-Stage Docker Build\nThe `Dockerfile` utilizes four stages to optimize the production image:\n1. **base**: Sets up Node 22 and activates pnpm.\n2. **deps**: Installs dependencies using `pnpm install --frozen-lockfile`.\n3. **build**: Copies source code, runs environment validation, and executes `pnpm build`.\n4. **runner**: Strips unused files, sets up a non-root user (`nextjs`), and serves the standalone output.\n\n### Pre-Build Environment Validation\nBefore the Next.js build step, the pipeline executes `scripts/check-public-env.cjs`. This script validates that all `NEXT_PUBLIC_*` environment variables required by the code are present in `.env`. Missing variables are inlined as `undefined` at build time, which can cause silent feature failures or routing errors in production.\n\n## Next.js Configuration\n\nThe application is configured via `next.config.mjs` with the following key settings:\n\n* **Standalone Output**: `output: 'standalone'` is enabled to bundle the server and client into a single artifact.\n* **i18n Plugin**: `createNextIntlPlugin(\"./i18n/request.ts\")` is used to handle cookie-based locale detection without route segments.\n* **Security Headers**: Default headers include `X-Content-Type-Options`, `X-Frame-Options`, and `Permissions-Policy` to restrict geolocation and microphone access.\n* **Monorepo Isolation**: `outputFileTracingRoot` is pinned to `__dirname` to prevent the standalone build from inferring a parent workspace and bundling sibling repositories.\n\n## Internationalization (i18n)\n\nThe application uses `next-intl` for localization. The workflow involves a split between the main catalog (`messages/en.json`) and surface-specific parts (`messages/parts/<surface>.json`).\n\n### Test Setup\nUnit tests mock `next-intl` in `vitest.setup.ts` to use the English catalog directly. This ensures tests fail immediately on missing keys rather than rendering literal key paths.\n\n* **Mocking**: `vi.mock(\"next-intl\")` replaces the library with a resolver backed by `messages/en.json`.\n* **Missing Key Handling**: The `t()` function throws a `MissingMessageError` if a key is not found in the catalog or parts directory.\n* **Parts Merging**: During test setup, `messages/parts/*.json` files are read and merged into the base catalog using `deepMerge`.\n\n### i18n Flow\nThe following diagram illustrates the test initialization flow for internationalization:\n\n```mermaid\nflowchart TD\n A[Test Init] --> B[Load messages/en.json]\n B --> C{parts dir exists?}\n C -- Yes --> D[Read messages/parts/*.json]\n D --> E[deepMerge into en.json]\n C -- No --> E\n E --> F[Mock next-intl]\n F --> G[Run Tests]\n G --> H{Key exists?}\n H -- Yes --> I[Return String]\n H -- No --> J[Throw MissingMessageError]\n```\n\n### Runtime vs. Test\n* **Runtime**: Uses `next-intl` with `NextIntlClientProvider` in the root layout.\n* **Tests**: Uses the mocked resolver in `vitest.setup.ts`. Tests can opt out of the mock using `vi.unmock(\"next-intl\")` if they require the real library or a different locale.\n\n## Testing Infrastructure\n\n### Vitest (Unit Testing)\nUnit tests are configured in `vitest.config.ts` to run in a Node environment.\n* **Coverage**: Includes `app`, `components`, `lib`, and `scripts` directories.\n* **Setup**: `vitest.setup.ts` is executed before all tests to configure the i18n mock and polyfill missing browser APIs (e.g., `ResizeObserver`, `PointerEvent`).\n\n### Playwright (E2E Testing)\nE2E tests are configured in `playwright.config.ts` with strict constraints to ensure data integrity:\n* **No WebServer**: The harness does not start a server. It attaches to a live stack running on port 3000.\n* **Single Worker**: `workers: 1` and `fullyParallel: false` are enforced. Journeys run against a shared tenant database; parallel execution causes interference that mimics product bugs.\n* **Timeouts**: General timeout is 60s (`60_000`), with action and navigation timeouts set to 15s and 30s respectively.\n* **Port Binding**: Tests target `http://localhost:3000`. Changing this port breaks WebAuthn passkey ceremonies due to origin binding.\n\n## Validation Scripts\n\nThe `package.json` defines a suite of validation scripts that act as gates before deployment or major commits. These scripts verify code quality, configuration, and feature availability.\n\n| Script | Purpose |\n| :--- | :--- |\n| `check:public-env` | Validates `NEXT_PUBLIC_*` variables exist before build. |\n| `check:i18n` | Merges message parts and checks for missing keys. |\n| `check:stream` | Validates streaming logic in `lib/stream` and `agent-board`. |\n| `check:uploads` | Tests upload functionality in `lib/uploads` and `components/documents`. |\n| `check:apps` | Tests application logic in `lib/apps` and `components/apps`. |\n| `check:chat-placement` | Validates chat UI placement hooks and tests. |\n| `check:automations` | Tests automation logic in `lib/automation`. |\n| `check:search` | Tests search functionality and narration. |\n| `check:token` | Validates token access logic. |\n| `check:boundaries` | Checks error boundary implementation. |\n| `check:error-copy` | Validates error message copy. |\n| `check:lists` | Validates list placement logic. |\n| `check:provenance` | Tests agent provenance and security settings. |\n| `orphan:scan` | Scans for orphaned modules or scripts. |\n\n## Key Dependencies\n\n* **Framework**: `next` (15.5.4), `react` (19.1.0), `react-dom` (19.1.0).\n* **UI**: `shadcn/ui` (configured in `components.json`), `@radix-ui/*` primitives, `lucide-react`.\n* **Internationalization**: `next-intl` (4.3.4).\n* **Testing**: `vitest` (4.1.9), `@testing-library/react`, `@playwright/test` (1.61.0).\n* **Utilities**: `zod` (3.25.76), `date-fns` (4.1.0), `clsx`, `tailwind-merge`.\n* **Charts/Graphs**: `recharts`, `@xyflow/react`.","startupsplatform-styles":"# StartupsPlatform — styles\n\n\n\n# StartupsPlatform — styles\n\n## Overview\n\nThe `globals.css` module serves as the central configuration file for the application's visual design system. It establishes the color palette, typography, spacing, and base styling rules using Tailwind CSS. This module is declarative and does not contain executable logic; instead, it defines the CSS variables and design tokens that the rest of the application consumes via utility classes.\n\n## Theming & Color System\n\nThe module utilizes the `oklch` color space for defining colors, providing better perceptual uniformity compared to traditional RGB or HSL. The color system is divided into semantic tokens (e.g., `primary`, `background`, `sidebar`) which are mapped to CSS variables.\n\n### Light Mode\nDefault values are defined in the `:root` selector. These variables control the appearance of UI components such as cards, popovers, and inputs.\n\n```css\n:root {\n --background: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --primary: oklch(0.205 0 0);\n --sidebar: oklch(0.985 0 0);\n /* ... additional tokens ... */\n}\n```\n\n### Dark Mode\nDark mode is implemented by overriding the CSS variables within the `.dark` selector. This ensures that the application automatically inverts colors when the dark mode class is applied to the document root.\n\n```css\n.dark {\n --background: oklch(0.145 0 0);\n --foreground: oklch(0.985 0 0);\n --sidebar: oklch(0.205 0 0);\n /* ... additional tokens ... */\n}\n```\n\n## Tailwind Configuration\n\nThe module integrates Tailwind CSS using the `@theme inline` directive. This maps the defined CSS variables directly to Tailwind's design tokens, allowing developers to use utility classes like `bg-primary` or `text-sidebar-foreground` without referencing raw hex codes.\n\n### Design Tokens\nThe following tokens are exposed to the Tailwind engine:\n- **Colors:** `background`, `foreground`, `card`, `popover`, `primary`, `secondary`, `muted`, `accent`, `destructive`, `border`, `input`, `ring`, `chart-1` through `chart-5`.\n- **Sidebar:** Specific tokens for the sidebar component (`sidebar`, `sidebar-foreground`, `sidebar-primary`, etc.).\n- **Typography:** `font-sans` and `font-mono` mapped to the 'Geist' font family.\n- **Spacing:** `radius-sm`, `radius-md`, `radius-lg`, `radius-xl` derived from the base `--radius` variable.\n\n## Global Styles & Base Layer\n\nThe `@layer base` directive applies foundational styles to the entire application before component-specific styles are loaded.\n\n- **Global Borders:** All elements (`*`) receive the `border-border` class and an outline ring with 50% opacity.\n- **Body Styling:** The `body` element is set to use the `background` and `foreground` color variables.\n\n```css\n@layer base {\n * {\n @apply border-border outline-ring/50;\n }\n body {\n @apply bg-background text-foreground;\n }\n}\n```\n\n## Dark Mode Implementation\n\nDark mode is triggered via the `dark` custom variant defined at the top of the file:\n\n```css\n@custom-variant dark (&:is(.dark *));\n```\n\nDevelopers must ensure the `.dark` class is present on the root element (e.g., `<html class=\"dark\">`) to activate the dark mode color overrides.\n\n## Usage Guidelines\n\n1. **Utility Classes:** Use Tailwind utility classes (e.g., `bg-primary`, `text-muted-foreground`) to reference the defined color tokens.\n2. **Customization:** To modify the color palette, update the `:root` or `.dark` CSS variables in `globals.css`. Changes will propagate automatically to all Tailwind classes referencing those variables.\n3. **Fonts:** The application uses the 'Geist' font family. Ensure the font files are available in the project's asset pipeline.\n4. **Animations:** The `tw-animate-css` import provides animation utilities. Refer to the library documentation for available animation classes.\n\n## Theming Architecture\n\nThe following diagram illustrates how the CSS variables flow into the Tailwind engine and ultimately affect the DOM.\n\n```mermaid\nflowchart TD\n Root[\":root / .dark\"] --> CSSVars[CSS Variables]\n CSSVars --> Theme[@theme inline]\n Theme --> Tailwind[Tailwind Utility Classes]\n Tailwind --> DOM[HTML Elements]\n \n Base[@layer base] --> GlobalStyles[Global Styles]\n GlobalStyles --> DOM\n \n CSSVars -.-> Base\n```","startupsplatform":"# StartupsPlatform\n\n\n\n# StartupsPlatform\n\n## Overview\n\nThe `StartupsPlatform` module is a Next.js 15 standalone application built with Node.js 22. It serves as the primary frontend interface for the Harakat project, utilizing a strict build pipeline, comprehensive validation scripts, and a multi-stage Docker deployment strategy. The application relies heavily on `next-intl` for internationalization and `shadcn/ui` for component design.\n\n## Architecture\n\nThe platform is structured into distinct layers that manage presentation, logic, configuration, and quality assurance.\n\n### Presentation Layer\nThe `app` and `components` sub-modules form the user interface. They consume design tokens defined in `styles` and utilize state management from `hooks`.\n\n### Logic Layer\nThe `hooks` module provides client-side React hooks for managing UI state, real-time synchronization, authentication, and notifications. It abstracts complex interactions with the backend API, browser security features, and window state into reusable, typed interfaces.\n* **Toast System:** The `use-toast.ts` hook implements a custom notification system with a single active toast limit (`TOAST_LIMIT = 1`) and a long timeout (`TOAST_REMOVE_DELAY = 1000000`).\n* **API Abstraction:** Interactions with external services are handled through the `lib` module, ensuring consistent data fetching and error handling across the application.\n\n### Configuration Layer\n* **Internationalization:** The `i18n` module implements locale-aware internationalization for `en` and `ar`. It utilizes a cookie-based approach to manage language preferences without URL prefixing, avoiding middleware complexity inherent in a `[locale]` directory structure. Key files include `routing.ts`, `request.ts`, and `navigation.ts`.\n* **Design System:** The `styles` module serves as the central configuration file for the visual design system. It establishes the color palette, typography, and spacing using Tailwind CSS and the `oklch` color space. The `globals.css` file defines semantic tokens (e.g., `primary`, `background`, `sidebar`) mapped to CSS variables.\n\n### Quality Assurance\nThe `journeys` module serves as the Journey Harness substrate for end-to-end testing pipelines. It does not contain test specifications, which are managed in `docs/personas/`. Instead, it relies on fixtures located in `fixtures/` to orchestrate browser sessions, handle authentication, and capture execution findings.\n\n## Workflows\n\n### User Interaction Flow\n1. **Initialization:** The application loads, resolving the locale via `i18n` (`request.ts`) and applying the visual theme from `styles` (`globals.css`).\n2. **State Management:** UI components in `components` interact with the `hooks` module to manage state and trigger notifications via `use-toast.ts`.\n3. **Data Fetching:** Components request data through `lib`, which abstracts API calls and handles responses.\n4. **Navigation:** User navigation is managed centrally through `i18n` (`navigation.ts`).\n\n### Testing Flow\n1. **Spec Definition:** Test scenarios are defined in `docs/personas/`.\n2. **Execution:** The `journeys` module loads fixtures from `fixtures/` to simulate user actions.\n3. **Observation:** The harness captures execution findings and validates against the defined persona types.\n\n## Module Dependencies\n\n```mermaid\ngraph TD\n subgraph UI\n A[app] --> B[components]\n end\n subgraph Logic\n B --> C[hooks]\n C --> D[lib]\n end\n subgraph Config\n D --> E[i18n]\n B --> F[styles]\n end\n subgraph QA\n A --> G[journeys]\n G --> H[fixtures]\n G --> I[docs/personas]\n end\n```\n\n## Sub-Modules\n\n* [app](app.md)\n* [components](components.md)\n* [hooks](hooks.md)\n* [i18n](i18n.md)\n* [journeys](journeys.md)\n* [lib](lib.md)\n* [messages](messages.md)\n* [scripts](scripts.md)\n* [styles](styles.md)","testpipe":"# testpipe\n\n\n\n# testpipe\n\nThe `testpipe` module serves as the central testing and validation infrastructure for the system, orchestrating skill verification, policy enforcement, multi-tenant isolation, and performance monitoring. It integrates specialized sub-modules to manage the lifecycle of test cases, from definition and execution to governance and reporting.\n\n## Core Functional Areas\n\n### Test Suites and Validation\nTest scenarios are defined within the **[suites](suites.md)** module, which coordinates execution logic across various test types (e.g., `tone_skill`, `collision`, `multi`). These suites rely on the **[checks](checks.md)** module to validate outcomes using functions like `contains_any` and `C`. Quality assurance is further handled by **[suite_quality](suite_quality.md)**, which evaluates semantic lease terms and grades actions via **[grading](grading.md)**.\n\n### Governance and Policy Management\nThe **[governance](governance.md)** module manages the lifecycle of system skills and policies. It handles token generation (`_token`) and policy revocation (`_psql`). Governance actions are triggered by test suites (e.g., `new_signature_skill` → `revoke_skill`) and tracked through **[gov_memory_run](gov_memory_run.md)**, which manages artifacts and memory claims. Regrading capabilities are available via **[gov_regrade](gov_regrade.md)**.\n\n### Isolation and Conformance\nTo ensure system integrity across environments, the **[isolation](isolation.md)** module provides conformance checks for multitenancy (`conformance_multitenant.py`) and self-checking mechanisms (`selfcheck.py`). These components verify project isolation and concurrent row handling.\n\n### Monitoring and Reporting\nSystem behavior is observed through the `mt_` suite of modules. **[mt_run](mt_run.md)** executes monitoring tasks, while **[mt_observe](mt_observe.md)** and **[mt_erp](mt_erp.md)** capture snapshots and connection states. Results are aggregated into reports via **[report](report.md)**, which handles styling and formatting.\n\n## Execution Workflows\n\n1. **Test Execution:** Suites (`[suites](suites.md)`) invoke validation checks (`[checks](checks.md)`) and governance actions (`[governance](governance.md)`).\n2. **Governance Loop:** Skills and policies are created or revoked (`[governance](governance.md)`), with memory artifacts managed by `gov_memory_run.py`.\n3. **Isolation Verification:** Multitenant conformance is verified independently via `[isolation](isolation.md)`.\n4. **Observation:** Monitoring tools (`mt_` modules) track system health and state during execution.\n5. **Reporting:** Final results are compiled by `[report](report.md)`.\n\n## Module Interactions\n\n```mermaid\nflowchart TD\n subgraph TestDefinition\n Suites[suites.py]\n Quality[suite_quality.py]\n end\n\n subgraph Validation\n Checks[checks.py]\n Grading[grading.py]\n end\n\n subgraph Governance\n Gov[governance.py]\n Memory[gov_memory_run.py]\n Regrade[gov_regrade.py]\n end\n\n subgraph Isolation\n Isolation[isolation/conformance_multitenant.py]\n end\n\n subgraph Monitoring\n MTRun[mt_run.py]\n MTObserve[mt_observe.py]\n end\n\n subgraph Reporting\n Report[report.py]\n end\n\n Suites -->|contains_any| Checks\n Suites -->|C| Checks\n Suites -->|revoke_skill| Gov\n Quality -->|contains_any| Checks\n Quality -->|grade_action_discipline| Grading\n Gov -->|_token| Gov\n Gov -->|_psql| Gov\n Memory -->|claim_new_artifact| Memory\n Memory -->|run_honcho| Memory\n MTObserve -->|snapshot| MTObserve\n MTObserve -->|_n| MTObserve\n MTRun -->|main| MTRun\n Report -->|_style_header| Report\n Isolation -->|_project_ids| Isolation\n```"};
var TREE = [{"name":"Root","slug":"root","files":[],"children":[{"name":"Root — AGENTS.md","slug":"root-agents-md","files":["AGENTS.md"]},{"name":"Root — CLAUDE.md","slug":"root-claude-md","files":["CLAUDE.md"]},{"name":"Root — DEPLOYMENT.md","slug":"root-deployment-md","files":["DEPLOYMENT.md"]},{"name":"Root — Harakat.code-workspace","slug":"root-harakat-code-workspace","files":["Harakat.code-workspace"]},{"name":"Root — WORKSPACE.md","slug":"root-workspace-md","files":["WORKSPACE.md"]},{"name":"Root — after-run1.yml","slug":"root-after-run1-yml","files":["after-run1.yml"]},{"name":"Root — docker-compose.yml","slug":"root-docker-compose-yml","files":["docker-compose.yml"]},{"name":"Root — lifecycle-recordings-90d.json","slug":"root-lifecycle-recordings-90d-json","files":["lifecycle-recordings-90d.json"]}]},{"name":"HarakatMobile","slug":"harakatmobile","files":[],"children":[{"name":"HarakatMobile — HarakatMobile","slug":"harakatmobile-harakatmobile","files":["HarakatMobile/README.md","HarakatMobile/app.json","HarakatMobile/eas.json","HarakatMobile/package.json","HarakatMobile/tsconfig.json"]},{"name":"HarakatMobile — assets","slug":"harakatmobile-assets","files":["HarakatMobile/assets/expo.icon/icon.json"]},{"name":"HarakatMobile — ios","slug":"harakatmobile-ios","files":["HarakatMobile/ios/Harakat.xcodeproj/project.pbxproj","HarakatMobile/ios/Harakat.xcodeproj/project.xcworkspace/contents.xcworkspacedata","HarakatMobile/ios/Harakat.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist","HarakatMobile/ios/Harakat.xcodeproj/xcshareddata/xcschemes/Harakat.xcscheme","HarakatMobile/ios/Harakat/AppDelegate.swift","HarakatMobile/ios/Harakat/Harakat-Bridging-Header.h","HarakatMobile/ios/Harakat/Harakat.entitlements","HarakatMobile/ios/Harakat/Images.xcassets/AppIcon.appiconset/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/SplashScreenBackground.colorset/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/SplashScreenLogo.imageset/Contents.json","HarakatMobile/ios/Harakat/Info.plist","HarakatMobile/ios/Harakat/SplashScreen.storyboard","HarakatMobile/ios/Harakat/Supporting/Expo.plist","HarakatMobile/ios/Harakat/expo.icon/icon.json","HarakatMobile/ios/Podfile","HarakatMobile/ios/Podfile.properties.json"]},{"name":"HarakatMobile — scripts","slug":"harakatmobile-scripts","files":["HarakatMobile/scripts/check-i18n.js","HarakatMobile/scripts/check-icons.mjs","HarakatMobile/scripts/check-ota-safe.mjs","HarakatMobile/scripts/harness-selftest.mjs","HarakatMobile/scripts/lib/settled.mjs","HarakatMobile/scripts/lib/sign-in-diagnosis.mjs","HarakatMobile/scripts/lib/web-export.mjs","HarakatMobile/scripts/reset-project.js","HarakatMobile/scripts/rtl-render-check.mjs","HarakatMobile/scripts/settle-selftest.mjs","HarakatMobile/scripts/stream-render-check.mjs"]},{"name":"HarakatMobile — src","slug":"harakatmobile-src","files":["HarakatMobile/src/app/(tabs)/_layout.tsx","HarakatMobile/src/app/(tabs)/board.tsx","HarakatMobile/src/app/(tabs)/index.tsx","HarakatMobile/src/app/(tabs)/notifications.tsx","HarakatMobile/src/app/(tabs)/settings/_layout.tsx","HarakatMobile/src/app/(tabs)/settings/appearance.tsx","HarakatMobile/src/app/(tabs)/settings/governance.tsx","HarakatMobile/src/app/(tabs)/settings/index.tsx","HarakatMobile/src/app/(tabs)/settings/language.tsx","HarakatMobile/src/app/(tabs)/settings/notifications.tsx","HarakatMobile/src/app/(tabs)/settings/profile.tsx","HarakatMobile/src/app/(tabs)/settings/security.tsx","HarakatMobile/src/app/_layout.tsx","HarakatMobile/src/app/login.tsx","HarakatMobile/src/components/animated-icon.module.css","HarakatMobile/src/components/animated-icon.tsx","HarakatMobile/src/components/animated-icon.web.tsx","HarakatMobile/src/components/board/board-canvas.tsx","HarakatMobile/src/components/board/board-card.tsx","HarakatMobile/src/components/board/chat-sheet.tsx","HarakatMobile/src/components/board/clamp.ts","HarakatMobile/src/components/board/inbox-list.tsx","HarakatMobile/src/components/chat/action-preview-card.tsx","HarakatMobile/src/components/chat/assistant-markdown.tsx","HarakatMobile/src/components/chat/chat-screen.tsx","HarakatMobile/src/components/chat/chat-sidebar.tsx","HarakatMobile/src/components/chat/composer-actions.ts","HarakatMobile/src/components/chat/voice-recorder.tsx","HarakatMobile/src/components/dashboard/ask-sheet.tsx","HarakatMobile/src/components/dashboard/unknown-widget.tsx","HarakatMobile/src/components/dashboard/widget-card.tsx","HarakatMobile/src/components/external-link.tsx","HarakatMobile/src/components/governance/pending-card.tsx","HarakatMobile/src/components/hint-row.tsx","HarakatMobile/src/components/themed-text.tsx","HarakatMobile/src/components/themed-view.tsx","HarakatMobile/src/components/ui/action-sheet.tsx","HarakatMobile/src/components/ui/button.tsx","HarakatMobile/src/components/ui/collapsible.tsx","HarakatMobile/src/components/ui/dismiss-keyboard-on-drag.tsx","HarakatMobile/src/components/ui/empty-state.tsx","HarakatMobile/src/components/ui/glass-card.tsx","HarakatMobile/src/components/ui/harakat-mark.tsx","HarakatMobile/src/components/ui/icon.tsx","HarakatMobile/src/components/ui/list-row.tsx","HarakatMobile/src/components/ui/load-error.tsx","HarakatMobile/src/components/ui/offline-pill.tsx","HarakatMobile/src/components/ui/read-only-notice.tsx","HarakatMobile/src/components/ui/segmented-control.tsx","HarakatMobile/src/components/ui/skeleton.tsx","HarakatMobile/src/components/ui/stale-strip.tsx","HarakatMobile/src/components/ui/stream-status-strip.tsx","HarakatMobile/src/components/ui/web-handoff-card.tsx","HarakatMobile/src/components/web-badge.tsx","HarakatMobile/src/constants/theme.ts","HarakatMobile/src/global.css","HarakatMobile/src/hooks/use-color-scheme.ts","HarakatMobile/src/hooks/use-color-scheme.web.ts","HarakatMobile/src/hooks/use-theme.ts","HarakatMobile/src/i18n/direction.ts","HarakatMobile/src/i18n/format.ts","HarakatMobile/src/i18n/i18n-context.tsx","HarakatMobile/src/i18n/locale-store.ts","HarakatMobile/src/i18n/messages/ar.json","HarakatMobile/src/i18n/messages/en.json","HarakatMobile/src/i18n/plural.ts","HarakatMobile/src/i18n/routing.ts","HarakatMobile/src/i18n/translate.ts","HarakatMobile/src/lib/api/agent-board.ts","HarakatMobile/src/lib/api/assistant.ts","HarakatMobile/src/lib/api/attachments.ts","HarakatMobile/src/lib/api/auth.ts","HarakatMobile/src/lib/api/client.ts","HarakatMobile/src/lib/api/conversations.ts","HarakatMobile/src/lib/api/dashboard.ts","HarakatMobile/src/lib/api/governance.ts","HarakatMobile/src/lib/api/notifications.ts","HarakatMobile/src/lib/api/sessions.ts","HarakatMobile/src/lib/api/voice.ts","HarakatMobile/src/lib/api/webauthn.ts","HarakatMobile/src/lib/assistant/approval-fields.ts","HarakatMobile/src/lib/auth/auth-context.tsx","HarakatMobile/src/lib/auth/auth-machine.ts","HarakatMobile/src/lib/auth/biometric-lock.tsx","HarakatMobile/src/lib/auth/passkeys.ts","HarakatMobile/src/lib/auth/token-store.ts","HarakatMobile/src/lib/board/reply-target.ts","HarakatMobile/src/lib/board/use-board-stream.ts","HarakatMobile/src/lib/chrome/tab-bar.tsx","HarakatMobile/src/lib/dashboard/widget-data.ts","HarakatMobile/src/lib/dashboard/widget-registry.ts","HarakatMobile/src/lib/deep-link-parker.ts","HarakatMobile/src/lib/deep-links.ts","HarakatMobile/src/lib/handoff.ts","HarakatMobile/src/lib/keyboard/drag-accumulator.ts","HarakatMobile/src/lib/layout.ts","HarakatMobile/src/lib/motion/motion.ts","HarakatMobile/src/lib/net/xhr-stream.ts","HarakatMobile/src/lib/notifications/feed.ts","HarakatMobile/src/lib/notifications/preferences.ts","HarakatMobile/src/lib/offline/net-state.ts","HarakatMobile/src/lib/offline/outbox.ts","HarakatMobile/src/lib/offline/read-cache.ts","HarakatMobile/src/lib/offline/storage.ts","HarakatMobile/src/lib/push.ts","HarakatMobile/src/lib/sse.ts","HarakatMobile/src/lib/stream/backoff.ts","HarakatMobile/src/lib/stream/classify.ts","HarakatMobile/src/lib/stream/connection.ts","HarakatMobile/src/lib/stream/dedupe.ts","HarakatMobile/src/lib/stream/index.ts","HarakatMobile/src/lib/stream/platform-signals.ts","HarakatMobile/src/lib/stream/rate-limit-gate.ts","HarakatMobile/src/lib/stream/replay.ts","HarakatMobile/src/lib/stream/stall-watchdog.ts","HarakatMobile/src/lib/stream/use-resilient-stream.ts","HarakatMobile/src/lib/ui/action-bands.ts","HarakatMobile/src/lib/ui/settle.ts","HarakatMobile/src/lib/ui/skeleton-widths.ts","HarakatMobile/src/lib/ui/use-settle.ts","HarakatMobile/src/lib/ui/view-state.ts","HarakatMobile/src/theme/theme-context.tsx","HarakatMobile/src/theme/tokens.ts"]},{"name":"HarakatMobile — store","slug":"harakatmobile-store","files":["HarakatMobile/store/README.md","HarakatMobile/store/app-store-privacy.md","HarakatMobile/store/assets-spec.md","HarakatMobile/store/credentials-and-wellknown.md","HarakatMobile/store/ios-privacy-manifest.md","HarakatMobile/store/play-data-safety.md","HarakatMobile/store/screenshots-checklist.md"]}]},{"name":"HarakatOffices_Server","slug":"harakatoffices-server","files":[],"children":[{"name":"HarakatOffices_Server — HarakatOffices_Server","slug":"harakatoffices-server-harakatoffices-server","files":["HarakatOffices_Server/Dockerfile","HarakatOffices_Server/QUICK_START_2FA.md","HarakatOffices_Server/_backfill.js","HarakatOffices_Server/_check_all_types.js","HarakatOffices_Server/_check_content.js","HarakatOffices_Server/_check_db.js","HarakatOffices_Server/_check_db2.js","HarakatOffices_Server/_check_doc.js","HarakatOffices_Server/_check_sync.js","HarakatOffices_Server/_check_transcript_status.js","HarakatOffices_Server/_diag_archive_download.js","HarakatOffices_Server/_fix6.js","HarakatOffices_Server/_g2-mint.ts","HarakatOffices_Server/_probe19_driveaudit.js","HarakatOffices_Server/_probe_ws10_app5001.ts","HarakatOffices_Server/_probe_ws10_e2e.cjs","HarakatOffices_Server/_probe_ws5_identity.ts","HarakatOffices_Server/_probe_ws7_app5001.ts","HarakatOffices_Server/_probe_ws7_e2e.cjs","HarakatOffices_Server/_progress.js","HarakatOffices_Server/_query.sql","HarakatOffices_Server/_reset.js","HarakatOffices_Server/_reset_sync.js","HarakatOffices_Server/_smoke_archive_extract.js","HarakatOffices_Server/_smoke_download_bytes.js","HarakatOffices_Server/_smoke_queue.js","HarakatOffices_Server/_start.bat","HarakatOffices_Server/_start.ps1","HarakatOffices_Server/_test_refresh.js","HarakatOffices_Server/_test_token.js","HarakatOffices_Server/_verify_sync.js","HarakatOffices_Server/_wipe_sync_data.js","HarakatOffices_Server/check-providers.js","HarakatOffices_Server/check-zoho.js","HarakatOffices_Server/create-test-support-ticket.js","HarakatOffices_Server/deactivate-test-user.js","HarakatOffices_Server/docker-compose.yml","HarakatOffices_Server/init-features.js","HarakatOffices_Server/init-virtualea-features.ps1","HarakatOffices_Server/package.json","HarakatOffices_Server/seed-startup-accounts.js","HarakatOffices_Server/test-smtp.ts","HarakatOffices_Server/test-zoho.ts","HarakatOffices_Server/tsconfig.json"]},{"name":"HarakatOffices_Server — docs","slug":"harakatoffices-server-docs","files":["HarakatOffices_Server/docs/2FA_TESTING_GUIDE.md","HarakatOffices_Server/docs/HERMES_BACKEND_ROLLOUT.md","HarakatOffices_Server/docs/PROVIDER_SERVICES_FLOW_DIAGRAM.md","HarakatOffices_Server/docs/PROVIDER_SERVICES_STORAGE.md","HarakatOffices_Server/docs/SERVICES_STORAGE_QUICK_REF.md","HarakatOffices_Server/docs/SERVICE_STORAGE_COMPLETE_GUIDE.md","HarakatOffices_Server/docs/TWO_FACTOR_AUTH_GUIDE.md"]},{"name":"HarakatOffices_Server — prisma","slug":"harakatoffices-server-prisma","files":["HarakatOffices_Server/prisma/manual/20260616_delegation_token.sql","HarakatOffices_Server/prisma/manual/20260617_embed_batch_item.sql","HarakatOffices_Server/prisma/manual/20260617_enrich_batch_item.sql","HarakatOffices_Server/prisma/manual/20260617_erp_user_id.sql","HarakatOffices_Server/prisma/manual/20260617_tool_registration_parameters.sql","HarakatOffices_Server/prisma/manual/20260617_vector_index_state.sql","HarakatOffices_Server/prisma/manual/20260618_startup_erp_app.sql","HarakatOffices_Server/prisma/manual/20260619_erp_l4_customization.sql","HarakatOffices_Server/prisma/manual/20260619_erp_l4_phase5_quorum.sql","HarakatOffices_Server/prisma/manual/20260621_agent_board.sql","HarakatOffices_Server/prisma/manual/20260621_agent_board_unique_assistant.sql","HarakatOffices_Server/prisma/manual/20260621_shell_v2_prefs.sql","HarakatOffices_Server/prisma/manual/20260623_shell_board_voice.sql","HarakatOffices_Server/prisma/manual/20260624_branch_head.sql","HarakatOffices_Server/prisma/manual/20260624_dashboard_layout.sql","HarakatOffices_Server/prisma/manual/20260624_startup_erp_app_removal.sql","HarakatOffices_Server/prisma/manual/20260624_user_assistant_active.sql","HarakatOffices_Server/prisma/manual/20260629_governance_authoring_request.sql","HarakatOffices_Server/prisma/manual/20260629_user_assistant_procedure.sql","HarakatOffices_Server/prisma/manual/20260630_conversation_lifecycle.sql","HarakatOffices_Server/prisma/manual/20260630_eri_evidence_bundle.sql","HarakatOffices_Server/prisma/manual/20260630_eri_run_taskstate.sql","HarakatOffices_Server/prisma/manual/20260701_conversation_checkpoint.sql","HarakatOffices_Server/prisma/manual/20260702_eri_p7_p10.sql","HarakatOffices_Server/prisma/manual/20260702_eri_tool_gateway.sql","HarakatOffices_Server/prisma/manual/20260702_erp_gaps_fill.sql","HarakatOffices_Server/prisma/manual/20260710_agent_file_creation.sql","HarakatOffices_Server/prisma/manual/20260710_board_v2.sql","HarakatOffices_Server/prisma/manual/20260710_policy_guardrail.sql","HarakatOffices_Server/prisma/manual/20260710_ws7_personal_governance.sql","HarakatOffices_Server/prisma/manual/20260713_company_profile.sql","HarakatOffices_Server/prisma/manual/20260713_employee_offboarding.sql","HarakatOffices_Server/prisma/manual/20260713_employee_purge.sql","HarakatOffices_Server/prisma/manual/20260713_governance_authoring_grant.sql","HarakatOffices_Server/prisma/manual/20260713_governance_creation_session.sql","HarakatOffices_Server/prisma/manual/20260713_org_authority_edits.sql","HarakatOffices_Server/prisma/manual/20260713_org_erp_mirror_v2.sql","HarakatOffices_Server/prisma/manual/20260713_org_erp_reconciliation.sql","HarakatOffices_Server/prisma/manual/20260714_erp_deployment.sql","HarakatOffices_Server/prisma/manual/20260714_skill_scope_model.sql","HarakatOffices_Server/prisma/manual/20260724_admin_typed_provisioning.sql","HarakatOffices_Server/prisma/manual/20260724_vendors_v1.sql","HarakatOffices_Server/prisma/manual/20260725_office_purge_drop.sql","HarakatOffices_Server/prisma/manual/20260725_page_documents.sql","HarakatOffices_Server/prisma/manual/20260725_portal_applicant_token.sql","HarakatOffices_Server/prisma/manual/20260725_report_templates.sql","HarakatOffices_Server/prisma/manual/20260725_startup_erp_app_visibility.sql","HarakatOffices_Server/prisma/manual/20260725_startup_erp_app_visibility_index.sql","HarakatOffices_Server/prisma/manual/20260728_document_workspaces.sql","HarakatOffices_Server/prisma/manual/20260728_one_assistant_per_employee.sql","HarakatOffices_Server/prisma/manual/20260729_hub_pins.sql","HarakatOffices_Server/prisma/manual/20260730_context_events.sql","HarakatOffices_Server/prisma/manual/20260803_agent_attestation.sql","HarakatOffices_Server/prisma/manual/20260803_artifacts.sql","HarakatOffices_Server/prisma/manual/20260803_audience_scope_label.sql","HarakatOffices_Server/prisma/manual/20260803_audit_chain.sql","HarakatOffices_Server/prisma/manual/20260803_automated_turn_claim.sql","HarakatOffices_Server/prisma/manual/20260803_automated_work.sql","HarakatOffices_Server/prisma/manual/20260803_conversation_thread_axes.sql","HarakatOffices_Server/prisma/manual/20260803_governance_settings.sql","HarakatOffices_Server/prisma/manual/20260803_packs.sql","HarakatOffices_Server/prisma/manual/20260803_room_bridge.sql","HarakatOffices_Server/prisma/manual/20260803_room_signing.sql","HarakatOffices_Server/prisma/manual/20260803_room_threads.sql","HarakatOffices_Server/prisma/manual/20260803_rooms.sql","HarakatOffices_Server/prisma/manual/20260803_tenant_scoping.sql","HarakatOffices_Server/prisma/manual/20260803_toolexec_tenant_key.sql","HarakatOffices_Server/prisma/manual/20260804_action_preview_why.sql","HarakatOffices_Server/prisma/manual/20260804_admin_console_gaps.sql","HarakatOffices_Server/prisma/manual/20260804_admin_session.sql","HarakatOffices_Server/prisma/manual/20260804_agent_watches.sql","HarakatOffices_Server/prisma/manual/20260804_corpus_v2.sql","HarakatOffices_Server/prisma/manual/20260804_mail_pipeline.sql","HarakatOffices_Server/prisma/manual/20260804_scheduled_job_dispatch.sql","HarakatOffices_Server/prisma/manual/20260804_tenant_container.sql","HarakatOffices_Server/prisma/manual/20260805_connector_notice.sql","HarakatOffices_Server/prisma/manual/20260805_connector_notice_tenant_fk.sql","HarakatOffices_Server/prisma/manual/20260806_mail_domain.sql","HarakatOffices_Server/prisma/manual/20260813_company_domain.sql","HarakatOffices_Server/prisma/manual/20260813_document_design_rules.sql","HarakatOffices_Server/prisma/manual/20260813_knowledge_external_unique.sql","HarakatOffices_Server/prisma/manual/20260813_project_rooms.sql","HarakatOffices_Server/prisma/manual/20260813_relay_target.sql","HarakatOffices_Server/prisma/migrations/20251014160702_init/migration.sql","HarakatOffices_Server/prisma/migrations/20251017171744_add_admin_profile_and_notifications/migration.sql","HarakatOffices_Server/prisma/migrations/20251017175539_add_admin_office_access/migration.sql","HarakatOffices_Server/prisma/migrations/20251017203138_add_provider_services/migration.sql","HarakatOffices_Server/prisma/migrations/20251017213825_add_metadata_to_provider/migration.sql","HarakatOffices_Server/prisma/migrations/20251019103715_add_office_users/migration.sql","HarakatOffices_Server/prisma/migrations/20251019111621_add_marketplace_models/migration.sql","HarakatOffices_Server/prisma/migrations/20251019113136_add_document_management/migration.sql","HarakatOffices_Server/prisma/migrations/20251019190139_add_learning_hub/migration.sql","HarakatOffices_Server/prisma/migrations/20251026182619_add_startup_credits_and_agents/migration.sql","HarakatOffices_Server/prisma/migrations/20251027090716_add_startup_users/migration.sql","HarakatOffices_Server/prisma/migrations/20251027093835_add_provider_proposal_request_type/migration.sql","HarakatOffices_Server/prisma/migrations/20251027105120_add_agent_proposal_request_type/migration.sql","HarakatOffices_Server/prisma/migrations/20251027142125_update_office_user_roles/migration.sql","HarakatOffices_Server/prisma/migrations/20251028192557_add_two_factor_auth/migration.sql","HarakatOffices_Server/prisma/migrations/20251028195125_add_password_change_verification/migration.sql","HarakatOffices_Server/prisma/migrations/20251030204449_add_startup_manager_junction/migration.sql","HarakatOffices_Server/prisma/migrations/20251031180731_shmad/migration.sql","HarakatOffices_Server/prisma/migrations/20251031211047_add_assistant_conversations/migration.sql","HarakatOffices_Server/prisma/migrations/20251031221228_add_credit_limit_to_office/migration.sql","HarakatOffices_Server/prisma/migrations/20251101120035_add_user_assistant/migration.sql","HarakatOffices_Server/prisma/migrations/20251101122118_add_assistant_workspace/migration.sql","HarakatOffices_Server/prisma/migrations/20251101123940_add_startup_service_requests/migration.sql","HarakatOffices_Server/prisma/migrations/20251101124007_add_startup_service_requests/migration.sql","HarakatOffices_Server/prisma/migrations/20251101130641_change_provider_to_company/migration.sql","HarakatOffices_Server/prisma/migrations/20251102174617_add_credit_limits/migration.sql","HarakatOffices_Server/prisma/migrations/20251114160957_add_startup_manager/migration.sql","HarakatOffices_Server/prisma/migrations/20251114185046_add_virtualea_features/migration.sql","HarakatOffices_Server/prisma/migrations/20260325065210_add_office_provider_service/migration.sql","HarakatOffices_Server/prisma/migrations/20260325220741_add_startup_feature_access/migration.sql","HarakatOffices_Server/prisma/migrations/20260327210413_add_startup_user_level/migration.sql","HarakatOffices_Server/prisma/migrations/20260329113153_add_scenarios/migration.sql","HarakatOffices_Server/prisma/migrations/20260401145739_branch_hierarchy_drives_tasks/migration.sql","HarakatOffices_Server/prisma/migrations/20260412124415_add_missing_models_and_columns/migration.sql","HarakatOffices_Server/prisma/migrations/20260413093000_startup_email_columns_backfill/migration.sql","HarakatOffices_Server/prisma/migrations/20260413100000_office_user_invites/migration.sql","HarakatOffices_Server/prisma/migrations/20260517000000_add_audit_entry/migration.sql","HarakatOffices_Server/prisma/migrations/20260517010000_add_mutation_proposal/migration.sql","HarakatOffices_Server/prisma/migrations/20260517020000_phase_b_vessel_foundation/migration.sql","HarakatOffices_Server/prisma/migrations/20260517030000_phase_c_inter_assistant_fabric/migration.sql","HarakatOffices_Server/prisma/migrations/20260517040000_phase_e_procedures/migration.sql","HarakatOffices_Server/prisma/migrations/20260517050000_phase_f_mcp_runtime/migration.sql","HarakatOffices_Server/prisma/migrations/20260517060000_phase_g_autoML/migration.sql","HarakatOffices_Server/prisma/migrations/20260517070000_phase_g_training_sandbox/migration.sql","HarakatOffices_Server/prisma/migrations/20260517080000_phase_g_startup_user_webauthn/migration.sql","HarakatOffices_Server/prisma/migrations/20260518000000_phase_g_augmentation/migration.sql","HarakatOffices_Server/prisma/migrations/20260518010000_phase_h_onboarding_state/migration.sql","HarakatOffices_Server/prisma/migrations/20260518020000_startup_branch_hierarchy/migration.sql","HarakatOffices_Server/prisma/migrations/20260518030000_phase_h_template_access/migration.sql","HarakatOffices_Server/prisma/migrations/20260518040000_policy_conflict_and_tool_registration/migration.sql","HarakatOffices_Server/prisma/migrations/20260519000000_parsed_doc_attempts/migration.sql","HarakatOffices_Server/prisma/migrations/20260521000000_retrieval_v2_models/migration.sql","HarakatOffices_Server/prisma/migrations/20260521010000_retrieval_v2_tenant_flag/migration.sql","HarakatOffices_Server/prisma/migrations/20260521020000_search_index_toc_nullable_node/migration.sql","HarakatOffices_Server/prisma/migrations/20260522000000_agent_directory_scenario_jobs/migration.sql","HarakatOffices_Server/prisma/migrations/20260523000000_startup_hermes_enabled/migration.sql","HarakatOffices_Server/prisma/migrations/20260524000000_email_reply_triage/migration.sql","HarakatOffices_Server/prisma/migrations/20260525000000_add_meeting_recording_fields/migration.sql","HarakatOffices_Server/prisma/migrations/20260526000000_add_meeting_transcript_lifecycle/migration.sql","HarakatOffices_Server/prisma/migrations/20260527000000_kb_node_meeting_source_key/migration.sql","HarakatOffices_Server/prisma/migrations/20260528000000_meeting_auto_record_rule/migration.sql","HarakatOffices_Server/prisma/migrations/20260529000000_add_usage_event_telemetry/migration.sql","HarakatOffices_Server/prisma/migrations/20260530000000_integration_needs_reauth/migration.sql","HarakatOffices_Server/prisma/migrations/20260603150000_add_ocr_batch_item/migration.sql","HarakatOffices_Server/prisma/migrations/20260616_delegation_token/migration.sql","HarakatOffices_Server/prisma/migrations/20260617_enrich_batch_item/migration.sql","HarakatOffices_Server/prisma/migrations/20260617_vector_index_state/migration.sql","HarakatOffices_Server/prisma/migrations/20260618_startup_erp_app/migration.sql","HarakatOffices_Server/prisma/migrations/20260625204849_startupuser_2fa/migration.sql","HarakatOffices_Server/prisma/migrations/20260625210000_session_metadata/migration.sql","HarakatOffices_Server/prisma/migrations/20260626000000_integration_scope_setting/migration.sql","HarakatOffices_Server/prisma/migrations/20260629043600_procedure_run_parallel/migration.sql","HarakatOffices_Server/prisma/migrations/20260705000000_onboarding_startup_profile/migration.sql","HarakatOffices_Server/prisma/migrations/20260705100000_onboarding_meeting_prefs/migration.sql","HarakatOffices_Server/prisma/migrations/20260705200000_drive_acl_entry/migration.sql","HarakatOffices_Server/prisma/migrations/20260705210000_notification_spine/migration.sql","HarakatOffices_Server/prisma/migrations/20260705220000_mobile_refresh_tokens/migration.sql","HarakatOffices_Server/prisma/migrations/20260708120000_conversation_ephemeral/migration.sql","HarakatOffices_Server/prisma/migrations/migration_lock.toml","HarakatOffices_Server/prisma/schema.prisma","HarakatOffices_Server/prisma/seed-complete.ts","HarakatOffices_Server/prisma/seed.ts","HarakatOffices_Server/prisma/tenant-placement-baseline.json","HarakatOffices_Server/prisma/tenant-scoping-baseline.json"]},{"name":"HarakatOffices_Server — scripts","slug":"harakatoffices-server-scripts","files":["HarakatOffices_Server/scripts/b3_create_sentinel_check.ts","HarakatOffices_Server/scripts/board-v2-selftest.ts","HarakatOffices_Server/scripts/force-transcript-batch.ts","HarakatOffices_Server/scripts/merge-weekly-conversations.ts","HarakatOffices_Server/scripts/merge-weekly-threads.ts","HarakatOffices_Server/scripts/procedure-assignee-live.sh","HarakatOffices_Server/scripts/retitle-weekly-threads.ts","HarakatOffices_Server/scripts/seed-tool-registry.ts","HarakatOffices_Server/scripts/test-mcp-access.ts","HarakatOffices_Server/scripts/verify-url-normalizer.ts"]},{"name":"HarakatOffices_Server — src","slug":"harakatoffices-server-src","files":["HarakatOffices_Server/src/app.ts","HarakatOffices_Server/src/core/access-key/assistant-claims.ts","HarakatOffices_Server/src/core/access-key/canSee.ts","HarakatOffices_Server/src/core/access-key/deriver.ts","HarakatOffices_Server/src/core/access-key/index.ts","HarakatOffices_Server/src/core/access-key/node-tier.ts","HarakatOffices_Server/src/core/access-key/openfga/client.ts","HarakatOffices_Server/src/core/access-key/openfga/governance.ts","HarakatOffices_Server/src/core/access-key/openfga/index.ts","HarakatOffices_Server/src/core/access-key/openfga/model.fga","HarakatOffices_Server/src/core/access-key/openfga/model.ts","HarakatOffices_Server/src/core/access-key/openfga/seed.ts","HarakatOffices_Server/src/core/access-key/openfga/tuples.ts","HarakatOffices_Server/src/core/access-key/overrides.ts","HarakatOffices_Server/src/core/access-key/tenant-owner.ts","HarakatOffices_Server/src/core/access-key/types.ts","HarakatOffices_Server/src/core/access-key/workspace-access.ts","HarakatOffices_Server/src/core/admin-session/decide.ts","HarakatOffices_Server/src/core/admin-session/index.ts","HarakatOffices_Server/src/core/admin-session/store.ts","HarakatOffices_Server/src/core/analytics.ts","HarakatOffices_Server/src/core/artifacts/artifacts.service.ts","HarakatOffices_Server/src/core/artifacts/durability.ts","HarakatOffices_Server/src/core/artifacts/index.ts","HarakatOffices_Server/src/core/artifacts/local/docker-runtime.ts","HarakatOffices_Server/src/core/artifacts/manage.ts","HarakatOffices_Server/src/core/artifacts/name.ts","HarakatOffices_Server/src/core/artifacts/reach.ts","HarakatOffices_Server/src/core/artifacts/runtime.ts","HarakatOffices_Server/src/core/artifacts/snapshot.ts","HarakatOffices_Server/src/core/artifacts/store.ts","HarakatOffices_Server/src/core/artifacts/types.ts","HarakatOffices_Server/src/core/audit-log/actions.ts","HarakatOffices_Server/src/core/audit-log/chain.ts","HarakatOffices_Server/src/core/audit-log/hash.ts","HarakatOffices_Server/src/core/audit-log/index.ts","HarakatOffices_Server/src/core/audit-log/writer.ts","HarakatOffices_Server/src/core/authority/tenant-owner-http.ts","HarakatOffices_Server/src/core/authority/tenant-owner.ts","HarakatOffices_Server/src/core/calendar/google-calendar.service.ts","HarakatOffices_Server/src/core/config/env.ts","HarakatOffices_Server/src/core/config/local-guard.test.ts","HarakatOffices_Server/src/core/config/local-guard.ts","HarakatOffices_Server/src/core/config/prisma.ts","HarakatOffices_Server/src/core/contacts/google-contacts.service.ts","HarakatOffices_Server/src/core/corpus-v2/columns.ts","HarakatOffices_Server/src/core/corpus-v2/content-hash.ts","HarakatOffices_Server/src/core/corpus-v2/index.ts","HarakatOffices_Server/src/core/corpus-v2/mount-path.ts","HarakatOffices_Server/src/core/corpus-v2/owed-work.ts","HarakatOffices_Server/src/core/corpus-v2/reading.ts","HarakatOffices_Server/src/core/corpus-v2/record.ts","HarakatOffices_Server/src/core/corpus-v2/store.ts","HarakatOffices_Server/src/core/corpus-v2/vector-target.ts","HarakatOffices_Server/src/core/docker/docker-client.ts","HarakatOffices_Server/src/core/document-design/index.ts","HarakatOffices_Server/src/core/drive/corpus-tree.ts","HarakatOffices_Server/src/core/drive/drive-acl.integration.test.ts","HarakatOffices_Server/src/core/drive/drive-acl.service.ts","HarakatOffices_Server/src/core/drive/drive-heartbeat.service.ts","HarakatOffices_Server/src/core/drive/edit-stability.test.ts","HarakatOffices_Server/src/core/drive/edit-stability.ts","HarakatOffices_Server/src/core/drive/folder-cache.ts","HarakatOffices_Server/src/core/drive/google-drive.service.ts","HarakatOffices_Server/src/core/drive/sync-log.ts","HarakatOffices_Server/src/core/email/email.service.ts","HarakatOffices_Server/src/core/email/templates/invitation.ts","HarakatOffices_Server/src/core/governance/command-policy.ts","HarakatOffices_Server/src/core/governance/compose.ts","HarakatOffices_Server/src/core/governance/descriptor.ts","HarakatOffices_Server/src/core/governance/enforcement.ts","HarakatOffices_Server/src/core/governance/index.ts","HarakatOffices_Server/src/core/governance/registry.ts","HarakatOffices_Server/src/core/governance/scope.ts","HarakatOffices_Server/src/core/governance/shadow.ts","HarakatOffices_Server/src/core/governance/store.ts","HarakatOffices_Server/src/core/inbound/index.ts","HarakatOffices_Server/src/core/inference/inference-host.service.ts","HarakatOffices_Server/src/core/integrations/connector-status.ts","HarakatOffices_Server/src/core/integrations/google-oauth.service.ts","HarakatOffices_Server/src/core/lifecycle/budget.ts","HarakatOffices_Server/src/core/lifecycle/drain.ts","HarakatOffices_Server/src/core/lifecycle/index.ts","HarakatOffices_Server/src/core/lifecycle/inflight.ts","HarakatOffices_Server/src/core/lifecycle/phase.ts","HarakatOffices_Server/src/core/lifecycle/signals.ts","HarakatOffices_Server/src/core/lifecycle/stream-surfaces.ts","HarakatOffices_Server/src/core/live-authority/agent-grant.ts","HarakatOffices_Server/src/core/live-authority/automated-jwt.ts","HarakatOffices_Server/src/core/live-authority/index.ts","HarakatOffices_Server/src/core/live-authority/live-person.ts","HarakatOffices_Server/src/core/live-authority/org-promotion.ts","HarakatOffices_Server/src/core/live-authority/request-origin.ts","HarakatOffices_Server/src/core/live-authority/shared-scope.ts","HarakatOffices_Server/src/core/live-authority/synthetic-principal.ts","HarakatOffices_Server/src/core/live-authority/turn-origin.ts","HarakatOffices_Server/src/core/mail/adapters/agenticmail.adapter.ts","HarakatOffices_Server/src/core/mail/adapters/agentmail.adapter.ts","HarakatOffices_Server/src/core/mail/adapters/loopback.adapter.ts","HarakatOffices_Server/src/core/mail/adapters/registry.ts","HarakatOffices_Server/src/core/mail/adapters/ses.transport.ts","HarakatOffices_Server/src/core/mail/address.ts","HarakatOffices_Server/src/core/mail/attachments.service.ts","HarakatOffices_Server/src/core/mail/audit.ts","HarakatOffices_Server/src/core/mail/causes.ts","HarakatOffices_Server/src/core/mail/domain-name.ts","HarakatOffices_Server/src/core/mail/domain.service.ts","HarakatOffices_Server/src/core/mail/forward.ts","HarakatOffices_Server/src/core/mail/inbound.service.ts","HarakatOffices_Server/src/core/mail/index.ts","HarakatOffices_Server/src/core/mail/ingest.service.ts","HarakatOffices_Server/src/core/mail/judge-rubric.ts","HarakatOffices_Server/src/core/mail/judge.ts","HarakatOffices_Server/src/core/mail/lifecycle.service.ts","HarakatOffices_Server/src/core/mail/mailbox.service.ts","HarakatOffices_Server/src/core/mail/mount.ts","HarakatOffices_Server/src/core/mail/outbound.service.ts","HarakatOffices_Server/src/core/mail/provider.ts","HarakatOffices_Server/src/core/mail/relay-map.ts","HarakatOffices_Server/src/core/mail/resolver.ts","HarakatOffices_Server/src/core/mail/search.service.ts","HarakatOffices_Server/src/core/mail/ses-identity.service.ts","HarakatOffices_Server/src/core/mail/store.ts","HarakatOffices_Server/src/core/mail/threading.ts","HarakatOffices_Server/src/core/mail/wake.ts","HarakatOffices_Server/src/core/outbound/index.ts","HarakatOffices_Server/src/core/outbound/inventory.ts","HarakatOffices_Server/src/core/pagination/cursor.ts","HarakatOffices_Server/src/core/pagination/http.ts","HarakatOffices_Server/src/core/pagination/index.ts","HarakatOffices_Server/src/core/pagination/inventory.ts","HarakatOffices_Server/src/core/pagination/keyset.ts","HarakatOffices_Server/src/core/pagination/request.ts","HarakatOffices_Server/src/core/policy/conflict-recorder.ts","HarakatOffices_Server/src/core/prompt-inspector/capture.ts","HarakatOffices_Server/src/core/prompt-inspector/envelope.ts","HarakatOffices_Server/src/core/prompt-inspector/index.ts","HarakatOffices_Server/src/core/prompt-inspector/masking.ts","HarakatOffices_Server/src/core/prompt-inspector/store.ts","HarakatOffices_Server/src/core/queue/byte-gate.ts","HarakatOffices_Server/src/core/queue/connection.ts","HarakatOffices_Server/src/core/queue/index.ts","HarakatOffices_Server/src/core/queue/queues.ts","HarakatOffices_Server/src/core/queue/types.ts","HarakatOffices_Server/src/core/queue/workers/archive-extract.worker.ts","HarakatOffices_Server/src/core/queue/workers/clean-document.worker.ts","HarakatOffices_Server/src/core/queue/workers/drive-download.worker.ts","HarakatOffices_Server/src/core/queue/workers/embed-batch-poll.worker.ts","HarakatOffices_Server/src/core/queue/workers/enrich-batch-poll.worker.ts","HarakatOffices_Server/src/core/queue/workers/enrich-document.worker.ts","HarakatOffices_Server/src/core/queue/workers/entity-extract.worker.ts","HarakatOffices_Server/src/core/queue/workers/folder-rollup.worker.ts","HarakatOffices_Server/src/core/queue/workers/ocr-batch-poll.worker.ts","HarakatOffices_Server/src/core/queue/workers/parse-extract.worker.ts","HarakatOffices_Server/src/core/queue/workers/recurring-dispatch.worker.ts","HarakatOffices_Server/src/core/queue/workers/retrieval-v2-helpers.ts","HarakatOffices_Server/src/core/queue/workers/scheduled-agent.worker.ts","HarakatOffices_Server/src/core/queue/workers/search-index.worker.ts","HarakatOffices_Server/src/core/queue/workers/toc-rebuild.worker.ts","HarakatOffices_Server/src/core/queue/workers/vector-index.worker.ts","HarakatOffices_Server/src/core/queue/workers/watch-poll.worker.ts","HarakatOffices_Server/src/core/sandbox/backend.ts","HarakatOffices_Server/src/core/sandbox/credentials.ts","HarakatOffices_Server/src/core/sandbox/egress-policy.ts","HarakatOffices_Server/src/core/sandbox/index.ts","HarakatOffices_Server/src/core/sandbox/local/docker.ts","HarakatOffices_Server/src/core/sandbox/local/local-backend.ts","HarakatOffices_Server/src/core/sandbox/login.ts","HarakatOffices_Server/src/core/sandbox/process.ts","HarakatOffices_Server/src/core/sandbox/proxy/config.ts","HarakatOffices_Server/src/core/sandbox/proxy/proxy-manager.ts","HarakatOffices_Server/src/core/sandbox/proxy/proxy-worker.cjs","HarakatOffices_Server/src/core/sandbox/proxy/worker-bridge.ts","HarakatOffices_Server/src/core/sandbox/routing.ts","HarakatOffices_Server/src/core/sandbox/sandbox.service.ts","HarakatOffices_Server/src/core/sandbox/scope.ts","HarakatOffices_Server/src/core/sandbox/types.ts","HarakatOffices_Server/src/core/security/delegation/attestation.ts","HarakatOffices_Server/src/core/security/delegation/authority.ts","HarakatOffices_Server/src/core/security/delegation/delegation.service.ts","HarakatOffices_Server/src/core/security/delegation/index.ts","HarakatOffices_Server/src/core/security/delegation/scope.ts","HarakatOffices_Server/src/core/security/egress/guarded-fetch.ts","HarakatOffices_Server/src/core/security/egress/index.ts","HarakatOffices_Server/src/core/security/egress/inventory.ts","HarakatOffices_Server/src/core/security/egress/ip-classify.ts","HarakatOffices_Server/src/core/security/egress/scrub.ts","HarakatOffices_Server/src/core/security/egress/url-policy.ts","HarakatOffices_Server/src/core/security/kms/envelope.ts","HarakatOffices_Server/src/core/security/kms/kms-cipher.ts","HarakatOffices_Server/src/core/security/kms/openbao-client.ts","HarakatOffices_Server/src/core/security/link/audit-chain.ts","HarakatOffices_Server/src/core/security/link/disclosure-gate.ts","HarakatOffices_Server/src/core/security/link/index.ts","HarakatOffices_Server/src/core/security/link/link.service.ts","HarakatOffices_Server/src/core/security/link/types.ts","HarakatOffices_Server/src/core/security/screening/index.ts","HarakatOffices_Server/src/core/security/screening/provenance.ts","HarakatOffices_Server/src/core/security/screening/rubric.ts","HarakatOffices_Server/src/core/security/screening/screen.ts","HarakatOffices_Server/src/core/security/secret-cipher.ts","HarakatOffices_Server/src/core/security/source-auth/ai-fetch.ts","HarakatOffices_Server/src/core/security/source-auth/config.ts","HarakatOffices_Server/src/core/security/source-auth/index.ts","HarakatOffices_Server/src/core/security/source-auth/sign.ts","HarakatOffices_Server/src/core/security/spiffe/index.ts","HarakatOffices_Server/src/core/security/spiffe/mutual-auth.ts","HarakatOffices_Server/src/core/security/spiffe/spiffe-id.ts","HarakatOffices_Server/src/core/security/spiffe/svid.ts","HarakatOffices_Server/src/core/seed/platform-skills.ts","HarakatOffices_Server/src/core/services/email.service.ts","HarakatOffices_Server/src/core/stream/index.ts","HarakatOffices_Server/src/core/stream/replay-log.ts","HarakatOffices_Server/src/core/tenancy/operator-global.ts","HarakatOffices_Server/src/core/tenancy/schema-model.ts","HarakatOffices_Server/src/core/tenancy/tenant-boundary.ts","HarakatOffices_Server/src/core/tenancy/tenant-scoping-rules.ts","HarakatOffices_Server/src/core/tenancy/tenant-surface.ts","HarakatOffices_Server/src/core/tenant-container/credentials.ts","HarakatOffices_Server/src/core/tenant-container/datasource.ts","HarakatOffices_Server/src/core/tenant-container/lifecycle.ts","HarakatOffices_Server/src/core/tenant-container/mover.ts","HarakatOffices_Server/src/core/tenant-container/placement.ts","HarakatOffices_Server/src/core/tenant-container/provision.ts","HarakatOffices_Server/src/core/tenant-container/route.ts","HarakatOffices_Server/src/core/tenant-container/schema-sources.ts","HarakatOffices_Server/src/core/tenant-container/transitions.ts","HarakatOffices_Server/src/core/text/sanitize.ts","HarakatOffices_Server/src/core/triggers/axes.ts","HarakatOffices_Server/src/core/triggers/claim-store.ts","HarakatOffices_Server/src/core/triggers/consent-store.ts","HarakatOffices_Server/src/core/triggers/consent.ts","HarakatOffices_Server/src/core/triggers/conversation-lock.ts","HarakatOffices_Server/src/core/triggers/delivery.ts","HarakatOffices_Server/src/core/triggers/destination.ts","HarakatOffices_Server/src/core/triggers/dispatch-store.ts","HarakatOffices_Server/src/core/triggers/event-kind.ts","HarakatOffices_Server/src/core/triggers/index.ts","HarakatOffices_Server/src/core/triggers/keys.ts","HarakatOffices_Server/src/core/triggers/memory-guard.ts","HarakatOffices_Server/src/core/triggers/outbound-rate.ts","HarakatOffices_Server/src/core/triggers/provenance.ts","HarakatOffices_Server/src/core/triggers/recurring-dispatcher.ts","HarakatOffices_Server/src/core/triggers/run-automated-turn.ts","HarakatOffices_Server/src/core/triggers/schedule-expression.ts","HarakatOffices_Server/src/core/triggers/silence.ts","HarakatOffices_Server/src/core/triggers/sub-thread.ts","HarakatOffices_Server/src/core/triggers/thread-open.ts","HarakatOffices_Server/src/core/triggers/types.ts","HarakatOffices_Server/src/core/voice/voice-storage.service.ts","HarakatOffices_Server/src/core/voice/voice-sweep.service.ts","HarakatOffices_Server/src/core/watches/index.ts","HarakatOffices_Server/src/core/watches/poller.ts","HarakatOffices_Server/src/core/watches/subjects.ts","HarakatOffices_Server/src/core/watches/types.ts","HarakatOffices_Server/src/core/watches/watch-store.ts","HarakatOffices_Server/src/core/write-receipt/erp.ts","HarakatOffices_Server/src/core/write-receipt/index.ts","HarakatOffices_Server/src/lib/prisma.ts","HarakatOffices_Server/src/middleware/access-claims.ts","HarakatOffices_Server/src/middleware/agent-capability.ts","HarakatOffices_Server/src/middleware/auth.ts","HarakatOffices_Server/src/middleware/cors.ts","HarakatOffices_Server/src/middleware/drain.ts","HarakatOffices_Server/src/middleware/errorHandler.ts","HarakatOffices_Server/src/middleware/meeting-callback-auth.ts","HarakatOffices_Server/src/middleware/org-authority-barrier.ts","HarakatOffices_Server/src/middleware/rate-limit.ts","HarakatOffices_Server/src/middleware/request-timing.ts","HarakatOffices_Server/src/middleware/startup-auth.ts","HarakatOffices_Server/src/modules/admin/admin.controller.ts","HarakatOffices_Server/src/modules/admin/admin.outbound.ts","HarakatOffices_Server/src/modules/admin/auth.controller.ts","HarakatOffices_Server/src/modules/admin/inference.routes.ts","HarakatOffices_Server/src/modules/admin/last-admin.ts","HarakatOffices_Server/src/modules/admin/providers/providers.controller.ts","HarakatOffices_Server/src/modules/admin/providers/providers.outbound.ts","HarakatOffices_Server/src/modules/admin/providers/providers.routes.ts","HarakatOffices_Server/src/modules/admin/provisioning.service.ts","HarakatOffices_Server/src/modules/admin/queues.routes.ts","HarakatOffices_Server/src/modules/admin/services.controller.ts","HarakatOffices_Server/src/modules/admin/startups.controller.ts","HarakatOffices_Server/src/modules/admin/startups.routes.ts","HarakatOffices_Server/src/modules/admin/support.controller.ts","HarakatOffices_Server/src/modules/admin/tenant-profile.service.ts","HarakatOffices_Server/src/modules/agent-board/agent-board.routes.ts","HarakatOffices_Server/src/modules/agent-board/avatar.test.ts","HarakatOffices_Server/src/modules/agent-board/avatar.ts","HarakatOffices_Server/src/modules/agent-board/board-item.controller.ts","HarakatOffices_Server/src/modules/agent-board/board-item.inbound.ts","HarakatOffices_Server/src/modules/agent-board/board-item.outbound.ts","HarakatOffices_Server/src/modules/agent-board/board-item.routes.ts","HarakatOffices_Server/src/modules/agent-board/board-item.service.test.ts","HarakatOffices_Server/src/modules/agent-board/board-item.service.ts","HarakatOffices_Server/src/modules/agent-board/conversation-state.controller.ts","HarakatOffices_Server/src/modules/agent-board/conversation-state.service.test.ts","HarakatOffices_Server/src/modules/agent-board/conversation-state.service.ts","HarakatOffices_Server/src/modules/agent-board/inbox-ephemeral.integration.test.ts","HarakatOffices_Server/src/modules/agent-board/inbox.controller.ts","HarakatOffices_Server/src/modules/agent-board/inbox.routes.ts","HarakatOffices_Server/src/modules/agent-board/inbox.service.test.ts","HarakatOffices_Server/src/modules/agent-board/inbox.service.ts","HarakatOffices_Server/src/modules/agent-board/notification.service.test.ts","HarakatOffices_Server/src/modules/agent-board/notification.service.ts","HarakatOffices_Server/src/modules/agent-board/realtime.test.ts","HarakatOffices_Server/src/modules/agent-board/realtime.ts","HarakatOffices_Server/src/modules/agent-board/redis-conn.ts","HarakatOffices_Server/src/modules/agent-board/single-assistant.test.ts","HarakatOffices_Server/src/modules/agent-board/single-assistant.ts","HarakatOffices_Server/src/modules/agent-board/stream.controller.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.controller.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.outbound.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.routes.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.service.ts","HarakatOffices_Server/src/modules/agent-directory/agent-session-cleanup.service.ts","HarakatOffices_Server/src/modules/agent-directory/agent-session-docker.service.ts","HarakatOffices_Server/src/modules/ai-analytics/ai-analytics.controller.ts","HarakatOffices_Server/src/modules/ai-analytics/ai-analytics.routes.ts","HarakatOffices_Server/src/modules/ai-analytics/ai-analytics.service.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.controller.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.inbound.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.outbound.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.proxy.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.routes.ts","HarakatOffices_Server/src/modules/artifacts/people.ts","HarakatOffices_Server/src/modules/artifacts/viewer-session.ts","HarakatOffices_Server/src/modules/audit/audit.controller.ts","HarakatOffices_Server/src/modules/audit/audit.outbound.ts","HarakatOffices_Server/src/modules/audit/audit.routes.ts","HarakatOffices_Server/src/modules/audit/audit.service.ts","HarakatOffices_Server/src/modules/autoload/autoload.controller.ts","HarakatOffices_Server/src/modules/autoload/autoload.outbound.ts","HarakatOffices_Server/src/modules/autoload/autoload.routes.ts","HarakatOffices_Server/src/modules/autoload/autoload.service.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.controller.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.inbound.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.routes.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.service.ts","HarakatOffices_Server/src/modules/automated-work/schedule-status.ts","HarakatOffices_Server/src/modules/automated-work/schedules.service.ts","HarakatOffices_Server/src/modules/automated-work/watches.service.ts","HarakatOffices_Server/src/modules/board/weekly-rollup.service.ts","HarakatOffices_Server/src/modules/capabilities/augmentation.service.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.controller.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.routes.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.service.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.types.ts","HarakatOffices_Server/src/modules/conversation-access/decide.ts","HarakatOffices_Server/src/modules/conversation-access/index.ts","HarakatOffices_Server/src/modules/conversation-access/store.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/conversation-lifecycle.service.integration.test.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/conversation-lifecycle.service.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/lifecycle-schema.integration.test.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/participants.service.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/thread-axes.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-authorize.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-producer.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-recall.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-search.service.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-triggers.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-vector.service.ts","HarakatOffices_Server/src/modules/conversation-memory/section-tree.ts","HarakatOffices_Server/src/modules/dashboard/apply-layout.integration.test.ts","HarakatOffices_Server/src/modules/dashboard/dashboard-layout.integration.test.ts","HarakatOffices_Server/src/modules/dashboard/dashboard-layout.service.ts","HarakatOffices_Server/src/modules/dashboard/dashboard.controller.ts","HarakatOffices_Server/src/modules/dashboard/widget-data.integration.test.ts","HarakatOffices_Server/src/modules/dashboard/widget-data.outbound.ts","HarakatOffices_Server/src/modules/dashboard/widget-data.service.ts","HarakatOffices_Server/src/modules/dashboard/widget-registry.test.ts","HarakatOffices_Server/src/modules/dashboard/widget-registry.ts","HarakatOffices_Server/src/modules/document/agent-images.ts","HarakatOffices_Server/src/modules/document/agent-plan.ts","HarakatOffices_Server/src/modules/document/agent-render.ts","HarakatOffices_Server/src/modules/document/branding.ts","HarakatOffices_Server/src/modules/document/document.types.ts","HarakatOffices_Server/src/modules/document/format.ts","HarakatOffices_Server/src/modules/document/gather.ts","HarakatOffices_Server/src/modules/document/gotenberg.client.ts","HarakatOffices_Server/src/modules/document/index.ts","HarakatOffices_Server/src/modules/document/labels.ts","HarakatOffices_Server/src/modules/document/mappers.ts","HarakatOffices_Server/src/modules/document/registry.ts","HarakatOffices_Server/src/modules/document/render.ts","HarakatOffices_Server/src/modules/document/templates/html.ts","HarakatOffices_Server/src/modules/document/templates/index.ts","HarakatOffices_Server/src/modules/document/templates/invoice.ts","HarakatOffices_Server/src/modules/document/templates/layout.ts","HarakatOffices_Server/src/modules/document/templates/payslip.ts","HarakatOffices_Server/src/modules/document/templates/purchase-order.ts","HarakatOffices_Server/src/modules/document/templates/report-template.ts","HarakatOffices_Server/src/modules/document/templates/sales.ts","HarakatOffices_Server/src/modules/eri/eri-inspection.integration.test.ts","HarakatOffices_Server/src/modules/eri/eri-schema.integration.test.ts","HarakatOffices_Server/src/modules/eri/eri.controller.ts","HarakatOffices_Server/src/modules/eri/eri.outbound.ts","HarakatOffices_Server/src/modules/eri/eri.service.integration.test.ts","HarakatOffices_Server/src/modules/eri/eri.service.ts","HarakatOffices_Server/src/modules/eri/learning.integration.test.ts","HarakatOffices_Server/src/modules/eri/learning.service.ts","HarakatOffices_Server/src/modules/eri/ops.controller.ts","HarakatOffices_Server/src/modules/eri/ops.integration.test.ts","HarakatOffices_Server/src/modules/eri/ops.outbound.ts","HarakatOffices_Server/src/modules/eri/ops.service.ts","HarakatOffices_Server/src/modules/erp/company-mirror-decision.ts","HarakatOffices_Server/src/modules/erp/customization/customization-catalog.ts","HarakatOffices_Server/src/modules/erp/customization/entity-def.ts","HarakatOffices_Server/src/modules/erp/customization/erp-changesets.service.ts","HarakatOffices_Server/src/modules/erp/customization/erp-customization.service.ts","HarakatOffices_Server/src/modules/erp/customization/erp-vocabulary.test.ts","HarakatOffices_Server/src/modules/erp/customization/erp-vocabulary.ts","HarakatOffices_Server/src/modules/erp/customization/identity-fields.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-action-hash.test.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-action-hash.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-allocation.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-entity-hash.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-overlay-hash.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-overlay-map.ts","HarakatOffices_Server/src/modules/erp/customization/ops-registry.test.ts","HarakatOffices_Server/src/modules/erp/customization/ops-registry.ts","HarakatOffices_Server/src/modules/erp/customization/packs/awqaf-pack.v1.ts","HarakatOffices_Server/src/modules/erp/customization/packs/awqaf-pack.v1_1.ts","HarakatOffices_Server/src/modules/erp/customization/packs/awqaf-pack.v1_2.ts","HarakatOffices_Server/src/modules/erp/customization/protected-models.ts","HarakatOffices_Server/src/modules/erp/erp-access-role.test.ts","HarakatOffices_Server/src/modules/erp/erp-access-role.ts","HarakatOffices_Server/src/modules/erp/erp-anchor-links.test.ts","HarakatOffices_Server/src/modules/erp/erp-anchor-links.ts","HarakatOffices_Server/src/modules/erp/erp-anchor.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-anchor.service.ts","HarakatOffices_Server/src/modules/erp/erp-apps.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-apps.service.ts","HarakatOffices_Server/src/modules/erp/erp-authority.service.ts","HarakatOffices_Server/src/modules/erp/erp-connections.service.ts","HarakatOffices_Server/src/modules/erp/erp-currency-seed.ts","HarakatOffices_Server/src/modules/erp/erp-error-degradation.test.ts","HarakatOffices_Server/src/modules/erp/erp-files.controller.ts","HarakatOffices_Server/src/modules/erp/erp-files.outbound.ts","HarakatOffices_Server/src/modules/erp/erp-files.service.ts","HarakatOffices_Server/src/modules/erp/erp-fleet.service.ts","HarakatOffices_Server/src/modules/erp/erp-gateway.client.ts","HarakatOffices_Server/src/modules/erp/erp-groups.test.ts","HarakatOffices_Server/src/modules/erp/erp-groups.ts","HarakatOffices_Server/src/modules/erp/erp-identity.ts","HarakatOffices_Server/src/modules/erp/erp-index-hooks.ts","HarakatOffices_Server/src/modules/erp/erp-index.service.ts","HarakatOffices_Server/src/modules/erp/erp-mcp-catalog.ts","HarakatOffices_Server/src/modules/erp/erp-mcp-dispatch.domain-coercion.test.ts","HarakatOffices_Server/src/modules/erp/erp-mcp-dispatch.ts","HarakatOffices_Server/src/modules/erp/erp-model-gate.ts","HarakatOffices_Server/src/modules/erp/erp-model-map.ts","HarakatOffices_Server/src/modules/erp/erp-provisioning.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-provisioning.service.ts","HarakatOffices_Server/src/modules/erp/erp-run-apps.ts","HarakatOffices_Server/src/modules/erp/erp-scope.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-scope.service.ts","HarakatOffices_Server/src/modules/erp/erp-stage-seed.test.ts","HarakatOffices_Server/src/modules/erp/erp-stage-seed.ts","HarakatOffices_Server/src/modules/erp/erp-target.ts","HarakatOffices_Server/src/modules/erp/erp-tenant-fields.ts","HarakatOffices_Server/src/modules/erp/erp-vat-seed.test.ts","HarakatOffices_Server/src/modules/erp/erp-vat-seed.ts","HarakatOffices_Server/src/modules/erp/erp-visibility.ts","HarakatOffices_Server/src/modules/erp/erp.controller.ts","HarakatOffices_Server/src/modules/erp/erp.routes.ts","HarakatOffices_Server/src/modules/erp/erp.service.test.ts","HarakatOffices_Server/src/modules/erp/erp.service.ts","HarakatOffices_Server/src/modules/erp/erp.types.ts","HarakatOffices_Server/src/modules/erp/fiscal-calendar.ts","HarakatOffices_Server/src/modules/erp/fiscal-identity.ts","HarakatOffices_Server/src/modules/erp/kernel-claims.test.ts","HarakatOffices_Server/src/modules/erp/kernel-claims.ts","HarakatOffices_Server/src/modules/erp/kernel-company.ts","HarakatOffices_Server/src/modules/erp/kernel-domain-compat.ts","HarakatOffices_Server/src/modules/erp/kernel-employee-projection.ts","HarakatOffices_Server/src/modules/erp/kernel-people-refs.ts","HarakatOffices_Server/src/modules/erp/kernel-route.test.ts","HarakatOffices_Server/src/modules/erp/kernel-route.ts","HarakatOffices_Server/src/modules/erp/kernel-stock-driver.ts","HarakatOffices_Server/src/modules/erp/kernel-tier.ts","HarakatOffices_Server/src/modules/governance/governance.controller.ts","HarakatOffices_Server/src/modules/governance/governance.routes.ts","HarakatOffices_Server/src/modules/governance/governance.service.ts","HarakatOffices_Server/src/modules/governance/prompts.controller.ts","HarakatOffices_Server/src/modules/health/health.routes.ts","HarakatOffices_Server/src/modules/health/health.service.test.ts","HarakatOffices_Server/src/modules/health/health.service.ts","HarakatOffices_Server/src/modules/hermes-routing/hermes-routing.controller.ts","HarakatOffices_Server/src/modules/hermes-routing/hermes-routing.routes.ts","HarakatOffices_Server/src/modules/integration-health/integration-health.controller.ts","HarakatOffices_Server/src/modules/integration-health/integration-health.routes.ts","HarakatOffices_Server/src/modules/integration-health/integration-health.service.ts","HarakatOffices_Server/src/modules/inter-assistant/answer-scope.ts","HarakatOffices_Server/src/modules/inter-assistant/ask-policy.ts","HarakatOffices_Server/src/modules/inter-assistant/ask-runner.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.controller.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.outbound.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.routes.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.service.ts","HarakatOffices_Server/src/modules/internal-delegation/internal-delegation.controller.ts","HarakatOffices_Server/src/modules/internal-delegation/internal-delegation.service.ts","HarakatOffices_Server/src/modules/knowledge/context-events.service.ts","HarakatOffices_Server/src/modules/knowledge/coverage-reconciler.service.ts","HarakatOffices_Server/src/modules/knowledge/doc-chunking.ts","HarakatOffices_Server/src/modules/knowledge/document-text.ts","HarakatOffices_Server/src/modules/knowledge/embed-batch.service.ts","HarakatOffices_Server/src/modules/knowledge/embed-bucket.ts","HarakatOffices_Server/src/modules/knowledge/evidence-schema.integration.test.ts","HarakatOffices_Server/src/modules/knowledge/evidence.service.integration.test.ts","HarakatOffices_Server/src/modules/knowledge/evidence.service.ts","HarakatOffices_Server/src/modules/knowledge/freshness-rider.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.controller.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.inbound.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.outbound.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.routes.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.service.ts","HarakatOffices_Server/src/modules/knowledge/meaning-search.ts","HarakatOffices_Server/src/modules/knowledge/mount-recall.ts","HarakatOffices_Server/src/modules/knowledge/mounts.ts","HarakatOffices_Server/src/modules/knowledge/quick-search.service.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-cache.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-quality.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-v2-flag.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-v2.service.ts","HarakatOffices_Server/src/modules/knowledge/search-evidence-wiring.integration.test.ts","HarakatOffices_Server/src/modules/knowledge/slot-ladder.ts","HarakatOffices_Server/src/modules/knowledge/vector-indexer.service.ts","HarakatOffices_Server/src/modules/learning/courses.controller.ts","HarakatOffices_Server/src/modules/learning/courses.outbound.ts","HarakatOffices_Server/src/modules/mail/mail.controller.ts","HarakatOffices_Server/src/modules/mail/mail.inbound.ts","HarakatOffices_Server/src/modules/mail/mail.outbound.ts","HarakatOffices_Server/src/modules/mail/mail.routes.ts","HarakatOffices_Server/src/modules/marketplace/agents.controller.ts","HarakatOffices_Server/src/modules/marketplace/agents.inbound.ts","HarakatOffices_Server/src/modules/marketplace/agents.outbound.ts","HarakatOffices_Server/src/modules/mcp/circuit-breaker.ts","HarakatOffices_Server/src/modules/mcp/mcp.controller.ts","HarakatOffices_Server/src/modules/mcp/mcp.routes.ts","HarakatOffices_Server/src/modules/mcp/mcp.service.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.controller.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.outbound.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.routes.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.service.ts","HarakatOffices_Server/src/modules/meeting/calendar-rule-scout.service.ts","HarakatOffices_Server/src/modules/meeting/meeting.controller.ts","HarakatOffices_Server/src/modules/meeting/meeting.routes.ts","HarakatOffices_Server/src/modules/meeting/meeting.service.ts","HarakatOffices_Server/src/modules/meeting/recording-email.ts","HarakatOffices_Server/src/modules/meeting/recording.controller.ts","HarakatOffices_Server/src/modules/meeting/recording.routes.ts","HarakatOffices_Server/src/modules/meeting/recording.service.ts","HarakatOffices_Server/src/modules/meeting/regenerate.service.ts","HarakatOffices_Server/src/modules/meeting/transcript-batch.service.ts","HarakatOffices_Server/src/modules/meeting/transcript-ingest.service.ts","HarakatOffices_Server/src/modules/meeting/url-normalizer.ts","HarakatOffices_Server/src/modules/memory/memory.controller.ts","HarakatOffices_Server/src/modules/memory/memory.outbound.ts","HarakatOffices_Server/src/modules/memory/memory.routes.ts","HarakatOffices_Server/src/modules/memory/memory.service.ts","HarakatOffices_Server/src/modules/mutations/mutation-appliers.ts","HarakatOffices_Server/src/modules/mutations/mutations.controller.ts","HarakatOffices_Server/src/modules/mutations/mutations.outbound.ts","HarakatOffices_Server/src/modules/mutations/mutations.routes.ts","HarakatOffices_Server/src/modules/mutations/mutations.service.ts","HarakatOffices_Server/src/modules/notifications/devices.service.ts","HarakatOffices_Server/src/modules/notifications/notification.service.test.ts","HarakatOffices_Server/src/modules/notifications/notification.service.ts","HarakatOffices_Server/src/modules/notifications/notifications.controller.ts","HarakatOffices_Server/src/modules/notifications/notifications.outbound.ts","HarakatOffices_Server/src/modules/notifications/notifications.realtime.ts","HarakatOffices_Server/src/modules/notifications/notifications.routes.ts","HarakatOffices_Server/src/modules/notifications/push.service.ts","HarakatOffices_Server/src/modules/notifications/recipients.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-draft.integration.test.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-draft.service.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-feed.integration.test.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-feed.service.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-persistence.integration.test.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.controller.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.routes.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.service.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.types.ts","HarakatOffices_Server/src/modules/packs/catalog/dentist.v1.ts","HarakatOffices_Server/src/modules/packs/index.ts","HarakatOffices_Server/src/modules/packs/pack-admin.service.ts","HarakatOffices_Server/src/modules/packs/pack-collision.ts","HarakatOffices_Server/src/modules/packs/pack-contract.ts","HarakatOffices_Server/src/modules/packs/pack-fetcher.ts","HarakatOffices_Server/src/modules/packs/pack-install.service.ts","HarakatOffices_Server/src/modules/packs/pack-planner.ts","HarakatOffices_Server/src/modules/packs/pack-resolution.ts","HarakatOffices_Server/src/modules/packs/pack-source.service.ts","HarakatOffices_Server/src/modules/packs/pack-sync.service.ts","HarakatOffices_Server/src/modules/packs/pack-tenant.service.ts","HarakatOffices_Server/src/modules/packs/pack-trust.ts","HarakatOffices_Server/src/modules/packs/packs.controller.ts","HarakatOffices_Server/src/modules/packs/packs.inbound.ts","HarakatOffices_Server/src/modules/packs/packs.outbound.ts","HarakatOffices_Server/src/modules/packs/packs.routes.ts","HarakatOffices_Server/src/modules/pages/compile.ts","HarakatOffices_Server/src/modules/pages/condition.ts","HarakatOffices_Server/src/modules/pages/flow.schema.ts","HarakatOffices_Server/src/modules/pages/flow.types.ts","HarakatOffices_Server/src/modules/pages/index.ts","HarakatOffices_Server/src/modules/pages/packs/awqaf-pages.v1.ts","HarakatOffices_Server/src/modules/pages/page-doc.ops.ts","HarakatOffices_Server/src/modules/pages/page-doc.schema.ts","HarakatOffices_Server/src/modules/pages/page-doc.service.ts","HarakatOffices_Server/src/modules/pages/page-doc.types.ts","HarakatOffices_Server/src/modules/pages/page.controller.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.ingest.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.io.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.kinds.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.service.ts","HarakatOffices_Server/src/modules/parsing/folder-signal.ts","HarakatOffices_Server/src/modules/parsing/ocr-batch-flush.ts","HarakatOffices_Server/src/modules/parsing/ocr-batch.service.ts","HarakatOffices_Server/src/modules/parsing/parsing.config.ts","HarakatOffices_Server/src/modules/parsing/parsing.controller.ts","HarakatOffices_Server/src/modules/parsing/parsing.outbound.ts","HarakatOffices_Server/src/modules/parsing/parsing.routes.ts","HarakatOffices_Server/src/modules/parsing/parsing.service.ts","HarakatOffices_Server/src/modules/policy/policy.controller.ts","HarakatOffices_Server/src/modules/policy/policy.outbound.ts","HarakatOffices_Server/src/modules/policy/policy.routes.ts","HarakatOffices_Server/src/modules/policy/policy.service.ts","HarakatOffices_Server/src/modules/portal/portal.controller.ts","HarakatOffices_Server/src/modules/portal/portal.forms.ts","HarakatOffices_Server/src/modules/portal/portal.routes.ts","HarakatOffices_Server/src/modules/portal/portal.service.ts","HarakatOffices_Server/src/modules/procedures/__fixtures__/procedure-contract-cases.json","HarakatOffices_Server/src/modules/procedures/erp-events.controller.ts","HarakatOffices_Server/src/modules/procedures/procedure-runs.service.ts","HarakatOffices_Server/src/modules/procedures/procedure-triggers.service.ts","HarakatOffices_Server/src/modules/procedures/procedure.outbound.ts","HarakatOffices_Server/src/modules/procedures/procedures.controller.ts","HarakatOffices_Server/src/modules/procedures/procedures.outbound.ts","HarakatOffices_Server/src/modules/procedures/procedures.routes.ts","HarakatOffices_Server/src/modules/procedures/procedures.service.ts","HarakatOffices_Server/src/modules/procedures/procedures.types.ts","HarakatOffices_Server/src/modules/procedures/relay-refcount.ts","HarakatOffices_Server/src/modules/procedures/step-assignee.ts","HarakatOffices_Server/src/modules/procedures/step-decision.service.ts","HarakatOffices_Server/src/modules/procedures/step-schema.ts","HarakatOffices_Server/src/modules/reports/index.ts","HarakatOffices_Server/src/modules/reports/packs/awqaf-reports.v1.ts","HarakatOffices_Server/src/modules/reports/report-compile.ts","HarakatOffices_Server/src/modules/reports/report-model-access.ts","HarakatOffices_Server/src/modules/reports/report-render.ts","HarakatOffices_Server/src/modules/reports/report-template.controller.ts","HarakatOffices_Server/src/modules/reports/report-template.ops.ts","HarakatOffices_Server/src/modules/reports/report-template.schema.ts","HarakatOffices_Server/src/modules/reports/report-template.service.ts","HarakatOffices_Server/src/modules/reports/report-template.types.ts","HarakatOffices_Server/src/modules/rooms/assistant-presence.ts","HarakatOffices_Server/src/modules/rooms/audience-floor.ts","HarakatOffices_Server/src/modules/rooms/audience.service.ts","HarakatOffices_Server/src/modules/rooms/bridge-brake.ts","HarakatOffices_Server/src/modules/rooms/bridge-queue.ts","HarakatOffices_Server/src/modules/rooms/bridge-seat-cause.ts","HarakatOffices_Server/src/modules/rooms/bridge-store.ts","HarakatOffices_Server/src/modules/rooms/bridge-transport.ts","HarakatOffices_Server/src/modules/rooms/bridge-turn.ts","HarakatOffices_Server/src/modules/rooms/bridge-wake.ts","HarakatOffices_Server/src/modules/rooms/bridge.service.ts","HarakatOffices_Server/src/modules/rooms/decision-visibility.ts","HarakatOffices_Server/src/modules/rooms/index.ts","HarakatOffices_Server/src/modules/rooms/member-view.ts","HarakatOffices_Server/src/modules/rooms/mentions.ts","HarakatOffices_Server/src/modules/rooms/nostr-crypto.ts","HarakatOffices_Server/src/modules/rooms/project-room.ts","HarakatOffices_Server/src/modules/rooms/projector.service.ts","HarakatOffices_Server/src/modules/rooms/relay-commands.ts","HarakatOffices_Server/src/modules/rooms/relay-health.ts","HarakatOffices_Server/src/modules/rooms/relay-http.ts","HarakatOffices_Server/src/modules/rooms/relay-registry.service.ts","HarakatOffices_Server/src/modules/rooms/room-conversation.ts","HarakatOffices_Server/src/modules/rooms/room-corpus-floor.ts","HarakatOffices_Server/src/modules/rooms/room-corpus.ts","HarakatOffices_Server/src/modules/rooms/room-event.ts","HarakatOffices_Server/src/modules/rooms/room-identity.ts","HarakatOffices_Server/src/modules/rooms/room-plan.ts","HarakatOffices_Server/src/modules/rooms/room-thread.service.ts","HarakatOffices_Server/src/modules/rooms/room-tools.controller.ts","HarakatOffices_Server/src/modules/rooms/room-tools.outbound.ts","HarakatOffices_Server/src/modules/rooms/room-tools.service.ts","HarakatOffices_Server/src/modules/rooms/rooms.controller.ts","HarakatOffices_Server/src/modules/rooms/rooms.inbound.ts","HarakatOffices_Server/src/modules/rooms/rooms.outbound.ts","HarakatOffices_Server/src/modules/rooms/rooms.routes.ts","HarakatOffices_Server/src/modules/rooms/rooms.service.ts","HarakatOffices_Server/src/modules/rooms/roster.ts","HarakatOffices_Server/src/modules/rooms/scope-label.ts","HarakatOffices_Server/src/modules/rooms/signing.controller.ts","HarakatOffices_Server/src/modules/rooms/signing.inbound.ts","HarakatOffices_Server/src/modules/rooms/signing.outbound.ts","HarakatOffices_Server/src/modules/rooms/signing.routes.ts","HarakatOffices_Server/src/modules/rooms/signing.service.ts","HarakatOffices_Server/src/modules/sandbox/sandbox-process.controller.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.caller.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.controller.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.inbound.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.outbound.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.routes.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.controller.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.outbound.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.routes.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.service.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.controller.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.outbound.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.routes.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.service.ts","HarakatOffices_Server/src/modules/search/authorize.ts","HarakatOffices_Server/src/modules/search/index.ts","HarakatOffices_Server/src/modules/search/name-rows.ts","HarakatOffices_Server/src/modules/search/search.service.ts","HarakatOffices_Server/src/modules/search/types.ts","HarakatOffices_Server/src/modules/search/vector.service.ts","HarakatOffices_Server/src/modules/settings/settings.controller.ts","HarakatOffices_Server/src/modules/settings/settings.inbound.ts","HarakatOffices_Server/src/modules/settings/settings.outbound.ts","HarakatOffices_Server/src/modules/shadow/shadow.controller.ts","HarakatOffices_Server/src/modules/shadow/shadow.routes.ts","HarakatOffices_Server/src/modules/shadow/shadow.service.ts","HarakatOffices_Server/src/modules/skills/skill-class.ts","HarakatOffices_Server/src/modules/skills/skill-scope.ts","HarakatOffices_Server/src/modules/skills/skills.controller.ts","HarakatOffices_Server/src/modules/skills/skills.dto.ts","HarakatOffices_Server/src/modules/skills/skills.outbound.ts","HarakatOffices_Server/src/modules/skills/skills.routes.ts","HarakatOffices_Server/src/modules/skills/skills.service.ts","HarakatOffices_Server/src/modules/startup-auth/assistant-on-accept.integration.test.ts","HarakatOffices_Server/src/modules/startup-auth/refresh.service.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.controller.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.outbound.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.routes.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.service.ts","HarakatOffices_Server/src/modules/startup-documents/startup-documents.controller.ts","HarakatOffices_Server/src/modules/startup-documents/startup-documents.outbound.ts","HarakatOffices_Server/src/modules/startup-documents/startup-documents.routes.ts","HarakatOffices_Server/src/modules/startup-documents/workspace.controller.ts","HarakatOffices_Server/src/modules/startup-documents/workspace.service.ts","HarakatOffices_Server/src/modules/startup/action-result-persist.integration.test.ts","HarakatOffices_Server/src/modules/startup/action-summary.test.ts","HarakatOffices_Server/src/modules/startup/action-summary.ts","HarakatOffices_Server/src/modules/startup/agent-file.controller.ts","HarakatOffices_Server/src/modules/startup/assistant-active.integration.test.ts","HarakatOffices_Server/src/modules/startup/assistant-eri-wiring.integration.test.ts","HarakatOffices_Server/src/modules/startup/assistant-skill-memory.test.ts","HarakatOffices_Server/src/modules/startup/assistant.outbound.ts","HarakatOffices_Server/src/modules/startup/assistant.service.ts","HarakatOffices_Server/src/modules/startup/branch-department-mirror.integration.test.ts","HarakatOffices_Server/src/modules/startup/branch-department-mirror.ts","HarakatOffices_Server/src/modules/startup/branch-head.integration.test.ts","HarakatOffices_Server/src/modules/startup/branch-parent.integration.test.ts","HarakatOffices_Server/src/modules/startup/chat-protocol.ts","HarakatOffices_Server/src/modules/startup/company-delete.integration.test.ts","HarakatOffices_Server/src/modules/startup/company-delete.service.ts","HarakatOffices_Server/src/modules/startup/company-profile.controller.ts","HarakatOffices_Server/src/modules/startup/company-profile.inbound.ts","HarakatOffices_Server/src/modules/startup/company-profile.outbound.ts","HarakatOffices_Server/src/modules/startup/company-profile.routes.ts","HarakatOffices_Server/src/modules/startup/company-profile.service.ts","HarakatOffices_Server/src/modules/startup/connector-notice.ts","HarakatOffices_Server/src/modules/startup/corpus-tree.integration.test.ts","HarakatOffices_Server/src/modules/startup/delegation.controller.ts","HarakatOffices_Server/src/modules/startup/delegation.outbound.ts","HarakatOffices_Server/src/modules/startup/delegation.routes.ts","HarakatOffices_Server/src/modules/startup/drive-acl-review.integration.test.ts","HarakatOffices_Server/src/modules/startup/drive-acl.controller.ts","HarakatOffices_Server/src/modules/startup/drive.inbound.ts","HarakatOffices_Server/src/modules/startup/erp-action.controller.ts","HarakatOffices_Server/src/modules/startup/erp-action.routes.ts","HarakatOffices_Server/src/modules/startup/erp-customization.controller.ts","HarakatOffices_Server/src/modules/startup/erp-customization.routes.ts","HarakatOffices_Server/src/modules/startup/erp-recruitment.controller.ts","HarakatOffices_Server/src/modules/startup/file-upload.controller.ts","HarakatOffices_Server/src/modules/startup/governance-authoring-grant.service.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.controller.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.outbound.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.routes.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.service.ts","HarakatOffices_Server/src/modules/startup/governance-creation-session.service.ts","HarakatOffices_Server/src/modules/startup/governance-draft.integration.test.ts","HarakatOffices_Server/src/modules/startup/governance-draft.service.ts","HarakatOffices_Server/src/modules/startup/governance-integrations.integration.test.ts","HarakatOffices_Server/src/modules/startup/governance-integrations.service.ts","HarakatOffices_Server/src/modules/startup/governance.service.ts","HarakatOffices_Server/src/modules/startup/offboarding/kernel-employee-lifecycle.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding-ownership-registry.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.controller.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.outbound.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.routes.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.service.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.worker.ts","HarakatOffices_Server/src/modules/startup/offboarding/purge-policy.ts","HarakatOffices_Server/src/modules/startup/offboarding/purge.service.ts","HarakatOffices_Server/src/modules/startup/offboarding/purge.worker.ts","HarakatOffices_Server/src/modules/startup/offboarding/seat-release.adapter.ts","HarakatOffices_Server/src/modules/startup/org-authority.controller.ts","HarakatOffices_Server/src/modules/startup/org-authority.flags.ts","HarakatOffices_Server/src/modules/startup/org-authority.outbound.ts","HarakatOffices_Server/src/modules/startup/org-authority.routes.ts","HarakatOffices_Server/src/modules/startup/org-authority.service.ts","HarakatOffices_Server/src/modules/startup/org-erp-kernel-capability.ts","HarakatOffices_Server/src/modules/startup/org-erp-mirror-v2.service.ts","HarakatOffices_Server/src/modules/startup/org-erp-mirror.worker.ts","HarakatOffices_Server/src/modules/startup/org-erp-reconciliation.service.ts","HarakatOffices_Server/src/modules/startup/people-map.integration.test.ts","HarakatOffices_Server/src/modules/startup/personal-governance.controller.ts","HarakatOffices_Server/src/modules/startup/personal-governance.outbound.ts","HarakatOffices_Server/src/modules/startup/personal-governance.service.ts","HarakatOffices_Server/src/modules/startup/preferences.controller.ts","HarakatOffices_Server/src/modules/startup/preferences.routes.ts","HarakatOffices_Server/src/modules/startup/preferences.service.test.ts","HarakatOffices_Server/src/modules/startup/preferences.service.ts","HarakatOffices_Server/src/modules/startup/runtime-access.ts","HarakatOffices_Server/src/modules/startup/session-metadata-schema.test.ts","HarakatOffices_Server/src/modules/startup/sessions.controller.ts","HarakatOffices_Server/src/modules/startup/sessions.integration.test.ts","HarakatOffices_Server/src/modules/startup/sessions.routes.ts","HarakatOffices_Server/src/modules/startup/sessions.service.ts","HarakatOffices_Server/src/modules/startup/startup.controller.ts","HarakatOffices_Server/src/modules/startup/startup.inbound.ts","HarakatOffices_Server/src/modules/startup/startup.outbound.ts","HarakatOffices_Server/src/modules/startup/startup.routes.ts","HarakatOffices_Server/src/modules/startup/startup.service.ts","HarakatOffices_Server/src/modules/startup/suites-removed-apps.integration.test.ts","HarakatOffices_Server/src/modules/startup/suites.controller.ts","HarakatOffices_Server/src/modules/startup/suites.routes.ts","HarakatOffices_Server/src/modules/startup/suites.service.integration.test.ts","HarakatOffices_Server/src/modules/startup/suites.service.test.ts","HarakatOffices_Server/src/modules/startup/suites.service.ts","HarakatOffices_Server/src/modules/startup/support.controller.ts","HarakatOffices_Server/src/modules/startup/support.outbound.ts","HarakatOffices_Server/src/modules/startup/team-erp-access-role.integration.test.ts","HarakatOffices_Server/src/modules/startup/twofa-schema.test.ts","HarakatOffices_Server/src/modules/startup/twofa.controller.ts","HarakatOffices_Server/src/modules/startup/twofa.integration.test.ts","HarakatOffices_Server/src/modules/startup/twofa.routes.ts","HarakatOffices_Server/src/modules/startup/twofa.service.ts","HarakatOffices_Server/src/modules/startup/workspace-profile.controller.ts","HarakatOffices_Server/src/modules/startup/workspace-profile.inbound.ts","HarakatOffices_Server/src/modules/startup/workspace-profile.outbound.ts","HarakatOffices_Server/src/modules/startup/workspace-profile.routes.ts","HarakatOffices_Server/src/modules/startup/workspace-profile.service.ts","HarakatOffices_Server/src/modules/stream/replay.controller.ts","HarakatOffices_Server/src/modules/tasks/tasks.controller.ts","HarakatOffices_Server/src/modules/tasks/tasks.inbound.ts","HarakatOffices_Server/src/modules/tasks/tasks.outbound.ts","HarakatOffices_Server/src/modules/tasks/tasks.routes.ts","HarakatOffices_Server/src/modules/tasks/tasks.service.ts","HarakatOffices_Server/src/modules/templates/admin-templates.controller.ts","HarakatOffices_Server/src/modules/templates/startup-templates.controller.ts","HarakatOffices_Server/src/modules/templates/templates.routes.ts","HarakatOffices_Server/src/modules/templates/templates.service.ts","HarakatOffices_Server/src/modules/tool-gateway/gateway.controller.ts","HarakatOffices_Server/src/modules/tool-gateway/gateway.service.ts","HarakatOffices_Server/src/modules/tool-gateway/policy-degradation.ts","HarakatOffices_Server/src/modules/tool-gateway/policy-guard.ts","HarakatOffices_Server/src/modules/tool-gateway/policy-judge-config.ts","HarakatOffices_Server/src/modules/tool-gateway/policy-judge.service.ts","HarakatOffices_Server/src/modules/tool-gateway/preview-purpose.ts","HarakatOffices_Server/src/modules/tool-registry/access.ts","HarakatOffices_Server/src/modules/tool-registry/tool-registry.controller.ts","HarakatOffices_Server/src/modules/tool-registry/tool-registry.outbound.ts","HarakatOffices_Server/src/modules/tool-registry/tool-registry.routes.ts","HarakatOffices_Server/src/modules/tool-registry/tool-registry.service.ts","HarakatOffices_Server/src/modules/usage-events/usage-events.controller.ts","HarakatOffices_Server/src/modules/usage-events/usage-events.outbound.ts","HarakatOffices_Server/src/modules/usage-events/usage-events.routes.ts","HarakatOffices_Server/src/modules/usage-events/usage-events.service.ts","HarakatOffices_Server/src/modules/vendors/vendor-asks.ts","HarakatOffices_Server/src/modules/vendors/vendor-links.controller.ts","HarakatOffices_Server/src/modules/vendors/vendor-links.routes.ts","HarakatOffices_Server/src/modules/vendors/vendor-links.service.ts","HarakatOffices_Server/src/modules/vendors/vendors-sweep.service.ts","HarakatOffices_Server/src/modules/vendors/vendors.access.ts","HarakatOffices_Server/src/modules/vendors/vendors.codes.ts","HarakatOffices_Server/src/modules/vendors/vendors.controller.ts","HarakatOffices_Server/src/modules/vendors/vendors.errors.ts","HarakatOffices_Server/src/modules/vendors/vendors.outbound.ts","HarakatOffices_Server/src/modules/vendors/vendors.routes.ts","HarakatOffices_Server/src/modules/vendors/vendors.service.ts","HarakatOffices_Server/src/modules/virtualea/virtualea.controller.ts","HarakatOffices_Server/src/modules/virtualea/virtualea.inbound.ts","HarakatOffices_Server/src/modules/virtualea/virtualea.routes.ts","HarakatOffices_Server/src/modules/virtualea/virtualea.service.ts","HarakatOffices_Server/src/modules/voice/voice.controller.ts","HarakatOffices_Server/src/modules/voice/voice.routes.ts","HarakatOffices_Server/src/modules/webauthn/credential-cascade.integration.test.ts","HarakatOffices_Server/src/modules/webauthn/webauthn.controller.ts","HarakatOffices_Server/src/modules/webauthn/webauthn.routes.ts","HarakatOffices_Server/src/modules/webauthn/webauthn.service.ts","HarakatOffices_Server/src/routes/admin.routes.ts","HarakatOffices_Server/src/routes/auth.routes.ts","HarakatOffices_Server/src/routes/clients.routes.ts","HarakatOffices_Server/src/routes/dashboard.routes.ts","HarakatOffices_Server/src/routes/index.ts","HarakatOffices_Server/src/routes/learning.routes.ts","HarakatOffices_Server/src/routes/marketplace.routes.ts","HarakatOffices_Server/src/routes/settings.routes.ts","HarakatOffices_Server/src/scripts/_backfill_progress.ts","HarakatOffices_Server/src/scripts/_check_integrations.ts","HarakatOffices_Server/src/scripts/_cleanup_zombies.ts","HarakatOffices_Server/src/scripts/_flush_ocr.ts","HarakatOffices_Server/src/scripts/_ingest_ocr.ts","HarakatOffices_Server/src/scripts/_since.ts","HarakatOffices_Server/src/scripts/_test_refresh.ts","HarakatOffices_Server/src/scripts/a5-route-verify.ts","HarakatOffices_Server/src/scripts/admin-provisioning-selftest.ts","HarakatOffices_Server/src/scripts/admin-session-live-test.ts","HarakatOffices_Server/src/scripts/admin-session-selftest.ts","HarakatOffices_Server/src/scripts/agent-capability-selftest.ts","HarakatOffices_Server/src/scripts/agent-enforcement-e2e.ts","HarakatOffices_Server/src/scripts/agent-plan-render-selftest.ts","HarakatOffices_Server/src/scripts/agent-provenance-selftest.ts","HarakatOffices_Server/src/scripts/agent-render-selftest.ts","HarakatOffices_Server/src/scripts/ai-hop-selftest.ts","HarakatOffices_Server/src/scripts/approval-purpose-live-test.ts","HarakatOffices_Server/src/scripts/approval-purpose-selftest.ts","HarakatOffices_Server/src/scripts/artifacts-e2e.ts","HarakatOffices_Server/src/scripts/artifacts-live-test.ts","HarakatOffices_Server/src/scripts/artifacts-manage-e2e.ts","HarakatOffices_Server/src/scripts/artifacts-manage-selftest.ts","HarakatOffices_Server/src/scripts/artifacts-selftest.ts","HarakatOffices_Server/src/scripts/assistant-truth-e2e.ts","HarakatOffices_Server/src/scripts/assistant-truth-selftest.ts","HarakatOffices_Server/src/scripts/attestation-live-test.ts","HarakatOffices_Server/src/scripts/attestation-selftest.ts","HarakatOffices_Server/src/scripts/audience-floor-live.ts","HarakatOffices_Server/src/scripts/audience-floor-selftest.ts","HarakatOffices_Server/src/scripts/audit-chain-e2e.ts","HarakatOffices_Server/src/scripts/audit-chain-selftest.ts","HarakatOffices_Server/src/scripts/audit-null-tier-nodes.ts","HarakatOffices_Server/src/scripts/authoring-grant-selftest.ts","HarakatOffices_Server/src/scripts/automated-work-live-test.ts","HarakatOffices_Server/src/scripts/automated-work-selftest.ts","HarakatOffices_Server/src/scripts/automation-surface-selftest.ts","HarakatOffices_Server/src/scripts/awqaf-pack-install.ts","HarakatOffices_Server/src/scripts/awqaf-pack-selftest.ts","HarakatOffices_Server/src/scripts/backfill-action-result-messages.ts","HarakatOffices_Server/src/scripts/backfill-erp-employees.ts","HarakatOffices_Server/src/scripts/backfill-kernel-employees.ts","HarakatOffices_Server/src/scripts/backfill-odoo-company-ids.ts","HarakatOffices_Server/src/scripts/backfill-retrieval-v2.ts","HarakatOffices_Server/src/scripts/backfill-unparsed.ts","HarakatOffices_Server/src/scripts/check-2fa-status.ts","HarakatOffices_Server/src/scripts/check-cipher-coverage.ts","HarakatOffices_Server/src/scripts/check-conversation-access.ts","HarakatOffices_Server/src/scripts/check-index-authz.ts","HarakatOffices_Server/src/scripts/check-mail-boundary.ts","HarakatOffices_Server/src/scripts/chunking-selftest.ts","HarakatOffices_Server/src/scripts/cleanup-awqaf-demo.ts","HarakatOffices_Server/src/scripts/cleanup-vertical-tenants.ts","HarakatOffices_Server/src/scripts/connector-status-live-test.ts","HarakatOffices_Server/src/scripts/connector-status-selftest.ts","HarakatOffices_Server/src/scripts/console-gaps-e2e.ts","HarakatOffices_Server/src/scripts/console-gaps-live-test.ts","HarakatOffices_Server/src/scripts/console-gaps-selftest.ts","HarakatOffices_Server/src/scripts/conversation-access-e2e.ts","HarakatOffices_Server/src/scripts/conversation-access-selftest.ts","HarakatOffices_Server/src/scripts/conversation-binding-live-test.ts","HarakatOffices_Server/src/scripts/conversation-binding-selftest.ts","HarakatOffices_Server/src/scripts/corpus-coverage-live-test.ts","HarakatOffices_Server/src/scripts/corpus-coverage-selftest.ts","HarakatOffices_Server/src/scripts/corpus-fetch-selftest.ts","HarakatOffices_Server/src/scripts/corpus-fetch-sources.ts","HarakatOffices_Server/src/scripts/corpus-finish-462.ts","HarakatOffices_Server/src/scripts/corpus-readiness-selftest.ts","HarakatOffices_Server/src/scripts/corpus-v2-converge.ts","HarakatOffices_Server/src/scripts/corpus-v2-isolation-e2e.ts","HarakatOffices_Server/src/scripts/corpus-v2-lane-proof.ts","HarakatOffices_Server/src/scripts/corpus-v2-read.ts","HarakatOffices_Server/src/scripts/corpus-v2-reading-selftest.ts","HarakatOffices_Server/src/scripts/corpus-v2-selftest.ts","HarakatOffices_Server/src/scripts/corpus-v2-shadow.ts","HarakatOffices_Server/src/scripts/corpus-v2-vector-cutover.ts","HarakatOffices_Server/src/scripts/corpus-v2-verify-migration.ts","HarakatOffices_Server/src/scripts/creation-session-gate-selftest.ts","HarakatOffices_Server/src/scripts/delegation-live-test.ts","HarakatOffices_Server/src/scripts/delegation-selftest.ts","HarakatOffices_Server/src/scripts/deploy-drain-selftest.ts","HarakatOffices_Server/src/scripts/derive-node-tiers.ts","HarakatOffices_Server/src/scripts/doc-pipeline-e2e.ts","HarakatOffices_Server/src/scripts/document-selftest.ts","HarakatOffices_Server/src/scripts/document-text-check.ts","HarakatOffices_Server/src/scripts/document-text-selftest.ts","HarakatOffices_Server/src/scripts/drain-check.ts","HarakatOffices_Server/src/scripts/drive-acl-backfill.ts","HarakatOffices_Server/src/scripts/egress-inventory-check.ts","HarakatOffices_Server/src/scripts/egress-selftest.ts","HarakatOffices_Server/src/scripts/embed-backlog-selftest.ts","HarakatOffices_Server/src/scripts/embed-backlog.ts","HarakatOffices_Server/src/scripts/embed-batch-selftest.ts","HarakatOffices_Server/src/scripts/embed-batch-service-selftest.ts","HarakatOffices_Server/src/scripts/embed-bucket-selftest.ts","HarakatOffices_Server/src/scripts/embed-corpus-batch.ts","HarakatOffices_Server/src/scripts/embed-corpus.ts","HarakatOffices_Server/src/scripts/encrypt-corpus.ts","HarakatOffices_Server/src/scripts/encrypt-existing-secrets.ts","HarakatOffices_Server/src/scripts/enrich-batch-heal-selftest.ts","HarakatOffices_Server/src/scripts/enrich-batch.ts","HarakatOffices_Server/src/scripts/enrich-selftest.ts","HarakatOffices_Server/src/scripts/enrich-source-cause-selftest.ts","HarakatOffices_Server/src/scripts/erp-access-live-test.ts","HarakatOffices_Server/src/scripts/erp-action-policy-selftest.ts","HarakatOffices_Server/src/scripts/erp-backfill-owners.ts","HarakatOffices_Server/src/scripts/erp-changesets-selftest.ts","HarakatOffices_Server/src/scripts/erp-company-selftest.ts","HarakatOffices_Server/src/scripts/erp-connections-selftest.ts","HarakatOffices_Server/src/scripts/erp-customize-selftest.ts","HarakatOffices_Server/src/scripts/erp-domain-compat-selftest.ts","HarakatOffices_Server/src/scripts/erp-employee-seam-selftest.ts","HarakatOffices_Server/src/scripts/erp-files-selftest.ts","HarakatOffices_Server/src/scripts/erp-fiscal-identity-selftest.ts","HarakatOffices_Server/src/scripts/erp-fleet-migrate-19.ts","HarakatOffices_Server/src/scripts/erp-gate-cause-selftest.ts","HarakatOffices_Server/src/scripts/erp-index-probe.ts","HarakatOffices_Server/src/scripts/erp-index.ts","HarakatOffices_Server/src/scripts/erp-l3-activate.ts","HarakatOffices_Server/src/scripts/erp-mcp-live-test.ts","HarakatOffices_Server/src/scripts/erp-mcp-selftest.ts","HarakatOffices_Server/src/scripts/erp-model-map-selftest.ts","HarakatOffices_Server/src/scripts/erp-people-refs-report.ts","HarakatOffices_Server/src/scripts/erp-people-refs-selftest.ts","HarakatOffices_Server/src/scripts/erp-per-run-selftest.ts","HarakatOffices_Server/src/scripts/erp-protected-models-selftest.ts","HarakatOffices_Server/src/scripts/erp-provision.ts","HarakatOffices_Server/src/scripts/erp-scoped-human-verify.ts","HarakatOffices_Server/src/scripts/erp-ui-metadata-selftest.ts","HarakatOffices_Server/src/scripts/finalize-startup19-residue.ts","HarakatOffices_Server/src/scripts/finish-startup19-actionable-residue.ts","HarakatOffices_Server/src/scripts/finish-startup19-local-drain.ts","HarakatOffices_Server/src/scripts/fix-awqaf-stages.ts","HarakatOffices_Server/src/scripts/fix-crm-stage-order.ts","HarakatOffices_Server/src/scripts/flip-retrieval-v2.ts","HarakatOffices_Server/src/scripts/folder-signal-check.ts","HarakatOffices_Server/src/scripts/folder-signal-live-test.ts","HarakatOffices_Server/src/scripts/folder-signal-selftest.ts","HarakatOffices_Server/src/scripts/generate-customization-skill.ts","HarakatOffices_Server/src/scripts/governance-authoring-selftest.ts","HarakatOffices_Server/src/scripts/governance-e2e.ts","HarakatOffices_Server/src/scripts/governance-selftest.ts","HarakatOffices_Server/src/scripts/guided-flows-selftest.ts","HarakatOffices_Server/src/scripts/health-selftest.ts","HarakatOffices_Server/src/scripts/inbound-dto-check.ts","HarakatOffices_Server/src/scripts/inbound-dto-selftest.ts","HarakatOffices_Server/src/scripts/incremental-index-19.ts","HarakatOffices_Server/src/scripts/inter-assistant-live-test.ts","HarakatOffices_Server/src/scripts/inter-assistant-selftest.ts","HarakatOffices_Server/src/scripts/kernel-cf-live-proof.ts","HarakatOffices_Server/src/scripts/kernel-claims-push.ts","HarakatOffices_Server/src/scripts/kernel-tier-selftest.ts","HarakatOffices_Server/src/scripts/kernel-verify-e2e.ts","HarakatOffices_Server/src/scripts/kernel-verify-selftest.ts","HarakatOffices_Server/src/scripts/kms-corpus-selftest.ts","HarakatOffices_Server/src/scripts/kms-selftest.ts","HarakatOffices_Server/src/scripts/live-authority-selftest.ts","HarakatOffices_Server/src/scripts/load-corpus-v2.ts","HarakatOffices_Server/src/scripts/mail-forward-e2e.ts","HarakatOffices_Server/src/scripts/mail-forward-live.ts","HarakatOffices_Server/src/scripts/mail-ingest-run.ts","HarakatOffices_Server/src/scripts/mail-pipeline-e2e.ts","HarakatOffices_Server/src/scripts/mail-pipeline-selftest.ts","HarakatOffices_Server/src/scripts/mail-send-live.ts","HarakatOffices_Server/src/scripts/mail-trial-tenant.ts","HarakatOffices_Server/src/scripts/mint-crawl-token.ts","HarakatOffices_Server/src/scripts/mirror-visibility-live-test.ts","HarakatOffices_Server/src/scripts/mirror-visibility-selftest.ts","HarakatOffices_Server/src/scripts/mobile-auth-selftest.ts","HarakatOffices_Server/src/scripts/mount-addressing-selftest.ts","HarakatOffices_Server/src/scripts/mount-recall-live-test.ts","HarakatOffices_Server/src/scripts/mount-surface-selftest.ts","HarakatOffices_Server/src/scripts/name-rows-selftest.ts","HarakatOffices_Server/src/scripts/node-tier-selftest.ts","HarakatOffices_Server/src/scripts/notifications-selftest.ts","HarakatOffices_Server/src/scripts/ocr-batch-selftest.ts","HarakatOffices_Server/src/scripts/odoo-stranded-subsystems-selftest.ts","HarakatOffices_Server/src/scripts/offboarding-selftest.ts","HarakatOffices_Server/src/scripts/openfga-governance-demo.ts","HarakatOffices_Server/src/scripts/openfga-seed.ts","HarakatOffices_Server/src/scripts/openfga-selftest.ts","HarakatOffices_Server/src/scripts/openfga-shadow-compare.ts","HarakatOffices_Server/src/scripts/org-authority-selftest.ts","HarakatOffices_Server/src/scripts/org-erp-mirror-v2-selftest.ts","HarakatOffices_Server/src/scripts/org-erp-reconcile.ts","HarakatOffices_Server/src/scripts/org-erp-reconciliation-selftest.ts","HarakatOffices_Server/src/scripts/orphaned-subsystems-live-test.ts","HarakatOffices_Server/src/scripts/outbound-dto-check.ts","HarakatOffices_Server/src/scripts/outbound-dto-e2e.ts","HarakatOffices_Server/src/scripts/outbound-dto-selftest.ts","HarakatOffices_Server/src/scripts/p2spike-export.ts","HarakatOffices_Server/src/scripts/packs-admin-live-test.ts","HarakatOffices_Server/src/scripts/packs-admin-selftest.ts","HarakatOffices_Server/src/scripts/packs-live-test.ts","HarakatOffices_Server/src/scripts/packs-migration-verify.ts","HarakatOffices_Server/src/scripts/packs-selftest.ts","HarakatOffices_Server/src/scripts/page-context-selftest.ts","HarakatOffices_Server/src/scripts/page-documents-selftest.ts","HarakatOffices_Server/src/scripts/pagination-check.ts","HarakatOffices_Server/src/scripts/pagination-e2e.sh","HarakatOffices_Server/src/scripts/pagination-e2e.ts","HarakatOffices_Server/src/scripts/pagination-selftest.ts","HarakatOffices_Server/src/scripts/personal-governance-selftest.ts","HarakatOffices_Server/src/scripts/personal-procedures-selftest.ts","HarakatOffices_Server/src/scripts/policy-guardrail-selftest.ts","HarakatOffices_Server/src/scripts/policy-judge-degradation-selftest.ts","HarakatOffices_Server/src/scripts/portal-selftest.ts","HarakatOffices_Server/src/scripts/procedure-assignee-live-test.ts","HarakatOffices_Server/src/scripts/procedure-assignee-selftest.ts","HarakatOffices_Server/src/scripts/procedure-triggers-selftest.ts","HarakatOffices_Server/src/scripts/procedures-selftest.ts","HarakatOffices_Server/src/scripts/project-rooms-selftest.ts","HarakatOffices_Server/src/scripts/purge-selftest.ts","HarakatOffices_Server/src/scripts/query-embedder-live-test.ts","HarakatOffices_Server/src/scripts/query-embedder-selftest.ts","HarakatOffices_Server/src/scripts/quick-search-selftest.ts","HarakatOffices_Server/src/scripts/recall-engine-e2e.ts","HarakatOffices_Server/src/scripts/recall-engine-live-test.ts","HarakatOffices_Server/src/scripts/recall-engine-selftest.ts","HarakatOffices_Server/src/scripts/reconcile-coverage.ts","HarakatOffices_Server/src/scripts/reconciler-selftest.ts","HarakatOffices_Server/src/scripts/recurring-dispatcher-live-test.ts","HarakatOffices_Server/src/scripts/recurring-dispatcher-selftest.ts","HarakatOffices_Server/src/scripts/redis-duplicate-check.ts","HarakatOffices_Server/src/scripts/reindex-meili.ts","HarakatOffices_Server/src/scripts/relay-health-live.ts","HarakatOffices_Server/src/scripts/relay-health-selftest.ts","HarakatOffices_Server/src/scripts/relay-refcount-selftest.ts","HarakatOffices_Server/src/scripts/repair-kernel-tiers.ts","HarakatOffices_Server/src/scripts/report-templates-selftest.ts","HarakatOffices_Server/src/scripts/retract-false-no-source.ts","HarakatOffices_Server/src/scripts/retrieval-authz-selftest.ts","HarakatOffices_Server/src/scripts/retrieval-v2-selftest.ts","HarakatOffices_Server/src/scripts/room-approval-visibility-live-test.ts","HarakatOffices_Server/src/scripts/room-bridge-live-test.ts","HarakatOffices_Server/src/scripts/room-bridge-relay-e2e.ts","HarakatOffices_Server/src/scripts/room-bridge-selftest.ts","HarakatOffices_Server/src/scripts/room-corpus-floor-live-test.ts","HarakatOffices_Server/src/scripts/room-corpus-floor-selftest.ts","HarakatOffices_Server/src/scripts/room-event-selftest.ts","HarakatOffices_Server/src/scripts/room-grant-e2e.ts","HarakatOffices_Server/src/scripts/room-grant-selftest.ts","HarakatOffices_Server/src/scripts/room-product-walk.ts","HarakatOffices_Server/src/scripts/room-signing-live-test.ts","HarakatOffices_Server/src/scripts/room-signing-selftest.ts","HarakatOffices_Server/src/scripts/rooms-projector-live-test.ts","HarakatOffices_Server/src/scripts/rooms-projector-selftest.ts","HarakatOffices_Server/src/scripts/rooms-ui-live-test.ts","HarakatOffices_Server/src/scripts/rooms-ui-selftest.ts","HarakatOffices_Server/src/scripts/sandbox-e2e.ts","HarakatOffices_Server/src/scripts/sandbox-live-test.ts","HarakatOffices_Server/src/scripts/sandbox-proxy-live-test.ts","HarakatOffices_Server/src/scripts/sandbox-proxy-selftest.ts","HarakatOffices_Server/src/scripts/sandbox-selftest.ts","HarakatOffices_Server/src/scripts/schema-table-check.ts","HarakatOffices_Server/src/scripts/screening-selftest.ts","HarakatOffices_Server/src/scripts/search-backfill-names.ts","HarakatOffices_Server/src/scripts/search-filter-drift-check.ts","HarakatOffices_Server/src/scripts/seed-admin.ts","HarakatOffices_Server/src/scripts/seed-agents.ts","HarakatOffices_Server/src/scripts/seed-awqaf-assistant-persona.ts","HarakatOffices_Server/src/scripts/seed-awqaf-deep-features.ts","HarakatOffices_Server/src/scripts/seed-awqaf-demo.ts","HarakatOffices_Server/src/scripts/seed-awqaf-finance-docs.ts","HarakatOffices_Server/src/scripts/seed-awqaf-finance-entries.ts","HarakatOffices_Server/src/scripts/seed-awqaf-finance.ts","HarakatOffices_Server/src/scripts/seed-awqaf-fixups.ts","HarakatOffices_Server/src/scripts/seed-awqaf-operations.ts","HarakatOffices_Server/src/scripts/seed-census-org.ts","HarakatOffices_Server/src/scripts/seed-company-personas.ts","HarakatOffices_Server/src/scripts/seed-contacts-skills.ts","HarakatOffices_Server/src/scripts/seed-dashboard-skill.ts","HarakatOffices_Server/src/scripts/seed-erp-mcp.ts","HarakatOffices_Server/src/scripts/seed-livetest-tenant.ts","HarakatOffices_Server/src/scripts/seed-livetest-verticals.ts","HarakatOffices_Server/src/scripts/seed-project-stages.ts","HarakatOffices_Server/src/scripts/seed-tenant-profiles.ts","HarakatOffices_Server/src/scripts/seed-test-users.ts","HarakatOffices_Server/src/scripts/seed-vat-accounts.ts","HarakatOffices_Server/src/scripts/seed-vertical-tenants.ts","HarakatOffices_Server/src/scripts/server-side-tier-live-test.ts","HarakatOffices_Server/src/scripts/server-side-tier-selftest.ts","HarakatOffices_Server/src/scripts/skill-scope-manifest.ts","HarakatOffices_Server/src/scripts/skill-scope-selftest.ts","HarakatOffices_Server/src/scripts/smoke-tier-defense.ts","HarakatOffices_Server/src/scripts/spiffe-e2e.ts","HarakatOffices_Server/src/scripts/startup-outbound-selftest.ts","HarakatOffices_Server/src/scripts/stream-replay-e2e.ts","HarakatOffices_Server/src/scripts/stream-replay-live.ts","HarakatOffices_Server/src/scripts/stream-replay-selftest.ts","HarakatOffices_Server/src/scripts/support/customization-spy-deps.ts","HarakatOffices_Server/src/scripts/sync-status.ts","HarakatOffices_Server/src/scripts/sync-tool-catalog.ts","HarakatOffices_Server/src/scripts/synthetic-principal-check.ts","HarakatOffices_Server/src/scripts/tenant-boundary-check.ts","HarakatOffices_Server/src/scripts/tenant-boundary-selftest.ts","HarakatOffices_Server/src/scripts/tenant-container-check.ts","HarakatOffices_Server/src/scripts/tenant-container-classify.ts","HarakatOffices_Server/src/scripts/tenant-container-live-test.ts","HarakatOffices_Server/src/scripts/tenant-container-selftest.ts","HarakatOffices_Server/src/scripts/tenant-isolation-e2e.ts","HarakatOffices_Server/src/scripts/tenant-owner-selftest.ts","HarakatOffices_Server/src/scripts/tenant-scoping-lint.ts","HarakatOffices_Server/src/scripts/tenant-scoping-selftest.ts","HarakatOffices_Server/src/scripts/tenant-scoping-trigger-check.ts","HarakatOffices_Server/src/scripts/test-access-key.ts","HarakatOffices_Server/src/scripts/test-email.ts","HarakatOffices_Server/src/scripts/thread-axes-live-test.ts","HarakatOffices_Server/src/scripts/thread-axes-selftest.ts","HarakatOffices_Server/src/scripts/tool-registry-diff-selftest.ts","HarakatOffices_Server/src/scripts/toolexec-idempotency-live-test.ts","HarakatOffices_Server/src/scripts/toolexec-idempotency-selftest.ts","HarakatOffices_Server/src/scripts/trigger-runner-e2e.ts","HarakatOffices_Server/src/scripts/trigger-runner-selftest.ts","HarakatOffices_Server/src/scripts/vector-live-test.ts","HarakatOffices_Server/src/scripts/vector-selftest.ts","HarakatOffices_Server/src/scripts/vendors-selftest.ts","HarakatOffices_Server/src/scripts/verify-admin-provisioning.ts","HarakatOffices_Server/src/scripts/verify-awqaf-deep.ts","HarakatOffices_Server/src/scripts/verify-awqaf-demo.ts","HarakatOffices_Server/src/scripts/verify-corpus-read.ts","HarakatOffices_Server/src/scripts/verify-doc-ids.ts","HarakatOffices_Server/src/scripts/verify-single-assistant.ts","HarakatOffices_Server/src/scripts/watches-live-test.ts","HarakatOffices_Server/src/scripts/watches-selftest.ts","HarakatOffices_Server/src/scripts/wave-live-verify.ts","HarakatOffices_Server/src/scripts/workspace-access-selftest.ts","HarakatOffices_Server/src/scripts/workspace-profile-authority-selftest.ts","HarakatOffices_Server/src/scripts/write-receipt-selftest.ts","HarakatOffices_Server/src/server.ts","HarakatOffices_Server/src/worker-entry.ts","HarakatOffices_Server/src/workers/capability-digest.ts","HarakatOffices_Server/src/workers/capability-drift-monitor.ts","HarakatOffices_Server/src/workers/capability-scout.ts","HarakatOffices_Server/src/workers/capability-training-sandbox.ts","HarakatOffices_Server/src/workers/erp-app-purge.worker.integration.test.ts","HarakatOffices_Server/src/workers/erp-app-purge.worker.ts","HarakatOffices_Server/src/workers/erp-app-purge.worker.unit.test.ts","HarakatOffices_Server/src/workers/scheduler.ts"]},{"name":"HarakatOffices_Server — tools","slug":"harakatoffices-server-tools","files":["HarakatOffices_Server/tools/tenant-migrate/README.md","HarakatOffices_Server/tools/tenant-migrate/export.sh","HarakatOffices_Server/tools/tenant-migrate/import.sh","HarakatOffices_Server/tools/tenant-migrate/import.sql"]},{"name":"HarakatOffices_Server — uploads","slug":"harakatoffices-server-uploads","files":["HarakatOffices_Server/uploads/startup-documents/agent-1784109977231-79664509.txt","HarakatOffices_Server/uploads/startup-documents/file-1786628806636-722721294.txt"]}]},{"name":"Harakat_AI","slug":"harakat-ai","files":[],"children":[{"name":"Harakat_AI — Harakat_AI","slug":"harakat-ai-harakat-ai","files":["Harakat_AI/Dockerfile","Harakat_AI/Harakat.code-workspace","Harakat_AI/README.md","Harakat_AI/VENDORED_FROM.md","Harakat_AI/__init__.py","Harakat_AI/ai_watchdog.ps1","Harakat_AI/app.py","Harakat_AI/feature_for_files.md","Harakat_AI/package.json","Harakat_AI/requirements.txt","Harakat_AI/service-account.json","Harakat_AI/tool_manifest.json","Harakat_AI/tsconfig.json","Harakat_AI/uvicorn.enablementA.err","Harakat_AI/uvicorn.enablementB.err","Harakat_AI/uvicorn.enablementB2.err","Harakat_AI/uvicorn.policies.err","Harakat_AI/uvicorn.procs.err"]},{"name":"Harakat_AI — agents","slug":"harakat-ai-agents","files":["Harakat_AI/agents/hermes_native/__init__.py","Harakat_AI/agents/hermes_native/aia_runner.py","Harakat_AI/agents/hermes_native/assistant_agent.py","Harakat_AI/agents/hermes_native/audit.py","Harakat_AI/agents/hermes_native/category_agents/__init__.py","Harakat_AI/agents/hermes_native/category_agents/child_runner.py","Harakat_AI/agents/hermes_native/category_agents/doc_subagent.py","Harakat_AI/agents/hermes_native/category_agents/erp_subagent.py","Harakat_AI/agents/hermes_native/gateway.py","Harakat_AI/agents/hermes_native/governance_creation_prompt.py","Harakat_AI/agents/hermes_native/harakat_memory_provider.py","Harakat_AI/agents/hermes_native/harakat_toolset.py","Harakat_AI/agents/hermes_native/honcho_user_memory.py","Harakat_AI/agents/hermes_native/mcp_toolset.py","Harakat_AI/agents/hermes_native/memory_setup.py","Harakat_AI/agents/hermes_native/memory_store.py","Harakat_AI/agents/hermes_native/native_config.py","Harakat_AI/agents/hermes_native/procedure_executor.py","Harakat_AI/agents/hermes_native/request_context.py","Harakat_AI/agents/hermes_native/run_budget.py","Harakat_AI/agents/hermes_native/run_failure.py","Harakat_AI/agents/hermes_native/runtime_policy.py","Harakat_AI/agents/hermes_native/search_command.py","Harakat_AI/agents/hermes_native/search_subagent.py","Harakat_AI/agents/hermes_native/shell.py","Harakat_AI/agents/hermes_native/shell_context.py","Harakat_AI/agents/hermes_native/skills/dashboard_composition.md","Harakat_AI/agents/hermes_native/skills_sync.py","Harakat_AI/agents/hermes_native/spiffe_identity.py","Harakat_AI/agents/hermes_native/sse_callbacks.py","Harakat_AI/agents/hermes_native/sse_events.py","Harakat_AI/agents/hermes_native/stt_bridge.py","Harakat_AI/agents/hermes_native/system_prompt.py","Harakat_AI/agents/hermes_native/tenant_vocabulary.py","Harakat_AI/agents/hermes_native/tier_guard.py","Harakat_AI/agents/hermes_native/tool_bridge.py","Harakat_AI/agents/hermes_native/usage_events.py","Harakat_AI/agents/meeting/__init__.py","Harakat_AI/agents/meeting/agent.py","Harakat_AI/agents/specialists/__init__.py","Harakat_AI/agents/specialists/docs.py","Harakat_AI/agents/specialists/docs_orchestrator.py","Harakat_AI/agents/specialists/internal_state.py","Harakat_AI/agents/specialists/pageindex_read.py","Harakat_AI/agents/specialists/retrieval_budget.py","Harakat_AI/agents/specialists/search_quality.py","Harakat_AI/agents/specialists/tools.py"]},{"name":"Harakat_AI — bench","slug":"harakat-ai-bench","files":["Harakat_AI/bench/headroom/README.md","Harakat_AI/bench/headroom/__init__.py","Harakat_AI/bench/headroom/audit_dump.py","Harakat_AI/bench/headroom/compressors.py","Harakat_AI/bench/headroom/eligibility.py","Harakat_AI/bench/headroom/harvest.py","Harakat_AI/bench/headroom/harvest_matrix.py","Harakat_AI/bench/headroom/honcho/aggregate.py","Harakat_AI/bench/headroom/honcho/alter_bge_1024.sh","Harakat_AI/bench/headroom/honcho/gen_env.py","Harakat_AI/bench/headroom/honcho/hermes_compress_eval.py","Harakat_AI/bench/headroom/honcho/honcho_eval.py","Harakat_AI/bench/headroom/honcho/model_compare.py","Harakat_AI/bench/headroom/honcho/run_matrix.sh","Harakat_AI/bench/headroom/honcho/run_matrix_bge.sh","Harakat_AI/bench/headroom/judge.py","Harakat_AI/bench/headroom/report.py","Harakat_AI/bench/headroom/report_compare.py","Harakat_AI/bench/headroom/report_matrix.py","Harakat_AI/bench/headroom/report_tokens.py","Harakat_AI/bench/headroom/run_benchmark.py","Harakat_AI/bench/headroom/run_matrix.py","Harakat_AI/bench/headroom/synthetic.py","Harakat_AI/bench/headroom/tests/__init__.py","Harakat_AI/bench/headroom/tests/test_compressors.py","Harakat_AI/bench/headroom/tests/test_eligibility.py","Harakat_AI/bench/headroom/tests/test_judge.py","Harakat_AI/bench/headroom/tests/test_report.py","Harakat_AI/bench/headroom/tests/test_tokens.py","Harakat_AI/bench/headroom/tokens.py","Harakat_AI/bench/honcho_leakage_check.py","Harakat_AI/bench/honcho_sync.py"]},{"name":"Harakat_AI — capabilities","slug":"harakat-ai-capabilities","files":["Harakat_AI/capabilities/__init__.py","Harakat_AI/capabilities/augmentation.py","Harakat_AI/capabilities/client.py","Harakat_AI/capabilities/definition_chat.py"]},{"name":"Harakat_AI — core","slug":"harakat-ai-core","files":["Harakat_AI/core/batch_desc.py","Harakat_AI/core/batch_embed.py","Harakat_AI/core/batch_entities.py","Harakat_AI/core/batch_ocr.py","Harakat_AI/core/batch_rollup.py","Harakat_AI/core/batch_toc.py","Harakat_AI/core/browser_agent.py","Harakat_AI/core/config.py","Harakat_AI/core/context_gate.py","Harakat_AI/core/document_plan.py","Harakat_AI/core/document_workers.py","Harakat_AI/core/embed_space.py","Harakat_AI/core/embeddings.py","Harakat_AI/core/erp_refs.py","Harakat_AI/core/erp_tool_risk.py","Harakat_AI/core/file_creation.py","Harakat_AI/core/grant.py","Harakat_AI/core/lifecycle.py","Harakat_AI/core/llm_pricing.py","Harakat_AI/core/local_embed.py","Harakat_AI/core/local_guard.py","Harakat_AI/core/meet_bot.py","Harakat_AI/core/meeting_scheduler.py","Harakat_AI/core/mounts.py","Harakat_AI/core/ocr.py","Harakat_AI/core/ocr_meter.py","Harakat_AI/core/policy_posture.py","Harakat_AI/core/post_meeting.py","Harakat_AI/core/posthog_tracker.py","Harakat_AI/core/receipt.py","Harakat_AI/core/rust_ingest.py","Harakat_AI/core/security/__init__.py","Harakat_AI/core/security/egress/__init__.py","Harakat_AI/core/security/egress/guarded_fetch.py","Harakat_AI/core/security/egress/hermes_baseline.json","Harakat_AI/core/security/egress/hermes_inventory.py","Harakat_AI/core/security/egress/inventory.py","Harakat_AI/core/security/egress/ip_classify.py","Harakat_AI/core/security/egress/policies.py","Harakat_AI/core/security/egress/scrub.py","Harakat_AI/core/security/egress/url_policy.py","Harakat_AI/core/selfhosted.py","Harakat_AI/core/source_auth/__init__.py","Harakat_AI/core/source_auth/config.py","Harakat_AI/core/source_auth/dedupe.py","Harakat_AI/core/source_auth/middleware.py","Harakat_AI/core/source_auth/signing.py","Harakat_AI/core/staging_key.py","Harakat_AI/core/tool_agent.py","Harakat_AI/core/tool_risk.py","Harakat_AI/core/tool_schemas/__init__.py","Harakat_AI/core/tools.py","Harakat_AI/core/tracing.py","Harakat_AI/core/transcription.py","Harakat_AI/core/utility_llm.py","Harakat_AI/core/vision_qa.py","Harakat_AI/core/vision_reader.py"]},{"name":"Harakat_AI — docs","slug":"harakat-ai-docs","files":["Harakat_AI/docs/AGENT_DEVELOPEMENT_GUIDE.md","Harakat_AI/docs/AI_SETUP_GUIDE.md","Harakat_AI/docs/AI_USAGE_GUIDE.md"]},{"name":"Harakat_AI — envelopes","slug":"harakat-ai-envelopes","files":["Harakat_AI/envelopes/__init__.py","Harakat_AI/envelopes/result_envelope.py"]},{"name":"Harakat_AI — erp-mcp","slug":"harakat-ai-erp-mcp","files":["Harakat_AI/erp-mcp/README.md","Harakat_AI/erp-mcp/_seed_finance.py","Harakat_AI/erp-mcp/package.json","Harakat_AI/erp-mcp/parity-ledger.json","Harakat_AI/erp-mcp/scripts/parity/__fixtures__/skills/_shared/erp-mcp-foundation/SKILL.md","Harakat_AI/erp-mcp/scripts/parity/__fixtures__/skills/sales-crm/crm/crm-x/SKILL.md","Harakat_AI/erp-mcp/scripts/parity/cli-smoke.test.ts","Harakat_AI/erp-mcp/scripts/parity/diff.test.ts","Harakat_AI/erp-mcp/scripts/parity/diff.ts","Harakat_AI/erp-mcp/scripts/parity/ledger.test.ts","Harakat_AI/erp-mcp/scripts/parity/ledger.ts","Harakat_AI/erp-mcp/scripts/parity/manifest-load.test.ts","Harakat_AI/erp-mcp/scripts/parity/manifest-load.ts","Harakat_AI/erp-mcp/scripts/parity/skill-parse.test.ts","Harakat_AI/erp-mcp/scripts/parity/skill-parse.ts","Harakat_AI/erp-mcp/scripts/parity/skills-load.test.ts","Harakat_AI/erp-mcp/scripts/parity/skills-load.ts","Harakat_AI/erp-mcp/scripts/parity/types.ts","Harakat_AI/erp-mcp/scripts/skill-parity.ts","Harakat_AI/erp-mcp/scripts/skill-spotcheck.ts","Harakat_AI/erp-mcp/scripts/smoke.ts","Harakat_AI/erp-mcp/src/customize.ts","Harakat_AI/erp-mcp/src/index.ts","Harakat_AI/erp-mcp/src/odoo.ts","Harakat_AI/erp-mcp/tsconfig.json"]},{"name":"Harakat_AI — erp-skills","slug":"harakat-ai-erp-skills","files":["Harakat_AI/erp-skills/INDEX.md","Harakat_AI/erp-skills/README.md","Harakat_AI/erp-skills/_shared/erp-chatter-activities/SKILL.md","Harakat_AI/erp-skills/_shared/erp-customization/SKILL.md","Harakat_AI/erp-skills/_shared/erp-dispatch/SKILL.md","Harakat_AI/erp-skills/_shared/erp-mcp-foundation/SKILL.md","Harakat_AI/erp-skills/_shared/erp-ownership/SKILL.md","Harakat_AI/erp-skills/finance/advancedaccounting/advancedaccounting-budgets/SKILL.md","Harakat_AI/erp-skills/finance/advancedaccounting/advancedaccounting-coordinator/SKILL.md","Harakat_AI/erp-skills/finance/advancedaccounting/advancedaccounting-dunning/SKILL.md","Harakat_AI/erp-skills/finance/advancedaccounting/advancedaccounting-reports-config/SKILL.md","Harakat_AI/erp-skills/finance/expenses/expenses-coordinator/SKILL.md","Harakat_AI/erp-skills/finance/expenses/expenses-form/SKILL.md","Harakat_AI/erp-skills/finance/expenses/expenses-lifecycle/SKILL.md","Harakat_AI/erp-skills/finance/expenses/expenses-reports-config/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-assets/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-bank-reconcile/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-bank-statements/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-configuration/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-coordinator/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-credit-notes/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-invoice-form/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-invoice-lifecycle/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-payments/SKILL.md","Harakat_AI/erp-skills/finance/finance/finance-reports/SKILL.md","Harakat_AI/erp-skills/finance/payroll/payroll-coordinator/SKILL.md","Harakat_AI/erp-skills/finance/payroll/payroll-payslips/SKILL.md","Harakat_AI/erp-skills/finance/payroll/payroll-structures-rules/SKILL.md","Harakat_AI/erp-skills/marketing/emailmarketing/emailmarketing-calendar-reports-config/SKILL.md","Harakat_AI/erp-skills/marketing/emailmarketing/emailmarketing-campaigns/SKILL.md","Harakat_AI/erp-skills/marketing/emailmarketing/emailmarketing-coordinator/SKILL.md","Harakat_AI/erp-skills/marketing/marketing-automation/marketing-automation-coordinator/SKILL.md","Harakat_AI/erp-skills/marketing/marketing-automation/marketing-automation-journeys/SKILL.md","Harakat_AI/erp-skills/marketing/marketing-automation/marketing-automation-steps/SKILL.md","Harakat_AI/erp-skills/marketing/marketingcard/marketingcard-campaigns/SKILL.md","Harakat_AI/erp-skills/marketing/marketingcard/marketingcard-coordinator/SKILL.md","Harakat_AI/erp-skills/marketing/marketingcard/marketingcard-reports-config/SKILL.md","Harakat_AI/erp-skills/marketing/website/website-coordinator/SKILL.md","Harakat_AI/erp-skills/marketing/website/website-menus-analytics-config/SKILL.md","Harakat_AI/erp-skills/marketing/website/website-pages/SKILL.md","Harakat_AI/erp-skills/people/attendance/attendance-coordinator/SKILL.md","Harakat_AI/erp-skills/people/attendance/attendance-kiosk-reports/SKILL.md","Harakat_AI/erp-skills/people/attendance/attendance-records/SKILL.md","Harakat_AI/erp-skills/people/employees/employees-appraisals/SKILL.md","Harakat_AI/erp-skills/people/employees/employees-contracts/SKILL.md","Harakat_AI/erp-skills/people/employees/employees-coordinator/SKILL.md","Harakat_AI/erp-skills/people/employees/employees-departments-jobs/SKILL.md","Harakat_AI/erp-skills/people/employees/employees-directory-form/SKILL.md","Harakat_AI/erp-skills/people/employees/employees-reports-config/SKILL.md","Harakat_AI/erp-skills/people/recruitment/recruitment-applicants/SKILL.md","Harakat_AI/erp-skills/people/recruitment/recruitment-coordinator/SKILL.md","Harakat_AI/erp-skills/people/skills/skills-catalog/SKILL.md","Harakat_AI/erp-skills/people/skills/skills-coordinator/SKILL.md","Harakat_AI/erp-skills/people/skills/skills-employee-skills/SKILL.md","Harakat_AI/erp-skills/people/skills/skills-matrix-reports/SKILL.md","Harakat_AI/erp-skills/people/timeoff/timeoff-allocations/SKILL.md","Harakat_AI/erp-skills/people/timeoff/timeoff-coordinator/SKILL.md","Harakat_AI/erp-skills/people/timeoff/timeoff-leaves/SKILL.md","Harakat_AI/erp-skills/people/timeoff/timeoff-types-calendar-reports-config/SKILL.md","Harakat_AI/erp-skills/productivity/datacycle/datacycle-coordinator/SKILL.md","Harakat_AI/erp-skills/productivity/datacycle/datacycle-records/SKILL.md","Harakat_AI/erp-skills/productivity/datacycle/datacycle-rules/SKILL.md","Harakat_AI/erp-skills/productivity/knowledge/knowledge-articles/SKILL.md","Harakat_AI/erp-skills/productivity/knowledge/knowledge-coordinator/SKILL.md","Harakat_AI/erp-skills/productivity/sign/sign-coordinator/SKILL.md","Harakat_AI/erp-skills/productivity/sign/sign-fields-signers/SKILL.md","Harakat_AI/erp-skills/productivity/sign/sign-requests/SKILL.md","Harakat_AI/erp-skills/productivity/todos/todos-coordinator/SKILL.md","Harakat_AI/erp-skills/productivity/todos/todos-tasks/SKILL.md","Harakat_AI/erp-skills/projects/planning/planning-coordinator/SKILL.md","Harakat_AI/erp-skills/projects/planning/planning-slots/SKILL.md","Harakat_AI/erp-skills/projects/project/project-coordinator/SKILL.md","Harakat_AI/erp-skills/projects/project/project-dependencies-gantt/SKILL.md","Harakat_AI/erp-skills/projects/project/project-find/SKILL.md","Harakat_AI/erp-skills/projects/project/project-profitability/SKILL.md","Harakat_AI/erp-skills/projects/project/project-projects-form/SKILL.md","Harakat_AI/erp-skills/projects/project/project-reports-config/SKILL.md","Harakat_AI/erp-skills/projects/project/project-stages/SKILL.md","Harakat_AI/erp-skills/projects/project/project-task-timesheets/SKILL.md","Harakat_AI/erp-skills/projects/project/project-tasks/SKILL.md","Harakat_AI/erp-skills/projects/project/project-templates/SKILL.md","Harakat_AI/erp-skills/projects/timesheets/timesheets-coordinator/SKILL.md","Harakat_AI/erp-skills/projects/timesheets/timesheets-grid/SKILL.md","Harakat_AI/erp-skills/projects/timesheets/timesheets-utilisation/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-bank-accounts/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-child-contacts/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-config-reports/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-coordinator/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-credit-control/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-dedup-merge/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-list-management/SKILL.md","Harakat_AI/erp-skills/sales-crm/contacts/contacts-records-form/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-activities-meetings/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-configuration/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-coordinator/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-dedup-merge/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-funnel-analytics/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-lead-capture-qualify/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-opportunity-form/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-pipeline/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-prospects/SKILL.md","Harakat_AI/erp-skills/sales-crm/crm/crm-win-loss/SKILL.md","Harakat_AI/erp-skills/sales-crm/pos/pos-coordinator/SKILL.md","Harakat_AI/erp-skills/sales-crm/pos/pos-orders/SKILL.md","Harakat_AI/erp-skills/sales-crm/pos/pos-reports-config/SKILL.md","Harakat_AI/erp-skills/sales-crm/pos/pos-sessions/SKILL.md","Harakat_AI/erp-skills/sales-crm/pos/pos-terminal/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-bundles/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-coordinator/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-invoicing/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-order-lifecycle/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-order-lines/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-pricing/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-quotation-form/SKILL.md","Harakat_AI/erp-skills/sales-crm/sales/sales-reports-config/SKILL.md","Harakat_AI/erp-skills/sales-crm/subscription/subscription-billing-invoices/SKILL.md","Harakat_AI/erp-skills/sales-crm/subscription/subscription-coordinator/SKILL.md","Harakat_AI/erp-skills/sales-crm/subscription/subscription-lifecycle/SKILL.md","Harakat_AI/erp-skills/sales-crm/subscription/subscription-plans/SKILL.md","Harakat_AI/erp-skills/sales-crm/subscription/subscription-records-form/SKILL.md","Harakat_AI/erp-skills/sales-crm/subscription/subscription-reports-config/SKILL.md","Harakat_AI/erp-skills/services/helpdesk/helpdesk-amc-visits/SKILL.md","Harakat_AI/erp-skills/services/helpdesk/helpdesk-coordinator/SKILL.md","Harakat_AI/erp-skills/services/helpdesk/helpdesk-reports-config/SKILL.md","Harakat_AI/erp-skills/services/helpdesk/helpdesk-tickets/SKILL.md","Harakat_AI/erp-skills/services/helpdesk/helpdesk-warranty/SKILL.md","Harakat_AI/erp-skills/services/livechat/livechat-channels/SKILL.md","Harakat_AI/erp-skills/services/livechat/livechat-coordinator/SKILL.md","Harakat_AI/erp-skills/services/livechat/livechat-sessions/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-coordinator/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-landed-costs/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-quality/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-replenishment/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-reports-config/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-stock-onhand/SKILL.md","Harakat_AI/erp-skills/supply-chain/inventory/inventory-transfers/SKILL.md","Harakat_AI/erp-skills/supply-chain/maintenance/maintenance-calendar-reports-config/SKILL.md","Harakat_AI/erp-skills/supply-chain/maintenance/maintenance-coordinator/SKILL.md","Harakat_AI/erp-skills/supply-chain/maintenance/maintenance-equipment/SKILL.md","Harakat_AI/erp-skills/supply-chain/maintenance/maintenance-requests/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-boms/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-coordinator/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-production-orders/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-production-planning/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-reports-config/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-work-orders/SKILL.md","Harakat_AI/erp-skills/supply-chain/manufacturing/manufacturing-workcenters-routing/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-agreements/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-coordinator/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-order-form/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-order-lifecycle/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-receipts/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-reports-config/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-requisitions/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-rfq-compare/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-scorecard/SKILL.md","Harakat_AI/erp-skills/supply-chain/purchase/purchase-vendor-rates/SKILL.md","Harakat_AI/erp-skills/supply-chain/repairs/repairs-coordinator/SKILL.md","Harakat_AI/erp-skills/supply-chain/repairs/repairs-orders/SKILL.md","Harakat_AI/erp-skills/supply-chain/repairs/repairs-parts/SKILL.md"]},{"name":"Harakat_AI — kubernetes","slug":"harakat-ai-kubernetes","files":["Harakat_AI/kubernetes/deployment.yaml"]},{"name":"Harakat_AI — mcp_client","slug":"harakat-ai-mcp-client","files":["Harakat_AI/mcp_client/__init__.py","Harakat_AI/mcp_client/circuit_breaker.py","Harakat_AI/mcp_client/client.py","Harakat_AI/mcp_client/credential_vault.py"]},{"name":"Harakat_AI — providers","slug":"harakat-ai-providers","files":["Harakat_AI/providers/__init__.py","Harakat_AI/providers/base.py","Harakat_AI/providers/gemini_provider.py","Harakat_AI/providers/groq_provider.py","Harakat_AI/providers/nemotron_provider.py","Harakat_AI/providers/openai_provider.py","Harakat_AI/providers/vertex_ai.py"]},{"name":"Harakat_AI — rust-ingest","slug":"harakat-ai-rust-ingest","files":["Harakat_AI/rust-ingest/Cargo.toml","Harakat_AI/rust-ingest/golden/pdf_parity_probe.py","Harakat_AI/rust-ingest/golden/run_golden.py","Harakat_AI/rust-ingest/src/csv.rs","Harakat_AI/rust-ingest/src/docx.rs","Harakat_AI/rust-ingest/src/lib.rs","Harakat_AI/rust-ingest/src/main.rs","Harakat_AI/rust-ingest/src/output.rs","Harakat_AI/rust-ingest/src/pdf.rs","Harakat_AI/rust-ingest/src/xlsx.rs","Harakat_AI/rust-ingest/tests/cli.rs","Harakat_AI/rust-ingest/tests/xlsx.rs"]},{"name":"Harakat_AI — scripts","slug":"harakat-ai-scripts","files":["Harakat_AI/scripts/ai_hop_selftest.py","Harakat_AI/scripts/approval_card_selftest.py","Harakat_AI/scripts/artifacts_selftest.py","Harakat_AI/scripts/b3_kickoff_selftest.py","Harakat_AI/scripts/bench_ocr.py","Harakat_AI/scripts/category_agents_selftest.py","Harakat_AI/scripts/connector_cause_selftest.py","Harakat_AI/scripts/corpus_v2_selftest.py","Harakat_AI/scripts/creation_context_redaction_selftest.py","Harakat_AI/scripts/creation_opening_turn_selftest.py","Harakat_AI/scripts/doc_evidence_selftest.py","Harakat_AI/scripts/document_plan_selftest.py","Harakat_AI/scripts/drain_selftest.py","Harakat_AI/scripts/egress_inventory_check.py","Harakat_AI/scripts/egress_selftest.py","Harakat_AI/scripts/erp_per_run_selftest.py","Harakat_AI/scripts/erp_refs_selftest.py","Harakat_AI/scripts/gen_tool_manifest_params.py","Harakat_AI/scripts/generate_capability_matrix.py","Harakat_AI/scripts/governance_tools_selftest.py","Harakat_AI/scripts/grant_toolset_selftest.py","Harakat_AI/scripts/hermes_egress_bump_test.py","Harakat_AI/scripts/hermes_egress_inventory.py","Harakat_AI/scripts/hermes_egress_selftest.py","Harakat_AI/scripts/kernel_contacts_selftest.py","Harakat_AI/scripts/local-embedder.sh","Harakat_AI/scripts/local_embed_budget_selftest.py","Harakat_AI/scripts/local_embed_parity.py","Harakat_AI/scripts/local_embed_selftest.py","Harakat_AI/scripts/mail_tools_selftest.py","Harakat_AI/scripts/measure_ocr_rates.py","Harakat_AI/scripts/mount_addressing_selftest.py","Harakat_AI/scripts/no_internal_leak_selftest.py","Harakat_AI/scripts/ocr_rate_selftest.py","Harakat_AI/scripts/org_read_selftest.py","Harakat_AI/scripts/page_context_selftest.py","Harakat_AI/scripts/peer_ask_refusal_selftest.py","Harakat_AI/scripts/policy_posture_selftest.py","Harakat_AI/scripts/procedure_assignee_selftest.py","Harakat_AI/scripts/reference_askback_selftest.py","Harakat_AI/scripts/run_failure_selftest.py","Harakat_AI/scripts/sandbox_execute_selftest.py","Harakat_AI/scripts/search_agent_read_e2e.py","Harakat_AI/scripts/search_agent_read_selftest.py","Harakat_AI/scripts/search_subagent_selftest.py","Harakat_AI/scripts/selfhosted_pipeline_selftest.py","Harakat_AI/scripts/silence_rule_selftest.py","Harakat_AI/scripts/smoke_batch_ocr.py","Harakat_AI/scripts/staging_key_selftest.py","Harakat_AI/scripts/task_store_selftest.py","Harakat_AI/scripts/test_batch_ocr.py","Harakat_AI/scripts/test_ocr_pdf_direct.py","Harakat_AI/scripts/tool_floor_selftest.py","Harakat_AI/scripts/tool_result_truthfulness_selftest.py","Harakat_AI/scripts/turn_origin_selftest.py","Harakat_AI/scripts/verify_batch_pipeline.py","Harakat_AI/scripts/vision_qa_selftest.py","Harakat_AI/scripts/write_receipt_selftest.py","Harakat_AI/scripts/xlsx_formula_selftest.py"]},{"name":"Harakat_AI — src","slug":"harakat-ai-src","files":["Harakat_AI/src/__init__.py","Harakat_AI/src/a.txt","Harakat_AI/src/runtime/__init__.py","Harakat_AI/src/runtime/main.py","Harakat_AI/src/runtime/uv/__init__.py","Harakat_AI/src/runtime/uv/controller.py","Harakat_AI/src/runtime/uv/executor.py","Harakat_AI/src/runtime/uv/workspace_manager.py"]},{"name":"Harakat_AI — tests","slug":"harakat-ai-tests","files":["Harakat_AI/tests/__init__.py","Harakat_AI/tests/a.txt","Harakat_AI/tests/test_action_result_event.py","Harakat_AI/tests/test_batch_embed.py","Harakat_AI/tests/test_batch_thinking_config.py","Harakat_AI/tests/test_coerce_procedure_steps.py","Harakat_AI/tests/test_create_skill_binds.py","Harakat_AI/tests/test_embed_batch_endpoints.py","Harakat_AI/tests/test_erp_customize_discoverable.py","Harakat_AI/tests/test_extract_dispatch.py","Harakat_AI/tests/test_feed_proposals.py","Harakat_AI/tests/test_governance_draft.py","Harakat_AI/tests/test_hermes_native_phase2.py","Harakat_AI/tests/test_hermes_native_phase3.py","Harakat_AI/tests/test_hermes_native_phase4.py","Harakat_AI/tests/test_hermes_native_phase5.py","Harakat_AI/tests/test_honcho_user_memory.py","Harakat_AI/tests/test_local_guard.py","Harakat_AI/tests/test_parse_workflow_docx.py","Harakat_AI/tests/test_procedure_executor.py","Harakat_AI/tests/test_registry_reassert_r2.py","Harakat_AI/tests/test_run_budget.py","Harakat_AI/tests/test_run_id_header.py","Harakat_AI/tests/test_rust_ingest.py","Harakat_AI/tests/test_search_documents_r2.py","Harakat_AI/tests/test_search_failsoft.py","Harakat_AI/tests/test_stt_bridge.py","Harakat_AI/tests/test_surface_prompt.py","Harakat_AI/tests/test_tool_gateway_hook.py","Harakat_AI/tests/test_tool_risk.py","Harakat_AI/tests/test_utility_llm.py"]},{"name":"Harakat_AI — workers","slug":"harakat-ai-workers","files":["Harakat_AI/workers/__init__.py","Harakat_AI/workers/document_indexer.py"]},{"name":"Harakat_AI — workflows","slug":"harakat-ai-workflows","files":["Harakat_AI/workflows/__init__.py","Harakat_AI/workflows/assistant_workflow.py","Harakat_AI/workflows/browser_workflow.py","Harakat_AI/workflows/clean_workflow.py","Harakat_AI/workflows/context_workflow.py","Harakat_AI/workflows/embed_workflow.py","Harakat_AI/workflows/enrichment_workflow.py","Harakat_AI/workflows/feed_proposals.py","Harakat_AI/workflows/governance_draft.py","Harakat_AI/workflows/hermes_debug_workflow.py","Harakat_AI/workflows/indexing_workflow.py","Harakat_AI/workflows/meeting_workflow.py","Harakat_AI/workflows/multimodal_description.py","Harakat_AI/workflows/parse_workflow.py"]}]},{"name":"Harakat_Admin","slug":"harakat-admin","files":[],"children":[{"name":"Harakat_Admin — Harakat_Admin","slug":"harakat-admin-harakat-admin","files":["Harakat_Admin/ACCESS_ACCOUNT_FEATURE.md","Harakat_Admin/ADMIN_UNUSED_UNHOOKED_INVENTORY.md","Harakat_Admin/BACKEND_API_REQUIREMENTS.md","Harakat_Admin/CORRECTED_IMPLEMENTATION.md","Harakat_Admin/DOCUMENTS_IMPLEMENTATION.md","Harakat_Admin/Dockerfile","Harakat_Admin/IMPLEMENTATION_COMPLETE.md","Harakat_Admin/INTEGRATION_TAB_REMOVAL.md","Harakat_Admin/PASSWORD_CHANGE_IMPLEMENTATION_COMPLETE.md","Harakat_Admin/PASSWORD_CHANGE_VERIFICATION_TESTING.md","Harakat_Admin/PERMISSIONS_SUPER_ADMIN_REMOVAL.md","Harakat_Admin/RESPONSIVE_DESIGN_IMPROVEMENTS.md","Harakat_Admin/URL_VALIDATION_INFO.md","Harakat_Admin/USER_MANAGEMENT_ERROR_HANDLING.md","Harakat_Admin/components.json","Harakat_Admin/next.config.mjs","Harakat_Admin/package.json","Harakat_Admin/playwright.config.ts","Harakat_Admin/postcss.config.mjs","Harakat_Admin/tsconfig.json","Harakat_Admin/tsconfig.tsbuildinfo"]},{"name":"Harakat_Admin — app","slug":"harakat-admin-app","files":["Harakat_Admin/app/admin/companies/[id]/page.tsx","Harakat_Admin/app/admin/companies/page.tsx","Harakat_Admin/app/admin/governance/page.tsx","Harakat_Admin/app/admin/inference/page.tsx","Harakat_Admin/app/admin/layout.tsx","Harakat_Admin/app/admin/learning-hub/[id]/page.tsx","Harakat_Admin/app/admin/learning-hub/layout.tsx","Harakat_Admin/app/admin/learning-hub/page.tsx","Harakat_Admin/app/admin/marketplace/[id]/page.tsx","Harakat_Admin/app/admin/marketplace/loading.tsx","Harakat_Admin/app/admin/marketplace/page.tsx","Harakat_Admin/app/admin/packs/page.tsx","Harakat_Admin/app/admin/page.tsx","Harakat_Admin/app/admin/services/[id]/page.tsx","Harakat_Admin/app/admin/services/loading.tsx","Harakat_Admin/app/admin/services/page.tsx","Harakat_Admin/app/admin/settings/page.tsx","Harakat_Admin/app/admin/support/[id]/page.tsx","Harakat_Admin/app/admin/support/page.tsx","Harakat_Admin/app/admin/vessel-templates/page.tsx","Harakat_Admin/app/apple-icon.tsx","Harakat_Admin/app/error.tsx","Harakat_Admin/app/global-error.tsx","Harakat_Admin/app/globals.css","Harakat_Admin/app/icon.tsx","Harakat_Admin/app/layout.tsx","Harakat_Admin/app/login/page.tsx","Harakat_Admin/app/not-found.tsx","Harakat_Admin/app/page.tsx"]},{"name":"Harakat_Admin — components","slug":"harakat-admin-components","files":["Harakat_Admin/components/ToasterProvider.tsx","Harakat_Admin/components/companies/CompanyProfileSheet.tsx","Harakat_Admin/components/companies/ProvisionCompanyDialog.tsx","Harakat_Admin/components/dashboard/DashboardSkeleton.tsx","Harakat_Admin/components/frame/PageFrame.tsx","Harakat_Admin/components/governance/command-policy-editor.tsx","Harakat_Admin/components/governance/governance-console.tsx","Harakat_Admin/components/governance/operator-coverage.tsx","Harakat_Admin/components/governance/prompt-inspector.tsx","Harakat_Admin/components/governance/resource-control.tsx","Harakat_Admin/components/governance/revision-history.tsx","Harakat_Admin/components/governance/shadow-panel.tsx","Harakat_Admin/components/governance/simulator-panel.tsx","Harakat_Admin/components/learning-hub/AddCourseDialog.tsx","Harakat_Admin/components/learning-hub/CoursesSkeleton.tsx","Harakat_Admin/components/learning-hub/EmptyCourses.tsx","Harakat_Admin/components/learning-hub/EmptyInstructors.tsx","Harakat_Admin/components/learning-hub/ErrorState.tsx","Harakat_Admin/components/learning-hub/InstructorsSkeleton.tsx","Harakat_Admin/components/learning-hub/tabs/CoursesTab.tsx","Harakat_Admin/components/learning-hub/tabs/InstructorsTab.tsx","Harakat_Admin/components/marketplace/content/AgentRegistryContent.tsx","Harakat_Admin/components/packs/dry-run-catalog.tsx","Harakat_Admin/components/packs/packs-console.tsx","Harakat_Admin/components/packs/source-field.tsx","Harakat_Admin/components/packs/source-form.tsx","Harakat_Admin/components/packs/tenant-packs-panel.tsx","Harakat_Admin/components/packs/update-badge.tsx","Harakat_Admin/components/records/RecordRoute.tsx","Harakat_Admin/components/services/CompanyFormDialog.tsx","Harakat_Admin/components/services/DeleteConfirmDialog.tsx","Harakat_Admin/components/services/FreelancerFormDialog.tsx","Harakat_Admin/components/services/tabs/CompaniesTab.tsx","Harakat_Admin/components/services/tabs/FreelancersTab.tsx","Harakat_Admin/components/settings/tabs/BackupAuditTab.tsx","Harakat_Admin/components/settings/tabs/CreditsTab.tsx","Harakat_Admin/components/settings/tabs/FeatureFlagsTab.tsx","Harakat_Admin/components/settings/tabs/NotificationsTab.tsx","Harakat_Admin/components/settings/tabs/PermissionsTab.tsx","Harakat_Admin/components/settings/tabs/PlatformTab.tsx","Harakat_Admin/components/settings/tabs/ProfileTab.tsx","Harakat_Admin/components/settings/tabs/SecurityTab.tsx","Harakat_Admin/components/settings/tabs/UsersTab.tsx","Harakat_Admin/components/state/ConfirmDestructiveDialog.tsx","Harakat_Admin/components/state/StatTile.tsx","Harakat_Admin/components/state/StateView.tsx","Harakat_Admin/components/support/SupportTicketsContent.tsx","Harakat_Admin/components/ui/accordion.tsx","Harakat_Admin/components/ui/alert-dialog.tsx","Harakat_Admin/components/ui/alert.tsx","Harakat_Admin/components/ui/aspect-ratio.tsx","Harakat_Admin/components/ui/avatar.tsx","Harakat_Admin/components/ui/badge.tsx","Harakat_Admin/components/ui/breadcrumb.tsx","Harakat_Admin/components/ui/button-group.tsx","Harakat_Admin/components/ui/button.tsx","Harakat_Admin/components/ui/calendar.tsx","Harakat_Admin/components/ui/card.tsx","Harakat_Admin/components/ui/carousel.tsx","Harakat_Admin/components/ui/chart.tsx","Harakat_Admin/components/ui/checkbox.tsx","Harakat_Admin/components/ui/collapsible.tsx","Harakat_Admin/components/ui/command.tsx","Harakat_Admin/components/ui/context-menu.tsx","Harakat_Admin/components/ui/dialog.tsx","Harakat_Admin/components/ui/drawer.tsx","Harakat_Admin/components/ui/dropdown-menu.tsx","Harakat_Admin/components/ui/empty.tsx","Harakat_Admin/components/ui/field.tsx","Harakat_Admin/components/ui/form.tsx","Harakat_Admin/components/ui/hover-card.tsx","Harakat_Admin/components/ui/input-group.tsx","Harakat_Admin/components/ui/input-otp.tsx","Harakat_Admin/components/ui/input.tsx","Harakat_Admin/components/ui/item.tsx","Harakat_Admin/components/ui/kbd.tsx","Harakat_Admin/components/ui/label.tsx","Harakat_Admin/components/ui/menubar.tsx","Harakat_Admin/components/ui/navigation-menu.tsx","Harakat_Admin/components/ui/pagination.tsx","Harakat_Admin/components/ui/popover.tsx","Harakat_Admin/components/ui/progress.tsx","Harakat_Admin/components/ui/radio-group.tsx","Harakat_Admin/components/ui/resizable.tsx","Harakat_Admin/components/ui/scroll-area.tsx","Harakat_Admin/components/ui/select.tsx","Harakat_Admin/components/ui/separator.tsx","Harakat_Admin/components/ui/sheet.tsx","Harakat_Admin/components/ui/sidebar.tsx","Harakat_Admin/components/ui/skeleton.tsx","Harakat_Admin/components/ui/slider.tsx","Harakat_Admin/components/ui/sonner.tsx","Harakat_Admin/components/ui/spinner.tsx","Harakat_Admin/components/ui/switch.tsx","Harakat_Admin/components/ui/table.tsx","Harakat_Admin/components/ui/tabs.tsx","Harakat_Admin/components/ui/textarea.tsx","Harakat_Admin/components/ui/toast.tsx","Harakat_Admin/components/ui/toaster.tsx","Harakat_Admin/components/ui/toggle-group.tsx","Harakat_Admin/components/ui/toggle.tsx","Harakat_Admin/components/ui/tooltip.tsx","Harakat_Admin/components/ui/use-mobile.tsx","Harakat_Admin/components/ui/use-toast.ts","Harakat_Admin/components/vessel-templates/parts.tsx"]},{"name":"Harakat_Admin — docs","slug":"harakat-admin-docs","files":["Harakat_Admin/docs/LEARNING_HUB_API_INTEGRATION.md"]},{"name":"Harakat_Admin — e2e","slug":"harakat-admin-e2e","files":["Harakat_Admin/e2e/records.spec.ts","Harakat_Admin/e2e/routes.spec.ts","Harakat_Admin/e2e/session.spec.ts","Harakat_Admin/e2e/support/console.ts"]},{"name":"Harakat_Admin — hooks","slug":"harakat-admin-hooks","files":["Harakat_Admin/hooks/use-mobile.ts","Harakat_Admin/hooks/use-toast.ts","Harakat_Admin/hooks/useAuthCheck.ts","Harakat_Admin/hooks/useResource.ts"]},{"name":"Harakat_Admin — lib","slug":"harakat-admin-lib","files":["Harakat_Admin/lib/api/admin.ts","Harakat_Admin/lib/api/audit.ts","Harakat_Admin/lib/api/auth.ts","Harakat_Admin/lib/api/client.ts","Harakat_Admin/lib/api/dashboard.ts","Harakat_Admin/lib/api/errors.ts","Harakat_Admin/lib/api/governance.ts","Harakat_Admin/lib/api/index.ts","Harakat_Admin/lib/api/inference.ts","Harakat_Admin/lib/api/learning.ts","Harakat_Admin/lib/api/marketplace.ts","Harakat_Admin/lib/api/notifications.ts","Harakat_Admin/lib/api/packs.ts","Harakat_Admin/lib/api/permissions.ts","Harakat_Admin/lib/api/providers.ts","Harakat_Admin/lib/api/services.ts","Harakat_Admin/lib/api/settings.ts","Harakat_Admin/lib/api/shape.ts","Harakat_Admin/lib/api/startups.ts","Harakat_Admin/lib/api/support.ts","Harakat_Admin/lib/api/templates.ts","Harakat_Admin/lib/auth/session.ts","Harakat_Admin/lib/companies/presentation.ts","Harakat_Admin/lib/governance/controls.ts","Harakat_Admin/lib/governance/manifest-types.ts","Harakat_Admin/lib/governance/parse.ts","Harakat_Admin/lib/packs/source-descriptors.ts","Harakat_Admin/lib/packs/types.ts","Harakat_Admin/lib/packs/vocabulary.ts","Harakat_Admin/lib/posthog.tsx","Harakat_Admin/lib/records/record-route.ts","Harakat_Admin/lib/utils.ts"]},{"name":"Harakat_Admin — scripts","slug":"harakat-admin-scripts","files":["Harakat_Admin/scripts/check-console-gaps.cjs","Harakat_Admin/scripts/check-error-boundaries.cjs","Harakat_Admin/scripts/check-frame.cjs","Harakat_Admin/scripts/check-governance-controls.cjs","Harakat_Admin/scripts/check-packs-console.cjs","Harakat_Admin/scripts/check-token-access.cjs"]},{"name":"Harakat_Admin — styles","slug":"harakat-admin-styles","files":["Harakat_Admin/styles/globals.css"]},{"name":"Harakat_Admin — types","slug":"harakat-admin-types","files":["Harakat_Admin/types/index.ts","Harakat_Admin/types/settings.ts"]}]},{"name":"Harakat_Kernel","slug":"harakat-kernel","files":[],"children":[{"name":"Harakat_Kernel — Harakat_Kernel","slug":"harakat-kernel-harakat-kernel","files":["Harakat_Kernel/Cargo.toml","Harakat_Kernel/README.md","Harakat_Kernel/deny.toml","Harakat_Kernel/rust-toolchain.toml"]},{"name":"Harakat_Kernel — apps","slug":"harakat-kernel-apps","files":["Harakat_Kernel/apps/accounts/Cargo.toml","Harakat_Kernel/apps/accounts/src/allocation.rs","Harakat_Kernel/apps/accounts/src/asset.rs","Harakat_Kernel/apps/accounts/src/entry.rs","Harakat_Kernel/apps/accounts/src/lib.rs","Harakat_Kernel/apps/accounts/src/masters.rs","Harakat_Kernel/apps/accounts/src/membership.rs","Harakat_Kernel/apps/accounts/src/period_lock.rs","Harakat_Kernel/apps/accounts/src/posting.rs","Harakat_Kernel/apps/accounts/src/settlement.rs","Harakat_Kernel/apps/accounts/src/vat.rs","Harakat_Kernel/apps/accounts/src/wip.rs","Harakat_Kernel/apps/accounts/tests/allocation_gate.rs","Harakat_Kernel/apps/accounts/tests/allocation_gate_api.rs","Harakat_Kernel/apps/accounts/tests/allocation_loosening_guard.rs","Harakat_Kernel/apps/accounts/tests/allocation_run.rs","Harakat_Kernel/apps/accounts/tests/allocation_switches.rs","Harakat_Kernel/apps/accounts/tests/balance_invariant.rs","Harakat_Kernel/apps/accounts/tests/company.rs","Harakat_Kernel/apps/accounts/tests/delete_guard.rs","Harakat_Kernel/apps/accounts/tests/fixed_asset.rs","Harakat_Kernel/apps/accounts/tests/fund_dimension_pg.rs","Harakat_Kernel/apps/accounts/tests/fund_required_on_post.rs","Harakat_Kernel/apps/accounts/tests/fund_trial_balance.rs","Harakat_Kernel/apps/accounts/tests/job_dimension.rs","Harakat_Kernel/apps/accounts/tests/job_totals.rs","Harakat_Kernel/apps/accounts/tests/membership_distribution.rs","Harakat_Kernel/apps/accounts/tests/period_lock.rs","Harakat_Kernel/apps/accounts/tests/post_time_numbering.rs","Harakat_Kernel/apps/accounts/tests/retention.rs","Harakat_Kernel/apps/accounts/tests/reversal.rs","Harakat_Kernel/apps/accounts/tests/settlement.rs","Harakat_Kernel/apps/accounts/tests/synthesis.rs","Harakat_Kernel/apps/accounts/tests/vat_return.rs","Harakat_Kernel/apps/accounts/tests/wip_revenue.rs","Harakat_Kernel/apps/advancedaccounting/Cargo.toml","Harakat_Kernel/apps/advancedaccounting/src/lib.rs","Harakat_Kernel/apps/appraisals/Cargo.toml","Harakat_Kernel/apps/appraisals/src/appraisal.rs","Harakat_Kernel/apps/appraisals/src/lib.rs","Harakat_Kernel/apps/appraisals/tests/registry_boots.rs","Harakat_Kernel/apps/attendance/Cargo.toml","Harakat_Kernel/apps/attendance/src/lib.rs","Harakat_Kernel/apps/catalog/Cargo.toml","Harakat_Kernel/apps/catalog/src/lib.rs","Harakat_Kernel/apps/catalog/src/masters.rs","Harakat_Kernel/apps/catalog/src/pricing.rs","Harakat_Kernel/apps/catalog/src/product.rs","Harakat_Kernel/apps/contacts/Cargo.toml","Harakat_Kernel/apps/contacts/src/lib.rs","Harakat_Kernel/apps/crm/Cargo.toml","Harakat_Kernel/apps/crm/src/lead.rs","Harakat_Kernel/apps/crm/src/lib.rs","Harakat_Kernel/apps/crm/src/masters.rs","Harakat_Kernel/apps/crm/src/team.rs","Harakat_Kernel/apps/crm/tests/flows.rs","Harakat_Kernel/apps/crm/tests/golden.rs","Harakat_Kernel/apps/datacycle/Cargo.toml","Harakat_Kernel/apps/datacycle/src/lib.rs","Harakat_Kernel/apps/dispatch/Cargo.toml","Harakat_Kernel/apps/dispatch/src/lib.rs","Harakat_Kernel/apps/dispatch/tests/flows.rs","Harakat_Kernel/apps/dispatch/tests/golden.rs","Harakat_Kernel/apps/employees/Cargo.toml","Harakat_Kernel/apps/employees/src/department.rs","Harakat_Kernel/apps/employees/src/employee.rs","Harakat_Kernel/apps/employees/src/lib.rs","Harakat_Kernel/apps/employees/src/masters.rs","Harakat_Kernel/apps/employees/src/settlement.rs","Harakat_Kernel/apps/employees/tests/bank_identity.rs","Harakat_Kernel/apps/employees/tests/bank_identity_migration_pg.rs","Harakat_Kernel/apps/employees/tests/employee_flows.rs","Harakat_Kernel/apps/employees/tests/gratuity_accrual.rs","Harakat_Kernel/apps/employees/tests/personal_identity_migration_pg.rs","Harakat_Kernel/apps/employees/tests/registry_boots.rs","Harakat_Kernel/apps/employees/tests/settlement.rs","Harakat_Kernel/apps/employees/tests/statutory_expiry.rs","Harakat_Kernel/apps/employees/tests/statutory_migration_pg.rs","Harakat_Kernel/apps/entities/Cargo.toml","Harakat_Kernel/apps/entities/src/lib.rs","Harakat_Kernel/apps/entities/tests/computed_fields.rs","Harakat_Kernel/apps/entities/tests/computed_fields_pg.rs","Harakat_Kernel/apps/entities/tests/required_state_create.rs","Harakat_Kernel/apps/expenses/Cargo.toml","Harakat_Kernel/apps/expenses/src/lib.rs","Harakat_Kernel/apps/expenses/tests/posting.rs","Harakat_Kernel/apps/finance/Cargo.toml","Harakat_Kernel/apps/finance/src/lib.rs","Harakat_Kernel/apps/finance/tests/allocation.rs","Harakat_Kernel/apps/finance/tests/posting.rs","Harakat_Kernel/apps/helpdesk/Cargo.toml","Harakat_Kernel/apps/helpdesk/src/lib.rs","Harakat_Kernel/apps/helpdesk/src/sla.rs","Harakat_Kernel/apps/helpdesk/src/team.rs","Harakat_Kernel/apps/helpdesk/src/ticket.rs","Harakat_Kernel/apps/helpdesk/tests/flows.rs","Harakat_Kernel/apps/helpdesk/tests/golden.rs","Harakat_Kernel/apps/helpdesk/tests/registry.rs","Harakat_Kernel/apps/knowledge/Cargo.toml","Harakat_Kernel/apps/knowledge/src/lib.rs","Harakat_Kernel/apps/maintenance/Cargo.toml","Harakat_Kernel/apps/maintenance/src/lib.rs","Harakat_Kernel/apps/manufacturing/Cargo.toml","Harakat_Kernel/apps/manufacturing/src/lib.rs","Harakat_Kernel/apps/marketing/Cargo.toml","Harakat_Kernel/apps/marketing/src/lib.rs","Harakat_Kernel/apps/marketingautomation/Cargo.toml","Harakat_Kernel/apps/marketingautomation/src/lib.rs","Harakat_Kernel/apps/notes/Cargo.toml","Harakat_Kernel/apps/notes/src/lib.rs","Harakat_Kernel/apps/notes/tests/compute.rs","Harakat_Kernel/apps/notes/tests/golden.rs","Harakat_Kernel/apps/notes/tests/registry.rs","Harakat_Kernel/apps/payroll/Cargo.toml","Harakat_Kernel/apps/payroll/src/lib.rs","Harakat_Kernel/apps/payroll/tests/contract_guards.rs","Harakat_Kernel/apps/payroll/tests/posting.rs","Harakat_Kernel/apps/payroll/tests/wage_revision.rs","Harakat_Kernel/apps/planning/Cargo.toml","Harakat_Kernel/apps/planning/src/lib.rs","Harakat_Kernel/apps/planning/tests/compute.rs","Harakat_Kernel/apps/pos/Cargo.toml","Harakat_Kernel/apps/pos/src/lib.rs","Harakat_Kernel/apps/pos/tests/posting.rs","Harakat_Kernel/apps/project/Cargo.toml","Harakat_Kernel/apps/project/src/budget.rs","Harakat_Kernel/apps/project/src/children.rs","Harakat_Kernel/apps/project/src/diary.rs","Harakat_Kernel/apps/project/src/lib.rs","Harakat_Kernel/apps/project/src/masters.rs","Harakat_Kernel/apps/project/src/package.rs","Harakat_Kernel/apps/project/src/project.rs","Harakat_Kernel/apps/project/src/retention.rs","Harakat_Kernel/apps/project/src/snag.rs","Harakat_Kernel/apps/project/src/submittal.rs","Harakat_Kernel/apps/project/src/valuation.rs","Harakat_Kernel/apps/project/src/variation.rs","Harakat_Kernel/apps/project/tests/site_diary_pg.rs","Harakat_Kernel/apps/purchase/Cargo.toml","Harakat_Kernel/apps/purchase/src/lib.rs","Harakat_Kernel/apps/purchase/src/order.rs","Harakat_Kernel/apps/purchase/src/rate.rs","Harakat_Kernel/apps/purchase/src/receipt.rs","Harakat_Kernel/apps/purchase/src/requisition.rs","Harakat_Kernel/apps/purchase/tests/bill.rs","Harakat_Kernel/apps/purchase/tests/flows.rs","Harakat_Kernel/apps/purchase/tests/receipt.rs","Harakat_Kernel/apps/purchase/tests/requisition.rs","Harakat_Kernel/apps/purchase/tests/vendor_rate.rs","Harakat_Kernel/apps/recruitment/Cargo.toml","Harakat_Kernel/apps/recruitment/src/lib.rs","Harakat_Kernel/apps/repairs/Cargo.toml","Harakat_Kernel/apps/repairs/src/lib.rs","Harakat_Kernel/apps/sale/Cargo.toml","Harakat_Kernel/apps/sale/src/lib.rs","Harakat_Kernel/apps/sale/src/masters.rs","Harakat_Kernel/apps/sale/src/order.rs","Harakat_Kernel/apps/sale/tests/retention.rs","Harakat_Kernel/apps/sign/Cargo.toml","Harakat_Kernel/apps/sign/src/lib.rs","Harakat_Kernel/apps/skills/Cargo.toml","Harakat_Kernel/apps/skills/src/lib.rs","Harakat_Kernel/apps/skills/src/skills.rs","Harakat_Kernel/apps/skills/tests/registry_boots.rs","Harakat_Kernel/apps/stock/Cargo.toml","Harakat_Kernel/apps/stock/src/common.rs","Harakat_Kernel/apps/stock/src/lib.rs","Harakat_Kernel/apps/stock/src/masters.rs","Harakat_Kernel/apps/stock/src/motion.rs","Harakat_Kernel/apps/stock/src/movement.rs","Harakat_Kernel/apps/stock/src/picking.rs","Harakat_Kernel/apps/stock/src/quant.rs","Harakat_Kernel/apps/stock/src/scrap.rs","Harakat_Kernel/apps/subscription/Cargo.toml","Harakat_Kernel/apps/subscription/src/lib.rs","Harakat_Kernel/apps/subscription/tests/posting.rs","Harakat_Kernel/apps/timeoff/Cargo.toml","Harakat_Kernel/apps/timeoff/src/entitlement.rs","Harakat_Kernel/apps/timeoff/src/leave_type.rs","Harakat_Kernel/apps/timeoff/src/lib.rs","Harakat_Kernel/apps/timeoff/tests/entitlement_math.rs","Harakat_Kernel/apps/timeoff/tests/leave_balance_report.rs","Harakat_Kernel/apps/timeoff/tests/leave_migration_pg.rs","Harakat_Kernel/apps/timeoff/tests/leave_request_flows.rs","Harakat_Kernel/apps/timeoff/tests/leave_type_flows.rs","Harakat_Kernel/apps/timesheets/Cargo.toml","Harakat_Kernel/apps/timesheets/src/lib.rs","Harakat_Kernel/apps/todos/Cargo.toml","Harakat_Kernel/apps/todos/src/lib.rs"]},{"name":"Harakat_Kernel — crates","slug":"harakat-kernel-crates","files":["Harakat_Kernel/crates/kernel-api/Cargo.toml","Harakat_Kernel/crates/kernel-api/src/binding.rs","Harakat_Kernel/crates/kernel-api/src/claims_route.rs","Harakat_Kernel/crates/kernel-api/src/entity_routes.rs","Harakat_Kernel/crates/kernel-api/src/execute.rs","Harakat_Kernel/crates/kernel-api/src/execute/chatter.rs","Harakat_Kernel/crates/kernel-api/src/execute/dispatch.rs","Harakat_Kernel/crates/kernel-api/src/execute/mutations.rs","Harakat_Kernel/crates/kernel-api/src/execute/reads.rs","Harakat_Kernel/crates/kernel-api/src/execute/system.rs","Harakat_Kernel/crates/kernel-api/src/health.rs","Harakat_Kernel/crates/kernel-api/src/idmap_routes.rs","Harakat_Kernel/crates/kernel-api/src/lib.rs","Harakat_Kernel/crates/kernel-api/src/manifest.rs","Harakat_Kernel/crates/kernel-api/src/overlay_routes.rs","Harakat_Kernel/crates/kernel-api/src/state.rs","Harakat_Kernel/crates/kernel-api/tests/api_integration.rs","Harakat_Kernel/crates/kernel-api/tests/chatter.rs","Harakat_Kernel/crates/kernel-api/tests/claims_route.rs","Harakat_Kernel/crates/kernel-api/tests/data_shapes.rs","Harakat_Kernel/crates/kernel-api/tests/entity_authoring.rs","Harakat_Kernel/crates/kernel-api/tests/idmap_routes.rs","Harakat_Kernel/crates/kernel-api/tests/overlay_authoring.rs","Harakat_Kernel/crates/kernel-api/tests/read_side_compat.rs","Harakat_Kernel/crates/kernel-api/tests/system_execute.rs","Harakat_Kernel/crates/kernel-authz/Cargo.toml","Harakat_Kernel/crates/kernel-authz/examples/verify_probe.rs","Harakat_Kernel/crates/kernel-authz/src/delegation.rs","Harakat_Kernel/crates/kernel-authz/src/lib.rs","Harakat_Kernel/crates/kernel-authz/src/openfga.rs","Harakat_Kernel/crates/kernel-authz/src/svid.rs","Harakat_Kernel/crates/kernel-authz/src/tier.rs","Harakat_Kernel/crates/kernel-core/Cargo.toml","Harakat_Kernel/crates/kernel-core/src/actor.rs","Harakat_Kernel/crates/kernel-core/src/app.rs","Harakat_Kernel/crates/kernel-core/src/authz.rs","Harakat_Kernel/crates/kernel-core/src/capability.rs","Harakat_Kernel/crates/kernel-core/src/claims.rs","Harakat_Kernel/crates/kernel-core/src/compute.rs","Harakat_Kernel/crates/kernel-core/src/descriptor.rs","Harakat_Kernel/crates/kernel-core/src/entity.rs","Harakat_Kernel/crates/kernel-core/src/error.rs","Harakat_Kernel/crates/kernel-core/src/event.rs","Harakat_Kernel/crates/kernel-core/src/expr.rs","Harakat_Kernel/crates/kernel-core/src/field.rs","Harakat_Kernel/crates/kernel-core/src/idmap.rs","Harakat_Kernel/crates/kernel-core/src/lib.rs","Harakat_Kernel/crates/kernel-core/src/manifest.rs","Harakat_Kernel/crates/kernel-core/src/model.rs","Harakat_Kernel/crates/kernel-core/src/mutation.rs","Harakat_Kernel/crates/kernel-core/src/overlay.rs","Harakat_Kernel/crates/kernel-core/src/owned.rs","Harakat_Kernel/crates/kernel-core/src/query.rs","Harakat_Kernel/crates/kernel-core/src/registry.rs","Harakat_Kernel/crates/kernel-core/src/seal.rs","Harakat_Kernel/crates/kernel-core/src/storage_contract.rs","Harakat_Kernel/crates/kernel-core/src/tenant.rs","Harakat_Kernel/crates/kernel-core/src/thread.rs","Harakat_Kernel/crates/kernel-core/src/value.rs","Harakat_Kernel/crates/kernel-core/src/wire.rs","Harakat_Kernel/crates/kernel-core/src/x2many.rs","Harakat_Kernel/crates/kernel-events/Cargo.toml","Harakat_Kernel/crates/kernel-events/src/cursor.rs","Harakat_Kernel/crates/kernel-events/src/dispatcher.rs","Harakat_Kernel/crates/kernel-events/src/lib.rs","Harakat_Kernel/crates/kernel-events/src/metering.rs","Harakat_Kernel/crates/kernel-events/src/outbox.rs","Harakat_Kernel/crates/kernel-events/src/relay.rs","Harakat_Kernel/crates/kernel-events/tests/common/mod.rs","Harakat_Kernel/crates/kernel-events/tests/dispatcher.rs","Harakat_Kernel/crates/kernel-events/tests/s5_id_gap_bug.rs","Harakat_Kernel/crates/kernel-expr/Cargo.toml","Harakat_Kernel/crates/kernel-expr/src/ast.rs","Harakat_Kernel/crates/kernel-expr/src/eval.rs","Harakat_Kernel/crates/kernel-expr/src/lexer.rs","Harakat_Kernel/crates/kernel-expr/src/lib.rs","Harakat_Kernel/crates/kernel-expr/src/parser.rs","Harakat_Kernel/crates/kernel-expr/src/typecheck.rs","Harakat_Kernel/crates/kernel-expr/tests/fuel_and_limits.rs","Harakat_Kernel/crates/kernel-expr/tests/golden.rs","Harakat_Kernel/crates/kernel-expr/tests/proptests.rs","Harakat_Kernel/crates/kernel-expr/tests/typecheck_reject.rs","Harakat_Kernel/crates/kernel-integration/Cargo.toml","Harakat_Kernel/crates/kernel-integration/src/lib.rs","Harakat_Kernel/crates/kernel-integration/tests/employees_split_pg.rs","Harakat_Kernel/crates/kernel-integration/tests/g2_storage_events_macros.rs","Harakat_Kernel/crates/kernel-integration/tests/g3_api_authz_storage.rs","Harakat_Kernel/crates/kernel-integration/tests/g4_vertical_slice.rs","Harakat_Kernel/crates/kernel-integration/tests/k1_helpdesk_pg.rs","Harakat_Kernel/crates/kernel-integration/tests/k2_crm_pg.rs","Harakat_Kernel/crates/kernel-integration/tests/migrate_ordering_pg.rs","Harakat_Kernel/crates/kernel-integration/tests/rfc002_semantics.rs","Harakat_Kernel/crates/kernel-macros/Cargo.toml","Harakat_Kernel/crates/kernel-macros/src/build.rs","Harakat_Kernel/crates/kernel-macros/src/codegen.rs","Harakat_Kernel/crates/kernel-macros/src/grammar.rs","Harakat_Kernel/crates/kernel-macros/src/ir.rs","Harakat_Kernel/crates/kernel-macros/src/lib.rs","Harakat_Kernel/crates/kernel-macros/src/validate.rs","Harakat_Kernel/crates/kernel-macros/tests/trybuild.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_computed_cycle.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_computed_cycle.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_computed_unknown_dep.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_computed_unknown_dep.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_duplicate_action.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_duplicate_action.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_sealed_on_non_text.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_sealed_on_non_text.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_state_machine_field_not_selection.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_state_machine_field_not_selection.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_state_machine_unknown_action.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_state_machine_unknown_action.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_unmappable_type.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/fail_unmappable_type.stderr","Harakat_Kernel/crates/kernel-macros/tests/ui/pass_full.rs","Harakat_Kernel/crates/kernel-macros/tests/ui/pass_minimal.rs","Harakat_Kernel/crates/kernel-overlay/Cargo.toml","Harakat_Kernel/crates/kernel-overlay/src/automation.rs","Harakat_Kernel/crates/kernel-overlay/src/lib.rs","Harakat_Kernel/crates/kernel-overlay/src/resolve.rs","Harakat_Kernel/crates/kernel-overlay/src/store.rs","Harakat_Kernel/crates/kernel-overlay/src/validate.rs","Harakat_Kernel/crates/kernel-overlay/tests/authoring_audit.rs","Harakat_Kernel/crates/kernel-overlay/tests/automation.rs","Harakat_Kernel/crates/kernel-overlay/tests/common/mod.rs","Harakat_Kernel/crates/kernel-overlay/tests/pg_store.rs","Harakat_Kernel/crates/kernel-overlay/tests/s3_matrix.rs","Harakat_Kernel/crates/kernel-seal/Cargo.toml","Harakat_Kernel/crates/kernel-seal/examples/gen_fixture.rs","Harakat_Kernel/crates/kernel-seal/src/envelope.rs","Harakat_Kernel/crates/kernel-seal/src/lib.rs","Harakat_Kernel/crates/kernel-seal/src/transit.rs","Harakat_Kernel/crates/kernel-seal/tests/live_openbao.rs","Harakat_Kernel/crates/kernel-server/Cargo.toml","Harakat_Kernel/crates/kernel-server/src/claims_store.rs","Harakat_Kernel/crates/kernel-server/src/lib.rs","Harakat_Kernel/crates/kernel-server/src/main.rs","Harakat_Kernel/crates/kernel-server/src/real.rs","Harakat_Kernel/crates/kernel-server/tests/boot_smoke.rs","Harakat_Kernel/crates/kernel-server/tests/claims_projection_pg.rs","Harakat_Kernel/crates/kernel-storage/Cargo.toml","Harakat_Kernel/crates/kernel-storage/src/custom.rs","Harakat_Kernel/crates/kernel-storage/src/ddl.rs","Harakat_Kernel/crates/kernel-storage/src/entity_store.rs","Harakat_Kernel/crates/kernel-storage/src/executor.rs","Harakat_Kernel/crates/kernel-storage/src/idmap.rs","Harakat_Kernel/crates/kernel-storage/src/kernel.rs","Harakat_Kernel/crates/kernel-storage/src/lib.rs","Harakat_Kernel/crates/kernel-storage/src/migrator.rs","Harakat_Kernel/crates/kernel-storage/src/row.rs","Harakat_Kernel/crates/kernel-storage/tests/audit_period_pg.rs","Harakat_Kernel/crates/kernel-storage/tests/chatter_pg.rs","Harakat_Kernel/crates/kernel-storage/tests/compile_fail/construct_without_ctx.rs","Harakat_Kernel/crates/kernel-storage/tests/compile_fail/construct_without_ctx.stderr","Harakat_Kernel/crates/kernel-storage/tests/compile_fail/no_default_backdoor.rs","Harakat_Kernel/crates/kernel-storage/tests/compile_fail/no_default_backdoor.stderr","Harakat_Kernel/crates/kernel-storage/tests/compile_fail/no_raw_sql_door.rs","Harakat_Kernel/crates/kernel-storage/tests/compile_fail/no_raw_sql_door.stderr","Harakat_Kernel/crates/kernel-storage/tests/entity_roundtrip.rs","Harakat_Kernel/crates/kernel-storage/tests/entity_store_pg.rs","Harakat_Kernel/crates/kernel-storage/tests/pg_kernel.rs","Harakat_Kernel/crates/kernel-storage/tests/s2_jsonb_bench.rs","Harakat_Kernel/crates/kernel-storage/tests/s4_compile_fail.rs","Harakat_Kernel/crates/kernel-storage/tests/s4_tenant_executor.rs","Harakat_Kernel/crates/kernel-storage/tests/unique_constraint_state_pg.rs","Harakat_Kernel/crates/kernel-testkit/Cargo.toml","Harakat_Kernel/crates/kernel-testkit/src/fake_authz.rs","Harakat_Kernel/crates/kernel-testkit/src/fake_events.rs","Harakat_Kernel/crates/kernel-testkit/src/fake_expr.rs","Harakat_Kernel/crates/kernel-testkit/src/fake_idmap.rs","Harakat_Kernel/crates/kernel-testkit/src/fake_overlay.rs","Harakat_Kernel/crates/kernel-testkit/src/fake_sealer.rs","Harakat_Kernel/crates/kernel-testkit/src/fixtures.rs","Harakat_Kernel/crates/kernel-testkit/src/lib.rs","Harakat_Kernel/crates/kernel-testkit/src/live.rs","Harakat_Kernel/crates/kernel-testkit/src/mem_store.rs","Harakat_Kernel/crates/kernel-testkit/src/pg.rs"]},{"name":"Harakat_Kernel — dev","slug":"harakat-kernel-dev","files":["Harakat_Kernel/dev/docker-compose.dev.yml","Harakat_Kernel/dev/kernel.env.example","Harakat_Kernel/dev/run-kernel.ps1","Harakat_Kernel/dev/run-kernel.sh"]},{"name":"Harakat_Kernel — docs","slug":"harakat-kernel-docs","files":["Harakat_Kernel/docs/contracts.md","Harakat_Kernel/docs/dev-setup.md","Harakat_Kernel/docs/rfcs/001-app-logic-hooks-and-grant-binding.md","Harakat_Kernel/docs/rfcs/002-write-hooks-ondelete-idmap.md","Harakat_Kernel/docs/rfcs/003-idmap-bind.md","Harakat_Kernel/docs/rfcs/004-shared-x2many-write-validation.md","Harakat_Kernel/docs/rfcs/005-record-ownership-mixin.md","Harakat_Kernel/docs/rfcs/006-unique-field-index.md","Harakat_Kernel/docs/rfcs/007-cross-app-posting-effects.md","Harakat_Kernel/docs/rfcs/008-delete-guard-hook.md","Harakat_Kernel/docs/rfcs/009-child-writes-dynamic-lines.md","Harakat_Kernel/docs/rfcs/010-custom-entities.md","Harakat_Kernel/docs/rfcs/011-allocation-grant-visibility.md","Harakat_Kernel/docs/rfcs/012-computed-fields-and-rollups.md"]},{"name":"Harakat_Kernel — scripts","slug":"harakat-kernel-scripts","files":["Harakat_Kernel/scripts/check-sqlx-boundary.sh","Harakat_Kernel/scripts/migrate-gate.sh"]},{"name":"Harakat_Kernel — tools","slug":"harakat-kernel-tools","files":["Harakat_Kernel/tools/diff-harness/Cargo.toml","Harakat_Kernel/tools/diff-harness/README.md","Harakat_Kernel/tools/diff-harness/scripts/crm-parity.json","Harakat_Kernel/tools/diff-harness/scripts/finance-books-odoo-leg.ps1","Harakat_Kernel/tools/diff-harness/scripts/finance-books-parity.divergences.md","Harakat_Kernel/tools/diff-harness/scripts/finance-books-parity.json","Harakat_Kernel/tools/diff-harness/scripts/helpdesk-parity.json","Harakat_Kernel/tools/diff-harness/scripts/notes-smoke.json","Harakat_Kernel/tools/diff-harness/scripts/odoo-crud-smoke.json","Harakat_Kernel/tools/diff-harness/scripts/wave2-dispatch-parity.json","Harakat_Kernel/tools/diff-harness/scripts/wave2-ownership-createseed-parity.json","Harakat_Kernel/tools/diff-harness/scripts/wave2-ownership-parity.json","Harakat_Kernel/tools/diff-harness/src/backend.rs","Harakat_Kernel/tools/diff-harness/src/config.rs","Harakat_Kernel/tools/diff-harness/src/differ.rs","Harakat_Kernel/tools/diff-harness/src/kernel_backend.rs","Harakat_Kernel/tools/diff-harness/src/lib.rs","Harakat_Kernel/tools/diff-harness/src/main.rs","Harakat_Kernel/tools/diff-harness/src/odoo_backend.rs","Harakat_Kernel/tools/diff-harness/src/projection.rs","Harakat_Kernel/tools/diff-harness/src/runner.rs","Harakat_Kernel/tools/diff-harness/src/script.rs","Harakat_Kernel/tools/diff-harness/tests/finance_books_selfdiff.rs","Harakat_Kernel/tools/diff-harness/tests/stub_backends.rs","Harakat_Kernel/tools/etl-catalog/Cargo.toml","Harakat_Kernel/tools/etl-catalog/src/main.rs","Harakat_Kernel/tools/etl-crm/Cargo.toml","Harakat_Kernel/tools/etl-crm/src/main.rs","Harakat_Kernel/tools/etl-helpdesk/Cargo.toml","Harakat_Kernel/tools/etl-helpdesk/src/main.rs","Harakat_Kernel/tools/etl-project/Cargo.toml","Harakat_Kernel/tools/etl-project/src/main.rs","Harakat_Kernel/tools/etl-purchase/Cargo.toml","Harakat_Kernel/tools/etl-purchase/src/main.rs","Harakat_Kernel/tools/etl-sale/Cargo.toml","Harakat_Kernel/tools/etl-sale/src/main.rs","Harakat_Kernel/tools/etl-stock/Cargo.toml","Harakat_Kernel/tools/etl-stock/src/main.rs","Harakat_Kernel/tools/etl-wave2/Cargo.toml","Harakat_Kernel/tools/etl-wave2/src/main.rs"]}]},{"name":"Harakat_Landing","slug":"harakat-landing","files":[],"children":[{"name":"Harakat_Landing — Harakat_Landing","slug":"harakat-landing-harakat-landing","files":["Harakat_Landing/Dockerfile","Harakat_Landing/components.json","Harakat_Landing/next.config.mjs","Harakat_Landing/package.json","Harakat_Landing/postcss.config.mjs","Harakat_Landing/tsconfig.json"]},{"name":"Harakat_Landing — app","slug":"harakat-landing-app","files":["Harakat_Landing/app/ClientLayout.tsx","Harakat_Landing/app/api/send-email/route.ts","Harakat_Landing/app/apple-icon.tsx","Harakat_Landing/app/calculator/page.tsx","Harakat_Landing/app/company/about/page.tsx","Harakat_Landing/app/company/careers/page.tsx","Harakat_Landing/app/company/security/page.tsx","Harakat_Landing/app/contact/page.tsx","Harakat_Landing/app/faq/page.tsx","Harakat_Landing/app/globals.css","Harakat_Landing/app/home.css","Harakat_Landing/app/icon.tsx","Harakat_Landing/app/layout.tsx","Harakat_Landing/app/login/page.tsx","Harakat_Landing/app/page.tsx","Harakat_Landing/app/platform/page.tsx","Harakat_Landing/app/pricing/page.tsx","Harakat_Landing/app/privacy-policy/page.tsx","Harakat_Landing/app/robots.ts","Harakat_Landing/app/sitemap.ts","Harakat_Landing/app/terms-of-service/page.tsx"]},{"name":"Harakat_Landing — components","slug":"harakat-landing-components","files":["Harakat_Landing/components/home/calculator.tsx","Harakat_Landing/components/home/contact-form-lp.tsx","Harakat_Landing/components/home/hero-data.ts","Harakat_Landing/components/home/hero-pills.tsx","Harakat_Landing/components/home/hero.tsx","Harakat_Landing/components/home/home-footer.tsx","Harakat_Landing/components/home/home-header.tsx","Harakat_Landing/components/home/how-it-works.tsx","Harakat_Landing/components/home/legal-page-lp.tsx","Harakat_Landing/components/home/marquee.tsx","Harakat_Landing/components/home/outcomes.tsx","Harakat_Landing/components/home/page-blocks.tsx","Harakat_Landing/components/home/page-shell.tsx","Harakat_Landing/components/home/phero-live.tsx","Harakat_Landing/components/home/pixel.tsx","Harakat_Landing/components/home/platform-story.tsx","Harakat_Landing/components/home/security.tsx","Harakat_Landing/components/home/smooth-scroll.tsx","Harakat_Landing/components/home/sock.tsx","Harakat_Landing/components/home/suite-grid.tsx","Harakat_Landing/components/home/what-we-do.tsx","Harakat_Landing/components/home/world-map.tsx","Harakat_Landing/components/hooks/use-debounced-dimensions.ts","Harakat_Landing/components/ui/accordion.tsx","Harakat_Landing/components/ui/alert-dialog.tsx","Harakat_Landing/components/ui/alert.tsx","Harakat_Landing/components/ui/animated-gradient-with-svg.tsx","Harakat_Landing/components/ui/aspect-ratio.tsx","Harakat_Landing/components/ui/avatar.tsx","Harakat_Landing/components/ui/badge.tsx","Harakat_Landing/components/ui/breadcrumb.tsx","Harakat_Landing/components/ui/button.tsx","Harakat_Landing/components/ui/calendar.tsx","Harakat_Landing/components/ui/card.tsx","Harakat_Landing/components/ui/carousel.tsx","Harakat_Landing/components/ui/chart.tsx","Harakat_Landing/components/ui/checkbox.tsx","Harakat_Landing/components/ui/collapsible.tsx","Harakat_Landing/components/ui/command.tsx","Harakat_Landing/components/ui/context-menu.tsx","Harakat_Landing/components/ui/dialog.tsx","Harakat_Landing/components/ui/drawer.tsx","Harakat_Landing/components/ui/dropdown-menu.tsx","Harakat_Landing/components/ui/floating-paths.tsx","Harakat_Landing/components/ui/form.tsx","Harakat_Landing/components/ui/hover-card.tsx","Harakat_Landing/components/ui/infinite-slider.tsx","Harakat_Landing/components/ui/input-otp.tsx","Harakat_Landing/components/ui/input.tsx","Harakat_Landing/components/ui/label.tsx","Harakat_Landing/components/ui/menubar.tsx","Harakat_Landing/components/ui/navigation-menu.tsx","Harakat_Landing/components/ui/pagination.tsx","Harakat_Landing/components/ui/popover.tsx","Harakat_Landing/components/ui/progress.tsx","Harakat_Landing/components/ui/progressive-blur.tsx","Harakat_Landing/components/ui/radio-group.tsx","Harakat_Landing/components/ui/resizable.tsx","Harakat_Landing/components/ui/scroll-area.tsx","Harakat_Landing/components/ui/select.tsx","Harakat_Landing/components/ui/separator.tsx","Harakat_Landing/components/ui/sheet.tsx","Harakat_Landing/components/ui/sidebar.tsx","Harakat_Landing/components/ui/skeleton.tsx","Harakat_Landing/components/ui/slider.tsx","Harakat_Landing/components/ui/sonner.tsx","Harakat_Landing/components/ui/switch.tsx","Harakat_Landing/components/ui/table.tsx","Harakat_Landing/components/ui/tabs.tsx","Harakat_Landing/components/ui/textarea.tsx","Harakat_Landing/components/ui/toast.tsx","Harakat_Landing/components/ui/toaster.tsx","Harakat_Landing/components/ui/toggle-group.tsx","Harakat_Landing/components/ui/toggle.tsx","Harakat_Landing/components/ui/tooltip.tsx","Harakat_Landing/components/ui/use-mobile.tsx","Harakat_Landing/components/ui/use-toast.ts"]},{"name":"Harakat_Landing — hooks","slug":"harakat-landing-hooks","files":["Harakat_Landing/hooks/use-mobile.ts","Harakat_Landing/hooks/use-toast.ts"]},{"name":"Harakat_Landing — lib","slug":"harakat-landing-lib","files":["Harakat_Landing/lib/utils.ts"]},{"name":"Harakat_Landing — public","slug":"harakat-landing-public","files":["Harakat_Landing/public/about.txt","Harakat_Landing/public/ai-context.json","Harakat_Landing/public/manifest.json"]},{"name":"Harakat_Landing — styles","slug":"harakat-landing-styles","files":["Harakat_Landing/styles/globals.css"]}]},{"name":"Harakat_Office","slug":"harakat-office","files":[],"children":[{"name":"Harakat_Office — app","slug":"harakat-office-app","files":["Harakat_Office/app/[locale]/(app)/layout.tsx","Harakat_Office/app/[locale]/(app)/projects/[id]/page.tsx","Harakat_Office/app/[locale]/(app)/projects/page.tsx","Harakat_Office/app/[locale]/layout.tsx","Harakat_Office/app/[locale]/login/page.tsx","Harakat_Office/app/[locale]/page.tsx","Harakat_Office/app/globals.css"]},{"name":"Harakat_Office — components","slug":"harakat-office-components","files":["Harakat_Office/components/board/board-tab.tsx","Harakat_Office/components/board/chain-pill.tsx","Harakat_Office/components/board/member-card.tsx","Harakat_Office/components/board/narrated-block.tsx","Harakat_Office/components/board/note-composer.tsx","Harakat_Office/components/board/signal-tile.tsx","Harakat_Office/components/common/empty-state.tsx","Harakat_Office/components/common/page-header.tsx","Harakat_Office/components/common/plain-text.tsx","Harakat_Office/components/common/states.tsx","Harakat_Office/components/common/status-badges.tsx","Harakat_Office/components/common/vendor-code.tsx","Harakat_Office/components/project/asks-tab.tsx","Harakat_Office/components/project/audit-tab.tsx","Harakat_Office/components/project/deliverables-tab.tsx","Harakat_Office/components/project/member-select.tsx","Harakat_Office/components/project/members-tab.tsx","Harakat_Office/components/project/milestones-tab.tsx","Harakat_Office/components/project/project-actions.tsx","Harakat_Office/components/projects/create-project-dialog.tsx","Harakat_Office/components/providers.tsx","Harakat_Office/components/shell/app-footer.tsx","Harakat_Office/components/shell/locale-switcher.tsx","Harakat_Office/components/shell/theme-toggle.tsx","Harakat_Office/components/shell/top-bar.tsx","Harakat_Office/components/shell/user-menu.tsx","Harakat_Office/components/theme-provider.tsx","Harakat_Office/components/ui/badge.tsx","Harakat_Office/components/ui/button.tsx","Harakat_Office/components/ui/card.tsx","Harakat_Office/components/ui/dialog.tsx","Harakat_Office/components/ui/dropdown-menu.tsx","Harakat_Office/components/ui/input.tsx","Harakat_Office/components/ui/label.tsx","Harakat_Office/components/ui/select.tsx","Harakat_Office/components/ui/separator.tsx","Harakat_Office/components/ui/skeleton.tsx","Harakat_Office/components/ui/sonner.tsx","Harakat_Office/components/ui/table.tsx","Harakat_Office/components/ui/tabs.tsx","Harakat_Office/components/ui/textarea.tsx"]},{"name":"Harakat_Office — i18n","slug":"harakat-office-i18n","files":["Harakat_Office/i18n/navigation.ts","Harakat_Office/i18n/request.ts","Harakat_Office/i18n/routing.ts"]},{"name":"Harakat_Office — lib","slug":"harakat-office-lib","files":["Harakat_Office/lib/api/auth.ts","Harakat_Office/lib/api/client.ts","Harakat_Office/lib/api/vendors.ts","Harakat_Office/lib/auth-context.tsx","Harakat_Office/lib/format.ts","Harakat_Office/lib/use-project-data.ts","Harakat_Office/lib/utils.ts","Harakat_Office/lib/vendor-codes.ts"]},{"name":"Harakat_Office — messages","slug":"harakat-office-messages","files":["Harakat_Office/messages/ar.json","Harakat_Office/messages/en.json"]},{"name":"Harakat_Office — Harakat_Office","slug":"harakat-office-harakat-office","files":["Harakat_Office/middleware.ts","Harakat_Office/next.config.mjs","Harakat_Office/package.json","Harakat_Office/postcss.config.mjs","Harakat_Office/tsconfig.json"]},{"name":"Harakat_Office — scripts","slug":"harakat-office-scripts","files":["Harakat_Office/scripts/check-i18n.mjs"]},{"name":"Harakat_Office — types","slug":"harakat-office-types","files":["Harakat_Office/types/vendors.ts"]}]},{"name":"StartupsPlatform","slug":"startupsplatform","files":[],"children":[{"name":"StartupsPlatform — StartupsPlatform","slug":"startupsplatform-startupsplatform","files":["StartupsPlatform/Dockerfile","StartupsPlatform/components.json","StartupsPlatform/next.config.mjs","StartupsPlatform/package.json","StartupsPlatform/playwright.config.ts","StartupsPlatform/postcss.config.mjs","StartupsPlatform/tsconfig.json","StartupsPlatform/vitest.config.ts","StartupsPlatform/vitest.setup.ts"]},{"name":"StartupsPlatform — app","slug":"startupsplatform-app","files":["StartupsPlatform/app/agent-board/layout.tsx","StartupsPlatform/app/agent-board/page.tsx","StartupsPlatform/app/apple-icon.tsx","StartupsPlatform/app/auth/callback/page.tsx","StartupsPlatform/app/dashboard/apps/[name]/page.tsx","StartupsPlatform/app/dashboard/apps/layout.tsx","StartupsPlatform/app/dashboard/apps/page.tsx","StartupsPlatform/app/dashboard/assistant/[id]/page.tsx","StartupsPlatform/app/dashboard/assistant/loading.tsx","StartupsPlatform/app/dashboard/assistant/page.tsx","StartupsPlatform/app/dashboard/automations/[id]/page.tsx","StartupsPlatform/app/dashboard/automations/page.tsx","StartupsPlatform/app/dashboard/documents/folder/[id]/page.tsx","StartupsPlatform/app/dashboard/documents/loading.tsx","StartupsPlatform/app/dashboard/documents/page.tsx","StartupsPlatform/app/dashboard/error.tsx","StartupsPlatform/app/dashboard/layout.tsx","StartupsPlatform/app/dashboard/page.test.tsx","StartupsPlatform/app/dashboard/page.tsx","StartupsPlatform/app/dashboard/rooms/[key]/page.tsx","StartupsPlatform/app/dashboard/rooms/page.tsx","StartupsPlatform/app/dashboard/rooms/rooms-project-surface.test.tsx","StartupsPlatform/app/dashboard/settings/company/page.tsx","StartupsPlatform/app/dashboard/settings/coordination/page.tsx","StartupsPlatform/app/dashboard/settings/erp/customization/page.tsx","StartupsPlatform/app/dashboard/settings/governance/actions/page.tsx","StartupsPlatform/app/dashboard/settings/governance/audit/page.tsx","StartupsPlatform/app/dashboard/settings/governance/capabilities/page.tsx","StartupsPlatform/app/dashboard/settings/governance/delegation/page.tsx","StartupsPlatform/app/dashboard/settings/governance/links/page.tsx","StartupsPlatform/app/dashboard/settings/governance/mcp/page.tsx","StartupsPlatform/app/dashboard/settings/governance/mutations/page.tsx","StartupsPlatform/app/dashboard/settings/governance/operations/page.tsx","StartupsPlatform/app/dashboard/settings/governance/page.tsx","StartupsPlatform/app/dashboard/settings/governance/policies/page.tsx","StartupsPlatform/app/dashboard/settings/governance/procedures/page.tsx","StartupsPlatform/app/dashboard/settings/governance/recording-rules/page.tsx","StartupsPlatform/app/dashboard/settings/governance/skills/page.tsx","StartupsPlatform/app/dashboard/settings/layout.tsx","StartupsPlatform/app/dashboard/settings/notifications/page.tsx","StartupsPlatform/app/dashboard/settings/page.tsx","StartupsPlatform/app/dashboard/settings/profile/page.tsx","StartupsPlatform/app/dashboard/settings/security/page.tsx","StartupsPlatform/app/dashboard/settings/workspace/page.tsx","StartupsPlatform/app/dashboard/support/page.tsx","StartupsPlatform/app/dashboard/utilities/calendar/page.tsx","StartupsPlatform/app/dashboard/utilities/chat/page.tsx","StartupsPlatform/app/dashboard/utilities/email/page.tsx","StartupsPlatform/app/dashboard/utilities/page.tsx","StartupsPlatform/app/erp/advancedaccounting/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/accounts/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/accounts/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/accounts/page.tsx","StartupsPlatform/app/erp/advancedaccounting/analytics/page.tsx","StartupsPlatform/app/erp/advancedaccounting/assets/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/assets/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/assets/page.tsx","StartupsPlatform/app/erp/advancedaccounting/audit-trail/page.tsx","StartupsPlatform/app/erp/advancedaccounting/balance-sheet/page.tsx","StartupsPlatform/app/erp/advancedaccounting/balance-sheet/statements-on-screen.test.tsx","StartupsPlatform/app/erp/advancedaccounting/chart-of-accounts-integrity.test.tsx","StartupsPlatform/app/erp/advancedaccounting/close/page.tsx","StartupsPlatform/app/erp/advancedaccounting/close/period-close-reopen.test.tsx","StartupsPlatform/app/erp/advancedaccounting/dunning/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/dunning/absent-vs-failed.test.tsx","StartupsPlatform/app/erp/advancedaccounting/dunning/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/dunning/page.tsx","StartupsPlatform/app/erp/advancedaccounting/entries/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/entries/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/entries/page.tsx","StartupsPlatform/app/erp/advancedaccounting/insights/page.tsx","StartupsPlatform/app/erp/advancedaccounting/journals/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/journals/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/journals/page.tsx","StartupsPlatform/app/erp/advancedaccounting/layout.tsx","StartupsPlatform/app/erp/advancedaccounting/new-writes-nothing.test.tsx","StartupsPlatform/app/erp/advancedaccounting/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/page.tsx","StartupsPlatform/app/erp/advancedaccounting/profit-and-loss/page.tsx","StartupsPlatform/app/erp/advancedaccounting/reconcile/page.tsx","StartupsPlatform/app/erp/advancedaccounting/reports/page.tsx","StartupsPlatform/app/erp/advancedaccounting/trial-balance/export-on-screen.test.tsx","StartupsPlatform/app/erp/advancedaccounting/trial-balance/page.tsx","StartupsPlatform/app/erp/advancedaccounting/trial-balance/reports-what-it-read.test.tsx","StartupsPlatform/app/erp/advancedaccounting/wip/[id]/page.tsx","StartupsPlatform/app/erp/advancedaccounting/wip/new/page.tsx","StartupsPlatform/app/erp/advancedaccounting/wip/page.tsx","StartupsPlatform/app/erp/attendance/[id]/page.tsx","StartupsPlatform/app/erp/attendance/analytics/page.tsx","StartupsPlatform/app/erp/attendance/insights/page.tsx","StartupsPlatform/app/erp/attendance/kiosk/page.tsx","StartupsPlatform/app/erp/attendance/layout.tsx","StartupsPlatform/app/erp/attendance/page.tsx","StartupsPlatform/app/erp/attendance/reports/page.tsx","StartupsPlatform/app/erp/beneficiaries/[id]/page.tsx","StartupsPlatform/app/erp/beneficiaries/layout.tsx","StartupsPlatform/app/erp/beneficiaries/links/page.test.tsx","StartupsPlatform/app/erp/beneficiaries/links/page.tsx","StartupsPlatform/app/erp/beneficiaries/loans/page.tsx","StartupsPlatform/app/erp/beneficiaries/page.test.tsx","StartupsPlatform/app/erp/beneficiaries/page.tsx","StartupsPlatform/app/erp/contacts/[id]/page.tsx","StartupsPlatform/app/erp/contacts/analytics/page.tsx","StartupsPlatform/app/erp/contacts/credit/page.test.tsx","StartupsPlatform/app/erp/contacts/credit/page.tsx","StartupsPlatform/app/erp/contacts/layout.tsx","StartupsPlatform/app/erp/contacts/merge/page.tsx","StartupsPlatform/app/erp/contacts/page.tsx","StartupsPlatform/app/erp/contacts/reports/page.tsx","StartupsPlatform/app/erp/crm/[id]/page.tsx","StartupsPlatform/app/erp/crm/analytics/page.tsx","StartupsPlatform/app/erp/crm/funnel/page.tsx","StartupsPlatform/app/erp/crm/insights/page.tsx","StartupsPlatform/app/erp/crm/layout.tsx","StartupsPlatform/app/erp/crm/leads/page.test.tsx","StartupsPlatform/app/erp/crm/leads/page.tsx","StartupsPlatform/app/erp/crm/page.test.tsx","StartupsPlatform/app/erp/crm/page.tsx","StartupsPlatform/app/erp/crm/prospects/page.tsx","StartupsPlatform/app/erp/crm/reports/page.tsx","StartupsPlatform/app/erp/crm/retired-routes.test.tsx","StartupsPlatform/app/erp/datacycle/[id]/page.tsx","StartupsPlatform/app/erp/datacycle/layout.tsx","StartupsPlatform/app/erp/datacycle/page.tsx","StartupsPlatform/app/erp/datacycle/records/page.tsx","StartupsPlatform/app/erp/emailmarketing/[id]/page.tsx","StartupsPlatform/app/erp/emailmarketing/analytics/page.tsx","StartupsPlatform/app/erp/emailmarketing/calendar/page.tsx","StartupsPlatform/app/erp/emailmarketing/insights/page.tsx","StartupsPlatform/app/erp/emailmarketing/layout.tsx","StartupsPlatform/app/erp/emailmarketing/page.tsx","StartupsPlatform/app/erp/emailmarketing/reports/page.tsx","StartupsPlatform/app/erp/employees/[id]/page.tsx","StartupsPlatform/app/erp/employees/analytics/page.tsx","StartupsPlatform/app/erp/employees/appraisals/[id]/page.test.tsx","StartupsPlatform/app/erp/employees/appraisals/[id]/page.tsx","StartupsPlatform/app/erp/employees/appraisals/page.test.tsx","StartupsPlatform/app/erp/employees/appraisals/page.tsx","StartupsPlatform/app/erp/employees/bad-segment.test.tsx","StartupsPlatform/app/erp/employees/contracts/[id]/page.tsx","StartupsPlatform/app/erp/employees/contracts/page.test.tsx","StartupsPlatform/app/erp/employees/contracts/page.tsx","StartupsPlatform/app/erp/employees/departments/page.tsx","StartupsPlatform/app/erp/employees/insights/page.tsx","StartupsPlatform/app/erp/employees/jobs/page.tsx","StartupsPlatform/app/erp/employees/layout.tsx","StartupsPlatform/app/erp/employees/merge-identity.test.ts","StartupsPlatform/app/erp/employees/merge-identity.ts","StartupsPlatform/app/erp/employees/organization/page.tsx","StartupsPlatform/app/erp/employees/orgchart/page.tsx","StartupsPlatform/app/erp/employees/orgchart/people-tree.test.ts","StartupsPlatform/app/erp/employees/orgchart/people-tree.ts","StartupsPlatform/app/erp/employees/page.test.tsx","StartupsPlatform/app/erp/employees/page.tsx","StartupsPlatform/app/erp/employees/people-sections.test.ts","StartupsPlatform/app/erp/employees/people-sections.ts","StartupsPlatform/app/erp/employees/people/[startupUserId]/page.tsx","StartupsPlatform/app/erp/employees/reports/page.tsx","StartupsPlatform/app/erp/entities/[model]/layout.tsx","StartupsPlatform/app/erp/entities/[model]/page.tsx","StartupsPlatform/app/erp/error.tsx","StartupsPlatform/app/erp/expenses/[id]/page.tsx","StartupsPlatform/app/erp/expenses/analytics/page.tsx","StartupsPlatform/app/erp/expenses/insights/page.tsx","StartupsPlatform/app/erp/expenses/layout.tsx","StartupsPlatform/app/erp/expenses/page.tsx","StartupsPlatform/app/erp/expenses/reports/page.tsx","StartupsPlatform/app/erp/finance/[id]/page.tsx","StartupsPlatform/app/erp/finance/[id]/tax-invoice/page.tsx","StartupsPlatform/app/erp/finance/aging/[partnerId]/page.tsx","StartupsPlatform/app/erp/finance/aging/page.tsx","StartupsPlatform/app/erp/finance/bad-segment.test.tsx","StartupsPlatform/app/erp/finance/layout.tsx","StartupsPlatform/app/erp/finance/new/page.tsx","StartupsPlatform/app/erp/finance/page.tsx","StartupsPlatform/app/erp/finance/payables/new/page.tsx","StartupsPlatform/app/erp/finance/payables/page.tsx","StartupsPlatform/app/erp/finance/payments/page.test.tsx","StartupsPlatform/app/erp/finance/payments/page.tsx","StartupsPlatform/app/erp/finance/vat-return/page.tsx","StartupsPlatform/app/erp/helpdesk/[id]/page.tsx","StartupsPlatform/app/erp/helpdesk/analytics/page.tsx","StartupsPlatform/app/erp/helpdesk/insights/page.tsx","StartupsPlatform/app/erp/helpdesk/layout.tsx","StartupsPlatform/app/erp/helpdesk/maintenance/page.tsx","StartupsPlatform/app/erp/helpdesk/page.tsx","StartupsPlatform/app/erp/helpdesk/reports/page.tsx","StartupsPlatform/app/erp/helpdesk/settings/page.tsx","StartupsPlatform/app/erp/helpdesk/teams/page.tsx","StartupsPlatform/app/erp/helpdesk/warranty/page.tsx","StartupsPlatform/app/erp/inventory/[id]/page.tsx","StartupsPlatform/app/erp/inventory/analytics/page.tsx","StartupsPlatform/app/erp/inventory/insights/page.tsx","StartupsPlatform/app/erp/inventory/landed-costs/page.tsx","StartupsPlatform/app/erp/inventory/layout.tsx","StartupsPlatform/app/erp/inventory/masters/page.tsx","StartupsPlatform/app/erp/inventory/operations/page.tsx","StartupsPlatform/app/erp/inventory/page.tsx","StartupsPlatform/app/erp/inventory/quality/page.tsx","StartupsPlatform/app/erp/inventory/replenishment/page.tsx","StartupsPlatform/app/erp/inventory/reports/page.tsx","StartupsPlatform/app/erp/inventory/stock/page.tsx","StartupsPlatform/app/erp/knowledge/layout.tsx","StartupsPlatform/app/erp/knowledge/page.tsx","StartupsPlatform/app/erp/layout.tsx","StartupsPlatform/app/erp/livechat/[id]/page.tsx","StartupsPlatform/app/erp/livechat/layout.tsx","StartupsPlatform/app/erp/livechat/page.tsx","StartupsPlatform/app/erp/livechat/sessions/page.tsx","StartupsPlatform/app/erp/maintenance/[id]/page.tsx","StartupsPlatform/app/erp/maintenance/analytics/page.tsx","StartupsPlatform/app/erp/maintenance/calendar/page.tsx","StartupsPlatform/app/erp/maintenance/contracts/page.tsx","StartupsPlatform/app/erp/maintenance/equipment/[id]/page.tsx","StartupsPlatform/app/erp/maintenance/equipment/page.tsx","StartupsPlatform/app/erp/maintenance/insights/page.tsx","StartupsPlatform/app/erp/maintenance/layout.tsx","StartupsPlatform/app/erp/maintenance/page.tsx","StartupsPlatform/app/erp/maintenance/reports/page.tsx","StartupsPlatform/app/erp/manufacturing/[id]/page.tsx","StartupsPlatform/app/erp/manufacturing/analytics/page.tsx","StartupsPlatform/app/erp/manufacturing/bom/[id]/page.tsx","StartupsPlatform/app/erp/manufacturing/bom/page.tsx","StartupsPlatform/app/erp/manufacturing/engineering/page.tsx","StartupsPlatform/app/erp/manufacturing/insights/page.tsx","StartupsPlatform/app/erp/manufacturing/layout.tsx","StartupsPlatform/app/erp/manufacturing/operations/page.tsx","StartupsPlatform/app/erp/manufacturing/page.tsx","StartupsPlatform/app/erp/manufacturing/planning/page.tsx","StartupsPlatform/app/erp/manufacturing/reports/page.tsx","StartupsPlatform/app/erp/manufacturing/routing/page.tsx","StartupsPlatform/app/erp/manufacturing/workcenters/page.tsx","StartupsPlatform/app/erp/manufacturing/workorder/[id]/page.tsx","StartupsPlatform/app/erp/manufacturing/workorder/page.tsx","StartupsPlatform/app/erp/marketing-automation/layout.tsx","StartupsPlatform/app/erp/marketing-automation/page.tsx","StartupsPlatform/app/erp/marketingcard/[id]/page.tsx","StartupsPlatform/app/erp/marketingcard/analytics/page.tsx","StartupsPlatform/app/erp/marketingcard/cards/page.tsx","StartupsPlatform/app/erp/marketingcard/insights/page.tsx","StartupsPlatform/app/erp/marketingcard/layout.tsx","StartupsPlatform/app/erp/marketingcard/page.tsx","StartupsPlatform/app/erp/marketingcard/reports/page.tsx","StartupsPlatform/app/erp/marketingcard/templates/page.tsx","StartupsPlatform/app/erp/ngofinance/distribute/page.tsx","StartupsPlatform/app/erp/ngofinance/layout.tsx","StartupsPlatform/app/erp/ngofinance/loans/page.tsx","StartupsPlatform/app/erp/ngofinance/page.test.tsx","StartupsPlatform/app/erp/ngofinance/page.tsx","StartupsPlatform/app/erp/ngofinance/rules/[id]/page.tsx","StartupsPlatform/app/erp/ngofinance/rules/page.tsx","StartupsPlatform/app/erp/ngofinance/statements/page.test.tsx","StartupsPlatform/app/erp/ngofinance/statements/page.tsx","StartupsPlatform/app/erp/not-found.tsx","StartupsPlatform/app/erp/page.tsx","StartupsPlatform/app/erp/pages/[key]/layout.tsx","StartupsPlatform/app/erp/pages/[key]/page.tsx","StartupsPlatform/app/erp/payroll/[id]/page.tsx","StartupsPlatform/app/erp/payroll/analytics/page.tsx","StartupsPlatform/app/erp/payroll/contracts/[id]/page.tsx","StartupsPlatform/app/erp/payroll/contracts/page.tsx","StartupsPlatform/app/erp/payroll/insights/page.tsx","StartupsPlatform/app/erp/payroll/layout.tsx","StartupsPlatform/app/erp/payroll/page.tsx","StartupsPlatform/app/erp/payroll/rules/page.tsx","StartupsPlatform/app/erp/payroll/structure/page.tsx","StartupsPlatform/app/erp/payroll/structures/page.tsx","StartupsPlatform/app/erp/planning/layout.tsx","StartupsPlatform/app/erp/planning/page.tsx","StartupsPlatform/app/erp/pos/[id]/page.tsx","StartupsPlatform/app/erp/pos/analytics/page.tsx","StartupsPlatform/app/erp/pos/insights/page.tsx","StartupsPlatform/app/erp/pos/layout.tsx","StartupsPlatform/app/erp/pos/page.tsx","StartupsPlatform/app/erp/pos/reports/page.tsx","StartupsPlatform/app/erp/pos/sessions/[id]/page.tsx","StartupsPlatform/app/erp/pos/sessions/page.tsx","StartupsPlatform/app/erp/pos/terminal/page.tsx","StartupsPlatform/app/erp/project/[id]/page.tsx","StartupsPlatform/app/erp/project/analytics/page.tsx","StartupsPlatform/app/erp/project/dependencies/page.tsx","StartupsPlatform/app/erp/project/gantt/page.tsx","StartupsPlatform/app/erp/project/insights/page.tsx","StartupsPlatform/app/erp/project/layout.tsx","StartupsPlatform/app/erp/project/page.tsx","StartupsPlatform/app/erp/project/profitability/page.tsx","StartupsPlatform/app/erp/project/reports/page.tsx","StartupsPlatform/app/erp/project/tasks/[id]/page.tsx","StartupsPlatform/app/erp/project/tasks/page.tsx","StartupsPlatform/app/erp/project/tasks/tasks-board.test.tsx","StartupsPlatform/app/erp/project/tasks/tasks-messages.test.ts","StartupsPlatform/app/erp/project/templates/page.tsx","StartupsPlatform/app/erp/purchase/[id]/page.tsx","StartupsPlatform/app/erp/purchase/bills/[moveId]/page.tsx","StartupsPlatform/app/erp/purchase/layout.tsx","StartupsPlatform/app/erp/purchase/new/page.tsx","StartupsPlatform/app/erp/purchase/page.tsx","StartupsPlatform/app/erp/purchase/receipts/[pickingId]/page.tsx","StartupsPlatform/app/erp/purchase/requisitions/[id]/page.tsx","StartupsPlatform/app/erp/purchase/requisitions/new/page.tsx","StartupsPlatform/app/erp/purchase/requisitions/page.tsx","StartupsPlatform/app/erp/recruitment/[id]/page.tsx","StartupsPlatform/app/erp/recruitment/analytics/page.tsx","StartupsPlatform/app/erp/recruitment/insights/page.tsx","StartupsPlatform/app/erp/recruitment/layout.tsx","StartupsPlatform/app/erp/recruitment/page.tsx","StartupsPlatform/app/erp/repairs/[id]/page.tsx","StartupsPlatform/app/erp/repairs/analytics/page.tsx","StartupsPlatform/app/erp/repairs/insights/page.tsx","StartupsPlatform/app/erp/repairs/layout.tsx","StartupsPlatform/app/erp/repairs/page.tsx","StartupsPlatform/app/erp/repairs/warranty/page.tsx","StartupsPlatform/app/erp/sales/[id]/page.tsx","StartupsPlatform/app/erp/sales/analytics/page.tsx","StartupsPlatform/app/erp/sales/bundles/page.tsx","StartupsPlatform/app/erp/sales/catalog/masters/page.tsx","StartupsPlatform/app/erp/sales/catalog/page.tsx","StartupsPlatform/app/erp/sales/insights/page.tsx","StartupsPlatform/app/erp/sales/layout.tsx","StartupsPlatform/app/erp/sales/new-quote.test.tsx","StartupsPlatform/app/erp/sales/page.test.tsx","StartupsPlatform/app/erp/sales/page.tsx","StartupsPlatform/app/erp/sales/pricing/page.tsx","StartupsPlatform/app/erp/sales/reports/page.tsx","StartupsPlatform/app/erp/sign-public/[token]/page.tsx","StartupsPlatform/app/erp/sign/layout.tsx","StartupsPlatform/app/erp/sign/page.tsx","StartupsPlatform/app/erp/skills/[id]/page.tsx","StartupsPlatform/app/erp/skills/analytics/page.tsx","StartupsPlatform/app/erp/skills/catalog/page.tsx","StartupsPlatform/app/erp/skills/insights/page.tsx","StartupsPlatform/app/erp/skills/layout.tsx","StartupsPlatform/app/erp/skills/matrix/page.tsx","StartupsPlatform/app/erp/skills/page.tsx","StartupsPlatform/app/erp/skills/reports/page.tsx","StartupsPlatform/app/erp/subscription/[id]/page.tsx","StartupsPlatform/app/erp/subscription/analytics/page.tsx","StartupsPlatform/app/erp/subscription/insights/page.tsx","StartupsPlatform/app/erp/subscription/layout.tsx","StartupsPlatform/app/erp/subscription/page.tsx","StartupsPlatform/app/erp/subscription/plans/page.tsx","StartupsPlatform/app/erp/subscription/reports/page.tsx","StartupsPlatform/app/erp/timeoff/[id]/page.tsx","StartupsPlatform/app/erp/timeoff/allocations/[id]/page.tsx","StartupsPlatform/app/erp/timeoff/allocations/page.tsx","StartupsPlatform/app/erp/timeoff/analytics/page.tsx","StartupsPlatform/app/erp/timeoff/calendar/page.tsx","StartupsPlatform/app/erp/timeoff/insights/page.tsx","StartupsPlatform/app/erp/timeoff/layout.tsx","StartupsPlatform/app/erp/timeoff/page.tsx","StartupsPlatform/app/erp/timeoff/reports/page.tsx","StartupsPlatform/app/erp/timeoff/types/page.tsx","StartupsPlatform/app/erp/timesheets/layout.tsx","StartupsPlatform/app/erp/timesheets/page.tsx","StartupsPlatform/app/erp/todos/[id]/page.tsx","StartupsPlatform/app/erp/todos/layout.tsx","StartupsPlatform/app/erp/todos/page.test.tsx","StartupsPlatform/app/erp/todos/page.tsx","StartupsPlatform/app/erp/website/[id]/page.tsx","StartupsPlatform/app/erp/website/analytics/page.tsx","StartupsPlatform/app/erp/website/layout.tsx","StartupsPlatform/app/erp/website/menus/page.tsx","StartupsPlatform/app/erp/website/page.tsx","StartupsPlatform/app/error.test.tsx","StartupsPlatform/app/error.tsx","StartupsPlatform/app/global-error.test.tsx","StartupsPlatform/app/global-error.tsx","StartupsPlatform/app/globals.css","StartupsPlatform/app/icon.tsx","StartupsPlatform/app/invite/[token]/page.tsx","StartupsPlatform/app/invite/page.tsx","StartupsPlatform/app/layout.tsx","StartupsPlatform/app/login/page.tsx","StartupsPlatform/app/oauth-callback/page.tsx","StartupsPlatform/app/onboarding/page.tsx","StartupsPlatform/app/page.tsx","StartupsPlatform/app/portal/[token]/page.test.tsx","StartupsPlatform/app/portal/[token]/page.tsx","StartupsPlatform/app/suites/layout.tsx","StartupsPlatform/app/suites/page.tsx"]},{"name":"StartupsPlatform — components","slug":"startupsplatform-components","files":["StartupsPlatform/components/agent-board/assistant-avatar.tsx","StartupsPlatform/components/agent-board/board-canvas.tsx","StartupsPlatform/components/agent-board/board-card.tsx","StartupsPlatform/components/agent-board/board-chat.tsx","StartupsPlatform/components/agent-board/board-palette.tsx","StartupsPlatform/components/agent-board/board-shell.tsx","StartupsPlatform/components/agent-board/fire-card.tsx","StartupsPlatform/components/agent-board/inbox-rail.tsx","StartupsPlatform/components/agent-board/inbox-row.tsx","StartupsPlatform/components/agent-board/note-card.tsx","StartupsPlatform/components/agent-board/notes-button.tsx","StartupsPlatform/components/agent-board/pin-card.tsx","StartupsPlatform/components/agent-board/pipeline-card.tsx","StartupsPlatform/components/agent-board/week-nav.ts","StartupsPlatform/components/apps/app-detail.tsx","StartupsPlatform/components/apps/app-list.tsx","StartupsPlatform/components/apps/durability-notice.tsx","StartupsPlatform/components/apps/reach-chip.tsx","StartupsPlatform/components/apps/version-history.tsx","StartupsPlatform/components/assistant/action-preview-card.tsx","StartupsPlatform/components/assistant/action-result-notice.test.tsx","StartupsPlatform/components/assistant/action-result-notice.tsx","StartupsPlatform/components/assistant/activity-log.tsx","StartupsPlatform/components/assistant/activity/agent-provenance.tsx","StartupsPlatform/components/assistant/assistant-avatar-picker.tsx","StartupsPlatform/components/assistant/assistants-table.tsx","StartupsPlatform/components/assistant/browser-session-card.tsx","StartupsPlatform/components/assistant/capability-suggestion-card.tsx","StartupsPlatform/components/assistant/clarification-card.tsx","StartupsPlatform/components/assistant/device-login-card.tsx","StartupsPlatform/components/assistant/document-blob.tsx","StartupsPlatform/components/assistant/flow-diagram.tsx","StartupsPlatform/components/assistant/governance-preview-card.tsx","StartupsPlatform/components/assistant/governance/governance-filters.tsx","StartupsPlatform/components/assistant/governance/governance-table-shell.tsx","StartupsPlatform/components/assistant/governance/governance-view-sheet.tsx","StartupsPlatform/components/assistant/governance/illustrative-flow.tsx","StartupsPlatform/components/assistant/governance/integrations-tab.tsx","StartupsPlatform/components/assistant/governance/policies-tab.tsx","StartupsPlatform/components/assistant/governance/procedures-tab.tsx","StartupsPlatform/components/assistant/governance/skills-tab.tsx","StartupsPlatform/components/assistant/index.ts","StartupsPlatform/components/assistant/lifecycle/activity-sheet.tsx","StartupsPlatform/components/assistant/lifecycle/config-panel.tsx","StartupsPlatform/components/assistant/lifecycle/drift-badge.tsx","StartupsPlatform/components/assistant/lifecycle/drift.ts","StartupsPlatform/components/assistant/lifecycle/lifecycle-avatar.tsx","StartupsPlatform/components/assistant/lifecycle/lifecycle-sheet.tsx","StartupsPlatform/components/assistant/lifecycle/presence-feed.ts","StartupsPlatform/components/assistant/lifecycle/presence.ts","StartupsPlatform/components/assistant/lifecycle/provenance.ts","StartupsPlatform/components/assistant/lifecycle/requirement-rows.tsx","StartupsPlatform/components/assistant/lifecycle/requirements.ts","StartupsPlatform/components/assistant/lifecycle/use-assistant-presence.ts","StartupsPlatform/components/assistant/lifecycle/use-assistant-setup.ts","StartupsPlatform/components/assistant/lifecycle/use-now.ts","StartupsPlatform/components/assistant/lifecycle/verb.ts","StartupsPlatform/components/assistant/lifecycle/working-presence.tsx","StartupsPlatform/components/assistant/personal-governance-sheet.tsx","StartupsPlatform/components/assistant/plan-card.tsx","StartupsPlatform/components/assistant/quality-footer.tsx","StartupsPlatform/components/assistant/sub-thread-box.tsx","StartupsPlatform/components/assistant/task-roadmap.tsx","StartupsPlatform/components/assistant/thinking-dropdown.tsx","StartupsPlatform/components/autoload/autoload-approval.tsx","StartupsPlatform/components/automations/automation-state.tsx","StartupsPlatform/components/automations/cadence-line.tsx","StartupsPlatform/components/automations/consent-panels.tsx","StartupsPlatform/components/automations/destination-picker.tsx","StartupsPlatform/components/automations/fire-log.tsx","StartupsPlatform/components/automations/schedule-row.tsx","StartupsPlatform/components/automations/watch-card.tsx","StartupsPlatform/components/automations/watch-list.tsx","StartupsPlatform/components/dashboard-shell.tsx","StartupsPlatform/components/dashboard/assistant-selector.tsx","StartupsPlatform/components/dashboard/building-card.tsx","StartupsPlatform/components/dashboard/dashboard-grid.tsx","StartupsPlatform/components/dashboard/four-blocks-loader.tsx","StartupsPlatform/components/dashboard/integration-health-banner.test.tsx","StartupsPlatform/components/dashboard/integration-health-banner.tsx","StartupsPlatform/components/dashboard/suggestion-tiles.tsx","StartupsPlatform/components/dashboard/widget-renderer.test.tsx","StartupsPlatform/components/dashboard/widget-renderer.tsx","StartupsPlatform/components/dashboard/widgets/breakdown-widget.tsx","StartupsPlatform/components/dashboard/widgets/list-widget.tsx","StartupsPlatform/components/dashboard/widgets/metric-widget.tsx","StartupsPlatform/components/dashboard/widgets/note-widget.tsx","StartupsPlatform/components/dashboard/widgets/progress-widget.tsx","StartupsPlatform/components/dashboard/widgets/trend-widget.tsx","StartupsPlatform/components/dashboard/widgets/utils.ts","StartupsPlatform/components/dashboard/widgets/widget-heading.tsx","StartupsPlatform/components/documents/create-folder-dialog.tsx","StartupsPlatform/components/documents/create-workspace-dialog.tsx","StartupsPlatform/components/documents/delete-document-dialog.tsx","StartupsPlatform/components/documents/document-actions.tsx","StartupsPlatform/components/documents/document-card.tsx","StartupsPlatform/components/documents/document-list-row.tsx","StartupsPlatform/components/documents/document-viewer.tsx","StartupsPlatform/components/documents/documents-folders.tsx","StartupsPlatform/components/documents/documents-stats.tsx","StartupsPlatform/components/documents/drive-acl-review.tsx","StartupsPlatform/components/documents/drive-folder-browser.tsx","StartupsPlatform/components/documents/drive-folder-viewer.tsx","StartupsPlatform/components/documents/edit-document-access-dialog.tsx","StartupsPlatform/components/documents/edit-folder-access-dialog.tsx","StartupsPlatform/components/documents/folder-scope-selector.tsx","StartupsPlatform/components/documents/hub-content.tsx","StartupsPlatform/components/documents/hub-controls.tsx","StartupsPlatform/components/documents/index.ts","StartupsPlatform/components/documents/item-card.tsx","StartupsPlatform/components/documents/item-detail-rail.tsx","StartupsPlatform/components/documents/sync-status-blob.tsx","StartupsPlatform/components/documents/sync-status-panel.tsx","StartupsPlatform/components/documents/types.ts","StartupsPlatform/components/documents/upload-document-dialog.tsx","StartupsPlatform/components/documents/upload-slots-view.tsx","StartupsPlatform/components/documents/use-document-preview.ts","StartupsPlatform/components/documents/utils.tsx","StartupsPlatform/components/documents/workspace-panel.tsx","StartupsPlatform/components/erp/action-approval-dialog.tsx","StartupsPlatform/components/erp/advancedaccounting/account-code-edit-collision.test.tsx","StartupsPlatform/components/erp/advancedaccounting/account-ledger.tsx","StartupsPlatform/components/erp/advancedaccounting/account-overview.tsx","StartupsPlatform/components/erp/advancedaccounting/advancedaccounting-rail.tsx","StartupsPlatform/components/erp/advancedaccounting/balance-sheet-report.tsx","StartupsPlatform/components/erp/advancedaccounting/budget-list.tsx","StartupsPlatform/components/erp/advancedaccounting/budget-overview.tsx","StartupsPlatform/components/erp/advancedaccounting/chart-integrity-notice.tsx","StartupsPlatform/components/erp/advancedaccounting/chart-of-accounts-table.tsx","StartupsPlatform/components/erp/advancedaccounting/create-sheet.tsx","StartupsPlatform/components/erp/advancedaccounting/dunning-list.tsx","StartupsPlatform/components/erp/advancedaccounting/dunning-overview.tsx","StartupsPlatform/components/erp/advancedaccounting/entry-balance.tsx","StartupsPlatform/components/erp/advancedaccounting/entry-overview.tsx","StartupsPlatform/components/erp/advancedaccounting/export-csv-button.tsx","StartupsPlatform/components/erp/advancedaccounting/journal-overview.tsx","StartupsPlatform/components/erp/advancedaccounting/posted-entry-locked.test.tsx","StartupsPlatform/components/erp/advancedaccounting/profit-and-loss-report.tsx","StartupsPlatform/components/erp/advancedaccounting/report-notices.tsx","StartupsPlatform/components/erp/advancedaccounting/reverse-entry-on-screen.test.tsx","StartupsPlatform/components/erp/advancedaccounting/reverse-entry.tsx","StartupsPlatform/components/erp/advancedaccounting/statement-export-copy.ts","StartupsPlatform/components/erp/advancedaccounting/statement-section.tsx","StartupsPlatform/components/erp/advancedaccounting/trial-balance-report.tsx","StartupsPlatform/components/erp/advancedaccounting/unplaced-accounts.tsx","StartupsPlatform/components/erp/applied-changes-tab.tsx","StartupsPlatform/components/erp/attendance/attendance-form.tsx","StartupsPlatform/components/erp/attendance/attendance-list.tsx","StartupsPlatform/components/erp/beneficiaries/family-file.tsx","StartupsPlatform/components/erp/beneficiaries/family-list.tsx","StartupsPlatform/components/erp/beneficiaries/family-tree.tsx","StartupsPlatform/components/erp/beneficiaries/issue-link-dialog.tsx","StartupsPlatform/components/erp/beneficiaries/loan-list.tsx","StartupsPlatform/components/erp/beneficiaries/not-installed.tsx","StartupsPlatform/components/erp/contacts/bank-accounts.tsx","StartupsPlatform/components/erp/contacts/company-picker.tsx","StartupsPlatform/components/erp/contacts/compliance-rows.tsx","StartupsPlatform/components/erp/contacts/confirm-delete-dialog.tsx","StartupsPlatform/components/erp/contacts/contact-cards.tsx","StartupsPlatform/components/erp/contacts/contact-documents.test.tsx","StartupsPlatform/components/erp/contacts/contact-documents.tsx","StartupsPlatform/components/erp/contacts/contact-history.test.tsx","StartupsPlatform/components/erp/contacts/contact-history.tsx","StartupsPlatform/components/erp/contacts/contact-overview.test.tsx","StartupsPlatform/components/erp/contacts/contact-overview.tsx","StartupsPlatform/components/erp/contacts/contact-relationships.tsx","StartupsPlatform/components/erp/contacts/contact-trn-and-people.test.tsx","StartupsPlatform/components/erp/contacts/contacts-empty.tsx","StartupsPlatform/components/erp/contacts/contacts-list.tsx","StartupsPlatform/components/erp/contacts/contacts-rail.tsx","StartupsPlatform/components/erp/contacts/link-contacts-dialog.tsx","StartupsPlatform/components/erp/contacts/partner-form.tsx","StartupsPlatform/components/erp/contacts/tag-control.test.tsx","StartupsPlatform/components/erp/crm/config-list.tsx","StartupsPlatform/components/erp/crm/crm-rail.tsx","StartupsPlatform/components/erp/crm/customer-create-parity.test.tsx","StartupsPlatform/components/erp/crm/customer-picker.tsx","StartupsPlatform/components/erp/crm/failure-not-absence.test.tsx","StartupsPlatform/components/erp/crm/lead-card.tsx","StartupsPlatform/components/erp/crm/lead-panel.tsx","StartupsPlatform/components/erp/crm/leads-list.tsx","StartupsPlatform/components/erp/crm/lost-outcome-dialog.test.tsx","StartupsPlatform/components/erp/crm/lost-outcome-dialog.tsx","StartupsPlatform/components/erp/crm/lost-route-parity.test.tsx","StartupsPlatform/components/erp/crm/many2many-tags.tsx","StartupsPlatform/components/erp/crm/opportunity-form.test.tsx","StartupsPlatform/components/erp/crm/opportunity-form.tsx","StartupsPlatform/components/erp/crm/opportunity-outcome-dialog.test.tsx","StartupsPlatform/components/erp/crm/opportunity-outcome-dialog.tsx","StartupsPlatform/components/erp/crm/opportunity-overview.test.tsx","StartupsPlatform/components/erp/crm/opportunity-overview.tsx","StartupsPlatform/components/erp/crm/phase-workspace.tsx","StartupsPlatform/components/erp/crm/pipeline-board-edges.test.tsx","StartupsPlatform/components/erp/crm/pipeline-board.test.tsx","StartupsPlatform/components/erp/crm/pipeline-board.tsx","StartupsPlatform/components/erp/crm/pipeline-filters.test.tsx","StartupsPlatform/components/erp/crm/pipeline-filters.tsx","StartupsPlatform/components/erp/crm/prospect-history-module.tsx","StartupsPlatform/components/erp/custom-fields-section.tsx","StartupsPlatform/components/erp/custom-property-rows.tsx","StartupsPlatform/components/erp/customization-form.test.tsx","StartupsPlatform/components/erp/customization-form.tsx","StartupsPlatform/components/erp/customization/col-header.tsx","StartupsPlatform/components/erp/customization/editable.tsx","StartupsPlatform/components/erp/datacycle/recycle-model-form.tsx","StartupsPlatform/components/erp/datacycle/recycle-model-list.tsx","StartupsPlatform/components/erp/emailmarketing/campaign-form.tsx","StartupsPlatform/components/erp/emailmarketing/campaign-list.tsx","StartupsPlatform/components/erp/erp/action-runner.tsx","StartupsPlatform/components/erp/erp/chatter.test.tsx","StartupsPlatform/components/erp/erp/chatter.tsx","StartupsPlatform/components/erp/erp/creatable-m2o-input.tsx","StartupsPlatform/components/erp/erp/field-cell.tsx","StartupsPlatform/components/erp/erp/field-input.tsx","StartupsPlatform/components/erp/erp/form-view.test.tsx","StartupsPlatform/components/erp/erp/form-view.tsx","StartupsPlatform/components/erp/erp/kanban-view.tsx","StartupsPlatform/components/erp/erp/list-view.tsx","StartupsPlatform/components/erp/erp/many2one-input.tsx","StartupsPlatform/components/erp/erp/model-page.tsx","StartupsPlatform/components/erp/erp/report-menu.test.tsx","StartupsPlatform/components/erp/erp/report-menu.tsx","StartupsPlatform/components/erp/erp/rich-text-editor.tsx","StartupsPlatform/components/erp/expenses/expense-form.tsx","StartupsPlatform/components/erp/expenses/expense-list.tsx","StartupsPlatform/components/erp/expenses/expense-record-router.tsx","StartupsPlatform/components/erp/expenses/expense-sheet-form.test.tsx","StartupsPlatform/components/erp/expenses/expense-sheet-form.tsx","StartupsPlatform/components/erp/expenses/expense-sheet-list.tsx","StartupsPlatform/components/erp/expenses/expenses-odoo-list.tsx","StartupsPlatform/components/erp/finance/aging-view.test.tsx","StartupsPlatform/components/erp/finance/aging-view.tsx","StartupsPlatform/components/erp/finance/amount-due.test.tsx","StartupsPlatform/components/erp/finance/counterparty-cell.ar.test.tsx","StartupsPlatform/components/erp/finance/counterparty-cell.test.tsx","StartupsPlatform/components/erp/finance/counterparty-cell.tsx","StartupsPlatform/components/erp/finance/counterparty-repair.test.tsx","StartupsPlatform/components/erp/finance/counterparty-repair.tsx","StartupsPlatform/components/erp/finance/csv-export-button.tsx","StartupsPlatform/components/erp/finance/customer-statement.test.tsx","StartupsPlatform/components/erp/finance/customer-statement.tsx","StartupsPlatform/components/erp/finance/dispatch-history.tsx","StartupsPlatform/components/erp/finance/invoice-create-discount.test.tsx","StartupsPlatform/components/erp/finance/invoice-create-form.tsx","StartupsPlatform/components/erp/finance/invoice-credit-note.ar.test.tsx","StartupsPlatform/components/erp/finance/invoice-credit-note.test.tsx","StartupsPlatform/components/erp/finance/invoice-credit-state.test.tsx","StartupsPlatform/components/erp/finance/invoice-files-tab.ar.test.tsx","StartupsPlatform/components/erp/finance/invoice-files-tab.test.tsx","StartupsPlatform/components/erp/finance/invoice-line-discount.test.tsx","StartupsPlatform/components/erp/finance/invoice-number-ledger.test.tsx","StartupsPlatform/components/erp/finance/invoice-number-readback.test.tsx","StartupsPlatform/components/erp/finance/invoice-number-render.test.tsx","StartupsPlatform/components/erp/finance/invoice-overview-tax-invoice.test.tsx","StartupsPlatform/components/erp/finance/invoice-overview-unresolved-tax.test.tsx","StartupsPlatform/components/erp/finance/invoice-overview.tsx","StartupsPlatform/components/erp/finance/invoice-retention-block.test.tsx","StartupsPlatform/components/erp/finance/invoice-retention-block.tsx","StartupsPlatform/components/erp/finance/invoice-retention.ar.test.tsx","StartupsPlatform/components/erp/finance/invoice-retention.test.tsx","StartupsPlatform/components/erp/finance/invoice-tax-render.test.tsx","StartupsPlatform/components/erp/finance/paid-badge.test.tsx","StartupsPlatform/components/erp/finance/payables-ledger.tsx","StartupsPlatform/components/erp/finance/receivables-ledger.tsx","StartupsPlatform/components/erp/finance/tax-invoice-document.test.tsx","StartupsPlatform/components/erp/finance/tax-invoice-document.tsx","StartupsPlatform/components/erp/finance/trn-value.tsx","StartupsPlatform/components/erp/finance/vat-return-exclusions.tsx","StartupsPlatform/components/erp/finance/vat-return-kernel-view.test.tsx","StartupsPlatform/components/erp/finance/vat-return-kernel-view.tsx","StartupsPlatform/components/erp/finance/vat-return-odoo-view.tsx","StartupsPlatform/components/erp/finance/vat-return-view.test.tsx","StartupsPlatform/components/erp/finance/vat-return-view.tsx","StartupsPlatform/components/erp/finance/vat-tax-classifier.tsx","StartupsPlatform/components/erp/helpdesk/merge-dialog.tsx","StartupsPlatform/components/erp/helpdesk/sla-record-state.tsx","StartupsPlatform/components/erp/helpdesk/ticket-board.test.tsx","StartupsPlatform/components/erp/helpdesk/ticket-board.tsx","StartupsPlatform/components/erp/helpdesk/ticket-list.tsx","StartupsPlatform/components/erp/helpdesk/ticket-overview.test.tsx","StartupsPlatform/components/erp/helpdesk/ticket-overview.tsx","StartupsPlatform/components/erp/helpdesk/ticket-project-link.test.tsx","StartupsPlatform/components/erp/hr/access-panel.tsx","StartupsPlatform/components/erp/hr/appraisal-card.tsx","StartupsPlatform/components/erp/hr/appraisal-overview.tsx","StartupsPlatform/components/erp/hr/appraisal-section.tsx","StartupsPlatform/components/erp/hr/bulk-add-dialog.tsx","StartupsPlatform/components/erp/hr/contract-form.test.tsx","StartupsPlatform/components/erp/hr/contract-form.tsx","StartupsPlatform/components/erp/hr/contract-list.tsx","StartupsPlatform/components/erp/hr/department-list.tsx","StartupsPlatform/components/erp/hr/departments-manager.tsx","StartupsPlatform/components/erp/hr/departments-panel.tsx","StartupsPlatform/components/erp/hr/employee-cards.tsx","StartupsPlatform/components/erp/hr/employee-form.test.tsx","StartupsPlatform/components/erp/hr/employee-form.tsx","StartupsPlatform/components/erp/hr/employee-list.tsx","StartupsPlatform/components/erp/hr/employee-payroll-panel.tsx","StartupsPlatform/components/erp/hr/employee-personal-panel.tsx","StartupsPlatform/components/erp/hr/employee-statutory-panel.tsx","StartupsPlatform/components/erp/hr/employees-not-found.tsx","StartupsPlatform/components/erp/hr/org-change-drawer.tsx","StartupsPlatform/components/erp/hr/orgchart-panel.tsx","StartupsPlatform/components/erp/hr/orgchart-tree.tsx","StartupsPlatform/components/erp/hr/people-sections-cards.tsx","StartupsPlatform/components/erp/hr/person-overview.test.tsx","StartupsPlatform/components/erp/hr/person-overview.tsx","StartupsPlatform/components/erp/hr/person-workspaces.tsx","StartupsPlatform/components/erp/hr/termination-dialog.tsx","StartupsPlatform/components/erp/inventory/counts-panel.tsx","StartupsPlatform/components/erp/inventory/inventory-count.tsx","StartupsPlatform/components/erp/inventory/inventory-rail.tsx","StartupsPlatform/components/erp/inventory/landed-cost-form.tsx","StartupsPlatform/components/erp/inventory/masters-manager.tsx","StartupsPlatform/components/erp/inventory/move-lines-editor.tsx","StartupsPlatform/components/erp/inventory/operations-panel.tsx","StartupsPlatform/components/erp/inventory/picking-board.tsx","StartupsPlatform/components/erp/inventory/picking-form.tsx","StartupsPlatform/components/erp/inventory/picking-list.tsx","StartupsPlatform/components/erp/inventory/reorder-rules.tsx","StartupsPlatform/components/erp/inventory/replenishment-panel.tsx","StartupsPlatform/components/erp/inventory/scrap-dialog.tsx","StartupsPlatform/components/erp/livechat/channel-form.tsx","StartupsPlatform/components/erp/livechat/channel-list.tsx","StartupsPlatform/components/erp/livechat/session-list.tsx","StartupsPlatform/components/erp/maintenance/contract-form.tsx","StartupsPlatform/components/erp/maintenance/equipment-form.tsx","StartupsPlatform/components/erp/maintenance/equipment-list.tsx","StartupsPlatform/components/erp/maintenance/request-form.tsx","StartupsPlatform/components/erp/maintenance/request-list.tsx","StartupsPlatform/components/erp/manufacturing/bom-form.tsx","StartupsPlatform/components/erp/manufacturing/bom-list.tsx","StartupsPlatform/components/erp/manufacturing/bom-panel.tsx","StartupsPlatform/components/erp/manufacturing/operations-panel.tsx","StartupsPlatform/components/erp/manufacturing/production-form.tsx","StartupsPlatform/components/erp/manufacturing/production-plan-form.tsx","StartupsPlatform/components/erp/manufacturing/productions-list.tsx","StartupsPlatform/components/erp/manufacturing/routing-panel.tsx","StartupsPlatform/components/erp/manufacturing/workcenters-panel.tsx","StartupsPlatform/components/erp/manufacturing/workorder-form.tsx","StartupsPlatform/components/erp/manufacturing/workorder-list.tsx","StartupsPlatform/components/erp/manufacturing/workorder-panel.tsx","StartupsPlatform/components/erp/marketing/campaign-builder.tsx","StartupsPlatform/components/erp/marketingcard/campaign-form.tsx","StartupsPlatform/components/erp/marketingcard/campaign-list.tsx","StartupsPlatform/components/erp/marketingcard/card-list.tsx","StartupsPlatform/components/erp/ngofinance/engine-off.tsx","StartupsPlatform/components/erp/ngofinance/entry-link.tsx","StartupsPlatform/components/erp/ngofinance/fund-editor.tsx","StartupsPlatform/components/erp/ngofinance/fund-list.tsx","StartupsPlatform/components/erp/ngofinance/membership-preview.tsx","StartupsPlatform/components/erp/ngofinance/rule-file.tsx","StartupsPlatform/components/erp/ngofinance/rule-list.tsx","StartupsPlatform/components/erp/ngofinance/run-list.tsx","StartupsPlatform/components/erp/ngofinance/split-preview.test.tsx","StartupsPlatform/components/erp/ngofinance/split-preview.tsx","StartupsPlatform/components/erp/pages/authored-screens-rail.tsx","StartupsPlatform/components/erp/pages/guided-flow-launcher.tsx","StartupsPlatform/components/erp/pages/guided-flow-runner.tsx","StartupsPlatform/components/erp/pages/page-document-form.tsx","StartupsPlatform/components/erp/pages/page-document-list.tsx","StartupsPlatform/components/erp/pages/page-document-surface.tsx","StartupsPlatform/components/erp/payroll/contract-list.tsx","StartupsPlatform/components/erp/payroll/contract-record.tsx","StartupsPlatform/components/erp/payroll/payroll-rail-extras.tsx","StartupsPlatform/components/erp/payroll/payslip-form.tsx","StartupsPlatform/components/erp/payroll/payslip-list.tsx","StartupsPlatform/components/erp/payroll/rules-panel.tsx","StartupsPlatform/components/erp/payroll/salary-lines-editor.tsx","StartupsPlatform/components/erp/payroll/salary-rule-list.tsx","StartupsPlatform/components/erp/payroll/structure-list.tsx","StartupsPlatform/components/erp/payroll/structures-panel.tsx","StartupsPlatform/components/erp/pin-apps-dialog.tsx","StartupsPlatform/components/erp/pos/order-form.tsx","StartupsPlatform/components/erp/pos/order-lines.tsx","StartupsPlatform/components/erp/pos/order-list.tsx","StartupsPlatform/components/erp/pos/session-form.tsx","StartupsPlatform/components/erp/pos/session-list.tsx","StartupsPlatform/components/erp/project/activity-types.tsx","StartupsPlatform/components/erp/project/hub-tasks.tsx","StartupsPlatform/components/erp/project/hub-timeline.test.tsx","StartupsPlatform/components/erp/project/hub-timeline.tsx","StartupsPlatform/components/erp/project/new-record-draft.test.tsx","StartupsPlatform/components/erp/project/new-record-draft.tsx","StartupsPlatform/components/erp/project/portfolio-panel.tsx","StartupsPlatform/components/erp/project/project-board.test.tsx","StartupsPlatform/components/erp/project/project-board.tsx","StartupsPlatform/components/erp/project/project-checklist.tsx","StartupsPlatform/components/erp/project/project-commercials.test.tsx","StartupsPlatform/components/erp/project/project-commercials.tsx","StartupsPlatform/components/erp/project/project-diary.test.tsx","StartupsPlatform/components/erp/project/project-diary.tsx","StartupsPlatform/components/erp/project/project-export.tsx","StartupsPlatform/components/erp/project/project-form.test.tsx","StartupsPlatform/components/erp/project/project-form.tsx","StartupsPlatform/components/erp/project/project-health.tsx","StartupsPlatform/components/erp/project/project-milestones.tsx","StartupsPlatform/components/erp/project/project-overview.tsx","StartupsPlatform/components/erp/project/project-packages.test.tsx","StartupsPlatform/components/erp/project/project-packages.tsx","StartupsPlatform/components/erp/project/project-rail.tsx","StartupsPlatform/components/erp/project/project-side-panel.tsx","StartupsPlatform/components/erp/project/project-snags.test.tsx","StartupsPlatform/components/erp/project/project-snags.tsx","StartupsPlatform/components/erp/project/project-submittals.test.tsx","StartupsPlatform/components/erp/project/project-submittals.tsx","StartupsPlatform/components/erp/project/project-valuations.test.tsx","StartupsPlatform/components/erp/project/project-valuations.tsx","StartupsPlatform/components/erp/project/stage-columns.tsx","StartupsPlatform/components/erp/project/task-form.test.tsx","StartupsPlatform/components/erp/project/task-form.tsx","StartupsPlatform/components/erp/project/task-list.test.tsx","StartupsPlatform/components/erp/project/task-list.tsx","StartupsPlatform/components/erp/project/task-overview.tsx","StartupsPlatform/components/erp/project/task-timesheets.tsx","StartupsPlatform/components/erp/project/templates-panel.test.tsx","StartupsPlatform/components/erp/project/templates-panel.tsx","StartupsPlatform/components/erp/purchase/approval-policy-card.tsx","StartupsPlatform/components/erp/purchase/bill-overview.tsx","StartupsPlatform/components/erp/purchase/order-approval-notice.test.tsx","StartupsPlatform/components/erp/purchase/order-approval-notice.tsx","StartupsPlatform/components/erp/purchase/order-approval-overview.test.tsx","StartupsPlatform/components/erp/purchase/order-bills.tsx","StartupsPlatform/components/erp/purchase/order-commitment.test.tsx","StartupsPlatform/components/erp/purchase/order-commitment.tsx","StartupsPlatform/components/erp/purchase/order-lineage.test.tsx","StartupsPlatform/components/erp/purchase/order-lineage.tsx","StartupsPlatform/components/erp/purchase/order-lines-allocation.test.tsx","StartupsPlatform/components/erp/purchase/order-lines-discount.test.tsx","StartupsPlatform/components/erp/purchase/order-lines.tsx","StartupsPlatform/components/erp/purchase/order-overview.tsx","StartupsPlatform/components/erp/purchase/order-receipts.tsx","StartupsPlatform/components/erp/purchase/order-send-reason.test.tsx","StartupsPlatform/components/erp/purchase/order-send-section.tsx","StartupsPlatform/components/erp/purchase/orders-list.tsx","StartupsPlatform/components/erp/purchase/orders-panel.tsx","StartupsPlatform/components/erp/purchase/purchase-rail.tsx","StartupsPlatform/components/erp/purchase/purchase-receipts.test.tsx","StartupsPlatform/components/erp/purchase/purchase-requisitions.test.tsx","StartupsPlatform/components/erp/purchase/receipt-overview.tsx","StartupsPlatform/components/erp/purchase/requisition-create-form.tsx","StartupsPlatform/components/erp/purchase/requisition-overview.tsx","StartupsPlatform/components/erp/purchase/requisitions-panel.tsx","StartupsPlatform/components/erp/purchase/rfq-comparison.intl.test.tsx","StartupsPlatform/components/erp/purchase/rfq-create-form.tsx","StartupsPlatform/components/erp/purchase/vendor-rate-hint.test.tsx","StartupsPlatform/components/erp/purchase/vendor-rate-hint.tsx","StartupsPlatform/components/erp/quality/inspection-form.tsx","StartupsPlatform/components/erp/recruitment/applicant-board.tsx","StartupsPlatform/components/erp/recruitment/applicant-form.tsx","StartupsPlatform/components/erp/recruitment/applicant-list.tsx","StartupsPlatform/components/erp/repairs/repair-form.tsx","StartupsPlatform/components/erp/repairs/repairs-list.tsx","StartupsPlatform/components/erp/repairs/warranty-form.tsx","StartupsPlatform/components/erp/sales/bundle-form.test.tsx","StartupsPlatform/components/erp/sales/bundle-form.tsx","StartupsPlatform/components/erp/sales/bundles-panel.tsx","StartupsPlatform/components/erp/sales/catalog-denied-vs-empty.test.tsx","StartupsPlatform/components/erp/sales/catalog-masters-manager.tsx","StartupsPlatform/components/erp/sales/order-board.tsx","StartupsPlatform/components/erp/sales/order-form-advance.test.tsx","StartupsPlatform/components/erp/sales/order-form-tax.test.tsx","StartupsPlatform/components/erp/sales/order-form.tsx","StartupsPlatform/components/erp/sales/order-overview.test.tsx","StartupsPlatform/components/erp/sales/order-overview.tsx","StartupsPlatform/components/erp/sales/orders-cards.tsx","StartupsPlatform/components/erp/sales/orders-ledger.tsx","StartupsPlatform/components/erp/sales/orders-list.tsx","StartupsPlatform/components/erp/sales/pricing-panel.test.tsx","StartupsPlatform/components/erp/sales/pricing-panel.tsx","StartupsPlatform/components/erp/shared/audit-entry.tsx","StartupsPlatform/components/erp/shared/commercial-lineage-strip.test.tsx","StartupsPlatform/components/erp/shared/commercial-lineage-strip.tsx","StartupsPlatform/components/erp/shared/confirm-dialog.intl.test.tsx","StartupsPlatform/components/erp/shared/confirm-dialog.test.tsx","StartupsPlatform/components/erp/shared/confirm-dialog.tsx","StartupsPlatform/components/erp/shared/currency-notice.tsx","StartupsPlatform/components/erp/shared/line-editor-discount.test.tsx","StartupsPlatform/components/erp/shared/line-editor.test.ts","StartupsPlatform/components/erp/shared/line-editor.tsx","StartupsPlatform/components/erp/shared/list/entity-row.test.tsx","StartupsPlatform/components/erp/shared/list/entity-row.tsx","StartupsPlatform/components/erp/shared/list/index.ts","StartupsPlatform/components/erp/shared/list/list-surface.test.tsx","StartupsPlatform/components/erp/shared/list/list-surface.tsx","StartupsPlatform/components/erp/shared/list/row-actions-view.tsx","StartupsPlatform/components/erp/shared/list/row-actions.test.ts","StartupsPlatform/components/erp/shared/list/row-actions.ts","StartupsPlatform/components/erp/shared/list/sticky-order.test.ts","StartupsPlatform/components/erp/shared/list/sticky-order.ts","StartupsPlatform/components/erp/shared/list/tombstone.test.tsx","StartupsPlatform/components/erp/shared/list/tombstone.tsx","StartupsPlatform/components/erp/shared/list/view-state.test.ts","StartupsPlatform/components/erp/shared/list/view-state.ts","StartupsPlatform/components/erp/shared/load-state.test.ts","StartupsPlatform/components/erp/shared/load-state.tsx","StartupsPlatform/components/erp/shared/ownership-control.tsx","StartupsPlatform/components/erp/shared/product-picker.tsx","StartupsPlatform/components/erp/shared/record-files-panel.test.tsx","StartupsPlatform/components/erp/shared/record-files-panel.tsx","StartupsPlatform/components/erp/shared/record-room-tab.test.tsx","StartupsPlatform/components/erp/shared/record-room-tab.tsx","StartupsPlatform/components/erp/shared/record-side-panel.test.tsx","StartupsPlatform/components/erp/shared/record-side-panel.tsx","StartupsPlatform/components/erp/shared/retired-surface.tsx","StartupsPlatform/components/erp/shell/app-frame.tsx","StartupsPlatform/components/erp/shell/app-rail.test.ts","StartupsPlatform/components/erp/shell/app-rail.tsx","StartupsPlatform/components/erp/shell/keep-alive-host.test.tsx","StartupsPlatform/components/erp/shell/keep-alive-host.tsx","StartupsPlatform/components/erp/shell/workspace.tsx","StartupsPlatform/components/erp/sign/document-surface.tsx","StartupsPlatform/components/erp/sign/request-builder.tsx","StartupsPlatform/components/erp/sign/signature-pad.tsx","StartupsPlatform/components/erp/skills/employee-skill-form.tsx","StartupsPlatform/components/erp/skills/employee-skill-list.tsx","StartupsPlatform/components/erp/skills/skills-catalog.tsx","StartupsPlatform/components/erp/subscription/subscription-board.tsx","StartupsPlatform/components/erp/subscription/subscription-form.tsx","StartupsPlatform/components/erp/subscription/subscription-list.tsx","StartupsPlatform/components/erp/timeoff/allocation-form.tsx","StartupsPlatform/components/erp/timeoff/allocation-list.tsx","StartupsPlatform/components/erp/timeoff/allocations-panel.tsx","StartupsPlatform/components/erp/timeoff/leave-form.tsx","StartupsPlatform/components/erp/timeoff/leave-list.tsx","StartupsPlatform/components/erp/timeoff/leave-type-list.tsx","StartupsPlatform/components/erp/timeoff/leave-types-panel.tsx","StartupsPlatform/components/erp/timesheets/analytic-accounts-panel.tsx","StartupsPlatform/components/erp/todos/todo-form.test.tsx","StartupsPlatform/components/erp/todos/todo-form.tsx","StartupsPlatform/components/erp/todos/todos-list.test.tsx","StartupsPlatform/components/erp/todos/todos-list.tsx","StartupsPlatform/components/erp/ui/avatar.test.tsx","StartupsPlatform/components/erp/ui/avatar.tsx","StartupsPlatform/components/erp/ui/board-scroller.tsx","StartupsPlatform/components/erp/ui/charts.tsx","StartupsPlatform/components/erp/ui/checkbox.test.tsx","StartupsPlatform/components/erp/ui/checkbox.tsx","StartupsPlatform/components/erp/ui/data-table.test.tsx","StartupsPlatform/components/erp/ui/data-table.tsx","StartupsPlatform/components/erp/ui/date-field.test.tsx","StartupsPlatform/components/erp/ui/date-field.tsx","StartupsPlatform/components/erp/ui/empty-state.tsx","StartupsPlatform/components/erp/ui/entity-combobox.test.tsx","StartupsPlatform/components/erp/ui/entity-combobox.tsx","StartupsPlatform/components/erp/ui/group-label.tsx","StartupsPlatform/components/erp/ui/module-shell.test.tsx","StartupsPlatform/components/erp/ui/module-shell.tsx","StartupsPlatform/components/erp/ui/overlay-stack.test.tsx","StartupsPlatform/components/erp/ui/overlay-stack.tsx","StartupsPlatform/components/erp/ui/overlay-z-order.test.tsx","StartupsPlatform/components/erp/ui/page-header.tsx","StartupsPlatform/components/erp/ui/panel.tsx","StartupsPlatform/components/erp/ui/pill.tsx","StartupsPlatform/components/erp/ui/rich-text.test.tsx","StartupsPlatform/components/erp/ui/rich-text.tsx","StartupsPlatform/components/erp/ui/section-add-button.tsx","StartupsPlatform/components/erp/ui/segmented-view.tsx","StartupsPlatform/components/erp/ui/select.tsx","StartupsPlatform/components/erp/ui/skeleton.tsx","StartupsPlatform/components/erp/ui/sort-header.tsx","StartupsPlatform/components/erp/ui/stat-card.tsx","StartupsPlatform/components/erp/ui/status-steps.tsx","StartupsPlatform/components/erp/ui/table-shell.tsx","StartupsPlatform/components/erp/ui/toolbar.tsx","StartupsPlatform/components/erp/ui/use-anchored.ts","StartupsPlatform/components/erp/website/page-form.tsx","StartupsPlatform/components/erp/website/page-list.tsx","StartupsPlatform/components/feature-guard.tsx","StartupsPlatform/components/icons/harakat-mark.tsx","StartupsPlatform/components/integrations/connect-sources-dialog.test.tsx","StartupsPlatform/components/integrations/connect-sources-dialog.tsx","StartupsPlatform/components/locale-toggle.tsx","StartupsPlatform/components/mail/mailbox-view.tsx","StartupsPlatform/components/onboarding/draft-chat.tsx","StartupsPlatform/components/onboarding/procedure-flow-editor.tsx","StartupsPlatform/components/onboarding/step-router.tsx","StartupsPlatform/components/onboarding/steps/apps.tsx","StartupsPlatform/components/onboarding/steps/basics.tsx","StartupsPlatform/components/onboarding/steps/defaults.tsx","StartupsPlatform/components/onboarding/steps/departments.tsx","StartupsPlatform/components/onboarding/steps/feed.tsx","StartupsPlatform/components/onboarding/steps/first-assistant.tsx","StartupsPlatform/components/onboarding/steps/governance.tsx","StartupsPlatform/components/onboarding/steps/people.tsx","StartupsPlatform/components/onboarding/steps/policies.tsx","StartupsPlatform/components/onboarding/steps/procedures.tsx","StartupsPlatform/components/onboarding/steps/sandbox.tsx","StartupsPlatform/components/onboarding/steps/skills.tsx","StartupsPlatform/components/onboarding/steps/tools-and-data.tsx","StartupsPlatform/components/onboarding/steps/working-norms.tsx","StartupsPlatform/components/onboarding/wizard-context.tsx","StartupsPlatform/components/onboarding/wizard-shell.tsx","StartupsPlatform/components/procedures/editor/auto-layout.ts","StartupsPlatform/components/procedures/editor/controlled-canvas.tsx","StartupsPlatform/components/procedures/editor/flow-conversion.ts","StartupsPlatform/components/procedures/editor/nodes/decision-node.tsx","StartupsPlatform/components/procedures/editor/nodes/index.ts","StartupsPlatform/components/procedures/editor/nodes/join-node.tsx","StartupsPlatform/components/procedures/editor/nodes/kind-theme.ts","StartupsPlatform/components/procedures/editor/nodes/node-badges.tsx","StartupsPlatform/components/procedures/editor/nodes/node-context.ts","StartupsPlatform/components/procedures/editor/nodes/parallel-node.tsx","StartupsPlatform/components/procedures/editor/nodes/standard-node.tsx","StartupsPlatform/components/procedures/editor/palette.tsx","StartupsPlatform/components/procedures/editor/panels/index.tsx","StartupsPlatform/components/procedures/editor/panels/join-panel.tsx","StartupsPlatform/components/procedures/editor/panels/parallel-panel.tsx","StartupsPlatform/components/procedures/editor/panels/property-panel.tsx","StartupsPlatform/components/procedures/editor/procedure-flow-editor.tsx","StartupsPlatform/components/procedures/editor/step-build.ts","StartupsPlatform/components/procedures/editor/tool-labels.ts","StartupsPlatform/components/procedures/procedure-flow-editor-v2.tsx","StartupsPlatform/components/rooms/room-composer.tsx","StartupsPlatform/components/rooms/room-decisions.tsx","StartupsPlatform/components/rooms/room-groups.ts","StartupsPlatform/components/rooms/room-message.tsx","StartupsPlatform/components/rooms/room-roster.tsx","StartupsPlatform/components/rooms/room-state.tsx","StartupsPlatform/components/rooms/start-project-room-dialog.tsx","StartupsPlatform/components/rtl-direction-provider.tsx","StartupsPlatform/components/search/document-peek.tsx","StartupsPlatform/components/search/identifier.tsx","StartupsPlatform/components/search/result-location.tsx","StartupsPlatform/components/settings/alerts-panel.tsx","StartupsPlatform/components/settings/connect-source-picker.tsx","StartupsPlatform/components/settings/data-privacy-panel.tsx","StartupsPlatform/components/settings/delete-company-dialog.tsx","StartupsPlatform/components/settings/email-panel.tsx","StartupsPlatform/components/settings/form/access-check.tsx","StartupsPlatform/components/settings/form/auto-derive.ts","StartupsPlatform/components/settings/form/constraint.ts","StartupsPlatform/components/settings/form/field-probe.tsx","StartupsPlatform/components/settings/form/gate.ts","StartupsPlatform/components/settings/form/identity-disclosure.tsx","StartupsPlatform/components/settings/form/index.ts","StartupsPlatform/components/settings/form/recovery-confirmation.tsx","StartupsPlatform/components/settings/form/required-disclosure.tsx","StartupsPlatform/components/settings/form/roles-disagree.tsx","StartupsPlatform/components/settings/form/save-result.tsx","StartupsPlatform/components/settings/form/setting-row.tsx","StartupsPlatform/components/settings/form/settings-form.tsx","StartupsPlatform/components/settings/form/unavailable-control.tsx","StartupsPlatform/components/settings/form/use-dirty-close.ts","StartupsPlatform/components/settings/mail-domain-panel.tsx","StartupsPlatform/components/settings/profile-panel.tsx","StartupsPlatform/components/settings/security-panel.tsx","StartupsPlatform/components/settings/security/action-policy-panel.tsx","StartupsPlatform/components/settings/security/agent-actions-panel.tsx","StartupsPlatform/components/settings/security/capabilities-panel.tsx","StartupsPlatform/components/settings/security/delegation-panel.tsx","StartupsPlatform/components/settings/security/passkeys-section.tsx","StartupsPlatform/components/settings/security/password-section.tsx","StartupsPlatform/components/settings/security/peer-asks-panel.tsx","StartupsPlatform/components/settings/security/peer-asks-section.tsx","StartupsPlatform/components/settings/security/security-extras.tsx","StartupsPlatform/components/settings/security/sessions-section.tsx","StartupsPlatform/components/settings/security/twofa-section.tsx","StartupsPlatform/components/settings/settings-tabs.ts","StartupsPlatform/components/settings/sources-panel.tsx","StartupsPlatform/components/settings/workspace-owner-access.tsx","StartupsPlatform/components/shared/load-state.tsx","StartupsPlatform/components/shell/assistant/chat-activity-dock.tsx","StartupsPlatform/components/shell/assistant/chat-composer.tsx","StartupsPlatform/components/shell/assistant/chat-dock.tsx","StartupsPlatform/components/shell/assistant/chat-find-bar.tsx","StartupsPlatform/components/shell/assistant/chat-messages.test.tsx","StartupsPlatform/components/shell/assistant/chat-messages.tsx","StartupsPlatform/components/shell/assistant/collapsed-line.tsx","StartupsPlatform/components/shell/assistant/connector-card.test.tsx","StartupsPlatform/components/shell/assistant/connector-card.tsx","StartupsPlatform/components/shell/assistant/conversation-history.tsx","StartupsPlatform/components/shell/assistant/hold-to-talk-mic.tsx","StartupsPlatform/components/shell/assistant/message-row-actions.tsx","StartupsPlatform/components/shell/assistant/remembered-conversation.ts","StartupsPlatform/components/shell/assistant/use-assistant-chat.ts","StartupsPlatform/components/shell/assistant/use-measured-height.ts","StartupsPlatform/components/shell/assistant/voice-bubble.tsx","StartupsPlatform/components/shell/category-tabs.tsx","StartupsPlatform/components/shell/data-table/resizable-table.tsx","StartupsPlatform/components/shell/data-table/table-toolbar.tsx","StartupsPlatform/components/shell/data-table/use-table-prefs.ts","StartupsPlatform/components/shell/page-header.tsx","StartupsPlatform/components/shell/side-rail/pinned-apps-block.tsx","StartupsPlatform/components/shell/side-rail/rail-item.tsx","StartupsPlatform/components/shell/side-rail/sidebar-rail.tsx","StartupsPlatform/components/shell/top-nav/app-tabs-strip.test.tsx","StartupsPlatform/components/shell/top-nav/app-tabs-strip.tsx","StartupsPlatform/components/shell/top-nav/global-search.tsx","StartupsPlatform/components/shell/top-nav/navbar.tsx","StartupsPlatform/components/shell/top-nav/notification-bell.tsx","StartupsPlatform/components/shell/top-nav/profile-menu.tsx","StartupsPlatform/components/shell/top-nav/tabs-provider.tsx","StartupsPlatform/components/shell/widget-boundary.tsx","StartupsPlatform/components/support/request-support-dialog.tsx","StartupsPlatform/components/support/view-ticket-dialog.tsx","StartupsPlatform/components/theme-provider.tsx","StartupsPlatform/components/theme-toggle.tsx","StartupsPlatform/components/ui/accordion.tsx","StartupsPlatform/components/ui/alert-dialog.tsx","StartupsPlatform/components/ui/alert.tsx","StartupsPlatform/components/ui/aspect-ratio.tsx","StartupsPlatform/components/ui/avatar.tsx","StartupsPlatform/components/ui/badge.tsx","StartupsPlatform/components/ui/breadcrumb.tsx","StartupsPlatform/components/ui/button-group.tsx","StartupsPlatform/components/ui/button.tsx","StartupsPlatform/components/ui/calendar.tsx","StartupsPlatform/components/ui/card.tsx","StartupsPlatform/components/ui/carousel.tsx","StartupsPlatform/components/ui/chart.tsx","StartupsPlatform/components/ui/checkbox.tsx","StartupsPlatform/components/ui/collapsible.tsx","StartupsPlatform/components/ui/command.tsx","StartupsPlatform/components/ui/context-menu.tsx","StartupsPlatform/components/ui/dialog.tsx","StartupsPlatform/components/ui/drawer.tsx","StartupsPlatform/components/ui/dropdown-menu.tsx","StartupsPlatform/components/ui/empty.tsx","StartupsPlatform/components/ui/field.tsx","StartupsPlatform/components/ui/form.tsx","StartupsPlatform/components/ui/ghost-scrollbar.tsx","StartupsPlatform/components/ui/hover-card.tsx","StartupsPlatform/components/ui/input-group.tsx","StartupsPlatform/components/ui/input-otp.tsx","StartupsPlatform/components/ui/input.tsx","StartupsPlatform/components/ui/item.tsx","StartupsPlatform/components/ui/kbd.tsx","StartupsPlatform/components/ui/label.tsx","StartupsPlatform/components/ui/menubar.tsx","StartupsPlatform/components/ui/navigation-menu.tsx","StartupsPlatform/components/ui/pagination.tsx","StartupsPlatform/components/ui/popover.tsx","StartupsPlatform/components/ui/progress.tsx","StartupsPlatform/components/ui/radio-group.tsx","StartupsPlatform/components/ui/resizable.tsx","StartupsPlatform/components/ui/scroll-area.tsx","StartupsPlatform/components/ui/select.tsx","StartupsPlatform/components/ui/separator.tsx","StartupsPlatform/components/ui/sheet.tsx","StartupsPlatform/components/ui/sidebar.tsx","StartupsPlatform/components/ui/skeleton.tsx","StartupsPlatform/components/ui/slider.tsx","StartupsPlatform/components/ui/sonner.tsx","StartupsPlatform/components/ui/spinner.tsx","StartupsPlatform/components/ui/switch.tsx","StartupsPlatform/components/ui/table.tsx","StartupsPlatform/components/ui/tabs.tsx","StartupsPlatform/components/ui/textarea.tsx","StartupsPlatform/components/ui/toast.tsx","StartupsPlatform/components/ui/toaster.tsx","StartupsPlatform/components/ui/toggle-group.tsx","StartupsPlatform/components/ui/toggle.tsx","StartupsPlatform/components/ui/tooltip.tsx","StartupsPlatform/components/ui/use-mobile.tsx","StartupsPlatform/components/ui/use-toast.ts"]},{"name":"StartupsPlatform — hooks","slug":"startupsplatform-hooks","files":["StartupsPlatform/hooks/use-auth.ts","StartupsPlatform/hooks/use-drive-sync.ts","StartupsPlatform/hooks/use-mobile.ts","StartupsPlatform/hooks/use-notification-stream.ts","StartupsPlatform/hooks/use-passkey-approval.ts","StartupsPlatform/hooks/use-toast.ts"]},{"name":"StartupsPlatform — i18n","slug":"startupsplatform-i18n","files":["StartupsPlatform/i18n/navigation.ts","StartupsPlatform/i18n/request.ts","StartupsPlatform/i18n/routing.ts"]},{"name":"StartupsPlatform — journeys","slug":"startupsplatform-journeys","files":["StartupsPlatform/journeys/README.md"]},{"name":"StartupsPlatform — lib","slug":"startupsplatform-lib","files":["StartupsPlatform/lib/__pe_probe.test.tsx","StartupsPlatform/lib/activity/action-labels.ts","StartupsPlatform/lib/activity/provenance.ts","StartupsPlatform/lib/agent-board/assistant-roster.test.ts","StartupsPlatform/lib/agent-board/assistant-roster.ts","StartupsPlatform/lib/agent-board/chat-splitter.ts","StartupsPlatform/lib/agent-board/config.ts","StartupsPlatform/lib/agent-board/fly-to-board.ts","StartupsPlatform/lib/agent-board/use-board-sizing.ts","StartupsPlatform/lib/agent-board/use-board-stream.ts","StartupsPlatform/lib/agent-board/week-range.test.ts","StartupsPlatform/lib/agent-board/week-range.ts","StartupsPlatform/lib/api/agent-board.ts","StartupsPlatform/lib/api/artifacts.ts","StartupsPlatform/lib/api/assistant-config.ts","StartupsPlatform/lib/api/assistant.ts","StartupsPlatform/lib/api/audit.ts","StartupsPlatform/lib/api/auth.ts","StartupsPlatform/lib/api/auto-record-rules.ts","StartupsPlatform/lib/api/automated-work.ts","StartupsPlatform/lib/api/capabilities.ts","StartupsPlatform/lib/api/client.test.ts","StartupsPlatform/lib/api/client.ts","StartupsPlatform/lib/api/company-profile.ts","StartupsPlatform/lib/api/connectors.ts","StartupsPlatform/lib/api/dashboard.ts","StartupsPlatform/lib/api/delegation.ts","StartupsPlatform/lib/api/drive-acl.ts","StartupsPlatform/lib/api/eri-ops.ts","StartupsPlatform/lib/api/erp-actions.ts","StartupsPlatform/lib/api/erp-customization.ts","StartupsPlatform/lib/api/features.ts","StartupsPlatform/lib/api/governance-draft.ts","StartupsPlatform/lib/api/governance-integrations.ts","StartupsPlatform/lib/api/http-error.ts","StartupsPlatform/lib/api/identity.ts","StartupsPlatform/lib/api/integration-health.ts","StartupsPlatform/lib/api/inter-assistant.ts","StartupsPlatform/lib/api/mail-domain.ts","StartupsPlatform/lib/api/mail.ts","StartupsPlatform/lib/api/mcp.ts","StartupsPlatform/lib/api/mutations.ts","StartupsPlatform/lib/api/notifications.ts","StartupsPlatform/lib/api/onboarding.ts","StartupsPlatform/lib/api/org-authority.test.ts","StartupsPlatform/lib/api/org-authority.ts","StartupsPlatform/lib/api/parsing.ts","StartupsPlatform/lib/api/pending-action.ts","StartupsPlatform/lib/api/people-map.ts","StartupsPlatform/lib/api/personal-governance.ts","StartupsPlatform/lib/api/policies.ts","StartupsPlatform/lib/api/portal-links.ts","StartupsPlatform/lib/api/portal.ts","StartupsPlatform/lib/api/preferences.ts","StartupsPlatform/lib/api/procedure-step-authority.ts","StartupsPlatform/lib/api/procedures.ts","StartupsPlatform/lib/api/profile.ts","StartupsPlatform/lib/api/rooms.ts","StartupsPlatform/lib/api/sandbox.ts","StartupsPlatform/lib/api/search.ts","StartupsPlatform/lib/api/security.ts","StartupsPlatform/lib/api/skills.ts","StartupsPlatform/lib/api/startup-documents.ts","StartupsPlatform/lib/api/suites.ts","StartupsPlatform/lib/api/team.ts","StartupsPlatform/lib/api/tool-registry.ts","StartupsPlatform/lib/api/vendor-links.ts","StartupsPlatform/lib/api/webauthn.ts","StartupsPlatform/lib/api/workspace-profile.ts","StartupsPlatform/lib/api/workspaces.ts","StartupsPlatform/lib/apps/blast-radius.ts","StartupsPlatform/lib/apps/durability.ts","StartupsPlatform/lib/apps/reach.ts","StartupsPlatform/lib/apps/version-history.ts","StartupsPlatform/lib/assistant/activity-log.ts","StartupsPlatform/lib/assistant/answer-quality.test.ts","StartupsPlatform/lib/assistant/answer-quality.ts","StartupsPlatform/lib/assistant/approval-fields.ts","StartupsPlatform/lib/assistant/ask-trigger.ts","StartupsPlatform/lib/assistant/collapsed-priority.ts","StartupsPlatform/lib/assistant/connector-requirements.ts","StartupsPlatform/lib/assistant/creation-trigger.ts","StartupsPlatform/lib/assistant/find-in-conversation.ts","StartupsPlatform/lib/assistant/generated-title.ts","StartupsPlatform/lib/assistant/message-groups.ts","StartupsPlatform/lib/assistant/page-context.test.ts","StartupsPlatform/lib/assistant/page-context.ts","StartupsPlatform/lib/assistant/protocol.fixtures.ts","StartupsPlatform/lib/assistant/protocol.test.ts","StartupsPlatform/lib/assistant/protocol.ts","StartupsPlatform/lib/assistant/tab-resolver.test.ts","StartupsPlatform/lib/assistant/tab-resolver.ts","StartupsPlatform/lib/assistant/use-device-logins.ts","StartupsPlatform/lib/auth-context.tsx","StartupsPlatform/lib/auth.ts","StartupsPlatform/lib/auth/session.ts","StartupsPlatform/lib/automation/cadence.ts","StartupsPlatform/lib/automation/use-automations.ts","StartupsPlatform/lib/automation/use-thread-fires.ts","StartupsPlatform/lib/automation/use-watches.ts","StartupsPlatform/lib/dashboard/pack-layout.test.ts","StartupsPlatform/lib/dashboard/pack-layout.ts","StartupsPlatform/lib/dashboard/use-dashboard-ask.test.ts","StartupsPlatform/lib/dashboard/use-dashboard-ask.ts","StartupsPlatform/lib/dashboard/widget-registry.test.ts","StartupsPlatform/lib/dashboard/widget-registry.ts","StartupsPlatform/lib/drives/connect-drive.ts","StartupsPlatform/lib/erp/accounting.test.ts","StartupsPlatform/lib/erp/accounting.ts","StartupsPlatform/lib/erp/action-approval.test.ts","StartupsPlatform/lib/erp/action-approval.ts","StartupsPlatform/lib/erp/advancedaccounting.ts","StartupsPlatform/lib/erp/advancedaccounting/asset-commit.test.ts","StartupsPlatform/lib/erp/advancedaccounting/asset-commit.ts","StartupsPlatform/lib/erp/advancedaccounting/assets.test.ts","StartupsPlatform/lib/erp/advancedaccounting/assets.ts","StartupsPlatform/lib/erp/advancedaccounting/audit-trail.test.ts","StartupsPlatform/lib/erp/advancedaccounting/audit-trail.ts","StartupsPlatform/lib/erp/advancedaccounting/chart-sections.test.ts","StartupsPlatform/lib/erp/advancedaccounting/chart-sections.ts","StartupsPlatform/lib/erp/advancedaccounting/entry-reversal.test.ts","StartupsPlatform/lib/erp/advancedaccounting/entry-reversal.ts","StartupsPlatform/lib/erp/advancedaccounting/entry-sums.test.ts","StartupsPlatform/lib/erp/advancedaccounting/entry-sums.ts","StartupsPlatform/lib/erp/advancedaccounting/period-lock.test.ts","StartupsPlatform/lib/erp/advancedaccounting/period-lock.ts","StartupsPlatform/lib/erp/advancedaccounting/statement-export.test.ts","StartupsPlatform/lib/erp/advancedaccounting/statement-export.ts","StartupsPlatform/lib/erp/advancedaccounting/wip-commit.ts","StartupsPlatform/lib/erp/advancedaccounting/wip.test.ts","StartupsPlatform/lib/erp/advancedaccounting/wip.ts","StartupsPlatform/lib/erp/app-catalog-labels.ts","StartupsPlatform/lib/erp/appraisal.test.ts","StartupsPlatform/lib/erp/appraisal.ts","StartupsPlatform/lib/erp/appraisals/attention.test.ts","StartupsPlatform/lib/erp/appraisals/attention.ts","StartupsPlatform/lib/erp/apps.ts","StartupsPlatform/lib/erp/attendance.ts","StartupsPlatform/lib/erp/beneficiaries.ts","StartupsPlatform/lib/erp/coa-integrity.test.ts","StartupsPlatform/lib/erp/coa-integrity.ts","StartupsPlatform/lib/erp/contact-links.test.ts","StartupsPlatform/lib/erp/contact-links.ts","StartupsPlatform/lib/erp/contacts-advanced.ts","StartupsPlatform/lib/erp/contacts-compliance.test.ts","StartupsPlatform/lib/erp/contacts-compliance.ts","StartupsPlatform/lib/erp/contacts.test.ts","StartupsPlatform/lib/erp/contacts.ts","StartupsPlatform/lib/erp/crm-advanced.ts","StartupsPlatform/lib/erp/crm.test.ts","StartupsPlatform/lib/erp/crm.ts","StartupsPlatform/lib/erp/crm/attention.test.ts","StartupsPlatform/lib/erp/crm/attention.ts","StartupsPlatform/lib/erp/customization/access.ts","StartupsPlatform/lib/erp/customization/canvas-edit.ts","StartupsPlatform/lib/erp/customization/client.ts","StartupsPlatform/lib/erp/customization/config-registry.ts","StartupsPlatform/lib/erp/customization/customize-context.tsx","StartupsPlatform/lib/erp/customization/dev-overrides.json","StartupsPlatform/lib/erp/customization/edit-ops.ts","StartupsPlatform/lib/erp/customization/i18n.ts","StartupsPlatform/lib/erp/customization/manifest.test.ts","StartupsPlatform/lib/erp/customization/manifest.ts","StartupsPlatform/lib/erp/customization/resolve-i18n.test.ts","StartupsPlatform/lib/erp/customization/resolve.test.ts","StartupsPlatform/lib/erp/customization/resolve.ts","StartupsPlatform/lib/erp/customization/types.ts","StartupsPlatform/lib/erp/customization/ui-overlay.ts","StartupsPlatform/lib/erp/customization/ui-values.ts","StartupsPlatform/lib/erp/customization/use-erp-i18n.ts","StartupsPlatform/lib/erp/customization/use-form-customization.ts","StartupsPlatform/lib/erp/customization/use-resolved-app.ts","StartupsPlatform/lib/erp/customization/use-shell-customization.ts","StartupsPlatform/lib/erp/datacycle.ts","StartupsPlatform/lib/erp/emailmarketing.ts","StartupsPlatform/lib/erp/employees.test.ts","StartupsPlatform/lib/erp/employees.ts","StartupsPlatform/lib/erp/erp/actions.ts","StartupsPlatform/lib/erp/erp/audit-labels.test.ts","StartupsPlatform/lib/erp/erp/audit-labels.ts","StartupsPlatform/lib/erp/erp/chatter.test.ts","StartupsPlatform/lib/erp/erp/chatter.ts","StartupsPlatform/lib/erp/erp/computed-rule.test.ts","StartupsPlatform/lib/erp/erp/computed-rule.ts","StartupsPlatform/lib/erp/erp/domain-sanitize.ts","StartupsPlatform/lib/erp/erp/domain-values.ts","StartupsPlatform/lib/erp/erp/erp-server.ts","StartupsPlatform/lib/erp/erp/kernel-routing.ts","StartupsPlatform/lib/erp/erp/metadata-client.ts","StartupsPlatform/lib/erp/erp/ownership.ts","StartupsPlatform/lib/erp/erp/rec-id.ts","StartupsPlatform/lib/erp/erp/record-files.ts","StartupsPlatform/lib/erp/erp/reports.test.ts","StartupsPlatform/lib/erp/erp/reports.ts","StartupsPlatform/lib/erp/erp/route-record-id.test.ts","StartupsPlatform/lib/erp/erp/route-record-id.ts","StartupsPlatform/lib/erp/erp/types.ts","StartupsPlatform/lib/erp/erp/widget-map.ts","StartupsPlatform/lib/erp/expenses.test.ts","StartupsPlatform/lib/erp/expenses.ts","StartupsPlatform/lib/erp/finance/aging-read.ts","StartupsPlatform/lib/erp/finance/aging.test.ts","StartupsPlatform/lib/erp/finance/aging.ts","StartupsPlatform/lib/erp/finance/attention.test.ts","StartupsPlatform/lib/erp/finance/attention.ts","StartupsPlatform/lib/erp/finance/csv-export.test.ts","StartupsPlatform/lib/erp/finance/csv-export.ts","StartupsPlatform/lib/erp/finance/csv.test.ts","StartupsPlatform/lib/erp/finance/csv.ts","StartupsPlatform/lib/erp/finance/default-tax.test.ts","StartupsPlatform/lib/erp/finance/default-tax.ts","StartupsPlatform/lib/erp/finance/invoice-number-request.test.ts","StartupsPlatform/lib/erp/finance/invoice-number.test.ts","StartupsPlatform/lib/erp/finance/invoice-number.ts","StartupsPlatform/lib/erp/finance/money-context.test.ts","StartupsPlatform/lib/erp/finance/money-context.ts","StartupsPlatform/lib/erp/finance/payables-attention.test.ts","StartupsPlatform/lib/erp/finance/payables-attention.ts","StartupsPlatform/lib/erp/finance/payment-counterparty.test.ts","StartupsPlatform/lib/erp/finance/payment-counterparty.ts","StartupsPlatform/lib/erp/finance/payment-readiness.test.ts","StartupsPlatform/lib/erp/finance/payment-readiness.ts","StartupsPlatform/lib/erp/finance/route-id.test.ts","StartupsPlatform/lib/erp/finance/route-id.ts","StartupsPlatform/lib/erp/finance/settlement.test.ts","StartupsPlatform/lib/erp/finance/settlement.ts","StartupsPlatform/lib/erp/finance/tax-invoice.test.ts","StartupsPlatform/lib/erp/finance/tax-invoice.ts","StartupsPlatform/lib/erp/finance/tax-request.test.ts","StartupsPlatform/lib/erp/finance/tax.test.ts","StartupsPlatform/lib/erp/finance/tax.ts","StartupsPlatform/lib/erp/finance/trn.ts","StartupsPlatform/lib/erp/finance/vat-return-kernel.test.ts","StartupsPlatform/lib/erp/finance/vat-return-kernel.ts","StartupsPlatform/lib/erp/finance/vat-return-live.test.ts","StartupsPlatform/lib/erp/finance/vat-return-read.ts","StartupsPlatform/lib/erp/finance/vat-return-request.test.ts","StartupsPlatform/lib/erp/finance/vat-return.test.ts","StartupsPlatform/lib/erp/finance/vat-return.ts","StartupsPlatform/lib/erp/helpdesk-project-link.test.ts","StartupsPlatform/lib/erp/helpdesk-sla.test.ts","StartupsPlatform/lib/erp/helpdesk.ts","StartupsPlatform/lib/erp/hr/departments.ts","StartupsPlatform/lib/erp/inventory.ts","StartupsPlatform/lib/erp/invoices.credit-notes.test.ts","StartupsPlatform/lib/erp/invoices.retention.test.ts","StartupsPlatform/lib/erp/invoices.ts","StartupsPlatform/lib/erp/kernel-task-dates.test.ts","StartupsPlatform/lib/erp/knowledge.ts","StartupsPlatform/lib/erp/landed-costs.ts","StartupsPlatform/lib/erp/ledger.test.ts","StartupsPlatform/lib/erp/ledger.ts","StartupsPlatform/lib/erp/livechat.ts","StartupsPlatform/lib/erp/maintenance.ts","StartupsPlatform/lib/erp/manufacturing.ts","StartupsPlatform/lib/erp/marketing-automation.ts","StartupsPlatform/lib/erp/marketingcard.ts","StartupsPlatform/lib/erp/money.test.ts","StartupsPlatform/lib/erp/money.ts","StartupsPlatform/lib/erp/mrp-advanced.ts","StartupsPlatform/lib/erp/ngofinance-authoring.ts","StartupsPlatform/lib/erp/ngofinance.ts","StartupsPlatform/lib/erp/pages/client.ts","StartupsPlatform/lib/erp/pages/condition.ts","StartupsPlatform/lib/erp/pages/flow-run.ts","StartupsPlatform/lib/erp/pages/list-view.test.ts","StartupsPlatform/lib/erp/pages/list-view.ts","StartupsPlatform/lib/erp/pages/pages.test.ts","StartupsPlatform/lib/erp/pages/resolve.ts","StartupsPlatform/lib/erp/pages/types.ts","StartupsPlatform/lib/erp/payments.ts","StartupsPlatform/lib/erp/payroll.test.ts","StartupsPlatform/lib/erp/payroll.ts","StartupsPlatform/lib/erp/planning.ts","StartupsPlatform/lib/erp/pos.ts","StartupsPlatform/lib/erp/products.test.ts","StartupsPlatform/lib/erp/products.ts","StartupsPlatform/lib/erp/project-enhance.ts","StartupsPlatform/lib/erp/project-snags.test.ts","StartupsPlatform/lib/erp/projects.ts","StartupsPlatform/lib/erp/purchase-allocation.test.ts","StartupsPlatform/lib/erp/purchase-allocation.ts","StartupsPlatform/lib/erp/purchases.test.ts","StartupsPlatform/lib/erp/purchases.ts","StartupsPlatform/lib/erp/quality.ts","StartupsPlatform/lib/erp/rail-icons.ts","StartupsPlatform/lib/erp/record-project-anchor.test.ts","StartupsPlatform/lib/erp/record-project-anchor.ts","StartupsPlatform/lib/erp/record-segment.test.ts","StartupsPlatform/lib/erp/record-segment.ts","StartupsPlatform/lib/erp/recruitment.test.ts","StartupsPlatform/lib/erp/recruitment.ts","StartupsPlatform/lib/erp/repairs.ts","StartupsPlatform/lib/erp/sales-advance-wire.test.ts","StartupsPlatform/lib/erp/sales-advanced.test.ts","StartupsPlatform/lib/erp/sales-advanced.ts","StartupsPlatform/lib/erp/sales-wire.test.ts","StartupsPlatform/lib/erp/sales.test.ts","StartupsPlatform/lib/erp/sales.ts","StartupsPlatform/lib/erp/sales/advance.test.ts","StartupsPlatform/lib/erp/sales/advance.ts","StartupsPlatform/lib/erp/sales/attention.test.ts","StartupsPlatform/lib/erp/sales/attention.ts","StartupsPlatform/lib/erp/sales/quote-tax.test.ts","StartupsPlatform/lib/erp/sales/quote-tax.ts","StartupsPlatform/lib/erp/service.ts","StartupsPlatform/lib/erp/sign.ts","StartupsPlatform/lib/erp/skills.ts","StartupsPlatform/lib/erp/statements.test.ts","StartupsPlatform/lib/erp/statements.ts","StartupsPlatform/lib/erp/subscriptions.ts","StartupsPlatform/lib/erp/task-assignee.test.ts","StartupsPlatform/lib/erp/task-schedule.test.ts","StartupsPlatform/lib/erp/task-write-divergence.test.ts","StartupsPlatform/lib/erp/tenant-currency.test.ts","StartupsPlatform/lib/erp/tenant-currency.ts","StartupsPlatform/lib/erp/timeoff.ts","StartupsPlatform/lib/erp/timesheets.ts","StartupsPlatform/lib/erp/todos-store.test.ts","StartupsPlatform/lib/erp/todos.test.ts","StartupsPlatform/lib/erp/todos.ts","StartupsPlatform/lib/erp/trial-balance.test.ts","StartupsPlatform/lib/erp/trial-balance.ts","StartupsPlatform/lib/erp/use-erp-search-entries.ts","StartupsPlatform/lib/erp/use-installed-erp-apps.ts","StartupsPlatform/lib/erp/use-record-project-anchor.ts","StartupsPlatform/lib/erp/use-suites-state.ts","StartupsPlatform/lib/erp/utils.ts","StartupsPlatform/lib/erp/website.ts","StartupsPlatform/lib/feature-access-context.tsx","StartupsPlatform/lib/format.test.ts","StartupsPlatform/lib/format.ts","StartupsPlatform/lib/i18n/bilingual-label.test.ts","StartupsPlatform/lib/i18n/bilingual-label.ts","StartupsPlatform/lib/i18n/locale-cookie.test.ts","StartupsPlatform/lib/i18n/locale-cookie.ts","StartupsPlatform/lib/integrations/reconnect-source.ts","StartupsPlatform/lib/knowledge/item-view.ts","StartupsPlatform/lib/knowledge/scope-view.ts","StartupsPlatform/lib/knowledge/use-hub-workspaces.ts","StartupsPlatform/lib/knowledge/use-synced-corpus.ts","StartupsPlatform/lib/posthog.tsx","StartupsPlatform/lib/procedures/__fixtures__/procedure-contract-cases.json","StartupsPlatform/lib/procedures/step-contract.ts","StartupsPlatform/lib/rooms/project-room-api.ts","StartupsPlatform/lib/rooms/use-rooms.ts","StartupsPlatform/lib/search/mounts.ts","StartupsPlatform/lib/search/use-quick-search.ts","StartupsPlatform/lib/shell/app-nav.ts","StartupsPlatform/lib/shell/first-name.ts","StartupsPlatform/lib/shell/nav.test.ts","StartupsPlatform/lib/shell/nav.ts","StartupsPlatform/lib/shell/payload.ts","StartupsPlatform/lib/shell/search-entries.ts","StartupsPlatform/lib/stream/backoff.ts","StartupsPlatform/lib/stream/classify.ts","StartupsPlatform/lib/stream/connection.ts","StartupsPlatform/lib/stream/dedupe.ts","StartupsPlatform/lib/stream/index.ts","StartupsPlatform/lib/stream/rate-limit-gate.ts","StartupsPlatform/lib/stream/reconnect-controller.ts","StartupsPlatform/lib/stream/replay.ts","StartupsPlatform/lib/stream/stall-watchdog.ts","StartupsPlatform/lib/stream/use-resilient-stream.ts","StartupsPlatform/lib/suites/use-suites-access.ts","StartupsPlatform/lib/uploads/file-guard.ts","StartupsPlatform/lib/uploads/slots.ts","StartupsPlatform/lib/uploads/use-drop-zone.ts","StartupsPlatform/lib/uploads/use-upload-slots.ts","StartupsPlatform/lib/utils.ts","StartupsPlatform/lib/vendor-codes.ts","StartupsPlatform/lib/weekly.ts"]},{"name":"StartupsPlatform — messages","slug":"startupsplatform-messages","files":["StartupsPlatform/messages/en.json","StartupsPlatform/messages/erp-ar.dictionary.json"]},{"name":"StartupsPlatform — scripts","slug":"startupsplatform-scripts","files":["StartupsPlatform/scripts/_a9-date-save-walk.cjs","StartupsPlatform/scripts/_a9-notfound-walk.cjs","StartupsPlatform/scripts/_a9-walk-lib.cjs","StartupsPlatform/scripts/_a9-walk-lib.test.cjs","StartupsPlatform/scripts/_contacts-redo-check.cjs","StartupsPlatform/scripts/_crawl-fresh.out","StartupsPlatform/scripts/_crawl-report-hussam-l3.json","StartupsPlatform/scripts/_crawl-report-hussam-l3fix.json","StartupsPlatform/scripts/_crawl-report-hussam-r2.json","StartupsPlatform/scripts/_crawl-report-maya-l3.json","StartupsPlatform/scripts/_crawl-report-maya.json","StartupsPlatform/scripts/_crawl-report.json","StartupsPlatform/scripts/_g2-emp-owner.cjs","StartupsPlatform/scripts/_g2-soak.cjs","StartupsPlatform/scripts/_g2-walk.cjs","StartupsPlatform/scripts/_midway-spot-check.cjs","StartupsPlatform/scripts/_midway-spot-check.out","StartupsPlatform/scripts/_midway2-r3-check.cjs","StartupsPlatform/scripts/_module-orphan-report.json","StartupsPlatform/scripts/_orphan-report.json","StartupsPlatform/scripts/_orphan-report.md","StartupsPlatform/scripts/_probe-bulkbar.cjs","StartupsPlatform/scripts/_probe-customrows-assignees.cjs","StartupsPlatform/scripts/_probe-invoice-a4.cjs","StartupsPlatform/scripts/_probe-wave1-moneyspine.cjs","StartupsPlatform/scripts/_project-redesign-walk.cjs","StartupsPlatform/scripts/_r4-attach-debug.cjs","StartupsPlatform/scripts/_r4-corrections-walk.cjs","StartupsPlatform/scripts/_repro-a4-wave.cjs","StartupsPlatform/scripts/_repro-activity-sync.cjs","StartupsPlatform/scripts/_repro-checklist.cjs","StartupsPlatform/scripts/_repro-dates.cjs","StartupsPlatform/scripts/_repro-nav.cjs","StartupsPlatform/scripts/_repro-nav2.cjs","StartupsPlatform/scripts/_repro-panel.cjs","StartupsPlatform/scripts/_repro-payables.cjs","StartupsPlatform/scripts/_smoke-finance.cjs","StartupsPlatform/scripts/_verify-frame-crm.cjs","StartupsPlatform/scripts/_verify-frame-pilot.cjs","StartupsPlatform/scripts/_verify-frame-suite1.cjs","StartupsPlatform/scripts/_verify-frame-suite2.cjs","StartupsPlatform/scripts/_verify-frame-suite3.cjs","StartupsPlatform/scripts/_verify-frame-suite4.cjs","StartupsPlatform/scripts/_verify-frame-suite5.cjs","StartupsPlatform/scripts/_verify-frame-suite8.cjs","StartupsPlatform/scripts/_verify-redirect-matrix.cjs","StartupsPlatform/scripts/check-error-boundaries.cjs","StartupsPlatform/scripts/check-error-boundaries.test.ts","StartupsPlatform/scripts/check-error-copy.cjs","StartupsPlatform/scripts/check-frame.cjs","StartupsPlatform/scripts/check-i18n-keys.mjs","StartupsPlatform/scripts/check-i18n.mjs","StartupsPlatform/scripts/check-list-placement.cjs","StartupsPlatform/scripts/check-public-env.cjs","StartupsPlatform/scripts/check-settings-forms.cjs","StartupsPlatform/scripts/check-token-access.cjs","StartupsPlatform/scripts/check-token-access.test.ts","StartupsPlatform/scripts/codemod-logical-direction.mjs","StartupsPlatform/scripts/crawl-pages.cjs","StartupsPlatform/scripts/erp-manifest-i18n.mjs","StartupsPlatform/scripts/list-placement-baseline.json","StartupsPlatform/scripts/merge-message-parts.mjs","StartupsPlatform/scripts/migrate-erp-overrides.cjs","StartupsPlatform/scripts/module-orphan-baseline.json","StartupsPlatform/scripts/module-orphans.cjs","StartupsPlatform/scripts/orphan-scan.cjs"]},{"name":"StartupsPlatform — styles","slug":"startupsplatform-styles","files":["StartupsPlatform/styles/globals.css"]}]},{"name":"deploy","slug":"deploy","files":[],"children":[{"name":"deploy — inference","slug":"deploy-inference","files":["deploy/inference/BENCHMARK-CEILING-2026-08-05.md","deploy/inference/LANES-2026-08-05.md","deploy/inference/box-up.sh","deploy/inference/provision.sh"]},{"name":"deploy — local","slug":"deploy-local","files":["deploy/local/README.md"]},{"name":"deploy — nginx","slug":"deploy-nginx","files":["deploy/nginx/conf.d/00-http.conf","deploy/nginx/conf.d/01-https.conf","deploy/nginx/conf.d/proxy-params.conf","deploy/nginx/conf.d/ssl-params.conf","deploy/nginx/nginx.conf"]},{"name":"deploy — openbao","slug":"deploy-openbao","files":["deploy/openbao/auto-unseal.sh","deploy/openbao/bao.env","deploy/openbao/config.hcl"]},{"name":"deploy — rooms","slug":"deploy-rooms","files":["deploy/rooms/Dockerfile.relay","deploy/rooms/README.md","deploy/rooms/compose.relay.yml","deploy/rooms/relay-load.py","deploy/rooms/relay-probe.py"]},{"name":"deploy — spire","slug":"deploy-spire","files":["deploy/spire/agent.conf","deploy/spire/server.conf","deploy/spire/svid-sidecar/Dockerfile","deploy/spire/svid-sidecar/svid-healthcheck.sh","deploy/spire/svid-sidecar/svid-refresh.sh"]}]},{"name":"docs","slug":"docs","files":[],"children":[{"name":"docs — docs","slug":"docs-docs","files":["docs/NGO-SHOWCASE-REPORT-2026-07-26.md","docs/README.md","docs/ai_inst.md","docs/git-rules.md","docs/hermes_harakat_analysis.md","docs/next_todo.md","docs/prodtodo_kernel.md","docs/search-command-and-erp-fix.md"]},{"name":"docs — architecture","slug":"docs-architecture","files":["docs/architecture/ARCHITECTURE_CHANGES.md","docs/architecture/caching_profile.md","docs/architecture/decisions/2026-07-17-rescope-gap-m-entities-as-data.md","docs/architecture/decisions/2026-07-17-reversal-affine-verdict-odoo-20-years.md","docs/architecture/endgame_residuals_and_isolation_plan_2026-07-23.md","docs/architecture/eri_bdh_integration_plan.md","docs/architecture/erp_integration.md","docs/architecture/erp_pipeline_map.md","docs/architecture/frontend_vision_and_grammar.md","docs/architecture/hermesxharakat.md","docs/architecture/k2_transition_data_topology.md","docs/architecture/k2_wave2_own_addons_spec.md","docs/architecture/k2_wave3_project_spec.md","docs/architecture/k2_wave4_hr_spec.md","docs/architecture/k2_wave5_sales_purchase_spec.md","docs/architecture/k2_wave6_stock_spec.md","docs/architecture/k2_wave7_catalog_spec.md","docs/architecture/k2_waves_2_4_review.md","docs/architecture/kernel_layers_planes.md","docs/architecture/kernel_overlay_contract.md","docs/architecture/model_of_record.md","docs/architecture/odoo.md","docs/architecture/p1_access_identity_study.md","docs/architecture/p1_corpus_encrypt_at_rest_design.md","docs/architecture/p1_delegation_tokens_design.md","docs/architecture/p1_per_run_delegation_design.md","docs/architecture/p1_spiffe_agent_identity_design.md","docs/architecture/p2_embeddings_validation_study.md","docs/architecture/p2_hybrid_embeddings_build.md","docs/architecture/p2_ingest_memory_hardening.md","docs/architecture/p2_per_question_results.md","docs/architecture/p4_foundation_audit.md","docs/architecture/p4_per_app_roadmap.md","docs/architecture/p4_skills_governance_plan.md","docs/architecture/p5_headroom_audit_pipeline_and_data.md","docs/architecture/p5_headroom_matrix.md","docs/architecture/p5_headroom_matrix_thinkon.md","docs/architecture/p5_headroom_offline_benchmark.md","docs/architecture/p5_headroom_thinking_comparison.md","docs/architecture/p5_headroom_token_economics_off.md","docs/architecture/primitives_p1_entities_design.md","docs/architecture/primitives_p3_allocation_design.md","docs/architecture/rooms-relay-per-tenant-ops.md","docs/architecture/selfhosted_inference_runbook.md","docs/architecture/workspace-evolution-blocks-blueprints-graph.md"]},{"name":"docs — automl","slug":"docs-automl","files":["docs/automl/FEATURE_UPDATE_AUTOML.md","docs/automl/TIMESFM_EXPLORATION.md"]},{"name":"docs — capacity","slug":"docs-capacity","files":["docs/capacity/estimate.md","docs/capacity/harakat_capacity_comparison.md"]},{"name":"docs — deployment","slug":"docs-deployment","files":["docs/deployment/DEPLOY_NOTES.md"]},{"name":"docs — formal","slug":"docs-formal","files":["docs/formal/tenant-resolution/NOTE.md","docs/formal/tenant-resolution/exhaustive.py","docs/formal/tenant-resolution/model.py","docs/formal/tenant-resolution/mutation.py"]},{"name":"docs — legacy","slug":"docs-legacy","files":["docs/legacy/README.md","docs/legacy/next_todo.md","docs/legacy/nexttodo_admin.md","docs/legacy/nexttodo_b.md","docs/legacy/nexttodo_kernel.md","docs/legacy/nexttodo_office.md"]},{"name":"docs — personas","slug":"docs-personas","files":["docs/personas/README.md","docs/personas/aqarat/persona.md","docs/personas/dar/persona.md","docs/personas/ibtisama/persona.md","docs/personas/lifespace/persona.md","docs/personas/wahaj/persona.md","docs/personas/waqf/persona.md"]},{"name":"docs — pipeline","slug":"docs-pipeline","files":["docs/pipeline/AB-TEST-REPORT-2026-07-30.md","docs/pipeline/AUDIT-100-PAGES-2026-07-30.md","docs/pipeline/BENCH-EMBED-2026-07-31.md","docs/pipeline/BLIND-AUDIT-1000-2026-07-31.md","docs/pipeline/CAD-DISCOVERY-2026-07-31.md","docs/pipeline/DIAGNOSIS-2026-07-29.md","docs/pipeline/DIFF-AUDIT-1000-2026-07-31.md","docs/pipeline/GPU-SESSION-RUNBOOK.md","docs/pipeline/PIPELINE-V2-SPEC-2026-07-30.md","docs/pipeline/QUANTIZATION-REPORT-2026-08-02.md","docs/pipeline/QUERY-EMBEDDING-HOSTING.md","docs/pipeline/README.md","docs/pipeline/SEARCH-BENCH-2026-07-31.md","docs/pipeline/SEARCH-V3-PLAN-2026-08-04.md","docs/pipeline/mounts/README.md","docs/pipeline/mounts/chats.md","docs/pipeline/mounts/email.md","docs/pipeline/mounts/erp.md","docs/pipeline/mounts/gdrive.md","docs/pipeline/mounts/onedrive.md","docs/pipeline/mounts/path-grammar.md","docs/pipeline/mounts/verify-anchors.py"]},{"name":"docs — product","slug":"docs-product","files":["docs/product/2026-06-30-vision-gaps.md","docs/product/AI_SECTION_REPORT_2026-07-10.md","docs/product/ASSISTANT_CAPABILITY_MATRIX.md","docs/product/COMPANY-TYPES-REPORT-2026-07-26.md","docs/product/CUSTOMER_FLOW_VARIATIONS_2026-07.md","docs/product/ERP_BACKEND_CUSTOMIZATION_GAPS_2026-07-02.md","docs/product/ERP_USECASE_AWQAF_2026-07-11.md","docs/product/GAPS_TO_VISION_2026-06-30.md","docs/product/LIVE_E2E_TEST_GAPS_2026-07-07.md","docs/product/LIVE_E2E_TEST_RERUN_2026-07-08.md","docs/product/PLATFORM_OVERVIEW.md","docs/product/design-refs/2026-07-28-surface-pass.md","docs/product/plans/eri_bdh_headroom_unified_ai_plan.md","docs/product/startups-platform-agents.md"]},{"name":"docs — reference","slug":"docs-reference","files":["docs/reference/google-liveapi-example.py","docs/reference/material-request-form-procedure.md","docs/reference/writing_docs_skill.md"]},{"name":"docs — retrieval","slug":"docs-retrieval","files":["docs/retrieval/EMBEDDINGS_QDRANT.md","docs/retrieval/HANDOVER_RETRIEVAL_V2.md"]},{"name":"docs — reviews","slug":"docs-reviews","files":["docs/reviews/2026-07-06-deployment-scalability-review.md","docs/reviews/2026-07-06-security-review.md"]},{"name":"docs — security","slug":"docs-security","files":["docs/security/AUDIT_REPORT.md","docs/security/ab-isolation-conformance.md","docs/security/codex_security_audit.md"]},{"name":"docs — specs","slug":"docs-specs","files":["docs/specs/2026-06-29-procedures-controlled-flow-parallel-COMPLETE.md","docs/specs/plans/2026-06-17-batch-embeddings.md","docs/specs/plans/2026-06-17-enrichment-batch-state-machine.md","docs/specs/plans/2026-06-17-erp-mcp-scoped-catalog.md","docs/specs/plans/2026-06-17-erp-migration-into-harakat.md","docs/specs/plans/2026-06-17-erp-per-employee-access.md","docs/specs/plans/2026-06-17-ingest-memory-rust-hardening.md","docs/specs/plans/2026-06-18-erp-dashboard-embed.md","docs/specs/plans/2026-06-18-erp-l1-line-visibility.md","docs/specs/plans/2026-06-18-erp-l2-catalog-generator.md","docs/specs/plans/2026-06-18-erp-l3-app-selection.md","docs/specs/plans/2026-06-19-erp-l4-phase1-customization-framework.md","docs/specs/plans/2026-06-19-erp-l4-phase2-field-data-ops.md","docs/specs/plans/2026-06-19-erp-l4-phase3-view-layout-ops.md","docs/specs/plans/2026-06-19-erp-l4-phase4-automation-behavior-ops.md","docs/specs/plans/2026-06-19-erp-l4-phase5-structural-destructive-rebrand.md","docs/specs/plans/2026-06-21-agent-board.md","docs/specs/plans/2026-06-21-dashboard-shell-v2.md","docs/specs/plans/2026-06-23-shell-board-voice-refinement.md","docs/specs/plans/2026-06-24-assistant-chat-rendering-fixes.md","docs/specs/plans/2026-06-24-dashboard-customization.md","docs/specs/plans/2026-06-24-intelligent-hub-redesign.md","docs/specs/plans/2026-06-24-knowledge-hub-redesign.md","docs/specs/plans/2026-06-24-suites-erp-app-surfacing.md","docs/specs/plans/2026-06-24-team-management-redesign.md","docs/specs/plans/2026-06-25-agentic-dashboard-rebuild.md","docs/specs/plans/2026-06-25-assistants-table.md","docs/specs/plans/2026-06-25-connect-module-shell-polish.md","docs/specs/plans/2026-06-25-employees-takeover.md","docs/specs/plans/2026-06-25-governance-tabs.md","docs/specs/plans/2026-06-25-knowledge-hub-corpus-source.md","docs/specs/plans/2026-06-25-security-spine.md","docs/specs/plans/2026-06-25-settings-polish.md","docs/specs/plans/2026-06-27-erp-advancedaccounting-app-plan.md","docs/specs/plans/2026-06-27-erp-attendance-app-plan.md","docs/specs/plans/2026-06-27-erp-contacts-app-plan.md","docs/specs/plans/2026-06-27-erp-crm-app-plan.md","docs/specs/plans/2026-06-27-erp-emailmarketing-app-plan.md","docs/specs/plans/2026-06-27-erp-employees-app-plan.md","docs/specs/plans/2026-06-27-erp-expenses-app-plan.md","docs/specs/plans/2026-06-27-erp-finance-app-plan.md","docs/specs/plans/2026-06-27-erp-helpdesk-app-plan.md","docs/specs/plans/2026-06-27-erp-inventory-app-plan.md","docs/specs/plans/2026-06-27-erp-knowledge-app-plan.md","docs/specs/plans/2026-06-27-erp-livechat-app-plan.md","docs/specs/plans/2026-06-27-erp-maintenance-app-plan.md","docs/specs/plans/2026-06-27-erp-manufacturing-app-plan.md","docs/specs/plans/2026-06-27-erp-marketing-automation-app-plan.md","docs/specs/plans/2026-06-27-erp-marketingcard-app-plan.md","docs/specs/plans/2026-06-27-erp-payroll-app-plan.md","docs/specs/plans/2026-06-27-erp-per-page-edits-foundation.md","docs/specs/plans/2026-06-27-erp-planning-app-plan.md","docs/specs/plans/2026-06-27-erp-pos-app-plan.md","docs/specs/plans/2026-06-27-erp-project-app-plan.md","docs/specs/plans/2026-06-27-erp-purchase-app-plan.md","docs/specs/plans/2026-06-27-erp-recruitment-app-plan.md","docs/specs/plans/2026-06-27-erp-repairs-app-plan.md","docs/specs/plans/2026-06-27-erp-sales-app-plan.md","docs/specs/plans/2026-06-27-erp-sign-app-plan.md","docs/specs/plans/2026-06-27-erp-skills-app-plan.md","docs/specs/plans/2026-06-27-erp-subscription-app-plan.md","docs/specs/plans/2026-06-27-erp-timeoff-app-plan.md","docs/specs/plans/2026-06-27-erp-timesheets-app-plan.md","docs/specs/plans/2026-06-27-erp-todos-app-plan.md","docs/specs/plans/2026-06-27-erp-website-app-plan.md","docs/specs/plans/2026-06-27-project-app-audit.md","docs/specs/plans/2026-06-28-erp-anchoring-plan.md","docs/specs/plans/2026-06-28-procedures-module-redo.md","docs/specs/plans/2026-06-29-agentic-governance-creation.md","docs/specs/plans/2026-06-29-procedures-controlled-flow-parallel.md","docs/specs/plans/2026-06-30-eri-phase1-safety-observability-plan.md","docs/specs/plans/2026-06-30-eri-phase2-run-taskstate-plan.md","docs/specs/plans/2026-06-30-erp-cleanup-and-user-facing-test-pipeline.md","docs/specs/plans/2026-06-30-phase0-erp-agent-tools.md","docs/specs/plans/2026-06-30-phase0-gap-d-provisioning.md","docs/specs/plans/2026-06-30-phase0-peer-note-producer.md","docs/specs/plans/2026-06-30-phase3-context-activation-evidencebundle-plan.md","docs/specs/plans/2026-06-30-phase4-conversation-lifecycle-plan.md","docs/specs/plans/2026-07-01-eri-phase5-conversation-memory-recall-plan.md","docs/specs/plans/2026-07-01-eri-phase5-d1-headroom-benchmark-plan.md","docs/specs/plans/2026-07-02-eri-phase6-tool-gateway-plan.md","docs/specs/plans/2026-07-02-eri-phases7-10-combined-plan.md","docs/specs/plans/2026-07-02-erp-gaps-fill-program.md","docs/specs/plans/2026-07-02-erp-vertical-usecases-backend-gaps.md","docs/specs/plans/2026-07-04-erp-app-frame-plan0-foundation.md","docs/specs/plans/2026-07-04-erp-app-frame-plan1-sales-crm.md","docs/specs/plans/2026-07-04-erp-app-frame-plan2-finance.md","docs/specs/plans/2026-07-04-erp-app-frame-plan3-supply-chain.md","docs/specs/plans/2026-07-04-erp-app-frame-plan4-projects.md","docs/specs/plans/2026-07-04-erp-app-frame-plan5-people.md","docs/specs/plans/2026-07-04-erp-app-frame-plan6-services.md","docs/specs/plans/2026-07-04-erp-app-frame-plan7-marketing.md","docs/specs/plans/2026-07-04-erp-app-frame-plan8-productivity.md","docs/specs/plans/2026-07-04-onboarding-alignment.md","docs/specs/plans/2026-07-05-mobile-app.md","docs/specs/plans/2026-07-05-notification-system.md","docs/specs/plans/2026-07-06-post-rollback-restoration.md","docs/specs/plans/2026-07-07-live-e2e-round2-plan.md","docs/specs/plans/2026-07-07-ws-a-backend-gaps.md","docs/specs/plans/2026-07-07-ws-b-governance-ia.md","docs/specs/plans/2026-07-07-ws-c-hub-assistant-only-authoring.md","docs/specs/plans/2026-07-07-ws-d-suites-background-removal.md","docs/specs/plans/2026-07-07-ws-e-dashboard-prompt.md","docs/specs/plans/2026-07-07-ws-f-agentic-board.md","docs/specs/plans/2026-07-07-ws-g-erp-projects-employees.md","docs/specs/plans/2026-07-08-live-e2e-round2-remaining-plan.md","docs/specs/plans/2026-07-09-enrich-batch-self-heal-plan.md","docs/specs/plans/2026-07-09-owner-round3-redesign-plan.md","docs/specs/plans/2026-07-09-retrieval-v2-only-coverage-plan.md","docs/specs/plans/2026-07-09-ws1-analytics-removal-plan.md","docs/specs/plans/2026-07-10-ws10-board-v2-plan.md","docs/specs/plans/2026-07-10-ws2-governance-redistribution-plan.md","docs/specs/plans/2026-07-10-ws3-sidebar-motion-plan.md","docs/specs/plans/2026-07-10-ws5-employees-orgchart-plan.md","docs/specs/plans/2026-07-10-ws6-module-system-v2-plan.md","docs/specs/plans/2026-07-10-ws7-personal-governance-plan.md","docs/specs/plans/2026-07-10-ws8-navbar-tickets-plan.md","docs/specs/plans/2026-07-16-invoices-purchase-redesign.md","docs/specs/plans/2026-07-24-platform-plan/README.md","docs/specs/plans/2026-07-24-platform-plan/admin-platform.md","docs/specs/plans/2026-07-24-platform-plan/apps.md","docs/specs/plans/2026-07-24-platform-plan/companies-platform.md","docs/specs/plans/2026-07-24-platform-plan/ngo-profile.md","docs/specs/plans/2026-07-24-platform-plan/office-platform.md","docs/specs/plans/2026-07-24-platform-plan/primitives.md","docs/specs/plans/2026-07-24-platform-plan/tenant-types.md","docs/specs/plans/2026-08-03-artifacts/DESIGN.md","docs/specs/plans/2026-08-03-room-signing-design.md","docs/specs/plans/2026-08-03-sandbox/DESIGN.md","docs/specs/plans/2026-08-04-sandbox-egress-sessions/DESIGN.md","docs/specs/specs/2026-06-17-batch-embeddings-design.md","docs/specs/specs/2026-06-17-capability-access-governance-design.md","docs/specs/specs/2026-06-17-enrichment-batch-state-machine-design.md","docs/specs/specs/2026-06-17-erp-migration-into-harakat-design.md","docs/specs/specs/2026-06-17-erp-per-employee-access-design.md","docs/specs/specs/2026-06-17-ingest-memory-rust-hardening-design.md","docs/specs/specs/2026-06-18-erp-dashboard-embed-design.md","docs/specs/specs/2026-06-18-erp-dynamic-access-customization-design.md","docs/specs/specs/2026-06-19-erp-l4-customization-program-design.md","docs/specs/specs/2026-06-19-erp-l4-phase2-field-data-ops-design.md","docs/specs/specs/2026-06-19-erp-l4-phase3-view-layout-ops-design.md","docs/specs/specs/2026-06-19-erp-l4-phase4-automation-behavior-ops-design.md","docs/specs/specs/2026-06-19-erp-l4-phase5-structural-destructive-rebrand-design.md","docs/specs/specs/2026-06-21-agent-board-design.md","docs/specs/specs/2026-06-21-dashboard-shell-v2-design.md","docs/specs/specs/2026-06-23-shell-board-voice-refinement-design.md","docs/specs/specs/2026-06-24-assistant-chat-rendering-fixes-design.md","docs/specs/specs/2026-06-24-dashboard-customization-design.md","docs/specs/specs/2026-06-24-intelligent-hub-redesign-design.md","docs/specs/specs/2026-06-24-knowledge-hub-redesign-design.md","docs/specs/specs/2026-06-24-suites-erp-app-surfacing-design.md","docs/specs/specs/2026-06-24-team-management-redesign-design.md","docs/specs/specs/2026-06-25-agentic-dashboard-rebuild-design.md","docs/specs/specs/2026-06-25-assistants-table-design.md","docs/specs/specs/2026-06-25-connect-module-shell-polish-design.md","docs/specs/specs/2026-06-25-employees-takeover-design.md","docs/specs/specs/2026-06-25-governance-tabs-design.md","docs/specs/specs/2026-06-25-knowledge-hub-corpus-source-design.md","docs/specs/specs/2026-06-25-security-spine-design.md","docs/specs/specs/2026-06-25-settings-polish-design.md","docs/specs/specs/2026-06-26-erp-per-page-edits-foundation-design.md","docs/specs/specs/2026-06-27-erp-advancedaccounting-app-design.md","docs/specs/specs/2026-06-27-erp-attendance-app-design.md","docs/specs/specs/2026-06-27-erp-contacts-app-design.md","docs/specs/specs/2026-06-27-erp-crm-app-design.md","docs/specs/specs/2026-06-27-erp-emailmarketing-app-design.md","docs/specs/specs/2026-06-27-erp-employees-app-design.md","docs/specs/specs/2026-06-27-erp-expenses-app-design.md","docs/specs/specs/2026-06-27-erp-finance-app-design.md","docs/specs/specs/2026-06-27-erp-helpdesk-app-design.md","docs/specs/specs/2026-06-27-erp-inventory-app-design.md","docs/specs/specs/2026-06-27-erp-knowledge-app-design.md","docs/specs/specs/2026-06-27-erp-livechat-app-design.md","docs/specs/specs/2026-06-27-erp-maintenance-app-design.md","docs/specs/specs/2026-06-27-erp-manufacturing-app-design.md","docs/specs/specs/2026-06-27-erp-marketing-automation-app-design.md","docs/specs/specs/2026-06-27-erp-marketingcard-app-design.md","docs/specs/specs/2026-06-27-erp-payroll-app-design.md","docs/specs/specs/2026-06-27-erp-planning-app-design.md","docs/specs/specs/2026-06-27-erp-pos-app-design.md","docs/specs/specs/2026-06-27-erp-project-app-design.md","docs/specs/specs/2026-06-27-erp-purchase-app-design.md","docs/specs/specs/2026-06-27-erp-recruitment-app-design.md","docs/specs/specs/2026-06-27-erp-repairs-app-design.md","docs/specs/specs/2026-06-27-erp-sales-app-design.md","docs/specs/specs/2026-06-27-erp-sign-app-design.md","docs/specs/specs/2026-06-27-erp-skills-app-design.md","docs/specs/specs/2026-06-27-erp-subscription-app-design.md","docs/specs/specs/2026-06-27-erp-timeoff-app-design.md","docs/specs/specs/2026-06-27-erp-timesheets-app-design.md","docs/specs/specs/2026-06-27-erp-todos-app-design.md","docs/specs/specs/2026-06-27-erp-website-app-design.md","docs/specs/specs/2026-06-28-erp-anchoring-design.md","docs/specs/specs/2026-06-28-erp-procedures-builder-fix-design.md","docs/specs/specs/2026-06-28-procedures-module-redo-design.md","docs/specs/specs/2026-06-29-agentic-governance-creation-design.md","docs/specs/specs/2026-06-29-procedures-controlled-flow-parallel-design.md","docs/specs/specs/2026-06-30-eri-phase1-safety-observability-design.md","docs/specs/specs/2026-06-30-eri-phase2-run-taskstate-design.md","docs/specs/specs/2026-06-30-eri-runtime-umbrella-design.md","docs/specs/specs/2026-06-30-erp-cleanup-and-user-facing-test-pipeline-design.md","docs/specs/specs/2026-06-30-phase0-anchoring-connection-layer-design.md","docs/specs/specs/2026-06-30-phase0-erp-agent-tools-design.md","docs/specs/specs/2026-06-30-phase0-local-profile-design.md","docs/specs/specs/2026-06-30-phase0-passkey-rail-design.md","docs/specs/specs/2026-06-30-phase0-peer-note-producer-design.md","docs/specs/specs/2026-06-30-phase0-per-employee-provisioning-design.md","docs/specs/specs/2026-06-30-phase3-context-activation-evidencebundle-design.md","docs/specs/specs/2026-06-30-phase4-conversation-lifecycle-design.md","docs/specs/specs/2026-07-01-eri-phase5-compression-headroom-design.md","docs/specs/specs/2026-07-01-eri-phase5-conversation-memory-recall-design.md","docs/specs/specs/2026-07-02-eri-phase6-tool-gateway-design.md","docs/specs/specs/2026-07-02-eri-phases7-10-combined-design.md","docs/specs/specs/2026-07-02-erp-gaps-fill-program-design.md","docs/specs/specs/2026-07-02-erp-vertical-usecases-backend-gaps-design.md","docs/specs/specs/2026-07-04-erp-app-frame-ia-redesign-design.md","docs/specs/specs/2026-07-04-erp-app-frame-spec0-foundation.md","docs/specs/specs/2026-07-04-erp-app-frame-suite1-sales-crm.md","docs/specs/specs/2026-07-04-erp-app-frame-suite2-finance.md","docs/specs/specs/2026-07-04-erp-app-frame-suite3-supply-chain.md","docs/specs/specs/2026-07-04-erp-app-frame-suite4-projects.md","docs/specs/specs/2026-07-04-erp-app-frame-suite5-people.md","docs/specs/specs/2026-07-04-erp-app-frame-suite6-services.md","docs/specs/specs/2026-07-04-erp-app-frame-suite7-marketing.md","docs/specs/specs/2026-07-04-erp-app-frame-suite8-productivity.md","docs/specs/specs/2026-07-04-onboarding-alignment-design.md","docs/specs/specs/2026-07-05-mobile-app-design.md","docs/specs/specs/2026-07-05-notification-system-design.md","docs/specs/specs/2026-07-07-live-e2e-gaps-fix-program-design.md","docs/specs/specs/2026-07-08-live-e2e-round2-full-design.md","docs/specs/specs/2026-07-09-owner-round3-redesign-spec.md","docs/specs/specs/2026-07-09-retrieval-v2-only-coverage-design.md","docs/specs/specs/2026-07-10-file-creation-spec.md","docs/specs/specs/2026-07-10-policy-guardrail-engine-spec.md","docs/specs/specs/2026-07-16-invoices-purchase-redesign-design.md","docs/specs/specs/2026-07-17-kernel-k1-helpdesk-behavior-spec.md","docs/specs/specs/2026-07-17-rust-kernel-k0-infrastructure-design.md","docs/specs/specs/2026-07-28-persona-simulation-pipeline-design.md","docs/specs/specs/2026-07-29-admin-platform/README.md","docs/specs/specs/2026-07-29-admin-platform/s1-activity-mcp-port.md","docs/specs/specs/2026-07-29-admin-platform/s2-pack-console.md","docs/specs/specs/2026-07-29-admin-platform/s3-suite-recommendations.md","docs/specs/vendors-v1-answer-leg-addendum.md","docs/specs/vendors-v1-coordinator-cockpit.md"]}]},{"name":"erp-harakat-backend","slug":"erp-harakat-backend","files":[],"children":[{"name":"erp-harakat-backend — erp-harakat-backend","slug":"erp-harakat-backend-erp-harakat-backend","files":["erp-harakat-backend/Dockerfile","erp-harakat-backend/odoo.conf"]},{"name":"erp-harakat-backend — custom_addons","slug":"erp-harakat-backend-custom-addons","files":["erp-harakat-backend/custom_addons/account_advanced/__init__.py","erp-harakat-backend/custom_addons/account_advanced/__manifest__.py","erp-harakat-backend/custom_addons/account_advanced/data/account_advanced_data.xml","erp-harakat-backend/custom_addons/account_advanced/models/__init__.py","erp-harakat-backend/custom_addons/account_advanced/models/account_analytic.py","erp-harakat-backend/custom_addons/account_advanced/models/account_budget.py","erp-harakat-backend/custom_addons/account_advanced/models/account_dunning.py","erp-harakat-backend/custom_addons/account_advanced/models/account_reconcile.py","erp-harakat-backend/custom_addons/account_advanced/models/account_report.py","erp-harakat-backend/custom_addons/account_advanced/views/account_advanced_menu.xml","erp-harakat-backend/custom_addons/account_advanced/views/account_budget_views.xml","erp-harakat-backend/custom_addons/account_advanced/views/account_dunning_views.xml","erp-harakat-backend/custom_addons/account_advanced/views/account_report_views.xml","erp-harakat-backend/custom_addons/account_advanced/wizard/__init__.py","erp-harakat-backend/custom_addons/account_advanced/wizard/account_dunning_wizard.py","erp-harakat-backend/custom_addons/account_advanced/wizard/account_dunning_wizard.xml","erp-harakat-backend/custom_addons/account_advanced/wizard/account_financial_report_wizard.py","erp-harakat-backend/custom_addons/account_advanced/wizard/account_financial_report_wizard.xml","erp-harakat-backend/custom_addons/account_assets/__init__.py","erp-harakat-backend/custom_addons/account_assets/__manifest__.py","erp-harakat-backend/custom_addons/account_assets/data/account_assets_data.xml","erp-harakat-backend/custom_addons/account_assets/models/__init__.py","erp-harakat-backend/custom_addons/account_assets/models/account_asset.py","erp-harakat-backend/custom_addons/account_assets/views/account_assets_views.xml","erp-harakat-backend/custom_addons/crm_advanced/__init__.py","erp-harakat-backend/custom_addons/crm_advanced/__manifest__.py","erp-harakat-backend/custom_addons/crm_advanced/models/__init__.py","erp-harakat-backend/custom_addons/crm_advanced/models/crm_competitor.py","erp-harakat-backend/custom_addons/crm_advanced/models/crm_lead.py","erp-harakat-backend/custom_addons/crm_advanced/views/crm_advanced_views.xml","erp-harakat-backend/custom_addons/erp_bridge/__init__.py","erp-harakat-backend/custom_addons/erp_bridge/__manifest__.py","erp-harakat-backend/custom_addons/erp_bridge/controllers/__init__.py","erp-harakat-backend/custom_addons/erp_bridge/controllers/auth.py","erp-harakat-backend/custom_addons/erp_bridge/controllers/crm.py","erp-harakat-backend/custom_addons/erp_bridge/controllers/main.py","erp-harakat-backend/custom_addons/erp_bridge/models/__init__.py","erp-harakat-backend/custom_addons/erp_bridge/models/api_log.py","erp-harakat-backend/custom_addons/erp_gateway/__init__.py","erp-harakat-backend/custom_addons/erp_gateway/__manifest__.py","erp-harakat-backend/custom_addons/erp_gateway/hooks.py","erp-harakat-backend/custom_addons/erp_gateway/migrations/1.1.0/post-migration.py","erp-harakat-backend/custom_addons/erp_gateway/models/__init__.py","erp-harakat-backend/custom_addons/erp_gateway/models/catalog.py","erp-harakat-backend/custom_addons/erp_gateway/models/customize.py","erp-harakat-backend/custom_addons/erp_gateway/models/event_relay.py","erp-harakat-backend/custom_addons/erp_gateway/models/gateway.py","erp-harakat-backend/custom_addons/erp_gateway/models/governed_models.py","erp-harakat-backend/custom_addons/erp_gateway/models/owner_mixin.py","erp-harakat-backend/custom_addons/erp_gateway/models/project_dependencies.py","erp-harakat-backend/custom_addons/erp_gateway/models/quotation_document_access.py","erp-harakat-backend/custom_addons/erp_gateway/models/res_users.py","erp-harakat-backend/custom_addons/erp_gateway/models/security_generator.py","erp-harakat-backend/custom_addons/erp_gateway/models/spiffe_verify.py","erp-harakat-backend/custom_addons/erp_gateway/security/erp_gateway_groups.xml","erp-harakat-backend/custom_addons/erp_gateway/security/erp_gateway_rules.xml","erp-harakat-backend/custom_addons/erp_gateway/tests/__init__.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_app_lifecycle.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_catalog.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_customize.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_event_relay.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_gateway.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_generator.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_protected_models.py","erp-harakat-backend/custom_addons/erp_gateway/tests/test_scoping.py","erp-harakat-backend/custom_addons/erp_gateway/views/erp_gateway_branding.xml","erp-harakat-backend/custom_addons/harakat_contacts/__init__.py","erp-harakat-backend/custom_addons/harakat_contacts/__manifest__.py","erp-harakat-backend/custom_addons/harakat_contacts/models/__init__.py","erp-harakat-backend/custom_addons/harakat_contacts/models/partner_merge.py","erp-harakat-backend/custom_addons/harakat_finance/__init__.py","erp-harakat-backend/custom_addons/harakat_finance/__manifest__.py","erp-harakat-backend/custom_addons/harakat_finance/models/__init__.py","erp-harakat-backend/custom_addons/harakat_finance/models/account_move.py","erp-harakat-backend/custom_addons/harakat_finance/models/dispatch.py","erp-harakat-backend/custom_addons/harakat_org/__init__.py","erp-harakat-backend/custom_addons/harakat_org/__manifest__.py","erp-harakat-backend/custom_addons/harakat_org/models/__init__.py","erp-harakat-backend/custom_addons/harakat_org/models/employee_mirror.py","erp-harakat-backend/custom_addons/harakat_org/models/org_mirror.py","erp-harakat-backend/custom_addons/harakat_purchase/__init__.py","erp-harakat-backend/custom_addons/harakat_purchase/__manifest__.py","erp-harakat-backend/custom_addons/harakat_purchase/models/__init__.py","erp-harakat-backend/custom_addons/harakat_purchase/models/purchase_dispatch.py","erp-harakat-backend/custom_addons/harakat_sales/__init__.py","erp-harakat-backend/custom_addons/harakat_sales/__manifest__.py","erp-harakat-backend/custom_addons/harakat_sales/models/__init__.py","erp-harakat-backend/custom_addons/harakat_sales/models/sale_dispatch.py","erp-harakat-backend/custom_addons/helpdesk/__init__.py","erp-harakat-backend/custom_addons/helpdesk/__manifest__.py","erp-harakat-backend/custom_addons/helpdesk/data/helpdesk_data.xml","erp-harakat-backend/custom_addons/helpdesk/models/__init__.py","erp-harakat-backend/custom_addons/helpdesk/models/helpdesk_sla.py","erp-harakat-backend/custom_addons/helpdesk/models/helpdesk_team.py","erp-harakat-backend/custom_addons/helpdesk/models/helpdesk_ticket.py","erp-harakat-backend/custom_addons/helpdesk/models/res_partner.py","erp-harakat-backend/custom_addons/helpdesk/security/helpdesk_security.xml","erp-harakat-backend/custom_addons/helpdesk/static/description/index.html","erp-harakat-backend/custom_addons/helpdesk/views/helpdesk_sla_views.xml","erp-harakat-backend/custom_addons/helpdesk/views/helpdesk_team_views.xml","erp-harakat-backend/custom_addons/helpdesk/views/helpdesk_ticket_views.xml","erp-harakat-backend/custom_addons/helpdesk/views/helpdesk_views.xml","erp-harakat-backend/custom_addons/helpdesk/wizard/__init__.py","erp-harakat-backend/custom_addons/helpdesk/wizard/helpdesk_ticket_merge.py","erp-harakat-backend/custom_addons/helpdesk/wizard/helpdesk_ticket_merge_views.xml","erp-harakat-backend/custom_addons/hr_appraisal_lite/__init__.py","erp-harakat-backend/custom_addons/hr_appraisal_lite/__manifest__.py","erp-harakat-backend/custom_addons/hr_appraisal_lite/data/hr_appraisal_lite_data.xml","erp-harakat-backend/custom_addons/hr_appraisal_lite/models/__init__.py","erp-harakat-backend/custom_addons/hr_appraisal_lite/models/hr_appraisal.py","erp-harakat-backend/custom_addons/hr_appraisal_lite/security/hr_appraisal_security.xml","erp-harakat-backend/custom_addons/hr_appraisal_lite/views/hr_appraisal_lite_views.xml","erp-harakat-backend/custom_addons/knowledge_base/__init__.py","erp-harakat-backend/custom_addons/knowledge_base/__manifest__.py","erp-harakat-backend/custom_addons/knowledge_base/models/__init__.py","erp-harakat-backend/custom_addons/knowledge_base/models/knowledge_article.py","erp-harakat-backend/custom_addons/knowledge_base/views/knowledge_base_views.xml","erp-harakat-backend/custom_addons/marketing_automation_lite/__init__.py","erp-harakat-backend/custom_addons/marketing_automation_lite/__manifest__.py","erp-harakat-backend/custom_addons/marketing_automation_lite/data/marketing_automation_lite_data.xml","erp-harakat-backend/custom_addons/marketing_automation_lite/models/__init__.py","erp-harakat-backend/custom_addons/marketing_automation_lite/models/marketing_campaign.py","erp-harakat-backend/custom_addons/marketing_automation_lite/views/marketing_automation_lite_views.xml","erp-harakat-backend/custom_addons/mrp_advanced/__init__.py","erp-harakat-backend/custom_addons/mrp_advanced/__manifest__.py","erp-harakat-backend/custom_addons/mrp_advanced/data/mrp_advanced_data.xml","erp-harakat-backend/custom_addons/mrp_advanced/models/__init__.py","erp-harakat-backend/custom_addons/mrp_advanced/models/production_plan.py","erp-harakat-backend/custom_addons/mrp_advanced/views/mrp_advanced_views.xml","erp-harakat-backend/custom_addons/payroll/__init__.py","erp-harakat-backend/custom_addons/payroll/__manifest__.py","erp-harakat-backend/custom_addons/payroll/data/payroll_data.xml","erp-harakat-backend/custom_addons/payroll/models/__init__.py","erp-harakat-backend/custom_addons/payroll/models/hr_contract.py","erp-harakat-backend/custom_addons/payroll/models/hr_payroll_structure.py","erp-harakat-backend/custom_addons/payroll/models/hr_payslip.py","erp-harakat-backend/custom_addons/payroll/models/hr_payslip_line.py","erp-harakat-backend/custom_addons/payroll/models/hr_salary_rule.py","erp-harakat-backend/custom_addons/payroll/views/hr_payroll_structure_views.xml","erp-harakat-backend/custom_addons/payroll/views/hr_payslip_views.xml","erp-harakat-backend/custom_addons/payroll/views/hr_salary_rule_views.xml","erp-harakat-backend/custom_addons/payroll/views/payroll_menu.xml","erp-harakat-backend/custom_addons/payroll/wizard/__init__.py","erp-harakat-backend/custom_addons/payroll/wizard/hr_payslip_run_wizard.py","erp-harakat-backend/custom_addons/payroll/wizard/hr_payslip_run_wizard.xml","erp-harakat-backend/custom_addons/planning_lite/__init__.py","erp-harakat-backend/custom_addons/planning_lite/__manifest__.py","erp-harakat-backend/custom_addons/planning_lite/data/planning_lite_data.xml","erp-harakat-backend/custom_addons/planning_lite/models/__init__.py","erp-harakat-backend/custom_addons/planning_lite/models/planning_slot.py","erp-harakat-backend/custom_addons/planning_lite/views/planning_lite_views.xml","erp-harakat-backend/custom_addons/project_advanced/__init__.py","erp-harakat-backend/custom_addons/project_advanced/__manifest__.py","erp-harakat-backend/custom_addons/project_advanced/models/__init__.py","erp-harakat-backend/custom_addons/project_advanced/models/account_analytic_line.py","erp-harakat-backend/custom_addons/project_advanced/models/project_activity_type.py","erp-harakat-backend/custom_addons/project_advanced/models/project_task.py","erp-harakat-backend/custom_addons/project_advanced/views/project_advanced_views.xml","erp-harakat-backend/custom_addons/quality_inspection/__init__.py","erp-harakat-backend/custom_addons/quality_inspection/__manifest__.py","erp-harakat-backend/custom_addons/quality_inspection/data/quality_inspection_data.xml","erp-harakat-backend/custom_addons/quality_inspection/models/__init__.py","erp-harakat-backend/custom_addons/quality_inspection/models/quality_inspection.py","erp-harakat-backend/custom_addons/quality_inspection/views/quality_inspection_views.xml","erp-harakat-backend/custom_addons/service_management/__init__.py","erp-harakat-backend/custom_addons/service_management/__manifest__.py","erp-harakat-backend/custom_addons/service_management/data/service_management_data.xml","erp-harakat-backend/custom_addons/service_management/models/__init__.py","erp-harakat-backend/custom_addons/service_management/models/maintenance_contract.py","erp-harakat-backend/custom_addons/service_management/models/warranty_claim.py","erp-harakat-backend/custom_addons/service_management/views/service_management_views.xml","erp-harakat-backend/custom_addons/sign_lite/__init__.py","erp-harakat-backend/custom_addons/sign_lite/__manifest__.py","erp-harakat-backend/custom_addons/sign_lite/data/sign_lite_data.xml","erp-harakat-backend/custom_addons/sign_lite/models/__init__.py","erp-harakat-backend/custom_addons/sign_lite/models/sign_request.py","erp-harakat-backend/custom_addons/sign_lite/views/sign_lite_views.xml","erp-harakat-backend/custom_addons/subscription/__init__.py","erp-harakat-backend/custom_addons/subscription/__manifest__.py","erp-harakat-backend/custom_addons/subscription/data/subscription_data.xml","erp-harakat-backend/custom_addons/subscription/models/__init__.py","erp-harakat-backend/custom_addons/subscription/models/product_template.py","erp-harakat-backend/custom_addons/subscription/models/sale_order.py","erp-harakat-backend/custom_addons/subscription/models/subscription.py","erp-harakat-backend/custom_addons/subscription/models/subscription_line.py","erp-harakat-backend/custom_addons/subscription/models/subscription_plan.py","erp-harakat-backend/custom_addons/subscription/views/subscription_analytics_views.xml","erp-harakat-backend/custom_addons/subscription/views/subscription_menu.xml","erp-harakat-backend/custom_addons/subscription/views/subscription_plan_views.xml","erp-harakat-backend/custom_addons/subscription/views/subscription_views.xml","erp-harakat-backend/custom_addons/subscription/wizard/__init__.py","erp-harakat-backend/custom_addons/subscription/wizard/subscription_cancel_wizard.py","erp-harakat-backend/custom_addons/subscription/wizard/subscription_change_wizard.py","erp-harakat-backend/custom_addons/subscription/wizard/subscription_change_wizard.xml"]},{"name":"erp-harakat-backend — scripts","slug":"erp-harakat-backend-scripts","files":["erp-harakat-backend/scripts/debrand.sh","erp-harakat-backend/scripts/tenant19_manifest.py","erp-harakat-backend/scripts/tenant19_scrub.py"]}]},{"name":"meeting-bot-worker","slug":"meeting-bot-worker","files":["meeting-bot-worker/Dockerfile","meeting-bot-worker/package.json","meeting-bot-worker/src/main.js"]},{"name":"meeting-transcript-worker","slug":"meeting-transcript-worker","files":["meeting-transcript-worker/Dockerfile","meeting-transcript-worker/package.json","meeting-transcript-worker/scripts/setup-google-stt.ps1","meeting-transcript-worker/src/gcs.js","meeting-transcript-worker/src/google-stt.js","meeting-transcript-worker/src/gpu-spec.js","meeting-transcript-worker/src/main.js","meeting-transcript-worker/src/mom.js","meeting-transcript-worker/src/pdf.js","meeting-transcript-worker/src/transcribe.js","meeting-transcript-worker/vast-whisper.sh"]},{"name":"scripts","slug":"scripts","files":[],"children":[{"name":"scripts — scripts","slug":"scripts-scripts","files":["scripts/branch-health.sh","scripts/buzz-room-inheritance-gate.sh","scripts/check-config.sh","scripts/check-submodule-pins.sh","scripts/close-feature.sh","scripts/gate-receipt.sh","scripts/inference-tunnel.sh","scripts/isolation-proof.sh","scripts/new-feature.sh","scripts/primary-checkout.sh","scripts/rooms-ops-measure.sh","scripts/rooms-relay.sh","scripts/rooms-substrate-check.sh","scripts/spire-up.sh","scripts/stack-lock.sh","scripts/track-board.sh"]},{"name":"scripts — gpu-embed","slug":"scripts-gpu-embed","files":["scripts/gpu-embed/gpu_embed.py","scripts/gpu-embed/gpu_embed_selftest.py","scripts/gpu-embed/onstart.sh"]},{"name":"scripts — gpu-fleet","slug":"scripts-gpu-fleet","files":["scripts/gpu-fleet/fleet.py","scripts/gpu-fleet/fleet_selftest.py","scripts/gpu-fleet/lane_worker.py","scripts/gpu-fleet/onstart.sh","scripts/gpu-fleet/prep_driver.py","scripts/gpu-fleet/provision-fleet.sh","scripts/gpu-fleet/shard.py"]},{"name":"scripts — gpu-full-load","slug":"scripts-gpu-full-load","files":["scripts/gpu-full-load/box.py","scripts/gpu-full-load/box_run.py","scripts/gpu-full-load/card_prompt.py","scripts/gpu-full-load/lane_worker.py","scripts/gpu-full-load/make_card_prompt.py","scripts/gpu-full-load/measure_gap.py","scripts/gpu-full-load/onstart.sh"]},{"name":"scripts — hooks","slug":"scripts-hooks","files":["scripts/hooks/pre-commit","scripts/hooks/pre-push"]},{"name":"scripts — pipeline-v2","slug":"scripts-pipeline-v2","files":["scripts/pipeline-v2/_env.py","scripts/pipeline-v2/build_fp16_ref.py","scripts/pipeline-v2/build_manifests.py","scripts/pipeline-v2/cpu_embed_bench.py","scripts/pipeline-v2/dwg_cpu_worker.py","scripts/pipeline-v2/dwg_vision_worker.py","scripts/pipeline-v2/dxf_sanitize.py","scripts/pipeline-v2/embed_all_v2.py","scripts/pipeline-v2/eos_probe.py","scripts/pipeline-v2/harvest.py","scripts/pipeline-v2/pool_probe.py","scripts/pipeline-v2/populate_meili_v2.py","scripts/pipeline-v2/preflight.sh","scripts/pipeline-v2/quant_bench3.py","scripts/pipeline-v2/qwen_zoom_reader.py","scripts/pipeline-v2/run15.py","scripts/pipeline-v2/run6_chat.py","scripts/pipeline-v2/search_bench.py","scripts/pipeline-v2/search_bench_deep.py","scripts/pipeline-v2/selfretrieve_probe.py","scripts/pipeline-v2/stage-cad-toolchain.sh","scripts/pipeline-v2/stage_type_corpus.py","scripts/pipeline-v2/type_prep.py","scripts/pipeline-v2/type_vision.py"]}]},{"name":"testpipe","slug":"testpipe","files":[],"children":[{"name":"testpipe — testpipe","slug":"testpipe-testpipe","files":["testpipe/README.md","testpipe/access_probe.py","testpipe/backtest_grader.py","testpipe/bakeoff_subagent.py","testpipe/bakeoff_tables.py","testpipe/checks.py","testpipe/config.py","testpipe/drive.py","testpipe/e2e_search.py","testpipe/framework.py","testpipe/fresh_user.py","testpipe/gov_dump.py","testpipe/gov_grading.py","testpipe/gov_memory_run.py","testpipe/gov_regrade.py","testpipe/governance.py","testpipe/grading.py","testpipe/harness.py","testpipe/honcho_probe.py","testpipe/inbound_mail.py","testpipe/meeting_setup.py","testpipe/mt_bakeoff.py","testpipe/mt_beats_g42.py","testpipe/mt_docgrade.py","testpipe/mt_erp.py","testpipe/mt_extract.py","testpipe/mt_fullreport.py","testpipe/mt_grade.py","testpipe/mt_identity.py","testpipe/mt_observe.py","testpipe/mt_pull_full.py","testpipe/mt_report.py","testpipe/mt_reset.py","testpipe/mt_run.py","testpipe/mt_time.py","testpipe/mt_transparency.py","testpipe/mt_turn.py","testpipe/probe_create.py","testpipe/probe_diag.py","testpipe/probe_queryset.py","testpipe/probe_retrieve.py","testpipe/projects_agent.py","testpipe/report.py","testpipe/repro_search.py","testpipe/run.py","testpipe/run_huge.py","testpipe/search_eval_run.py","testpipe/search_subagent_queryset.json","testpipe/search_subagent_report.py","testpipe/search_subagent_run.py","testpipe/smoke_thinking.py","testpipe/suite_contacts.py","testpipe/suite_quality.py","testpipe/suites.py","testpipe/switch_model.py","testpipe/vertex_token.py"]},{"name":"testpipe — isolation","slug":"testpipe-isolation","files":["testpipe/isolation/README.md","testpipe/isolation/__init__.py","testpipe/isolation/conformance_multitenant.py","testpipe/isolation/fixtures.py","testpipe/isolation/lane.py","testpipe/isolation/obligations.py","testpipe/isolation/run.py","testpipe/isolation/selfcheck.py"]}]}];
var META = {"fromCommit":"e4f075f55268d6dfb56bf699d8c54d438337496b","generatedAt":"2026-08-15T02:04:20.382Z","model":"Qwen/Qwen3.5-9B","lang":"","moduleFiles":{"Root":["AGENTS.md","CLAUDE.md","DEPLOYMENT.md","Harakat.code-workspace","WORKSPACE.md","after-run1.yml","docker-compose.yml","lifecycle-recordings-90d.json"],"Root — AGENTS.md":["AGENTS.md"],"Root — CLAUDE.md":["CLAUDE.md"],"Root — DEPLOYMENT.md":["DEPLOYMENT.md"],"Root — Harakat.code-workspace":["Harakat.code-workspace"],"Root — WORKSPACE.md":["WORKSPACE.md"],"Root — after-run1.yml":["after-run1.yml"],"Root — docker-compose.yml":["docker-compose.yml"],"Root — lifecycle-recordings-90d.json":["lifecycle-recordings-90d.json"],"HarakatMobile":["HarakatMobile/README.md","HarakatMobile/app.json","HarakatMobile/eas.json","HarakatMobile/package.json","HarakatMobile/tsconfig.json","HarakatMobile/assets/expo.icon/icon.json","HarakatMobile/ios/Harakat.xcodeproj/project.pbxproj","HarakatMobile/ios/Harakat.xcodeproj/project.xcworkspace/contents.xcworkspacedata","HarakatMobile/ios/Harakat.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist","HarakatMobile/ios/Harakat.xcodeproj/xcshareddata/xcschemes/Harakat.xcscheme","HarakatMobile/ios/Harakat/AppDelegate.swift","HarakatMobile/ios/Harakat/Harakat-Bridging-Header.h","HarakatMobile/ios/Harakat/Harakat.entitlements","HarakatMobile/ios/Harakat/Images.xcassets/AppIcon.appiconset/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/SplashScreenBackground.colorset/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/SplashScreenLogo.imageset/Contents.json","HarakatMobile/ios/Harakat/Info.plist","HarakatMobile/ios/Harakat/SplashScreen.storyboard","HarakatMobile/ios/Harakat/Supporting/Expo.plist","HarakatMobile/ios/Harakat/expo.icon/icon.json","HarakatMobile/ios/Podfile","HarakatMobile/ios/Podfile.properties.json","HarakatMobile/scripts/check-i18n.js","HarakatMobile/scripts/check-icons.mjs","HarakatMobile/scripts/check-ota-safe.mjs","HarakatMobile/scripts/harness-selftest.mjs","HarakatMobile/scripts/lib/settled.mjs","HarakatMobile/scripts/lib/sign-in-diagnosis.mjs","HarakatMobile/scripts/lib/web-export.mjs","HarakatMobile/scripts/reset-project.js","HarakatMobile/scripts/rtl-render-check.mjs","HarakatMobile/scripts/settle-selftest.mjs","HarakatMobile/scripts/stream-render-check.mjs","HarakatMobile/src/app/(tabs)/_layout.tsx","HarakatMobile/src/app/(tabs)/board.tsx","HarakatMobile/src/app/(tabs)/index.tsx","HarakatMobile/src/app/(tabs)/notifications.tsx","HarakatMobile/src/app/(tabs)/settings/_layout.tsx","HarakatMobile/src/app/(tabs)/settings/appearance.tsx","HarakatMobile/src/app/(tabs)/settings/governance.tsx","HarakatMobile/src/app/(tabs)/settings/index.tsx","HarakatMobile/src/app/(tabs)/settings/language.tsx","HarakatMobile/src/app/(tabs)/settings/notifications.tsx","HarakatMobile/src/app/(tabs)/settings/profile.tsx","HarakatMobile/src/app/(tabs)/settings/security.tsx","HarakatMobile/src/app/_layout.tsx","HarakatMobile/src/app/login.tsx","HarakatMobile/src/components/animated-icon.module.css","HarakatMobile/src/components/animated-icon.tsx","HarakatMobile/src/components/animated-icon.web.tsx","HarakatMobile/src/components/board/board-canvas.tsx","HarakatMobile/src/components/board/board-card.tsx","HarakatMobile/src/components/board/chat-sheet.tsx","HarakatMobile/src/components/board/clamp.ts","HarakatMobile/src/components/board/inbox-list.tsx","HarakatMobile/src/components/chat/action-preview-card.tsx","HarakatMobile/src/components/chat/assistant-markdown.tsx","HarakatMobile/src/components/chat/chat-screen.tsx","HarakatMobile/src/components/chat/chat-sidebar.tsx","HarakatMobile/src/components/chat/composer-actions.ts","HarakatMobile/src/components/chat/voice-recorder.tsx","HarakatMobile/src/components/dashboard/ask-sheet.tsx","HarakatMobile/src/components/dashboard/unknown-widget.tsx","HarakatMobile/src/components/dashboard/widget-card.tsx","HarakatMobile/src/components/external-link.tsx","HarakatMobile/src/components/governance/pending-card.tsx","HarakatMobile/src/components/hint-row.tsx","HarakatMobile/src/components/themed-text.tsx","HarakatMobile/src/components/themed-view.tsx","HarakatMobile/src/components/ui/action-sheet.tsx","HarakatMobile/src/components/ui/button.tsx","HarakatMobile/src/components/ui/collapsible.tsx","HarakatMobile/src/components/ui/dismiss-keyboard-on-drag.tsx","HarakatMobile/src/components/ui/empty-state.tsx","HarakatMobile/src/components/ui/glass-card.tsx","HarakatMobile/src/components/ui/harakat-mark.tsx","HarakatMobile/src/components/ui/icon.tsx","HarakatMobile/src/components/ui/list-row.tsx","HarakatMobile/src/components/ui/load-error.tsx","HarakatMobile/src/components/ui/offline-pill.tsx","HarakatMobile/src/components/ui/read-only-notice.tsx","HarakatMobile/src/components/ui/segmented-control.tsx","HarakatMobile/src/components/ui/skeleton.tsx","HarakatMobile/src/components/ui/stale-strip.tsx","HarakatMobile/src/components/ui/stream-status-strip.tsx","HarakatMobile/src/components/ui/web-handoff-card.tsx","HarakatMobile/src/components/web-badge.tsx","HarakatMobile/src/constants/theme.ts","HarakatMobile/src/global.css","HarakatMobile/src/hooks/use-color-scheme.ts","HarakatMobile/src/hooks/use-color-scheme.web.ts","HarakatMobile/src/hooks/use-theme.ts","HarakatMobile/src/i18n/direction.ts","HarakatMobile/src/i18n/format.ts","HarakatMobile/src/i18n/i18n-context.tsx","HarakatMobile/src/i18n/locale-store.ts","HarakatMobile/src/i18n/messages/ar.json","HarakatMobile/src/i18n/messages/en.json","HarakatMobile/src/i18n/plural.ts","HarakatMobile/src/i18n/routing.ts","HarakatMobile/src/i18n/translate.ts","HarakatMobile/src/lib/api/agent-board.ts","HarakatMobile/src/lib/api/assistant.ts","HarakatMobile/src/lib/api/attachments.ts","HarakatMobile/src/lib/api/auth.ts","HarakatMobile/src/lib/api/client.ts","HarakatMobile/src/lib/api/conversations.ts","HarakatMobile/src/lib/api/dashboard.ts","HarakatMobile/src/lib/api/governance.ts","HarakatMobile/src/lib/api/notifications.ts","HarakatMobile/src/lib/api/sessions.ts","HarakatMobile/src/lib/api/voice.ts","HarakatMobile/src/lib/api/webauthn.ts","HarakatMobile/src/lib/assistant/approval-fields.ts","HarakatMobile/src/lib/auth/auth-context.tsx","HarakatMobile/src/lib/auth/auth-machine.ts","HarakatMobile/src/lib/auth/biometric-lock.tsx","HarakatMobile/src/lib/auth/passkeys.ts","HarakatMobile/src/lib/auth/token-store.ts","HarakatMobile/src/lib/board/reply-target.ts","HarakatMobile/src/lib/board/use-board-stream.ts","HarakatMobile/src/lib/chrome/tab-bar.tsx","HarakatMobile/src/lib/dashboard/widget-data.ts","HarakatMobile/src/lib/dashboard/widget-registry.ts","HarakatMobile/src/lib/deep-link-parker.ts","HarakatMobile/src/lib/deep-links.ts","HarakatMobile/src/lib/handoff.ts","HarakatMobile/src/lib/keyboard/drag-accumulator.ts","HarakatMobile/src/lib/layout.ts","HarakatMobile/src/lib/motion/motion.ts","HarakatMobile/src/lib/net/xhr-stream.ts","HarakatMobile/src/lib/notifications/feed.ts","HarakatMobile/src/lib/notifications/preferences.ts","HarakatMobile/src/lib/offline/net-state.ts","HarakatMobile/src/lib/offline/outbox.ts","HarakatMobile/src/lib/offline/read-cache.ts","HarakatMobile/src/lib/offline/storage.ts","HarakatMobile/src/lib/push.ts","HarakatMobile/src/lib/sse.ts","HarakatMobile/src/lib/stream/backoff.ts","HarakatMobile/src/lib/stream/classify.ts","HarakatMobile/src/lib/stream/connection.ts","HarakatMobile/src/lib/stream/dedupe.ts","HarakatMobile/src/lib/stream/index.ts","HarakatMobile/src/lib/stream/platform-signals.ts","HarakatMobile/src/lib/stream/rate-limit-gate.ts","HarakatMobile/src/lib/stream/replay.ts","HarakatMobile/src/lib/stream/stall-watchdog.ts","HarakatMobile/src/lib/stream/use-resilient-stream.ts","HarakatMobile/src/lib/ui/action-bands.ts","HarakatMobile/src/lib/ui/settle.ts","HarakatMobile/src/lib/ui/skeleton-widths.ts","HarakatMobile/src/lib/ui/use-settle.ts","HarakatMobile/src/lib/ui/view-state.ts","HarakatMobile/src/theme/theme-context.tsx","HarakatMobile/src/theme/tokens.ts","HarakatMobile/store/README.md","HarakatMobile/store/app-store-privacy.md","HarakatMobile/store/assets-spec.md","HarakatMobile/store/credentials-and-wellknown.md","HarakatMobile/store/ios-privacy-manifest.md","HarakatMobile/store/play-data-safety.md","HarakatMobile/store/screenshots-checklist.md"],"HarakatMobile — HarakatMobile":["HarakatMobile/README.md","HarakatMobile/app.json","HarakatMobile/eas.json","HarakatMobile/package.json","HarakatMobile/tsconfig.json"],"HarakatMobile — assets":["HarakatMobile/assets/expo.icon/icon.json"],"HarakatMobile — ios":["HarakatMobile/ios/Harakat.xcodeproj/project.pbxproj","HarakatMobile/ios/Harakat.xcodeproj/project.xcworkspace/contents.xcworkspacedata","HarakatMobile/ios/Harakat.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist","HarakatMobile/ios/Harakat.xcodeproj/xcshareddata/xcschemes/Harakat.xcscheme","HarakatMobile/ios/Harakat/AppDelegate.swift","HarakatMobile/ios/Harakat/Harakat-Bridging-Header.h","HarakatMobile/ios/Harakat/Harakat.entitlements","HarakatMobile/ios/Harakat/Images.xcassets/AppIcon.appiconset/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/SplashScreenBackground.colorset/Contents.json","HarakatMobile/ios/Harakat/Images.xcassets/SplashScreenLogo.imageset/Contents.json","HarakatMobile/ios/Harakat/Info.plist","HarakatMobile/ios/Harakat/SplashScreen.storyboard","HarakatMobile/ios/Harakat/Supporting/Expo.plist","HarakatMobile/ios/Harakat/expo.icon/icon.json","HarakatMobile/ios/Podfile","HarakatMobile/ios/Podfile.properties.json"],"HarakatMobile — scripts":["HarakatMobile/scripts/check-i18n.js","HarakatMobile/scripts/check-icons.mjs","HarakatMobile/scripts/check-ota-safe.mjs","HarakatMobile/scripts/harness-selftest.mjs","HarakatMobile/scripts/lib/settled.mjs","HarakatMobile/scripts/lib/sign-in-diagnosis.mjs","HarakatMobile/scripts/lib/web-export.mjs","HarakatMobile/scripts/reset-project.js","HarakatMobile/scripts/rtl-render-check.mjs","HarakatMobile/scripts/settle-selftest.mjs","HarakatMobile/scripts/stream-render-check.mjs"],"HarakatMobile — src":["HarakatMobile/src/app/(tabs)/_layout.tsx","HarakatMobile/src/app/(tabs)/board.tsx","HarakatMobile/src/app/(tabs)/index.tsx","HarakatMobile/src/app/(tabs)/notifications.tsx","HarakatMobile/src/app/(tabs)/settings/_layout.tsx","HarakatMobile/src/app/(tabs)/settings/appearance.tsx","HarakatMobile/src/app/(tabs)/settings/governance.tsx","HarakatMobile/src/app/(tabs)/settings/index.tsx","HarakatMobile/src/app/(tabs)/settings/language.tsx","HarakatMobile/src/app/(tabs)/settings/notifications.tsx","HarakatMobile/src/app/(tabs)/settings/profile.tsx","HarakatMobile/src/app/(tabs)/settings/security.tsx","HarakatMobile/src/app/_layout.tsx","HarakatMobile/src/app/login.tsx","HarakatMobile/src/components/animated-icon.module.css","HarakatMobile/src/components/animated-icon.tsx","HarakatMobile/src/components/animated-icon.web.tsx","HarakatMobile/src/components/board/board-canvas.tsx","HarakatMobile/src/components/board/board-card.tsx","HarakatMobile/src/components/board/chat-sheet.tsx","HarakatMobile/src/components/board/clamp.ts","HarakatMobile/src/components/board/inbox-list.tsx","HarakatMobile/src/components/chat/action-preview-card.tsx","HarakatMobile/src/components/chat/assistant-markdown.tsx","HarakatMobile/src/components/chat/chat-screen.tsx","HarakatMobile/src/components/chat/chat-sidebar.tsx","HarakatMobile/src/components/chat/composer-actions.ts","HarakatMobile/src/components/chat/voice-recorder.tsx","HarakatMobile/src/components/dashboard/ask-sheet.tsx","HarakatMobile/src/components/dashboard/unknown-widget.tsx","HarakatMobile/src/components/dashboard/widget-card.tsx","HarakatMobile/src/components/external-link.tsx","HarakatMobile/src/components/governance/pending-card.tsx","HarakatMobile/src/components/hint-row.tsx","HarakatMobile/src/components/themed-text.tsx","HarakatMobile/src/components/themed-view.tsx","HarakatMobile/src/components/ui/action-sheet.tsx","HarakatMobile/src/components/ui/button.tsx","HarakatMobile/src/components/ui/collapsible.tsx","HarakatMobile/src/components/ui/dismiss-keyboard-on-drag.tsx","HarakatMobile/src/components/ui/empty-state.tsx","HarakatMobile/src/components/ui/glass-card.tsx","HarakatMobile/src/components/ui/harakat-mark.tsx","HarakatMobile/src/components/ui/icon.tsx","HarakatMobile/src/components/ui/list-row.tsx","HarakatMobile/src/components/ui/load-error.tsx","HarakatMobile/src/components/ui/offline-pill.tsx","HarakatMobile/src/components/ui/read-only-notice.tsx","HarakatMobile/src/components/ui/segmented-control.tsx","HarakatMobile/src/components/ui/skeleton.tsx","HarakatMobile/src/components/ui/stale-strip.tsx","HarakatMobile/src/components/ui/stream-status-strip.tsx","HarakatMobile/src/components/ui/web-handoff-card.tsx","HarakatMobile/src/components/web-badge.tsx","HarakatMobile/src/constants/theme.ts","HarakatMobile/src/global.css","HarakatMobile/src/hooks/use-color-scheme.ts","HarakatMobile/src/hooks/use-color-scheme.web.ts","HarakatMobile/src/hooks/use-theme.ts","HarakatMobile/src/i18n/direction.ts","HarakatMobile/src/i18n/format.ts","HarakatMobile/src/i18n/i18n-context.tsx","HarakatMobile/src/i18n/locale-store.ts","HarakatMobile/src/i18n/messages/ar.json","HarakatMobile/src/i18n/messages/en.json","HarakatMobile/src/i18n/plural.ts","HarakatMobile/src/i18n/routing.ts","HarakatMobile/src/i18n/translate.ts","HarakatMobile/src/lib/api/agent-board.ts","HarakatMobile/src/lib/api/assistant.ts","HarakatMobile/src/lib/api/attachments.ts","HarakatMobile/src/lib/api/auth.ts","HarakatMobile/src/lib/api/client.ts","HarakatMobile/src/lib/api/conversations.ts","HarakatMobile/src/lib/api/dashboard.ts","HarakatMobile/src/lib/api/governance.ts","HarakatMobile/src/lib/api/notifications.ts","HarakatMobile/src/lib/api/sessions.ts","HarakatMobile/src/lib/api/voice.ts","HarakatMobile/src/lib/api/webauthn.ts","HarakatMobile/src/lib/assistant/approval-fields.ts","HarakatMobile/src/lib/auth/auth-context.tsx","HarakatMobile/src/lib/auth/auth-machine.ts","HarakatMobile/src/lib/auth/biometric-lock.tsx","HarakatMobile/src/lib/auth/passkeys.ts","HarakatMobile/src/lib/auth/token-store.ts","HarakatMobile/src/lib/board/reply-target.ts","HarakatMobile/src/lib/board/use-board-stream.ts","HarakatMobile/src/lib/chrome/tab-bar.tsx","HarakatMobile/src/lib/dashboard/widget-data.ts","HarakatMobile/src/lib/dashboard/widget-registry.ts","HarakatMobile/src/lib/deep-link-parker.ts","HarakatMobile/src/lib/deep-links.ts","HarakatMobile/src/lib/handoff.ts","HarakatMobile/src/lib/keyboard/drag-accumulator.ts","HarakatMobile/src/lib/layout.ts","HarakatMobile/src/lib/motion/motion.ts","HarakatMobile/src/lib/net/xhr-stream.ts","HarakatMobile/src/lib/notifications/feed.ts","HarakatMobile/src/lib/notifications/preferences.ts","HarakatMobile/src/lib/offline/net-state.ts","HarakatMobile/src/lib/offline/outbox.ts","HarakatMobile/src/lib/offline/read-cache.ts","HarakatMobile/src/lib/offline/storage.ts","HarakatMobile/src/lib/push.ts","HarakatMobile/src/lib/sse.ts","HarakatMobile/src/lib/stream/backoff.ts","HarakatMobile/src/lib/stream/classify.ts","HarakatMobile/src/lib/stream/connection.ts","HarakatMobile/src/lib/stream/dedupe.ts","HarakatMobile/src/lib/stream/index.ts","HarakatMobile/src/lib/stream/platform-signals.ts","HarakatMobile/src/lib/stream/rate-limit-gate.ts","HarakatMobile/src/lib/stream/replay.ts","HarakatMobile/src/lib/stream/stall-watchdog.ts","HarakatMobile/src/lib/stream/use-resilient-stream.ts","HarakatMobile/src/lib/ui/action-bands.ts","HarakatMobile/src/lib/ui/settle.ts","HarakatMobile/src/lib/ui/skeleton-widths.ts","HarakatMobile/src/lib/ui/use-settle.ts","HarakatMobile/src/lib/ui/view-state.ts","HarakatMobile/src/theme/theme-context.tsx","HarakatMobile/src/theme/tokens.ts"],"HarakatMobile — store":["HarakatMobile/store/README.md","HarakatMobile/store/app-store-privacy.md","HarakatMobile/store/assets-spec.md","HarakatMobile/store/credentials-and-wellknown.md","HarakatMobile/store/ios-privacy-manifest.md","HarakatMobile/store/play-data-safety.md","HarakatMobile/store/screenshots-checklist.md"],"HarakatOffices_Server":["HarakatOffices_Server/Dockerfile","HarakatOffices_Server/QUICK_START_2FA.md","HarakatOffices_Server/_backfill.js","HarakatOffices_Server/_check_all_types.js","HarakatOffices_Server/_check_content.js","HarakatOffices_Server/_check_db.js","HarakatOffices_Server/_check_db2.js","HarakatOffices_Server/_check_doc.js","HarakatOffices_Server/_check_sync.js","HarakatOffices_Server/_check_transcript_status.js","HarakatOffices_Server/_diag_archive_download.js","HarakatOffices_Server/_fix6.js","HarakatOffices_Server/_g2-mint.ts","HarakatOffices_Server/_probe19_driveaudit.js","HarakatOffices_Server/_probe_ws10_app5001.ts","HarakatOffices_Server/_probe_ws10_e2e.cjs","HarakatOffices_Server/_probe_ws5_identity.ts","HarakatOffices_Server/_probe_ws7_app5001.ts","HarakatOffices_Server/_probe_ws7_e2e.cjs","HarakatOffices_Server/_progress.js","HarakatOffices_Server/_query.sql","HarakatOffices_Server/_reset.js","HarakatOffices_Server/_reset_sync.js","HarakatOffices_Server/_smoke_archive_extract.js","HarakatOffices_Server/_smoke_download_bytes.js","HarakatOffices_Server/_smoke_queue.js","HarakatOffices_Server/_start.bat","HarakatOffices_Server/_start.ps1","HarakatOffices_Server/_test_refresh.js","HarakatOffices_Server/_test_token.js","HarakatOffices_Server/_verify_sync.js","HarakatOffices_Server/_wipe_sync_data.js","HarakatOffices_Server/check-providers.js","HarakatOffices_Server/check-zoho.js","HarakatOffices_Server/create-test-support-ticket.js","HarakatOffices_Server/deactivate-test-user.js","HarakatOffices_Server/docker-compose.yml","HarakatOffices_Server/init-features.js","HarakatOffices_Server/init-virtualea-features.ps1","HarakatOffices_Server/package.json","HarakatOffices_Server/seed-startup-accounts.js","HarakatOffices_Server/test-smtp.ts","HarakatOffices_Server/test-zoho.ts","HarakatOffices_Server/tsconfig.json","HarakatOffices_Server/docs/2FA_TESTING_GUIDE.md","HarakatOffices_Server/docs/HERMES_BACKEND_ROLLOUT.md","HarakatOffices_Server/docs/PROVIDER_SERVICES_FLOW_DIAGRAM.md","HarakatOffices_Server/docs/PROVIDER_SERVICES_STORAGE.md","HarakatOffices_Server/docs/SERVICES_STORAGE_QUICK_REF.md","HarakatOffices_Server/docs/SERVICE_STORAGE_COMPLETE_GUIDE.md","HarakatOffices_Server/docs/TWO_FACTOR_AUTH_GUIDE.md","HarakatOffices_Server/prisma/manual/20260616_delegation_token.sql","HarakatOffices_Server/prisma/manual/20260617_embed_batch_item.sql","HarakatOffices_Server/prisma/manual/20260617_enrich_batch_item.sql","HarakatOffices_Server/prisma/manual/20260617_erp_user_id.sql","HarakatOffices_Server/prisma/manual/20260617_tool_registration_parameters.sql","HarakatOffices_Server/prisma/manual/20260617_vector_index_state.sql","HarakatOffices_Server/prisma/manual/20260618_startup_erp_app.sql","HarakatOffices_Server/prisma/manual/20260619_erp_l4_customization.sql","HarakatOffices_Server/prisma/manual/20260619_erp_l4_phase5_quorum.sql","HarakatOffices_Server/prisma/manual/20260621_agent_board.sql","HarakatOffices_Server/prisma/manual/20260621_agent_board_unique_assistant.sql","HarakatOffices_Server/prisma/manual/20260621_shell_v2_prefs.sql","HarakatOffices_Server/prisma/manual/20260623_shell_board_voice.sql","HarakatOffices_Server/prisma/manual/20260624_branch_head.sql","HarakatOffices_Server/prisma/manual/20260624_dashboard_layout.sql","HarakatOffices_Server/prisma/manual/20260624_startup_erp_app_removal.sql","HarakatOffices_Server/prisma/manual/20260624_user_assistant_active.sql","HarakatOffices_Server/prisma/manual/20260629_governance_authoring_request.sql","HarakatOffices_Server/prisma/manual/20260629_user_assistant_procedure.sql","HarakatOffices_Server/prisma/manual/20260630_conversation_lifecycle.sql","HarakatOffices_Server/prisma/manual/20260630_eri_evidence_bundle.sql","HarakatOffices_Server/prisma/manual/20260630_eri_run_taskstate.sql","HarakatOffices_Server/prisma/manual/20260701_conversation_checkpoint.sql","HarakatOffices_Server/prisma/manual/20260702_eri_p7_p10.sql","HarakatOffices_Server/prisma/manual/20260702_eri_tool_gateway.sql","HarakatOffices_Server/prisma/manual/20260702_erp_gaps_fill.sql","HarakatOffices_Server/prisma/manual/20260710_agent_file_creation.sql","HarakatOffices_Server/prisma/manual/20260710_board_v2.sql","HarakatOffices_Server/prisma/manual/20260710_policy_guardrail.sql","HarakatOffices_Server/prisma/manual/20260710_ws7_personal_governance.sql","HarakatOffices_Server/prisma/manual/20260713_company_profile.sql","HarakatOffices_Server/prisma/manual/20260713_employee_offboarding.sql","HarakatOffices_Server/prisma/manual/20260713_employee_purge.sql","HarakatOffices_Server/prisma/manual/20260713_governance_authoring_grant.sql","HarakatOffices_Server/prisma/manual/20260713_governance_creation_session.sql","HarakatOffices_Server/prisma/manual/20260713_org_authority_edits.sql","HarakatOffices_Server/prisma/manual/20260713_org_erp_mirror_v2.sql","HarakatOffices_Server/prisma/manual/20260713_org_erp_reconciliation.sql","HarakatOffices_Server/prisma/manual/20260714_erp_deployment.sql","HarakatOffices_Server/prisma/manual/20260714_skill_scope_model.sql","HarakatOffices_Server/prisma/manual/20260724_admin_typed_provisioning.sql","HarakatOffices_Server/prisma/manual/20260724_vendors_v1.sql","HarakatOffices_Server/prisma/manual/20260725_office_purge_drop.sql","HarakatOffices_Server/prisma/manual/20260725_page_documents.sql","HarakatOffices_Server/prisma/manual/20260725_portal_applicant_token.sql","HarakatOffices_Server/prisma/manual/20260725_report_templates.sql","HarakatOffices_Server/prisma/manual/20260725_startup_erp_app_visibility.sql","HarakatOffices_Server/prisma/manual/20260725_startup_erp_app_visibility_index.sql","HarakatOffices_Server/prisma/manual/20260728_document_workspaces.sql","HarakatOffices_Server/prisma/manual/20260728_one_assistant_per_employee.sql","HarakatOffices_Server/prisma/manual/20260729_hub_pins.sql","HarakatOffices_Server/prisma/manual/20260730_context_events.sql","HarakatOffices_Server/prisma/manual/20260803_agent_attestation.sql","HarakatOffices_Server/prisma/manual/20260803_artifacts.sql","HarakatOffices_Server/prisma/manual/20260803_audience_scope_label.sql","HarakatOffices_Server/prisma/manual/20260803_audit_chain.sql","HarakatOffices_Server/prisma/manual/20260803_automated_turn_claim.sql","HarakatOffices_Server/prisma/manual/20260803_automated_work.sql","HarakatOffices_Server/prisma/manual/20260803_conversation_thread_axes.sql","HarakatOffices_Server/prisma/manual/20260803_governance_settings.sql","HarakatOffices_Server/prisma/manual/20260803_packs.sql","HarakatOffices_Server/prisma/manual/20260803_room_bridge.sql","HarakatOffices_Server/prisma/manual/20260803_room_signing.sql","HarakatOffices_Server/prisma/manual/20260803_room_threads.sql","HarakatOffices_Server/prisma/manual/20260803_rooms.sql","HarakatOffices_Server/prisma/manual/20260803_tenant_scoping.sql","HarakatOffices_Server/prisma/manual/20260803_toolexec_tenant_key.sql","HarakatOffices_Server/prisma/manual/20260804_action_preview_why.sql","HarakatOffices_Server/prisma/manual/20260804_admin_console_gaps.sql","HarakatOffices_Server/prisma/manual/20260804_admin_session.sql","HarakatOffices_Server/prisma/manual/20260804_agent_watches.sql","HarakatOffices_Server/prisma/manual/20260804_corpus_v2.sql","HarakatOffices_Server/prisma/manual/20260804_mail_pipeline.sql","HarakatOffices_Server/prisma/manual/20260804_scheduled_job_dispatch.sql","HarakatOffices_Server/prisma/manual/20260804_tenant_container.sql","HarakatOffices_Server/prisma/manual/20260805_connector_notice.sql","HarakatOffices_Server/prisma/manual/20260805_connector_notice_tenant_fk.sql","HarakatOffices_Server/prisma/manual/20260806_mail_domain.sql","HarakatOffices_Server/prisma/manual/20260813_company_domain.sql","HarakatOffices_Server/prisma/manual/20260813_document_design_rules.sql","HarakatOffices_Server/prisma/manual/20260813_knowledge_external_unique.sql","HarakatOffices_Server/prisma/manual/20260813_project_rooms.sql","HarakatOffices_Server/prisma/manual/20260813_relay_target.sql","HarakatOffices_Server/prisma/migrations/20251014160702_init/migration.sql","HarakatOffices_Server/prisma/migrations/20251017171744_add_admin_profile_and_notifications/migration.sql","HarakatOffices_Server/prisma/migrations/20251017175539_add_admin_office_access/migration.sql","HarakatOffices_Server/prisma/migrations/20251017203138_add_provider_services/migration.sql","HarakatOffices_Server/prisma/migrations/20251017213825_add_metadata_to_provider/migration.sql","HarakatOffices_Server/prisma/migrations/20251019103715_add_office_users/migration.sql","HarakatOffices_Server/prisma/migrations/20251019111621_add_marketplace_models/migration.sql","HarakatOffices_Server/prisma/migrations/20251019113136_add_document_management/migration.sql","HarakatOffices_Server/prisma/migrations/20251019190139_add_learning_hub/migration.sql","HarakatOffices_Server/prisma/migrations/20251026182619_add_startup_credits_and_agents/migration.sql","HarakatOffices_Server/prisma/migrations/20251027090716_add_startup_users/migration.sql","HarakatOffices_Server/prisma/migrations/20251027093835_add_provider_proposal_request_type/migration.sql","HarakatOffices_Server/prisma/migrations/20251027105120_add_agent_proposal_request_type/migration.sql","HarakatOffices_Server/prisma/migrations/20251027142125_update_office_user_roles/migration.sql","HarakatOffices_Server/prisma/migrations/20251028192557_add_two_factor_auth/migration.sql","HarakatOffices_Server/prisma/migrations/20251028195125_add_password_change_verification/migration.sql","HarakatOffices_Server/prisma/migrations/20251030204449_add_startup_manager_junction/migration.sql","HarakatOffices_Server/prisma/migrations/20251031180731_shmad/migration.sql","HarakatOffices_Server/prisma/migrations/20251031211047_add_assistant_conversations/migration.sql","HarakatOffices_Server/prisma/migrations/20251031221228_add_credit_limit_to_office/migration.sql","HarakatOffices_Server/prisma/migrations/20251101120035_add_user_assistant/migration.sql","HarakatOffices_Server/prisma/migrations/20251101122118_add_assistant_workspace/migration.sql","HarakatOffices_Server/prisma/migrations/20251101123940_add_startup_service_requests/migration.sql","HarakatOffices_Server/prisma/migrations/20251101124007_add_startup_service_requests/migration.sql","HarakatOffices_Server/prisma/migrations/20251101130641_change_provider_to_company/migration.sql","HarakatOffices_Server/prisma/migrations/20251102174617_add_credit_limits/migration.sql","HarakatOffices_Server/prisma/migrations/20251114160957_add_startup_manager/migration.sql","HarakatOffices_Server/prisma/migrations/20251114185046_add_virtualea_features/migration.sql","HarakatOffices_Server/prisma/migrations/20260325065210_add_office_provider_service/migration.sql","HarakatOffices_Server/prisma/migrations/20260325220741_add_startup_feature_access/migration.sql","HarakatOffices_Server/prisma/migrations/20260327210413_add_startup_user_level/migration.sql","HarakatOffices_Server/prisma/migrations/20260329113153_add_scenarios/migration.sql","HarakatOffices_Server/prisma/migrations/20260401145739_branch_hierarchy_drives_tasks/migration.sql","HarakatOffices_Server/prisma/migrations/20260412124415_add_missing_models_and_columns/migration.sql","HarakatOffices_Server/prisma/migrations/20260413093000_startup_email_columns_backfill/migration.sql","HarakatOffices_Server/prisma/migrations/20260413100000_office_user_invites/migration.sql","HarakatOffices_Server/prisma/migrations/20260517000000_add_audit_entry/migration.sql","HarakatOffices_Server/prisma/migrations/20260517010000_add_mutation_proposal/migration.sql","HarakatOffices_Server/prisma/migrations/20260517020000_phase_b_vessel_foundation/migration.sql","HarakatOffices_Server/prisma/migrations/20260517030000_phase_c_inter_assistant_fabric/migration.sql","HarakatOffices_Server/prisma/migrations/20260517040000_phase_e_procedures/migration.sql","HarakatOffices_Server/prisma/migrations/20260517050000_phase_f_mcp_runtime/migration.sql","HarakatOffices_Server/prisma/migrations/20260517060000_phase_g_autoML/migration.sql","HarakatOffices_Server/prisma/migrations/20260517070000_phase_g_training_sandbox/migration.sql","HarakatOffices_Server/prisma/migrations/20260517080000_phase_g_startup_user_webauthn/migration.sql","HarakatOffices_Server/prisma/migrations/20260518000000_phase_g_augmentation/migration.sql","HarakatOffices_Server/prisma/migrations/20260518010000_phase_h_onboarding_state/migration.sql","HarakatOffices_Server/prisma/migrations/20260518020000_startup_branch_hierarchy/migration.sql","HarakatOffices_Server/prisma/migrations/20260518030000_phase_h_template_access/migration.sql","HarakatOffices_Server/prisma/migrations/20260518040000_policy_conflict_and_tool_registration/migration.sql","HarakatOffices_Server/prisma/migrations/20260519000000_parsed_doc_attempts/migration.sql","HarakatOffices_Server/prisma/migrations/20260521000000_retrieval_v2_models/migration.sql","HarakatOffices_Server/prisma/migrations/20260521010000_retrieval_v2_tenant_flag/migration.sql","HarakatOffices_Server/prisma/migrations/20260521020000_search_index_toc_nullable_node/migration.sql","HarakatOffices_Server/prisma/migrations/20260522000000_agent_directory_scenario_jobs/migration.sql","HarakatOffices_Server/prisma/migrations/20260523000000_startup_hermes_enabled/migration.sql","HarakatOffices_Server/prisma/migrations/20260524000000_email_reply_triage/migration.sql","HarakatOffices_Server/prisma/migrations/20260525000000_add_meeting_recording_fields/migration.sql","HarakatOffices_Server/prisma/migrations/20260526000000_add_meeting_transcript_lifecycle/migration.sql","HarakatOffices_Server/prisma/migrations/20260527000000_kb_node_meeting_source_key/migration.sql","HarakatOffices_Server/prisma/migrations/20260528000000_meeting_auto_record_rule/migration.sql","HarakatOffices_Server/prisma/migrations/20260529000000_add_usage_event_telemetry/migration.sql","HarakatOffices_Server/prisma/migrations/20260530000000_integration_needs_reauth/migration.sql","HarakatOffices_Server/prisma/migrations/20260603150000_add_ocr_batch_item/migration.sql","HarakatOffices_Server/prisma/migrations/20260616_delegation_token/migration.sql","HarakatOffices_Server/prisma/migrations/20260617_enrich_batch_item/migration.sql","HarakatOffices_Server/prisma/migrations/20260617_vector_index_state/migration.sql","HarakatOffices_Server/prisma/migrations/20260618_startup_erp_app/migration.sql","HarakatOffices_Server/prisma/migrations/20260625204849_startupuser_2fa/migration.sql","HarakatOffices_Server/prisma/migrations/20260625210000_session_metadata/migration.sql","HarakatOffices_Server/prisma/migrations/20260626000000_integration_scope_setting/migration.sql","HarakatOffices_Server/prisma/migrations/20260629043600_procedure_run_parallel/migration.sql","HarakatOffices_Server/prisma/migrations/20260705000000_onboarding_startup_profile/migration.sql","HarakatOffices_Server/prisma/migrations/20260705100000_onboarding_meeting_prefs/migration.sql","HarakatOffices_Server/prisma/migrations/20260705200000_drive_acl_entry/migration.sql","HarakatOffices_Server/prisma/migrations/20260705210000_notification_spine/migration.sql","HarakatOffices_Server/prisma/migrations/20260705220000_mobile_refresh_tokens/migration.sql","HarakatOffices_Server/prisma/migrations/20260708120000_conversation_ephemeral/migration.sql","HarakatOffices_Server/prisma/migrations/migration_lock.toml","HarakatOffices_Server/prisma/schema.prisma","HarakatOffices_Server/prisma/seed-complete.ts","HarakatOffices_Server/prisma/seed.ts","HarakatOffices_Server/prisma/tenant-placement-baseline.json","HarakatOffices_Server/prisma/tenant-scoping-baseline.json","HarakatOffices_Server/scripts/b3_create_sentinel_check.ts","HarakatOffices_Server/scripts/board-v2-selftest.ts","HarakatOffices_Server/scripts/force-transcript-batch.ts","HarakatOffices_Server/scripts/merge-weekly-conversations.ts","HarakatOffices_Server/scripts/merge-weekly-threads.ts","HarakatOffices_Server/scripts/procedure-assignee-live.sh","HarakatOffices_Server/scripts/retitle-weekly-threads.ts","HarakatOffices_Server/scripts/seed-tool-registry.ts","HarakatOffices_Server/scripts/test-mcp-access.ts","HarakatOffices_Server/scripts/verify-url-normalizer.ts","HarakatOffices_Server/src/app.ts","HarakatOffices_Server/src/core/access-key/assistant-claims.ts","HarakatOffices_Server/src/core/access-key/canSee.ts","HarakatOffices_Server/src/core/access-key/deriver.ts","HarakatOffices_Server/src/core/access-key/index.ts","HarakatOffices_Server/src/core/access-key/node-tier.ts","HarakatOffices_Server/src/core/access-key/openfga/client.ts","HarakatOffices_Server/src/core/access-key/openfga/governance.ts","HarakatOffices_Server/src/core/access-key/openfga/index.ts","HarakatOffices_Server/src/core/access-key/openfga/model.fga","HarakatOffices_Server/src/core/access-key/openfga/model.ts","HarakatOffices_Server/src/core/access-key/openfga/seed.ts","HarakatOffices_Server/src/core/access-key/openfga/tuples.ts","HarakatOffices_Server/src/core/access-key/overrides.ts","HarakatOffices_Server/src/core/access-key/tenant-owner.ts","HarakatOffices_Server/src/core/access-key/types.ts","HarakatOffices_Server/src/core/access-key/workspace-access.ts","HarakatOffices_Server/src/core/admin-session/decide.ts","HarakatOffices_Server/src/core/admin-session/index.ts","HarakatOffices_Server/src/core/admin-session/store.ts","HarakatOffices_Server/src/core/analytics.ts","HarakatOffices_Server/src/core/artifacts/artifacts.service.ts","HarakatOffices_Server/src/core/artifacts/durability.ts","HarakatOffices_Server/src/core/artifacts/index.ts","HarakatOffices_Server/src/core/artifacts/local/docker-runtime.ts","HarakatOffices_Server/src/core/artifacts/manage.ts","HarakatOffices_Server/src/core/artifacts/name.ts","HarakatOffices_Server/src/core/artifacts/reach.ts","HarakatOffices_Server/src/core/artifacts/runtime.ts","HarakatOffices_Server/src/core/artifacts/snapshot.ts","HarakatOffices_Server/src/core/artifacts/store.ts","HarakatOffices_Server/src/core/artifacts/types.ts","HarakatOffices_Server/src/core/audit-log/actions.ts","HarakatOffices_Server/src/core/audit-log/chain.ts","HarakatOffices_Server/src/core/audit-log/hash.ts","HarakatOffices_Server/src/core/audit-log/index.ts","HarakatOffices_Server/src/core/audit-log/writer.ts","HarakatOffices_Server/src/core/authority/tenant-owner-http.ts","HarakatOffices_Server/src/core/authority/tenant-owner.ts","HarakatOffices_Server/src/core/calendar/google-calendar.service.ts","HarakatOffices_Server/src/core/config/env.ts","HarakatOffices_Server/src/core/config/local-guard.test.ts","HarakatOffices_Server/src/core/config/local-guard.ts","HarakatOffices_Server/src/core/config/prisma.ts","HarakatOffices_Server/src/core/contacts/google-contacts.service.ts","HarakatOffices_Server/src/core/corpus-v2/columns.ts","HarakatOffices_Server/src/core/corpus-v2/content-hash.ts","HarakatOffices_Server/src/core/corpus-v2/index.ts","HarakatOffices_Server/src/core/corpus-v2/mount-path.ts","HarakatOffices_Server/src/core/corpus-v2/owed-work.ts","HarakatOffices_Server/src/core/corpus-v2/reading.ts","HarakatOffices_Server/src/core/corpus-v2/record.ts","HarakatOffices_Server/src/core/corpus-v2/store.ts","HarakatOffices_Server/src/core/corpus-v2/vector-target.ts","HarakatOffices_Server/src/core/docker/docker-client.ts","HarakatOffices_Server/src/core/document-design/index.ts","HarakatOffices_Server/src/core/drive/corpus-tree.ts","HarakatOffices_Server/src/core/drive/drive-acl.integration.test.ts","HarakatOffices_Server/src/core/drive/drive-acl.service.ts","HarakatOffices_Server/src/core/drive/drive-heartbeat.service.ts","HarakatOffices_Server/src/core/drive/edit-stability.test.ts","HarakatOffices_Server/src/core/drive/edit-stability.ts","HarakatOffices_Server/src/core/drive/folder-cache.ts","HarakatOffices_Server/src/core/drive/google-drive.service.ts","HarakatOffices_Server/src/core/drive/sync-log.ts","HarakatOffices_Server/src/core/email/email.service.ts","HarakatOffices_Server/src/core/email/templates/invitation.ts","HarakatOffices_Server/src/core/governance/command-policy.ts","HarakatOffices_Server/src/core/governance/compose.ts","HarakatOffices_Server/src/core/governance/descriptor.ts","HarakatOffices_Server/src/core/governance/enforcement.ts","HarakatOffices_Server/src/core/governance/index.ts","HarakatOffices_Server/src/core/governance/registry.ts","HarakatOffices_Server/src/core/governance/scope.ts","HarakatOffices_Server/src/core/governance/shadow.ts","HarakatOffices_Server/src/core/governance/store.ts","HarakatOffices_Server/src/core/inbound/index.ts","HarakatOffices_Server/src/core/inference/inference-host.service.ts","HarakatOffices_Server/src/core/integrations/connector-status.ts","HarakatOffices_Server/src/core/integrations/google-oauth.service.ts","HarakatOffices_Server/src/core/lifecycle/budget.ts","HarakatOffices_Server/src/core/lifecycle/drain.ts","HarakatOffices_Server/src/core/lifecycle/index.ts","HarakatOffices_Server/src/core/lifecycle/inflight.ts","HarakatOffices_Server/src/core/lifecycle/phase.ts","HarakatOffices_Server/src/core/lifecycle/signals.ts","HarakatOffices_Server/src/core/lifecycle/stream-surfaces.ts","HarakatOffices_Server/src/core/live-authority/agent-grant.ts","HarakatOffices_Server/src/core/live-authority/automated-jwt.ts","HarakatOffices_Server/src/core/live-authority/index.ts","HarakatOffices_Server/src/core/live-authority/live-person.ts","HarakatOffices_Server/src/core/live-authority/org-promotion.ts","HarakatOffices_Server/src/core/live-authority/request-origin.ts","HarakatOffices_Server/src/core/live-authority/shared-scope.ts","HarakatOffices_Server/src/core/live-authority/synthetic-principal.ts","HarakatOffices_Server/src/core/live-authority/turn-origin.ts","HarakatOffices_Server/src/core/mail/adapters/agenticmail.adapter.ts","HarakatOffices_Server/src/core/mail/adapters/agentmail.adapter.ts","HarakatOffices_Server/src/core/mail/adapters/loopback.adapter.ts","HarakatOffices_Server/src/core/mail/adapters/registry.ts","HarakatOffices_Server/src/core/mail/adapters/ses.transport.ts","HarakatOffices_Server/src/core/mail/address.ts","HarakatOffices_Server/src/core/mail/attachments.service.ts","HarakatOffices_Server/src/core/mail/audit.ts","HarakatOffices_Server/src/core/mail/causes.ts","HarakatOffices_Server/src/core/mail/domain-name.ts","HarakatOffices_Server/src/core/mail/domain.service.ts","HarakatOffices_Server/src/core/mail/forward.ts","HarakatOffices_Server/src/core/mail/inbound.service.ts","HarakatOffices_Server/src/core/mail/index.ts","HarakatOffices_Server/src/core/mail/ingest.service.ts","HarakatOffices_Server/src/core/mail/judge-rubric.ts","HarakatOffices_Server/src/core/mail/judge.ts","HarakatOffices_Server/src/core/mail/lifecycle.service.ts","HarakatOffices_Server/src/core/mail/mailbox.service.ts","HarakatOffices_Server/src/core/mail/mount.ts","HarakatOffices_Server/src/core/mail/outbound.service.ts","HarakatOffices_Server/src/core/mail/provider.ts","HarakatOffices_Server/src/core/mail/relay-map.ts","HarakatOffices_Server/src/core/mail/resolver.ts","HarakatOffices_Server/src/core/mail/search.service.ts","HarakatOffices_Server/src/core/mail/ses-identity.service.ts","HarakatOffices_Server/src/core/mail/store.ts","HarakatOffices_Server/src/core/mail/threading.ts","HarakatOffices_Server/src/core/mail/wake.ts","HarakatOffices_Server/src/core/outbound/index.ts","HarakatOffices_Server/src/core/outbound/inventory.ts","HarakatOffices_Server/src/core/pagination/cursor.ts","HarakatOffices_Server/src/core/pagination/http.ts","HarakatOffices_Server/src/core/pagination/index.ts","HarakatOffices_Server/src/core/pagination/inventory.ts","HarakatOffices_Server/src/core/pagination/keyset.ts","HarakatOffices_Server/src/core/pagination/request.ts","HarakatOffices_Server/src/core/policy/conflict-recorder.ts","HarakatOffices_Server/src/core/prompt-inspector/capture.ts","HarakatOffices_Server/src/core/prompt-inspector/envelope.ts","HarakatOffices_Server/src/core/prompt-inspector/index.ts","HarakatOffices_Server/src/core/prompt-inspector/masking.ts","HarakatOffices_Server/src/core/prompt-inspector/store.ts","HarakatOffices_Server/src/core/queue/byte-gate.ts","HarakatOffices_Server/src/core/queue/connection.ts","HarakatOffices_Server/src/core/queue/index.ts","HarakatOffices_Server/src/core/queue/queues.ts","HarakatOffices_Server/src/core/queue/types.ts","HarakatOffices_Server/src/core/queue/workers/archive-extract.worker.ts","HarakatOffices_Server/src/core/queue/workers/clean-document.worker.ts","HarakatOffices_Server/src/core/queue/workers/drive-download.worker.ts","HarakatOffices_Server/src/core/queue/workers/embed-batch-poll.worker.ts","HarakatOffices_Server/src/core/queue/workers/enrich-batch-poll.worker.ts","HarakatOffices_Server/src/core/queue/workers/enrich-document.worker.ts","HarakatOffices_Server/src/core/queue/workers/entity-extract.worker.ts","HarakatOffices_Server/src/core/queue/workers/folder-rollup.worker.ts","HarakatOffices_Server/src/core/queue/workers/ocr-batch-poll.worker.ts","HarakatOffices_Server/src/core/queue/workers/parse-extract.worker.ts","HarakatOffices_Server/src/core/queue/workers/recurring-dispatch.worker.ts","HarakatOffices_Server/src/core/queue/workers/retrieval-v2-helpers.ts","HarakatOffices_Server/src/core/queue/workers/scheduled-agent.worker.ts","HarakatOffices_Server/src/core/queue/workers/search-index.worker.ts","HarakatOffices_Server/src/core/queue/workers/toc-rebuild.worker.ts","HarakatOffices_Server/src/core/queue/workers/vector-index.worker.ts","HarakatOffices_Server/src/core/queue/workers/watch-poll.worker.ts","HarakatOffices_Server/src/core/sandbox/backend.ts","HarakatOffices_Server/src/core/sandbox/credentials.ts","HarakatOffices_Server/src/core/sandbox/egress-policy.ts","HarakatOffices_Server/src/core/sandbox/index.ts","HarakatOffices_Server/src/core/sandbox/local/docker.ts","HarakatOffices_Server/src/core/sandbox/local/local-backend.ts","HarakatOffices_Server/src/core/sandbox/login.ts","HarakatOffices_Server/src/core/sandbox/process.ts","HarakatOffices_Server/src/core/sandbox/proxy/config.ts","HarakatOffices_Server/src/core/sandbox/proxy/proxy-manager.ts","HarakatOffices_Server/src/core/sandbox/proxy/proxy-worker.cjs","HarakatOffices_Server/src/core/sandbox/proxy/worker-bridge.ts","HarakatOffices_Server/src/core/sandbox/routing.ts","HarakatOffices_Server/src/core/sandbox/sandbox.service.ts","HarakatOffices_Server/src/core/sandbox/scope.ts","HarakatOffices_Server/src/core/sandbox/types.ts","HarakatOffices_Server/src/core/security/delegation/attestation.ts","HarakatOffices_Server/src/core/security/delegation/authority.ts","HarakatOffices_Server/src/core/security/delegation/delegation.service.ts","HarakatOffices_Server/src/core/security/delegation/index.ts","HarakatOffices_Server/src/core/security/delegation/scope.ts","HarakatOffices_Server/src/core/security/egress/guarded-fetch.ts","HarakatOffices_Server/src/core/security/egress/index.ts","HarakatOffices_Server/src/core/security/egress/inventory.ts","HarakatOffices_Server/src/core/security/egress/ip-classify.ts","HarakatOffices_Server/src/core/security/egress/scrub.ts","HarakatOffices_Server/src/core/security/egress/url-policy.ts","HarakatOffices_Server/src/core/security/kms/envelope.ts","HarakatOffices_Server/src/core/security/kms/kms-cipher.ts","HarakatOffices_Server/src/core/security/kms/openbao-client.ts","HarakatOffices_Server/src/core/security/link/audit-chain.ts","HarakatOffices_Server/src/core/security/link/disclosure-gate.ts","HarakatOffices_Server/src/core/security/link/index.ts","HarakatOffices_Server/src/core/security/link/link.service.ts","HarakatOffices_Server/src/core/security/link/types.ts","HarakatOffices_Server/src/core/security/screening/index.ts","HarakatOffices_Server/src/core/security/screening/provenance.ts","HarakatOffices_Server/src/core/security/screening/rubric.ts","HarakatOffices_Server/src/core/security/screening/screen.ts","HarakatOffices_Server/src/core/security/secret-cipher.ts","HarakatOffices_Server/src/core/security/source-auth/ai-fetch.ts","HarakatOffices_Server/src/core/security/source-auth/config.ts","HarakatOffices_Server/src/core/security/source-auth/index.ts","HarakatOffices_Server/src/core/security/source-auth/sign.ts","HarakatOffices_Server/src/core/security/spiffe/index.ts","HarakatOffices_Server/src/core/security/spiffe/mutual-auth.ts","HarakatOffices_Server/src/core/security/spiffe/spiffe-id.ts","HarakatOffices_Server/src/core/security/spiffe/svid.ts","HarakatOffices_Server/src/core/seed/platform-skills.ts","HarakatOffices_Server/src/core/services/email.service.ts","HarakatOffices_Server/src/core/stream/index.ts","HarakatOffices_Server/src/core/stream/replay-log.ts","HarakatOffices_Server/src/core/tenancy/operator-global.ts","HarakatOffices_Server/src/core/tenancy/schema-model.ts","HarakatOffices_Server/src/core/tenancy/tenant-boundary.ts","HarakatOffices_Server/src/core/tenancy/tenant-scoping-rules.ts","HarakatOffices_Server/src/core/tenancy/tenant-surface.ts","HarakatOffices_Server/src/core/tenant-container/credentials.ts","HarakatOffices_Server/src/core/tenant-container/datasource.ts","HarakatOffices_Server/src/core/tenant-container/lifecycle.ts","HarakatOffices_Server/src/core/tenant-container/mover.ts","HarakatOffices_Server/src/core/tenant-container/placement.ts","HarakatOffices_Server/src/core/tenant-container/provision.ts","HarakatOffices_Server/src/core/tenant-container/route.ts","HarakatOffices_Server/src/core/tenant-container/schema-sources.ts","HarakatOffices_Server/src/core/tenant-container/transitions.ts","HarakatOffices_Server/src/core/text/sanitize.ts","HarakatOffices_Server/src/core/triggers/axes.ts","HarakatOffices_Server/src/core/triggers/claim-store.ts","HarakatOffices_Server/src/core/triggers/consent-store.ts","HarakatOffices_Server/src/core/triggers/consent.ts","HarakatOffices_Server/src/core/triggers/conversation-lock.ts","HarakatOffices_Server/src/core/triggers/delivery.ts","HarakatOffices_Server/src/core/triggers/destination.ts","HarakatOffices_Server/src/core/triggers/dispatch-store.ts","HarakatOffices_Server/src/core/triggers/event-kind.ts","HarakatOffices_Server/src/core/triggers/index.ts","HarakatOffices_Server/src/core/triggers/keys.ts","HarakatOffices_Server/src/core/triggers/memory-guard.ts","HarakatOffices_Server/src/core/triggers/outbound-rate.ts","HarakatOffices_Server/src/core/triggers/provenance.ts","HarakatOffices_Server/src/core/triggers/recurring-dispatcher.ts","HarakatOffices_Server/src/core/triggers/run-automated-turn.ts","HarakatOffices_Server/src/core/triggers/schedule-expression.ts","HarakatOffices_Server/src/core/triggers/silence.ts","HarakatOffices_Server/src/core/triggers/sub-thread.ts","HarakatOffices_Server/src/core/triggers/thread-open.ts","HarakatOffices_Server/src/core/triggers/types.ts","HarakatOffices_Server/src/core/voice/voice-storage.service.ts","HarakatOffices_Server/src/core/voice/voice-sweep.service.ts","HarakatOffices_Server/src/core/watches/index.ts","HarakatOffices_Server/src/core/watches/poller.ts","HarakatOffices_Server/src/core/watches/subjects.ts","HarakatOffices_Server/src/core/watches/types.ts","HarakatOffices_Server/src/core/watches/watch-store.ts","HarakatOffices_Server/src/core/write-receipt/erp.ts","HarakatOffices_Server/src/core/write-receipt/index.ts","HarakatOffices_Server/src/lib/prisma.ts","HarakatOffices_Server/src/middleware/access-claims.ts","HarakatOffices_Server/src/middleware/agent-capability.ts","HarakatOffices_Server/src/middleware/auth.ts","HarakatOffices_Server/src/middleware/cors.ts","HarakatOffices_Server/src/middleware/drain.ts","HarakatOffices_Server/src/middleware/errorHandler.ts","HarakatOffices_Server/src/middleware/meeting-callback-auth.ts","HarakatOffices_Server/src/middleware/org-authority-barrier.ts","HarakatOffices_Server/src/middleware/rate-limit.ts","HarakatOffices_Server/src/middleware/request-timing.ts","HarakatOffices_Server/src/middleware/startup-auth.ts","HarakatOffices_Server/src/modules/admin/admin.controller.ts","HarakatOffices_Server/src/modules/admin/admin.outbound.ts","HarakatOffices_Server/src/modules/admin/auth.controller.ts","HarakatOffices_Server/src/modules/admin/inference.routes.ts","HarakatOffices_Server/src/modules/admin/last-admin.ts","HarakatOffices_Server/src/modules/admin/providers/providers.controller.ts","HarakatOffices_Server/src/modules/admin/providers/providers.outbound.ts","HarakatOffices_Server/src/modules/admin/providers/providers.routes.ts","HarakatOffices_Server/src/modules/admin/provisioning.service.ts","HarakatOffices_Server/src/modules/admin/queues.routes.ts","HarakatOffices_Server/src/modules/admin/services.controller.ts","HarakatOffices_Server/src/modules/admin/startups.controller.ts","HarakatOffices_Server/src/modules/admin/startups.routes.ts","HarakatOffices_Server/src/modules/admin/support.controller.ts","HarakatOffices_Server/src/modules/admin/tenant-profile.service.ts","HarakatOffices_Server/src/modules/agent-board/agent-board.routes.ts","HarakatOffices_Server/src/modules/agent-board/avatar.test.ts","HarakatOffices_Server/src/modules/agent-board/avatar.ts","HarakatOffices_Server/src/modules/agent-board/board-item.controller.ts","HarakatOffices_Server/src/modules/agent-board/board-item.inbound.ts","HarakatOffices_Server/src/modules/agent-board/board-item.outbound.ts","HarakatOffices_Server/src/modules/agent-board/board-item.routes.ts","HarakatOffices_Server/src/modules/agent-board/board-item.service.test.ts","HarakatOffices_Server/src/modules/agent-board/board-item.service.ts","HarakatOffices_Server/src/modules/agent-board/conversation-state.controller.ts","HarakatOffices_Server/src/modules/agent-board/conversation-state.service.test.ts","HarakatOffices_Server/src/modules/agent-board/conversation-state.service.ts","HarakatOffices_Server/src/modules/agent-board/inbox-ephemeral.integration.test.ts","HarakatOffices_Server/src/modules/agent-board/inbox.controller.ts","HarakatOffices_Server/src/modules/agent-board/inbox.routes.ts","HarakatOffices_Server/src/modules/agent-board/inbox.service.test.ts","HarakatOffices_Server/src/modules/agent-board/inbox.service.ts","HarakatOffices_Server/src/modules/agent-board/notification.service.test.ts","HarakatOffices_Server/src/modules/agent-board/notification.service.ts","HarakatOffices_Server/src/modules/agent-board/realtime.test.ts","HarakatOffices_Server/src/modules/agent-board/realtime.ts","HarakatOffices_Server/src/modules/agent-board/redis-conn.ts","HarakatOffices_Server/src/modules/agent-board/single-assistant.test.ts","HarakatOffices_Server/src/modules/agent-board/single-assistant.ts","HarakatOffices_Server/src/modules/agent-board/stream.controller.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.controller.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.outbound.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.routes.ts","HarakatOffices_Server/src/modules/agent-directory/agent-directory.service.ts","HarakatOffices_Server/src/modules/agent-directory/agent-session-cleanup.service.ts","HarakatOffices_Server/src/modules/agent-directory/agent-session-docker.service.ts","HarakatOffices_Server/src/modules/ai-analytics/ai-analytics.controller.ts","HarakatOffices_Server/src/modules/ai-analytics/ai-analytics.routes.ts","HarakatOffices_Server/src/modules/ai-analytics/ai-analytics.service.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.controller.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.inbound.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.outbound.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.proxy.ts","HarakatOffices_Server/src/modules/artifacts/artifacts.routes.ts","HarakatOffices_Server/src/modules/artifacts/people.ts","HarakatOffices_Server/src/modules/artifacts/viewer-session.ts","HarakatOffices_Server/src/modules/audit/audit.controller.ts","HarakatOffices_Server/src/modules/audit/audit.outbound.ts","HarakatOffices_Server/src/modules/audit/audit.routes.ts","HarakatOffices_Server/src/modules/audit/audit.service.ts","HarakatOffices_Server/src/modules/autoload/autoload.controller.ts","HarakatOffices_Server/src/modules/autoload/autoload.outbound.ts","HarakatOffices_Server/src/modules/autoload/autoload.routes.ts","HarakatOffices_Server/src/modules/autoload/autoload.service.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.controller.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.inbound.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.routes.ts","HarakatOffices_Server/src/modules/automated-work/automated-work.service.ts","HarakatOffices_Server/src/modules/automated-work/schedule-status.ts","HarakatOffices_Server/src/modules/automated-work/schedules.service.ts","HarakatOffices_Server/src/modules/automated-work/watches.service.ts","HarakatOffices_Server/src/modules/board/weekly-rollup.service.ts","HarakatOffices_Server/src/modules/capabilities/augmentation.service.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.controller.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.routes.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.service.ts","HarakatOffices_Server/src/modules/capabilities/capabilities.types.ts","HarakatOffices_Server/src/modules/conversation-access/decide.ts","HarakatOffices_Server/src/modules/conversation-access/index.ts","HarakatOffices_Server/src/modules/conversation-access/store.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/conversation-lifecycle.service.integration.test.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/conversation-lifecycle.service.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/lifecycle-schema.integration.test.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/participants.service.ts","HarakatOffices_Server/src/modules/conversation-lifecycle/thread-axes.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-authorize.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-producer.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-recall.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-search.service.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-triggers.ts","HarakatOffices_Server/src/modules/conversation-memory/checkpoint-vector.service.ts","HarakatOffices_Server/src/modules/conversation-memory/section-tree.ts","HarakatOffices_Server/src/modules/dashboard/apply-layout.integration.test.ts","HarakatOffices_Server/src/modules/dashboard/dashboard-layout.integration.test.ts","HarakatOffices_Server/src/modules/dashboard/dashboard-layout.service.ts","HarakatOffices_Server/src/modules/dashboard/dashboard.controller.ts","HarakatOffices_Server/src/modules/dashboard/widget-data.integration.test.ts","HarakatOffices_Server/src/modules/dashboard/widget-data.outbound.ts","HarakatOffices_Server/src/modules/dashboard/widget-data.service.ts","HarakatOffices_Server/src/modules/dashboard/widget-registry.test.ts","HarakatOffices_Server/src/modules/dashboard/widget-registry.ts","HarakatOffices_Server/src/modules/document/agent-images.ts","HarakatOffices_Server/src/modules/document/agent-plan.ts","HarakatOffices_Server/src/modules/document/agent-render.ts","HarakatOffices_Server/src/modules/document/branding.ts","HarakatOffices_Server/src/modules/document/document.types.ts","HarakatOffices_Server/src/modules/document/format.ts","HarakatOffices_Server/src/modules/document/gather.ts","HarakatOffices_Server/src/modules/document/gotenberg.client.ts","HarakatOffices_Server/src/modules/document/index.ts","HarakatOffices_Server/src/modules/document/labels.ts","HarakatOffices_Server/src/modules/document/mappers.ts","HarakatOffices_Server/src/modules/document/registry.ts","HarakatOffices_Server/src/modules/document/render.ts","HarakatOffices_Server/src/modules/document/templates/html.ts","HarakatOffices_Server/src/modules/document/templates/index.ts","HarakatOffices_Server/src/modules/document/templates/invoice.ts","HarakatOffices_Server/src/modules/document/templates/layout.ts","HarakatOffices_Server/src/modules/document/templates/payslip.ts","HarakatOffices_Server/src/modules/document/templates/purchase-order.ts","HarakatOffices_Server/src/modules/document/templates/report-template.ts","HarakatOffices_Server/src/modules/document/templates/sales.ts","HarakatOffices_Server/src/modules/eri/eri-inspection.integration.test.ts","HarakatOffices_Server/src/modules/eri/eri-schema.integration.test.ts","HarakatOffices_Server/src/modules/eri/eri.controller.ts","HarakatOffices_Server/src/modules/eri/eri.outbound.ts","HarakatOffices_Server/src/modules/eri/eri.service.integration.test.ts","HarakatOffices_Server/src/modules/eri/eri.service.ts","HarakatOffices_Server/src/modules/eri/learning.integration.test.ts","HarakatOffices_Server/src/modules/eri/learning.service.ts","HarakatOffices_Server/src/modules/eri/ops.controller.ts","HarakatOffices_Server/src/modules/eri/ops.integration.test.ts","HarakatOffices_Server/src/modules/eri/ops.outbound.ts","HarakatOffices_Server/src/modules/eri/ops.service.ts","HarakatOffices_Server/src/modules/erp/company-mirror-decision.ts","HarakatOffices_Server/src/modules/erp/customization/customization-catalog.ts","HarakatOffices_Server/src/modules/erp/customization/entity-def.ts","HarakatOffices_Server/src/modules/erp/customization/erp-changesets.service.ts","HarakatOffices_Server/src/modules/erp/customization/erp-customization.service.ts","HarakatOffices_Server/src/modules/erp/customization/erp-vocabulary.test.ts","HarakatOffices_Server/src/modules/erp/customization/erp-vocabulary.ts","HarakatOffices_Server/src/modules/erp/customization/identity-fields.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-action-hash.test.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-action-hash.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-allocation.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-entity-hash.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-overlay-hash.ts","HarakatOffices_Server/src/modules/erp/customization/kernel-overlay-map.ts","HarakatOffices_Server/src/modules/erp/customization/ops-registry.test.ts","HarakatOffices_Server/src/modules/erp/customization/ops-registry.ts","HarakatOffices_Server/src/modules/erp/customization/packs/awqaf-pack.v1.ts","HarakatOffices_Server/src/modules/erp/customization/packs/awqaf-pack.v1_1.ts","HarakatOffices_Server/src/modules/erp/customization/packs/awqaf-pack.v1_2.ts","HarakatOffices_Server/src/modules/erp/customization/protected-models.ts","HarakatOffices_Server/src/modules/erp/erp-access-role.test.ts","HarakatOffices_Server/src/modules/erp/erp-access-role.ts","HarakatOffices_Server/src/modules/erp/erp-anchor-links.test.ts","HarakatOffices_Server/src/modules/erp/erp-anchor-links.ts","HarakatOffices_Server/src/modules/erp/erp-anchor.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-anchor.service.ts","HarakatOffices_Server/src/modules/erp/erp-apps.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-apps.service.ts","HarakatOffices_Server/src/modules/erp/erp-authority.service.ts","HarakatOffices_Server/src/modules/erp/erp-connections.service.ts","HarakatOffices_Server/src/modules/erp/erp-currency-seed.ts","HarakatOffices_Server/src/modules/erp/erp-error-degradation.test.ts","HarakatOffices_Server/src/modules/erp/erp-files.controller.ts","HarakatOffices_Server/src/modules/erp/erp-files.outbound.ts","HarakatOffices_Server/src/modules/erp/erp-files.service.ts","HarakatOffices_Server/src/modules/erp/erp-fleet.service.ts","HarakatOffices_Server/src/modules/erp/erp-gateway.client.ts","HarakatOffices_Server/src/modules/erp/erp-groups.test.ts","HarakatOffices_Server/src/modules/erp/erp-groups.ts","HarakatOffices_Server/src/modules/erp/erp-identity.ts","HarakatOffices_Server/src/modules/erp/erp-index-hooks.ts","HarakatOffices_Server/src/modules/erp/erp-index.service.ts","HarakatOffices_Server/src/modules/erp/erp-mcp-catalog.ts","HarakatOffices_Server/src/modules/erp/erp-mcp-dispatch.domain-coercion.test.ts","HarakatOffices_Server/src/modules/erp/erp-mcp-dispatch.ts","HarakatOffices_Server/src/modules/erp/erp-model-gate.ts","HarakatOffices_Server/src/modules/erp/erp-model-map.ts","HarakatOffices_Server/src/modules/erp/erp-provisioning.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-provisioning.service.ts","HarakatOffices_Server/src/modules/erp/erp-run-apps.ts","HarakatOffices_Server/src/modules/erp/erp-scope.service.test.ts","HarakatOffices_Server/src/modules/erp/erp-scope.service.ts","HarakatOffices_Server/src/modules/erp/erp-stage-seed.test.ts","HarakatOffices_Server/src/modules/erp/erp-stage-seed.ts","HarakatOffices_Server/src/modules/erp/erp-target.ts","HarakatOffices_Server/src/modules/erp/erp-tenant-fields.ts","HarakatOffices_Server/src/modules/erp/erp-vat-seed.test.ts","HarakatOffices_Server/src/modules/erp/erp-vat-seed.ts","HarakatOffices_Server/src/modules/erp/erp-visibility.ts","HarakatOffices_Server/src/modules/erp/erp.controller.ts","HarakatOffices_Server/src/modules/erp/erp.routes.ts","HarakatOffices_Server/src/modules/erp/erp.service.test.ts","HarakatOffices_Server/src/modules/erp/erp.service.ts","HarakatOffices_Server/src/modules/erp/erp.types.ts","HarakatOffices_Server/src/modules/erp/fiscal-calendar.ts","HarakatOffices_Server/src/modules/erp/fiscal-identity.ts","HarakatOffices_Server/src/modules/erp/kernel-claims.test.ts","HarakatOffices_Server/src/modules/erp/kernel-claims.ts","HarakatOffices_Server/src/modules/erp/kernel-company.ts","HarakatOffices_Server/src/modules/erp/kernel-domain-compat.ts","HarakatOffices_Server/src/modules/erp/kernel-employee-projection.ts","HarakatOffices_Server/src/modules/erp/kernel-people-refs.ts","HarakatOffices_Server/src/modules/erp/kernel-route.test.ts","HarakatOffices_Server/src/modules/erp/kernel-route.ts","HarakatOffices_Server/src/modules/erp/kernel-stock-driver.ts","HarakatOffices_Server/src/modules/erp/kernel-tier.ts","HarakatOffices_Server/src/modules/governance/governance.controller.ts","HarakatOffices_Server/src/modules/governance/governance.routes.ts","HarakatOffices_Server/src/modules/governance/governance.service.ts","HarakatOffices_Server/src/modules/governance/prompts.controller.ts","HarakatOffices_Server/src/modules/health/health.routes.ts","HarakatOffices_Server/src/modules/health/health.service.test.ts","HarakatOffices_Server/src/modules/health/health.service.ts","HarakatOffices_Server/src/modules/hermes-routing/hermes-routing.controller.ts","HarakatOffices_Server/src/modules/hermes-routing/hermes-routing.routes.ts","HarakatOffices_Server/src/modules/integration-health/integration-health.controller.ts","HarakatOffices_Server/src/modules/integration-health/integration-health.routes.ts","HarakatOffices_Server/src/modules/integration-health/integration-health.service.ts","HarakatOffices_Server/src/modules/inter-assistant/answer-scope.ts","HarakatOffices_Server/src/modules/inter-assistant/ask-policy.ts","HarakatOffices_Server/src/modules/inter-assistant/ask-runner.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.controller.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.outbound.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.routes.ts","HarakatOffices_Server/src/modules/inter-assistant/inter-assistant.service.ts","HarakatOffices_Server/src/modules/internal-delegation/internal-delegation.controller.ts","HarakatOffices_Server/src/modules/internal-delegation/internal-delegation.service.ts","HarakatOffices_Server/src/modules/knowledge/context-events.service.ts","HarakatOffices_Server/src/modules/knowledge/coverage-reconciler.service.ts","HarakatOffices_Server/src/modules/knowledge/doc-chunking.ts","HarakatOffices_Server/src/modules/knowledge/document-text.ts","HarakatOffices_Server/src/modules/knowledge/embed-batch.service.ts","HarakatOffices_Server/src/modules/knowledge/embed-bucket.ts","HarakatOffices_Server/src/modules/knowledge/evidence-schema.integration.test.ts","HarakatOffices_Server/src/modules/knowledge/evidence.service.integration.test.ts","HarakatOffices_Server/src/modules/knowledge/evidence.service.ts","HarakatOffices_Server/src/modules/knowledge/freshness-rider.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.controller.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.inbound.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.outbound.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.routes.ts","HarakatOffices_Server/src/modules/knowledge/knowledge.service.ts","HarakatOffices_Server/src/modules/knowledge/meaning-search.ts","HarakatOffices_Server/src/modules/knowledge/mount-recall.ts","HarakatOffices_Server/src/modules/knowledge/mounts.ts","HarakatOffices_Server/src/modules/knowledge/quick-search.service.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-cache.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-quality.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-v2-flag.ts","HarakatOffices_Server/src/modules/knowledge/retrieval-v2.service.ts","HarakatOffices_Server/src/modules/knowledge/search-evidence-wiring.integration.test.ts","HarakatOffices_Server/src/modules/knowledge/slot-ladder.ts","HarakatOffices_Server/src/modules/knowledge/vector-indexer.service.ts","HarakatOffices_Server/src/modules/learning/courses.controller.ts","HarakatOffices_Server/src/modules/learning/courses.outbound.ts","HarakatOffices_Server/src/modules/mail/mail.controller.ts","HarakatOffices_Server/src/modules/mail/mail.inbound.ts","HarakatOffices_Server/src/modules/mail/mail.outbound.ts","HarakatOffices_Server/src/modules/mail/mail.routes.ts","HarakatOffices_Server/src/modules/marketplace/agents.controller.ts","HarakatOffices_Server/src/modules/marketplace/agents.inbound.ts","HarakatOffices_Server/src/modules/marketplace/agents.outbound.ts","HarakatOffices_Server/src/modules/mcp/circuit-breaker.ts","HarakatOffices_Server/src/modules/mcp/mcp.controller.ts","HarakatOffices_Server/src/modules/mcp/mcp.routes.ts","HarakatOffices_Server/src/modules/mcp/mcp.service.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.controller.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.outbound.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.routes.ts","HarakatOffices_Server/src/modules/meeting/auto-record-rule.service.ts","HarakatOffices_Server/src/modules/meeting/calendar-rule-scout.service.ts","HarakatOffices_Server/src/modules/meeting/meeting.controller.ts","HarakatOffices_Server/src/modules/meeting/meeting.routes.ts","HarakatOffices_Server/src/modules/meeting/meeting.service.ts","HarakatOffices_Server/src/modules/meeting/recording-email.ts","HarakatOffices_Server/src/modules/meeting/recording.controller.ts","HarakatOffices_Server/src/modules/meeting/recording.routes.ts","HarakatOffices_Server/src/modules/meeting/recording.service.ts","HarakatOffices_Server/src/modules/meeting/regenerate.service.ts","HarakatOffices_Server/src/modules/meeting/transcript-batch.service.ts","HarakatOffices_Server/src/modules/meeting/transcript-ingest.service.ts","HarakatOffices_Server/src/modules/meeting/url-normalizer.ts","HarakatOffices_Server/src/modules/memory/memory.controller.ts","HarakatOffices_Server/src/modules/memory/memory.outbound.ts","HarakatOffices_Server/src/modules/memory/memory.routes.ts","HarakatOffices_Server/src/modules/memory/memory.service.ts","HarakatOffices_Server/src/modules/mutations/mutation-appliers.ts","HarakatOffices_Server/src/modules/mutations/mutations.controller.ts","HarakatOffices_Server/src/modules/mutations/mutations.outbound.ts","HarakatOffices_Server/src/modules/mutations/mutations.routes.ts","HarakatOffices_Server/src/modules/mutations/mutations.service.ts","HarakatOffices_Server/src/modules/notifications/devices.service.ts","HarakatOffices_Server/src/modules/notifications/notification.service.test.ts","HarakatOffices_Server/src/modules/notifications/notification.service.ts","HarakatOffices_Server/src/modules/notifications/notifications.controller.ts","HarakatOffices_Server/src/modules/notifications/notifications.outbound.ts","HarakatOffices_Server/src/modules/notifications/notifications.realtime.ts","HarakatOffices_Server/src/modules/notifications/notifications.routes.ts","HarakatOffices_Server/src/modules/notifications/push.service.ts","HarakatOffices_Server/src/modules/notifications/recipients.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-draft.integration.test.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-draft.service.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-feed.integration.test.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-feed.service.ts","HarakatOffices_Server/src/modules/onboarding/onboarding-persistence.integration.test.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.controller.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.routes.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.service.ts","HarakatOffices_Server/src/modules/onboarding/onboarding.types.ts","HarakatOffices_Server/src/modules/packs/catalog/dentist.v1.ts","HarakatOffices_Server/src/modules/packs/index.ts","HarakatOffices_Server/src/modules/packs/pack-admin.service.ts","HarakatOffices_Server/src/modules/packs/pack-collision.ts","HarakatOffices_Server/src/modules/packs/pack-contract.ts","HarakatOffices_Server/src/modules/packs/pack-fetcher.ts","HarakatOffices_Server/src/modules/packs/pack-install.service.ts","HarakatOffices_Server/src/modules/packs/pack-planner.ts","HarakatOffices_Server/src/modules/packs/pack-resolution.ts","HarakatOffices_Server/src/modules/packs/pack-source.service.ts","HarakatOffices_Server/src/modules/packs/pack-sync.service.ts","HarakatOffices_Server/src/modules/packs/pack-tenant.service.ts","HarakatOffices_Server/src/modules/packs/pack-trust.ts","HarakatOffices_Server/src/modules/packs/packs.controller.ts","HarakatOffices_Server/src/modules/packs/packs.inbound.ts","HarakatOffices_Server/src/modules/packs/packs.outbound.ts","HarakatOffices_Server/src/modules/packs/packs.routes.ts","HarakatOffices_Server/src/modules/pages/compile.ts","HarakatOffices_Server/src/modules/pages/condition.ts","HarakatOffices_Server/src/modules/pages/flow.schema.ts","HarakatOffices_Server/src/modules/pages/flow.types.ts","HarakatOffices_Server/src/modules/pages/index.ts","HarakatOffices_Server/src/modules/pages/packs/awqaf-pages.v1.ts","HarakatOffices_Server/src/modules/pages/page-doc.ops.ts","HarakatOffices_Server/src/modules/pages/page-doc.schema.ts","HarakatOffices_Server/src/modules/pages/page-doc.service.ts","HarakatOffices_Server/src/modules/pages/page-doc.types.ts","HarakatOffices_Server/src/modules/pages/page.controller.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.ingest.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.io.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.kinds.ts","HarakatOffices_Server/src/modules/parsing/enrich-batch.service.ts","HarakatOffices_Server/src/modules/parsing/folder-signal.ts","HarakatOffices_Server/src/modules/parsing/ocr-batch-flush.ts","HarakatOffices_Server/src/modules/parsing/ocr-batch.service.ts","HarakatOffices_Server/src/modules/parsing/parsing.config.ts","HarakatOffices_Server/src/modules/parsing/parsing.controller.ts","HarakatOffices_Server/src/modules/parsing/parsing.outbound.ts","HarakatOffices_Server/src/modules/parsing/parsing.routes.ts","HarakatOffices_Server/src/modules/parsing/parsing.service.ts","HarakatOffices_Server/src/modules/policy/policy.controller.ts","HarakatOffices_Server/src/modules/policy/policy.outbound.ts","HarakatOffices_Server/src/modules/policy/policy.routes.ts","HarakatOffices_Server/src/modules/policy/policy.service.ts","HarakatOffices_Server/src/modules/portal/portal.controller.ts","HarakatOffices_Server/src/modules/portal/portal.forms.ts","HarakatOffices_Server/src/modules/portal/portal.routes.ts","HarakatOffices_Server/src/modules/portal/portal.service.ts","HarakatOffices_Server/src/modules/procedures/__fixtures__/procedure-contract-cases.json","HarakatOffices_Server/src/modules/procedures/erp-events.controller.ts","HarakatOffices_Server/src/modules/procedures/procedure-runs.service.ts","HarakatOffices_Server/src/modules/procedures/procedure-triggers.service.ts","HarakatOffices_Server/src/modules/procedures/procedure.outbound.ts","HarakatOffices_Server/src/modules/procedures/procedures.controller.ts","HarakatOffices_Server/src/modules/procedures/procedures.outbound.ts","HarakatOffices_Server/src/modules/procedures/procedures.routes.ts","HarakatOffices_Server/src/modules/procedures/procedures.service.ts","HarakatOffices_Server/src/modules/procedures/procedures.types.ts","HarakatOffices_Server/src/modules/procedures/relay-refcount.ts","HarakatOffices_Server/src/modules/procedures/step-assignee.ts","HarakatOffices_Server/src/modules/procedures/step-decision.service.ts","HarakatOffices_Server/src/modules/procedures/step-schema.ts","HarakatOffices_Server/src/modules/reports/index.ts","HarakatOffices_Server/src/modules/reports/packs/awqaf-reports.v1.ts","HarakatOffices_Server/src/modules/reports/report-compile.ts","HarakatOffices_Server/src/modules/reports/report-model-access.ts","HarakatOffices_Server/src/modules/reports/report-render.ts","HarakatOffices_Server/src/modules/reports/report-template.controller.ts","HarakatOffices_Server/src/modules/reports/report-template.ops.ts","HarakatOffices_Server/src/modules/reports/report-template.schema.ts","HarakatOffices_Server/src/modules/reports/report-template.service.ts","HarakatOffices_Server/src/modules/reports/report-template.types.ts","HarakatOffices_Server/src/modules/rooms/assistant-presence.ts","HarakatOffices_Server/src/modules/rooms/audience-floor.ts","HarakatOffices_Server/src/modules/rooms/audience.service.ts","HarakatOffices_Server/src/modules/rooms/bridge-brake.ts","HarakatOffices_Server/src/modules/rooms/bridge-queue.ts","HarakatOffices_Server/src/modules/rooms/bridge-seat-cause.ts","HarakatOffices_Server/src/modules/rooms/bridge-store.ts","HarakatOffices_Server/src/modules/rooms/bridge-transport.ts","HarakatOffices_Server/src/modules/rooms/bridge-turn.ts","HarakatOffices_Server/src/modules/rooms/bridge-wake.ts","HarakatOffices_Server/src/modules/rooms/bridge.service.ts","HarakatOffices_Server/src/modules/rooms/decision-visibility.ts","HarakatOffices_Server/src/modules/rooms/index.ts","HarakatOffices_Server/src/modules/rooms/member-view.ts","HarakatOffices_Server/src/modules/rooms/mentions.ts","HarakatOffices_Server/src/modules/rooms/nostr-crypto.ts","HarakatOffices_Server/src/modules/rooms/project-room.ts","HarakatOffices_Server/src/modules/rooms/projector.service.ts","HarakatOffices_Server/src/modules/rooms/relay-commands.ts","HarakatOffices_Server/src/modules/rooms/relay-health.ts","HarakatOffices_Server/src/modules/rooms/relay-http.ts","HarakatOffices_Server/src/modules/rooms/relay-registry.service.ts","HarakatOffices_Server/src/modules/rooms/room-conversation.ts","HarakatOffices_Server/src/modules/rooms/room-corpus-floor.ts","HarakatOffices_Server/src/modules/rooms/room-corpus.ts","HarakatOffices_Server/src/modules/rooms/room-event.ts","HarakatOffices_Server/src/modules/rooms/room-identity.ts","HarakatOffices_Server/src/modules/rooms/room-plan.ts","HarakatOffices_Server/src/modules/rooms/room-thread.service.ts","HarakatOffices_Server/src/modules/rooms/room-tools.controller.ts","HarakatOffices_Server/src/modules/rooms/room-tools.outbound.ts","HarakatOffices_Server/src/modules/rooms/room-tools.service.ts","HarakatOffices_Server/src/modules/rooms/rooms.controller.ts","HarakatOffices_Server/src/modules/rooms/rooms.inbound.ts","HarakatOffices_Server/src/modules/rooms/rooms.outbound.ts","HarakatOffices_Server/src/modules/rooms/rooms.routes.ts","HarakatOffices_Server/src/modules/rooms/rooms.service.ts","HarakatOffices_Server/src/modules/rooms/roster.ts","HarakatOffices_Server/src/modules/rooms/scope-label.ts","HarakatOffices_Server/src/modules/rooms/signing.controller.ts","HarakatOffices_Server/src/modules/rooms/signing.inbound.ts","HarakatOffices_Server/src/modules/rooms/signing.outbound.ts","HarakatOffices_Server/src/modules/rooms/signing.routes.ts","HarakatOffices_Server/src/modules/rooms/signing.service.ts","HarakatOffices_Server/src/modules/sandbox/sandbox-process.controller.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.caller.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.controller.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.inbound.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.outbound.ts","HarakatOffices_Server/src/modules/sandbox/sandbox.routes.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.controller.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.outbound.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.routes.ts","HarakatOffices_Server/src/modules/scenario-templates/scenario-templates.service.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.controller.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.outbound.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.routes.ts","HarakatOffices_Server/src/modules/scheduled-tasks/scheduled-tasks.service.ts","HarakatOffices_Server/src/modules/search/authorize.ts","HarakatOffices_Server/src/modules/search/index.ts","HarakatOffices_Server/src/modules/search/name-rows.ts","HarakatOffices_Server/src/modules/search/search.service.ts","HarakatOffices_Server/src/modules/search/types.ts","HarakatOffices_Server/src/modules/search/vector.service.ts","HarakatOffices_Server/src/modules/settings/settings.controller.ts","HarakatOffices_Server/src/modules/settings/settings.inbound.ts","HarakatOffices_Server/src/modules/settings/settings.outbound.ts","HarakatOffices_Server/src/modules/shadow/shadow.controller.ts","HarakatOffices_Server/src/modules/shadow/shadow.routes.ts","HarakatOffices_Server/src/modules/shadow/shadow.service.ts","HarakatOffices_Server/src/modules/skills/skill-class.ts","HarakatOffices_Server/src/modules/skills/skill-scope.ts","HarakatOffices_Server/src/modules/skills/skills.controller.ts","HarakatOffices_Server/src/modules/skills/skills.dto.ts","HarakatOffices_Server/src/modules/skills/skills.outbound.ts","HarakatOffices_Server/src/modules/skills/skills.routes.ts","HarakatOffices_Server/src/modules/skills/skills.service.ts","HarakatOffices_Server/src/modules/startup-auth/assistant-on-accept.integration.test.ts","HarakatOffices_Server/src/modules/startup-auth/refresh.service.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.controller.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.outbound.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.routes.ts","HarakatOffices_Server/src/modules/startup-auth/startup-auth.service.ts","HarakatOffices_Server/src/modules/startup-documents/startup-documents.controller.ts","HarakatOffices_Server/src/modules/startup-documents/startup-documents.outbound.ts","HarakatOffices_Server/src/modules/startup-documents/startup-documents.routes.ts","HarakatOffices_Server/src/modules/startup-documents/workspace.controller.ts","HarakatOffices_Server/src/modules/startup-documents/workspace.service.ts","HarakatOffices_Server/src/modules/startup/action-result-persist.integration.test.ts","HarakatOffices_Server/src/modules/startup/action-summary.test.ts","HarakatOffices_Server/src/modules/startup/action-summary.ts","HarakatOffices_Server/src/modules/startup/agent-file.controller.ts","HarakatOffices_Server/src/modules/startup/assistant-active.integration.test.ts","HarakatOffices_Server/src/modules/startup/assistant-eri-wiring.integration.test.ts","HarakatOffices_Server/src/modules/startup/assistant-skill-memory.test.ts","HarakatOffices_Server/src/modules/startup/assistant.outbound.ts","HarakatOffices_Server/src/modules/startup/assistant.service.ts","HarakatOffices_Server/src/modules/startup/branch-department-mirror.integration.test.ts","HarakatOffices_Server/src/modules/startup/branch-department-mirror.ts","HarakatOffices_Server/src/modules/startup/branch-head.integration.test.ts","HarakatOffices_Server/src/modules/startup/branch-parent.integration.test.ts","HarakatOffices_Server/src/modules/startup/chat-protocol.ts","HarakatOffices_Server/src/modules/startup/company-delete.integration.test.ts","HarakatOffices_Server/src/modules/startup/company-delete.service.ts","HarakatOffices_Server/src/modules/startup/company-profile.controller.ts","HarakatOffices_Server/src/modules/startup/company-profile.inbound.ts","HarakatOffices_Server/src/modules/startup/company-profile.outbound.ts","HarakatOffices_Server/src/modules/startup/company-profile.routes.ts","HarakatOffices_Server/src/modules/startup/company-profile.service.ts","HarakatOffices_Server/src/modules/startup/connector-notice.ts","HarakatOffices_Server/src/modules/startup/corpus-tree.integration.test.ts","HarakatOffices_Server/src/modules/startup/delegation.controller.ts","HarakatOffices_Server/src/modules/startup/delegation.outbound.ts","HarakatOffices_Server/src/modules/startup/delegation.routes.ts","HarakatOffices_Server/src/modules/startup/drive-acl-review.integration.test.ts","HarakatOffices_Server/src/modules/startup/drive-acl.controller.ts","HarakatOffices_Server/src/modules/startup/drive.inbound.ts","HarakatOffices_Server/src/modules/startup/erp-action.controller.ts","HarakatOffices_Server/src/modules/startup/erp-action.routes.ts","HarakatOffices_Server/src/modules/startup/erp-customization.controller.ts","HarakatOffices_Server/src/modules/startup/erp-customization.routes.ts","HarakatOffices_Server/src/modules/startup/erp-recruitment.controller.ts","HarakatOffices_Server/src/modules/startup/file-upload.controller.ts","HarakatOffices_Server/src/modules/startup/governance-authoring-grant.service.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.controller.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.outbound.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.routes.ts","HarakatOffices_Server/src/modules/startup/governance-authoring.service.ts","HarakatOffices_Server/src/modules/startup/governance-creation-session.service.ts","HarakatOffices_Server/src/modules/startup/governance-draft.integration.test.ts","HarakatOffices_Server/src/modules/startup/governance-draft.service.ts","HarakatOffices_Server/src/modules/startup/governance-integrations.integration.test.ts","HarakatOffices_Server/src/modules/startup/governance-integrations.service.ts","HarakatOffices_Server/src/modules/startup/governance.service.ts","HarakatOffices_Server/src/modules/startup/offboarding/kernel-employee-lifecycle.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding-ownership-registry.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.controller.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.outbound.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.routes.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.service.ts","HarakatOffices_Server/src/modules/startup/offboarding/offboarding.worker.ts","HarakatOffices_Server/src/modules/startup/offboarding/purge-policy.ts","HarakatOffices_Server/src/modules/startup/offboarding/purge.service.ts","HarakatOffices_Server/src/modules/startup/offboarding/purge.worker.ts","HarakatOffices_Server/src/modules/startup/offboarding/seat-release.adapter.ts","HarakatOffices_Server/src/modules/startup/org-authority.controller.ts","HarakatOffices_Server/src/modules/startup/org-authority.flags.ts","HarakatOffices_Server/src/modules/startup/org-authority.outbound.ts","HarakatOffices_Server/src/modules/startup/org-authority.routes.ts","HarakatOffices_Server/src/modules/startup/org-authority.service.ts","HarakatOffices_Server/src/modules/startup/org-erp-kernel-capability.ts","HarakatOffices_Server/src/modules/startup/org-erp-mirror-v2.service.ts","HarakatOffices_Server/src/modules/startup/org-erp-mirror.worker.ts","HarakatOffices_Server/src/modules/startup/org-erp-reconciliation.service.ts","HarakatOffices_Server/src/modules/startup/people-map.integration.test.ts","HarakatOffices_Server/src/modules/startup/personal-governance.controller.ts","HarakatOffices_Server/src/modules/startup/personal-governance.outbound.ts","HarakatOffices_Server/src/modules/startup/personal-governance.service.ts","HarakatOffices_Server/src/modules/startup/preferences.controller.ts","HarakatOffices_Server/src/modules/startup/preferences.routes.ts","HarakatOffices_Server/src/modules/startup/preferences.service.test.ts","HarakatOffices_Server/src/modules/startup/preferences.service.ts","HarakatOffices_Server/src/modules/startup/runtime-access.ts","HarakatOffices_Server/src/modules/startup/session-metadata-schema.test.ts","HarakatOffices_Server/src/modules/startup/sessions.controller.ts","HarakatOffices_Server/src/modules/startup/sessions.integration.test.ts","HarakatOffices_Server/src/modules/startup/sessions.routes.ts","HarakatOffices_Server/src/modules/startup/sessions.service.ts","HarakatOffices_Server/src/modules/startup/startup.controller.ts","HarakatOffices_Server/src/modules/startup/startup.inbound.ts","HarakatOffices_Server/src/modules/startup/startup.outbound.ts","HarakatOffices_Server/src/modules/startup/startup.routes.ts","HarakatOffices_Server/src/modules/startup/startup.service.ts","HarakatOffices_Server/src/modules/startup/suites-removed-apps.integration.test.ts","HarakatOffices_Server/src/modules/startup/suites.controller.ts","HarakatOffices_Server/src/modules/startup/suites.routes.ts","HarakatOffices_Server/src/modules/startup/suites.service.integration.test.ts","HarakatOffices_Server/src/modules/startup/suites.service.test.ts","HarakatOffices_Server/src/modules/startup/suites.service.ts","HarakatOffices_Server/src/modules/startup/support.controller.ts","HarakatOffices_Server/src/modules/startup/support.outbound.ts","HarakatOffices_Server/src/modules/startup/team-erp-access-role.integration.test.ts","HarakatOffices_Server/src/modules/startup/twofa-schema.test.ts","HarakatOffices_Server/src/modules/startup/twofa.controller.ts","HarakatOffices_Server/src/modules/startup/twofa.integration.test.ts","HarakatOffices_Server/src/modules/startup/twofa.routes.ts","HarakatOffices_Server/src/modules/startup/twofa.s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment