# LT Live App

This is the first local live app for LT. It uses Python standard library plus SQLite and a browser wallet.

## Run locally

From `LT`:

```powershell
powershell -ExecutionPolicy Bypass -File app/run-local.ps1
```

or:

```cmd
app\run-local.cmd
```

Then open:

```text
http://127.0.0.1:8790/
```

## What works now

- Matter intake for will, inheritance, trust, capacity-event, board, and shareholder workflows.
- Evidence events with `sha256:` hashes.
- Local SQLite storage.
- Wallet connect through `window.ethereum`.
- Zweichain chain switch/add prompt using chain id `7853` / `0x1ead`.
- LT token balance read after a deployed LT token address is entered.
- Hash-only self-transaction timestamp preparation through the connected wallet.
- Board/shareholder voting snapshots with per-share or token-weighted fields.

## Safety boundary

The app is not production-authenticated yet. Do not put real client data into a public server. Keep real will, inheritance, family, board, shareholder, and private trust details off-chain. The chain action is designed for hashes only, and the wallet still asks the user to confirm any transaction.

## API

- `GET /api/health`
- `GET /api/config`
- `GET /api/status`
- `GET /api/matters`
- `POST /api/matters`
- `GET /api/evidence`
- `POST /api/evidence`
- `GET /api/votes`
- `POST /api/votes`

Writes are enabled by the local launchers with:

```text
LT_ENABLE_PUBLIC_WRITES=1
```

For a VPS or public demo, add authentication, rate limiting, backups, and review queues before enabling writes.
