This commit implements Options B, C, and D for enhanced roleplay capabilities: **Option B: Enhanced Roleplay Features** - Add regex pattern matching for World Info keywords with fallback to literal matching - Make scan depth configurable (default: 20, range: 1-100 messages) - Make Author's Note insertion depth configurable (default: 3, range: 1-50 messages) - Add World Info import/export functionality with merge/replace options - Update WorldInfoEntry struct with use_regex field - Update RoleplaySettings with scan_depth and authors_note_depth fields - Modify build_roleplay_context() to return configurable note_depth - Update all 4 chat functions to use configurable Author's Note depth **Option C: Chat Export Enhancements** - Add export_chat_as_markdown: Clean markdown format with bold role labels - Add export_chat_as_text: Simple plain text format with decorative separator - Add export_chat_as_html: Styled HTML with responsive design and color-coded messages - All exports use native file dialogs with appropriate file filters **Option D: Polish & Quality of Life** - Add validate_regex_pattern command for real-time regex validation - Add update_roleplay_depths command with range validation - Enhance add_world_info_entry with input validation (regex, empty checks) - Enhance update_world_info_entry with input validation - Add detailed error messages for all validation failures **Technical Details:** - Add regex dependency to Cargo.toml - Use #[serde(default)] attributes for backward compatibility - Graceful error handling with fallback strategies - HTML export includes proper escaping for XSS protection - All new commands registered in Tauri invoke_handler 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
36 lines
1007 B
TOML
36 lines
1007 B
TOML
[package]
|
|
name = "tauri-app"
|
|
version = "0.1.0"
|
|
description = "A Tauri App"
|
|
authors = ["you"]
|
|
edition = "2021"
|
|
|
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
|
|
|
[lib]
|
|
# The `_lib` suffix may seem redundant but it is necessary
|
|
# to make the lib name unique and wouldn't conflict with the bin name.
|
|
# This seems to be only an issue on Windows, see https://github.com/rust-lang/cargo/issues/8519
|
|
name = "tauri_app_lib"
|
|
crate-type = ["staticlib", "cdylib", "rlib"]
|
|
|
|
[build-dependencies]
|
|
tauri-build = { version = "2", features = [] }
|
|
|
|
[dependencies]
|
|
tauri = { version = "2", features = ["protocol-asset"] }
|
|
tauri-plugin-opener = "2"
|
|
tauri-plugin-dialog = "2"
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
reqwest = { version = "0.12", features = ["json", "stream"] }
|
|
tokio = { version = "1", features = ["full"] }
|
|
uuid = { version = "1", features = ["v4"] }
|
|
futures = "0.3"
|
|
bytes = "1"
|
|
png = "0.17"
|
|
base64 = "0.21"
|
|
image = "0.24"
|
|
regex = "1"
|
|
|