# rubenwe/stlvault architecture

> Architecture diagram of the GitHub repository rubenwe/stlvault, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/rubenwe/stlvault
- Repository: https://github.com/rubenwe/stlvault

## Overview

STLVault is a Unity-based 3D model viewer and organizer for STL files. Its documented workflow is to import models from folders, automatically tag and transform them, generate previews, then search, inspect, edit, and organize them into collections. Configuration and service modules indicate internal support for persistent settings and library state. The README documents the feature flow, but no source excerpts were provided, so edges below reflect documented relationships rather than inspected call sites.

Main entry points: [`Assets/Scripts/Services/ImportFolder.cs`](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ImportFolder.cs) (Folder import), [`Assets/Scripts/Services/ImportFolderTagHelper.cs`](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ImportFolderTagHelper.cs) (Auto-tag and transform), [`Assets/Scripts/Services/PreviewList.cs`](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/PreviewList.cs) (Search items), [`Assets/Scripts/Util/Stl/StlImporter.cs`](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Util/Stl/StlImporter.cs) (STL parsing)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ingest["Import and processing"]
  node_import["Folder import<br/>[ImportFolder.cs]"]
  node_stl["STL parsing<br/>[StlImporter.cs]"]
  node_auto["Auto-tag and transform"]
  node_preview["Preview generation<br/>[IPreviewBuilder.cs]"]
end

subgraph group_library["Library services"]
  node_librarycore["Model library<br/>[Library.cs]"]
  node_metadata["Tags and metadata<br/>[MetaData.cs]"]
end

subgraph group_experience["Browse and organize"]
  node_search["Search items<br/>[PreviewList.cs]"]
  node_savedsearch["Saved searches"]
  node_viewer["3D model view<br/>[MainScene.unity]"]
  node_editing["Tag and rotation edits"]
  node_collections["User collections"]
end

subgraph group_support["State and utilities"]
  node_settings["Application settings"]
  node_configstore["Configuration store<br/>[ConfigStore.cs]"]
  node_previewstore["Preview image store"]
end

node_user(("STLVault user"))
node_folders["Model folders"]

node_user -->|"starts import"| node_import
node_folders -->|"provides STL files"| node_import
node_import -->|"imports STL"| node_stl
node_import -->|"auto processes"| node_auto
node_import -->|"generates previews"| node_preview
node_import -->|"adds items"| node_librarycore
node_user -->|"searches items"| node_search
node_search -->|"saves searches"| node_savedsearch
node_user -->|"views models"| node_viewer
node_user -->|"edits tags and rotation"| node_editing
node_user -->|"organizes items"| node_collections
node_auto -->|"assigns tags"| node_metadata

click node_import "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ImportFolder.cs"
click node_stl "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Util/Stl/StlImporter.cs"
click node_auto "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ImportFolderTagHelper.cs"
click node_preview "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/IPreviewBuilder.cs"
click node_librarycore "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/Library.cs"
click node_metadata "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/MetaData.cs"
click node_search "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/PreviewList.cs"
click node_savedsearch "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/SavedSearchConfig.cs"
click node_viewer "https://github.com/rubenwe/stlvault/blob/master/Assets/Scenes/MainScene.unity"
click node_editing "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/SelectionTracker.cs"
click node_collections "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/CollectionConfig.cs"
click node_settings "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/ApplicationSettings.cs"
click node_configstore "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ConfigStore.cs"
click node_previewstore "https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/PreviewImageStore.cs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_import,node_stl,node_auto,node_preview,node_user toneBlue
class node_librarycore,node_metadata toneAmber
class node_search,node_savedsearch,node_viewer,node_editing,node_collections toneMint
class node_settings,node_configstore,node_previewstore toneRose
class node_folders toneIndigo
```

## Components

### Import and processing

- [Folder import](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ImportFolder.cs): `Assets/Scripts/Services/ImportFolder.cs`
- [STL parsing](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Util/Stl/StlImporter.cs): `Assets/Scripts/Util/Stl/StlImporter.cs`
- [Auto-tag and transform](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ImportFolderTagHelper.cs): `Assets/Scripts/Services/ImportFolderTagHelper.cs`
- [Preview generation](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/IPreviewBuilder.cs): `Assets/Scripts/Services/IPreviewBuilder.cs`

### Library services

- [Model library](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/Library.cs): `Assets/Scripts/Services/Library.cs`
- [Tags and metadata](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/MetaData.cs): `Assets/Scripts/Config/MetaData.cs`

### Browse and organize

- [Search items](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/PreviewList.cs): `Assets/Scripts/Services/PreviewList.cs`
- [Saved searches](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/SavedSearchConfig.cs): `Assets/Scripts/Config/SavedSearchConfig.cs`
- [3D model view](https://github.com/rubenwe/stlvault/blob/master/Assets/Scenes/MainScene.unity): `Assets/Scenes/MainScene.unity`
- [Tag and rotation edits](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/SelectionTracker.cs): `Assets/Scripts/Services/SelectionTracker.cs`
- [User collections](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/CollectionConfig.cs): `Assets/Scripts/Config/CollectionConfig.cs`

### State and utilities

- [Application settings](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Config/ApplicationSettings.cs): `Assets/Scripts/Config/ApplicationSettings.cs`
- [Configuration store](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/ConfigStore.cs): `Assets/Scripts/Services/ConfigStore.cs`
- [Preview image store](https://github.com/rubenwe/stlvault/blob/master/Assets/Scripts/Services/PreviewImageStore.cs): `Assets/Scripts/Services/PreviewImageStore.cs`

### Other components

- **STLVault user**
- **Model folders**

## Connections

- STLVault user → Folder import: starts import (evidence: `README.md`)
- Model folders → Folder import: provides STL files (evidence: `README.md`)
- Folder import → STL parsing: imports STL (evidence: `README.md`)
- Folder import → Auto-tag and transform: auto processes (evidence: `README.md`)
- Folder import → Preview generation: generates previews (evidence: `README.md`)
- Folder import → Model library: adds items (evidence: `README.md`)
- STLVault user → Search items: searches items (evidence: `README.md`)
- Search items → Saved searches: saves searches (evidence: `README.md`)
- STLVault user → 3D model view: views models (evidence: `README.md`)
- STLVault user → Tag and rotation edits: edits tags and rotation (evidence: `README.md`)
- STLVault user → User collections: organizes items (evidence: `README.md`)
- Auto-tag and transform → Tags and metadata: assigns tags (evidence: `README.md`)
