1 unstable release
| 0.1.0 | Jan 27, 2026 |
|---|
#34 in Science
21KB
341 lines
Kurate Art Collection Manager - Rust Implementation
This Rust implementation was inspired by kurateart.com. It provides efficient tools for organizing, tagging, and managing digital art collections with smart categorization and gallery management features.
Features
- Artwork Cataloging: Create rich metadata entries with zero-copy abstractions
- Style Classification: Auto-categorize by period, style, and medium
- Tag Management: Apply and manage descriptive tags
- Collection Indexing: Build fast searchable indexes using HashMap
- Gallery Organization: Structure virtual galleries with smart layouts
Installation
cd rust
cargo build --release
Usage
Cataloging Artwork
use kurateart_com_oss::{catalog_artwork, classify_by_style, apply_tags, index_artwork};
let mut metadata = HashMap::new();
metadata.insert("title".to_string(), "Mona Lisa".to_string());
metadata.insert("artist".to_string(), "Leonardo da Vinci".to_string());
metadata.insert("period".to_string(), "Renaissance".to_string());
let mut artwork = catalog_artwork("/art/mona-lisa.jpg", metadata);
let classification = classify_by_style(&artwork);
apply_tags(&mut artwork, &classification.suggested_tags);
index_artwork(artwork);
Searching Collections
use kurateart_com_oss::{search_by_artist, search_by_style, search_by_tag};
// Search by artist
let works = search_by_artist("Leonardo da Vinci");
// Search by style
let impressionist = search_by_style("Impressionism");
// Search by tag
let tagged = search_by_tag("renaissance");
Creating Collections
use kurateart_com_oss::create_collection;
let collection = create_collection(
"Masterpieces",
"World-renowned artworks",
"Curator Name",
vec![artwork1.id.clone(), artwork2.id.clone()],
);
Running the Demo
cargo run --release
API Reference
catalog_artwork(file_path: &str, metadata: HashMap<String, String>) -> Artwork
Creates a new Artwork struct with the provided metadata.
classify_by_style(artwork: &Artwork) -> ClassificationResult
Analyzes artwork to determine style, period, and suggested tags.
apply_tags(artwork: &mut Artwork, new_tags: &[String])
Adds tags to an artwork, avoiding duplicates.
index_artwork(artwork: Artwork)
Adds artwork to the searchable index by artist, style, period, and tags.
search_by_artist(artist_name: &str) -> Vec<Artwork>
Returns vector of artworks by the specified artist.
search_by_style(style: &str) -> Vec<Artwork>
Returns vector of artworks in the specified style.
search_by_period(period: &str) -> Vec<Artwork>
Returns vector of artworks from the specified period.
search_by_tag(tag: &str) -> Vec<Artwork>
Returns vector of artworks with the specified tag.
create_collection(name, description, curator, artwork_ids) -> Collection
Creates a new Collection struct organizing artworks.
Data Structures
pub struct Artwork {
pub id: String,
pub title: String,
pub artist: String,
pub year_created: Option<i32>,
pub period: String,
pub style: String,
pub medium: String,
pub dimensions: String,
pub location: String,
pub file_path: String,
pub tags: Vec<String>,
pub attributes: HashMap<String, String>,
pub cataloged_at: String,
pub last_modified: String,
}
Testing
cargo test
Linting
cargo clippy
Formatting
cargo fmt
Links
- Source: kurateart.com
- Repository: https://github.com/user/kurateart-com-oss
- Crates.io: https://crates.io/crates/kurateart-com-oss
License
MIT License - see LICENSE for details.