Commit Graph

511 Commits

Author SHA1 Message Date
tomt610 126cfedaa4 fix: Historical context injection for both text and chat completion prompts
- Fix swipe data retrieval to check both message.extra and swipe_info sources
- Fix user_message_end position to inject into preceding (not next) user message
- Add ordered content-matching for text completion prompt injection
- Add ordered content-matching for chat completion prompt injection
- Remove unnecessary HTML entity normalization
- Clean up unused imports and variables
2026-01-11 13:45:42 +00:00
Spicy_Marinara d5d649f122 Update promptBuilder.js 2026-01-10 21:21:25 +01:00
Spicy Marinara 0cd764c39b Merge pull request #90 from tomt610/feature/history-persistence
Feature/history persistence
2026-01-10 20:35:03 +01:00
tomt610 b9a15722d6 Fix history injection for prewarm extensions
- Use persistent event listeners instead of once() to inject into ALL generations
- Don't clear context map on GENERATION_ENDED so prewarm gets the same context
- Remove unused onGenerationEndedCleanup function
2026-01-10 19:33:26 +00:00
Spicy_Marinara 995f3a7a98 Add Deception System and CYOA features with toggles, custom prompts, and proper injection ordering 2026-01-10 20:24:41 +01:00
tomt610 db97f012b0 Refactor history injection to modify prompts instead of chat messages
This prevents any risk of injected context being accidentally saved to the chat.
Instead of modifying chat[].mes directly, we now:
1. Build a context map during GENERATION_STARTED
2. Inject into the prompt string (GENERATE_AFTER_COMBINE_PROMPTS) for text completion
3. Inject into the message array (CHAT_COMPLETION_PROMPT_READY) for chat completion

The original chat messages are never modified.
2026-01-10 19:10:33 +00:00
Spicy_Marinara 681b8ba2bc Merge remote-tracking branch 'tomt610/feature/fab-widgets' into test-pr90-pr91-combined 2026-01-10 16:47:15 +01:00
Spicy_Marinara 2d961936c2 Merge remote-tracking branch 'tomt610/feature/history-persistence' into test-pr90-pr91-combined 2026-01-10 16:47:12 +01:00
Spicy_Marinara b534bd4c71 Update README.md 2026-01-10 16:41:27 +01:00
tomt610 73cbb27713 feat(mobile): Add FAB widgets with info display around toggle button
- Add 8-position widget system around mobile FAB button (N, NE, E, SE, S, SW, W, NW)
- Display weather icon, weather description, time, date, location around FAB
- Show stats and RPG attributes in larger West/Northwest positions
- Add animated clock face matching main panel design
- Implement expandable text on hover/tap for truncated content
- Add FAB spinner animation during API requests
- Respect tracker preset settings for filtering displayed stats/attributes
- Sync FAB data with lastGeneratedData for real-time updates
- Hide FAB widgets on desktop viewport (>1000px) and when panel is open
- Add settings UI for enabling/disabling individual widget types
- Update FAB widgets on manual edits in tracker editor and stats panels
2026-01-10 13:25:40 +00:00
tomt610 db2bed16a7 Clean up debug logging in history injection 2026-01-09 21:14:21 +00:00
tomt610 ecb5d74d6e Enhance preset saving and loading to include historyPersistence 2026-01-09 21:05:11 +00:00
tomt610 fea59efe4e Refactor historical context handling and remove unused initialization function 2026-01-09 20:51:28 +00:00
tomt610 b43cca5b6f Refactor message injection options in promptBuilder and trackerEditor 2026-01-09 20:24:07 +00:00
tomt610 94f562f1bb Refactor message restoration logic to use a one-time event listener 2026-01-09 20:20:04 +00:00
tomt610 3d5fc5fee1 Refactor historical context injection logic to support dynamic message indexing based on injection position 2026-01-09 20:10:21 +00:00
tomt610 98ef751a9f Implement historical context injection for chat messages and enhance settings for persistence 2026-01-09 19:39:05 +00:00
Spicy_Marinara f5641ec1f0 Merge branch 'pr-88' 2026-01-09 12:11:51 +01:00
Spicy_Marinara 0320c3fdd5 Fix duplicate keys in en.json and add missing periods to user-facing messages 2026-01-09 12:08:53 +01:00
Spicy_Marinara 3d0ebe4694 Update en.json 2026-01-09 12:00:55 +01:00
Spicy_Marinara 510723cac4 v3.3.3
- Strengthened default prompts to not include user's persona in the characters' section.
- Updated some descriptions for buttons and custom fields.
2026-01-09 11:54:43 +01:00
tomt610 f6733f87a2 feat: Add preset management system for tracker configurations
- Add preset selector dropdown in tracker editor modal
- Support creating, loading, and deleting presets
- Add per-character/group preset associations with auto-switch
- Add default preset functionality with star button
- Update import to offer 'Apply to Current' or 'Create New Preset' options
- Add preset management UI styles and import dialog styles
2026-01-09 10:38:57 +00:00
Spicy_Marinara ddc02d9bbc Release v3.3.2: Fix auto-update on chat switch & restore character removal v3.3.2 2026-01-09 10:04:29 +01:00
Spicy Marinara 659b5bb82b Merge pull request #87 from tomt610/fix/quest-removal-sync
Fix: Sync quest changes to committedTrackerData
2026-01-09 09:29:28 +01:00
tomt610 5f72e6f549 Fix: Sync quest changes to committedTrackerData
When manually adding/editing/removing quests via UI, the changes were
only saved to extensionSettings but not to committedTrackerData.userStats.
This caused the AI to see stale quest data on the next external server
update, resulting in removed quests reappearing.

- Add syncQuestsToCommittedData() function to update JSON quest data
- Call sync and saveChatData() on all quest modification actions
- Imports committedTrackerData, lastGeneratedData, saveChatData
2026-01-09 00:23:23 +00:00
Spicy_Marinara 0d71dcca04 v3.3.1: Fix Recent Events reading from lastGeneratedData and add desktop thought panel collapse v3.3.1 2026-01-08 23:29:18 +01:00
Spicy Marinara 39e2a07829 Merge pull request #85 from tomt610/feature/update-complete-event
Add event emission when tracker update completes
2026-01-08 23:18:10 +01:00
tomt610 dedfead59e Add event emission when tracker update completes
Emits 'rpg_companion_update_complete' event after updateRPGData() finishes.
This allows other extensions (like Context Prewarm) to hook into the
completion of tracker updates and perform actions afterward.

The event is emitted in the finally block, so it fires regardless of
success or failure, after isGenerating is reset.
2026-01-08 22:12:06 +00:00
Spicy_Marinara f1179d3b83 v3.3.0: Fix encounter UI theming and JSON cleaning regex properties v3.3.0 2026-01-08 21:52:31 +01:00
Spicy_Marinara 045d1da88b Update README.md 2026-01-08 19:50:20 +01:00
Spicy_Marinara bd056934e1 v3.2.5: Always enable JSON cleaning regex with proper settings 2026-01-08 18:27:16 +01:00
Spicy_Marinara e5bd1e0411 v3.2.4: Fix Present Characters field editing - relationship badges, custom fields, and avatar upload 2026-01-08 18:13:12 +01:00
Spicy_Marinara 055c19951c v3.2.3: Restore avatar upload feature for Present Characters 2026-01-08 13:05:02 +01:00
Spicy_Marinara d41996fb04 v3.2.2: Remove fixed max-width on mobile to support high zoom levels 2026-01-08 12:45:20 +01:00
Spicy_Marinara 2624309523 v3.2.1: Fix mobile viewport height issues with dvh units 2026-01-08 11:18:09 +01:00
Spicy_Marinara 7e9d98738f v3.2.0: Major update with JSON trackers, locking system, and UI improvements 2026-01-08 10:35:54 +01:00
Spicy_Marinara be05051a39 v3.1.1: Fix mobile tabs not initializing on mobile devices 2026-01-08 00:12:19 +01:00
Spicy_Marinara a3063aff4f v3.1.0: Add parser error detection and recommended models section 2026-01-07 22:56:26 +01:00
Spicy_Marinara dbf5c2d17a Merge branch 'main' of https://github.com/SpicyMarinara/rpg-companion-sillytavern 2026-01-07 21:29:20 +01:00
Spicy_Marinara 718d45095d v3.0.1 - Fix thought bubble editing persistence 2026-01-07 20:26:11 +01:00
Spicy_Marinara 897380d532 v3.0.1 - Fix thought bubble editing persistence 2026-01-07 20:25:49 +01:00
Spicy_Marinara 93327e4416 Merge remote changes for v3.0.0 release 2026-01-07 19:52:51 +01:00
Spicy_Marinara c3cdac24c6 Release v3.0.0 - Major update with JSON format, lock/unlock trackers, reorganized UI, colored dialogues, editable prompts, and numerous bug fixes 2026-01-07 17:22:22 +01:00
Spicy Marinara f536472dbe Merge pull request #82 from munimunigamer/auto-update-ext
Fixed auto updating with external api mode
2026-01-06 01:01:16 +01:00
munimunigamer 5bba422904 fixed auto updating with external api mode 2026-01-05 23:58:48 -06:00
Spicy_Marinara 8df6548e0b v2.1.3 - Improved thought bubble positioning and responsiveness
- Align thought bubbles with avatar top instead of center for better visibility
- Fix issue where bubbles extend above avatar when scrolling is limited
- Change thought circles to horizontal layout for cleaner visual flow
- Add responsive positioning that adapts to screen width changes
- Implement smart viewport detection to prevent cutoff at narrow widths
2026-01-03 11:40:07 +01:00
Spicy_Marinara 58020e93d0 Fix: Ensure clothing instruction is included in separate generation prompts 2026-01-03 01:17:41 +01:00
Spicy_Marinara ef03bb11ee Update version to 2.1.2 in settings.html 2026-01-03 00:59:07 +01:00
Spicy_Marinara d75f76b807 Update README with v2.1.2 changelog 2026-01-03 00:58:22 +01:00
Spicy_Marinara c6b71ec1aa Add optional toggle for Relationship Status Fields (v2.1.2)
- Added relationships.enabled toggle in tracker configuration
- Relationship fields and emoji badges can now be disabled/enabled
- UI toggle added in Edit Trackers > Present Characters tab
- Updated prompt generation to respect the toggle
- Maintains backward compatibility with existing configs
- Added i18n translations (en, zh-tw)
2026-01-03 00:55:29 +01:00