Skip to content

Commit 8809509

Browse files
added more notes to contributing guide for UI (tensorzero#3526)
* added more notes to contributing guide for UI * Fix formatting for steps in CONTRIBUTING.md * Update TENSORZERO_EVALUATIONS_PATH in CONTRIBUTING.md --------- Co-authored-by: Gabriel Bianconi <[email protected]>
1 parent d6fc831 commit 8809509

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

CONTRIBUTING.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -194,22 +194,24 @@ To set it up, follow these steps from the `ui` directory:
194194
1. Install dependencies: `pnpm install`
195195
2. Build the internal N-API client for TensorZero using `pnpm -r build`. If you have changed your Rust code, you may also have to run `pnpm build-bindings` from `../internal/tensorzero-node`.
196196
3. Create a `fixtures/.env` following the `fixtures/.env.example`.
197-
4. Set the following environment variables:
197+
4. Run `cargo build`.
198+
5. Set the following environment variables in your cwd `ui/` (note the previous step edited the vars in `fixtures/`):
198199
```bash
199200
TENSORZERO_GATEWAY_URL="http://localhost:3000"
200201
TENSORZERO_CLICKHOUSE_URL="http://chuser:chpassword@localhost:8123/tensorzero_ui_fixtures"
201202
TENSORZERO_UI_CONFIG_PATH="fixtures/config/tensorzero.toml"
202-
203+
TENSORZERO_EVALUATIONS_PATH="../target/debug/evaluations"
204+
203205
# Optional: add provider credentials for optimization workflows
204206
OPENAI_API_KEY="..."
205207
FIREWORKS_API_KEY="..."
206208
FIREWORKS_ACCOUNT_ID="..."
207209
```
208-
5. Launch the dependencies: `docker compose -f fixtures/docker-compose.yml up --build --force-recreate`.
210+
6. Launch the dependencies: `docker compose -f fixtures/docker-compose.yml up --build --force-recreate`.
209211
You can omit these last 2 flags to skip the build step, but they ensure you're using the latest gateway.
210-
6. Launch the development server: `pnpm dev`
212+
7. Launch the development server: `pnpm dev`
211213

212-
Separately, you can run headless tests with `pnpm test` and Playwright tests with `pnpm test-e2e`.
214+
Separately, you can run headless tests with `pnpm test` and Playwright tests with `pnpm test-e2e` (the latter will require a `pnpm exec playwright install`).
213215
We also maintain a Docker Compose for e2e tests `fixtures/docker-compose.e2e.yml` that is used in CI for the Playwright tests.
214216
This file uses a different configuration that mandates credentials for image fetching.
215217

0 commit comments

Comments
 (0)