Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Kork & Krone

**Last updated:** 7 November 2026
**Last updated:** 10. November 2026
**Submission:** 3 (first complete prototype, beta)
**Status:** In progress. See [Status for submission 3](#status-for-submission-3).

Expand Down Expand Up @@ -52,8 +52,8 @@ Submission 3 should be the first complete prototype, with search, browsing, sort
| Filtering and sorting in the user interface | Done | Filter panel, active filters and sorting on `/sok`. Needs the new backend on the VM |
| Wine detail page | Done | Facts, food pairing and rating at `/vin/:id`. Student reviews are added with the reviews feature |
| Student reviews (stored in the database) | Planned | |
| Larger dataset on the VM | Planned | |
| Continuous integration (CI) | Not yet started | |
| Larger dataset on the VM | Done | |
| Continuous integration (CI) | Not yet started | Slim version: 1 007 wines and 150 000 ratings |

<!--
Update the backend row when it runs on the VM: "Done. Try it in Apollo Sandbox at /project2/graphql".
Expand Down Expand Up @@ -160,8 +160,11 @@ We use the [X-Wines](https://github.com/rogerioxavier/X-Wines) dataset. It is re
| Slim | 1 007 | 150 000 | Planned for the VM |
| Full | 100 646 | about 21 million | Planned for load testing and to show that the solution scales |

The VM and local development currently use the Test version. We plan to load Slim on the VM, because it gives
enough wines to make search, filters and pagination meaningful, and it imports quickly.
Local development uses the Test version. The VM uses the Slim version, because it gives
enough wines to make search, filters and pagination meaningful, and it imports in a few seconds.
The Slim files are not in the repository. Download them from
[Kaggle](https://www.kaggle.com/datasets/rogerioxavier/x-wines-slim-version) and see the
[VM guide](docs/vm.md) for how to load them.

We plan to use Full locally to show that the solution scales. Search, filtering, sorting and pagination run in
PostgreSQL with indexes (a trigram index for text search and B-tree and GIN indexes for sorting and filters),
Expand Down Expand Up @@ -343,13 +346,14 @@ Claude and ChatGPT are the main models used. The usecases for the AI tools are a
3. [x] Filter panel with counts from `filterOptions`, and sorting. All choices stored in the URL.
4. [x] Connect the landing page to the backend.
5. [x] Wine detail page.
6. [ ] Start the backend on the VM and load the dataset.
6. [x] Start the backend on the VM and load the dataset.

### Then: towards the next submission

- [ ] Student reviews: GraphQL mutation, database table, validation, and the new rating shown at once.
- [ ] Wishlist stored in the backend.
- [ ] Larger dataset on the VM, and a load test with the full dataset.
- [x] Larger dataset on the VM.
- [ ] Load test with the Full dataset.
- [ ] CI, an enforced coverage threshold, and eslint-plugin-jsx-a11y.
- [ ] Measure sustainability and fill in the budget table.
- [ ] Screen reader test and a written reflection on the use of AI.
Expand Down
24 changes: 24 additions & 0 deletions docs/vm.md
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,30 @@ ProxyPassReverse "/project2/graphql" "http://127.0.0.1:3001/graphql"
3. Install the backend dependencies and start it using the `nohup` instructions above.
4. Check the backend log, API response, and application in the browser.

## Load the Slim dataset

The VM uses the Slim version of X-Wines (1 007 wines, 150 000 ratings).
The files are not in the repository.

1. Download the Slim version from
[Kaggle](https://www.kaggle.com/datasets/rogerioxavier/x-wines-slim-version) and unzip it.
2. Copy the two CSV files to the VM. Run this on your own computer:

```bash
ssh <username>@it2810-18.idi.ntnu.no 'mkdir -p ~/xwines-slim'
scp XWines_Slim_1K_wines.csv XWines_Slim_150K_ratings.csv <username>@it2810-18.idi.ntnu.no:~/xwines-slim/
```

3. Import them on the VM:

```bash
cd ~/ntnuhome/T18-Project-2/backend
npx tsx src/scripts/seed-xwines.ts ~/xwines-slim/XWines_Slim_1K_wines.csv ~/xwines-slim/XWines_Slim_150K_ratings.csv
```

The import is safe to run more than once. The Test wines are part of Slim, so they are updated, not duplicated.
The backend does not need a restart.

## Command reference

- [GNU nohup manual](https://www.gnu.org/software/coreutils/manual/html_node/nohup-invocation.html)
Expand Down