From e3f0c31d94796f0c92b4af1832795ec2ee1082ab Mon Sep 17 00:00:00 2001 From: stan44 Date: Sat, 21 Feb 2026 23:29:09 -0600 Subject: [PATCH] Add Setup and Installation --- Setup-and-Installation.md | 102 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 Setup-and-Installation.md diff --git a/Setup-and-Installation.md b/Setup-and-Installation.md new file mode 100644 index 0000000..cd50816 --- /dev/null +++ b/Setup-and-Installation.md @@ -0,0 +1,102 @@ +# Setup and Installation + +This page covers local setup for the Python baseline and optional C# migration workspace. + +## Prerequisites + +- Python `3.14` +- `pip` and virtual environment support +- Windows or Linux +- Optional: GPU drivers/toolkit if using `requirements_gpu.txt` + +## Dependency Profiles + +- `requirements_base.txt`: shared runtime dependencies +- `requirements_cpu_only.txt`: base + CPU AI stack +- `requirements_gpu.txt`: base + GPU AI stack +- `requirements_nlp_optional.txt`: optional spaCy backend + +## Windows Setup (CPU default) + +```powershell +cd Project_Journal +py -3.14 -m venv .venv +.\.venv\Scripts\Activate.ps1 +python -m pip install --upgrade pip +python -m pip install --extra-index-url https://download.pytorch.org/whl/cpu -r requirements_cpu_only.txt +``` + +Run desktop app: + +```powershell +python .\journal\run_desktop.py +``` + +## Linux Setup (CPU default) + +```bash +cd Project_Journal +python3.14 -m venv .venv +source .venv/bin/activate +python -m pip install --upgrade pip +python -m pip install --extra-index-url https://download.pytorch.org/whl/cpu -r requirements_cpu_only.txt +``` + +Run desktop app: + +```bash +python ./journal/run_desktop.py +``` + +## Linux GPU Setup (optional) + +```bash +cd Project_Journal +python3.14 -m venv .venv +source .venv/bin/activate +python -m pip install --upgrade pip +python -m pip install -r requirements_gpu.txt +``` + +## Optional NLP Backend (spaCy) + +```bash +python -m pip install -r requirements_nlp_optional.txt +python -m spacy download en_core_web_sm +``` + +NLP backend modes: + +- `auto` (default): spaCy if available, fallback otherwise +- `spacy`: require spaCy and fail if unavailable +- `fallback`: always use fallback NLP heuristics + +Examples: + +```powershell +$env:JOURNAL_NLP_BACKEND = "fallback" +python .\journal\run_desktop.py +``` + +```bash +export JOURNAL_NLP_BACKEND=spacy +python ./journal/run_desktop.py +``` + +## C# Migration Workspace Setup (optional) + +Location: `journal-master/journal/` + +Use: + +- `journal-master/journal/README.md` +- `journal-master/journal/MINIMAL_MACHINE_SETUP.md` + +Quick check: + +```powershell +cd journal-master/journal +./scripts/dotnet-min.ps1 restore Journal.Sidecar/Journal.Sidecar.csproj +./scripts/dotnet-min.ps1 build Journal.Sidecar/Journal.Sidecar.csproj +./scripts/dotnet-min.ps1 run --project Journal.SmokeTests/Journal.SmokeTests.csproj +```