[PR #19] [MERGED] Multiparent and navigation #27

Closed
opened 2026-10-15 18:07:56 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/SillyTavern/SillyTavern-Timelines/pull/19
Author: @Technologicat
Created: 2/2/2024
Status: ✅ Merged
Merged: 2/4/2024
Merged by: @Cohee1207

Base: master ← Head: multiparent


📝 Commits (10+)

📊 Changes

8 files changed (+834 additions, -301 deletions)

View changed files

📝 README.md (+18 -5)
📝 index.js (+604 -182)
📝 timeline.html (+24 -18)
📝 tl_graph.js (+85 -11)
📝 tl_node_data.js (+92 -82)
📝 tl_style.css (+9 -0)
📝 tl_style.js (+0 -2)
📝 tl_utils.js (+2 -1)

📄 Description

It seems that the nearer you get to getting the UX to feel just right, the smaller the things that start feeling like major usability roadblocks. Hence the following changes:

Changelog

  • Text search:
    • The search now uses fragment search (a.k.a. swoop), e.g. ear use mat would match this line.
      • A fragment search is an AND using whitespace-delimited fragments. Their ordering in the query does not matter.
      • As before, the search query is matched over the whole message.
      • At least in my own experience, fragment search typically significantly cuts down on the user time spent on the search task. I've quickly jumped to individual lines in a 500-page book manuscript just by fragment search over the whole file (by typing short fragments of a few words that occur somewhere on that line). Didn't need other navigation methods much.
      • Inspired by the HELM Swoop function in the Helm package for Emacs.
    • Search results are now highlighted in the tooltip and in the full info panel.
      • In case of common substrings, such as las laser, the longest fragments are matched first to ensure correct highlighting.
    • Search now triggers just by focusing the search field, too.
    • Searching slightly optimized, by lowercasing the query just once.
  • The graph builder now understands nodes that have multiple parent nodes.
    • This means timelines can now converge as well as diverge.
    • This occurs when you send the same canned reply at the same chat depth in different chat sessions - for example, when using the script I posted in https://github.com/SillyTavern/SillyTavern/issues/1777.
    • If you're polite when talking to AI, this can also happen when you send just "Thanks!" and that happens to be at the same chat depth as an earlier "Thanks!" in some other timeline.
    • Previous versions simply connected the node only to its first detected parent.
  • The node ranking algorithm can now be chosen in the settings
    • Previous versions used network-simplex, new default is tight-tree
    • tight-tree better deals with the resulting mess when nodes with multiple parents exist.
  • Hover over an edge to highlight it.
  • Hover over node (or click it open) to highlight all its connected edges.
  • Click an edge to jump to its far end.
    • "Far" is measured from the clicked position to the positions of the connected nodes, picking the one further away.
    • This is convenient for navigating along long edges in the graph.
  • Node tooltip improved; edge tooltip added.
    • Tooltips now have instructions for what happens when you click etc.
    • Node tooltip uses the same message formatting (for the truncated message) as the full info panel.
    • Message truncation for the node tooltip now always occurs at a word boundary.
  • Node full info panel:
    • Added buttons, per timeline, to jump to next/previous message in that timeline.
      • This is convenient when edges overlap in the layout.
    • The button rows are now in the same visual order as the nodes in the graph (when using default layout settings).
      • It's alphabetical, so the newest items appear at the bottom for now.
    • The buttons in each row now auto-size themselves to the same vertical height (tallest one wins).
      • This yields a visually more pleasing layout when the label in the main button becomes so long it takes multiple lines.
  • Clicking a legend entry again to unfocus it now zooms out, for consistency with text search behavior (clearing the search zooms out).
  • Fixed bugs in padding size computation for the auto-zooms.
    • Respects zoom limits correctly.
    • Limits the amount of padding when zooming in really close, so that there is always enough space for at least one node.

Screenshot

Multiple parent nodes, edge highlighting, and the new navigation buttons.

image


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/SillyTavern/SillyTavern-Timelines/pull/19 **Author:** [@Technologicat](https://github.com/Technologicat) **Created:** 2/2/2024 **Status:** ✅ Merged **Merged:** 2/4/2024 **Merged by:** [@Cohee1207](https://github.com/Cohee1207) **Base:** `master` ← **Head:** `multiparent` --- ### 📝 Commits (10+) - [`967b42b`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/967b42b1cffa3099ce294a00ff9303b053cd61ce) Treat multiple parent nodes correctly; add rank algorithm selection - [`ee54c9d`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/ee54c9d72bc31448079681cc6e4572a223f6a7d3) Better consistency for auto-zoom-out - [`d20d2c0`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/d20d2c02d30519046eb252bbbf80d856bf60c8d4) clean up taptippy closing - [`39b00b0`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/39b00b0212fb62932587178951b75fe67eda4edb) add comment - [`09a0199`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/09a0199969e6eaf78c6bc3a0c73383fa24de48d6) whitespace - [`2093528`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/20935281450557b74a1f70d10063daca2fbade43) comment - [`15826f1`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/15826f125ed183e1d9992aaf775f5831d88a41d7) comment - [`7c2b633`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/7c2b633f6c95f11c5cfafc4d59d65b5d7913b976) add edge highlighting on mouseover, click to navigate to far end - [`a82c8e1`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/a82c8e1d57011b1fc01f8ac918f8d430a5a71029) update README - [`f07dfe8`](https://github.com/SillyTavern/SillyTavern-Timelines/commit/f07dfe8893096eb4921d71acea45e288f9b27ac9) add comment ### 📊 Changes **8 files changed** (+834 additions, -301 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+18 -5) 📝 `index.js` (+604 -182) 📝 `timeline.html` (+24 -18) 📝 `tl_graph.js` (+85 -11) 📝 `tl_node_data.js` (+92 -82) 📝 `tl_style.css` (+9 -0) 📝 `tl_style.js` (+0 -2) 📝 `tl_utils.js` (+2 -1) </details> ### 📄 Description It seems that the nearer you get to getting the UX to feel just right, the smaller the things that start feeling like major usability roadblocks. Hence the following changes: **Changelog** - Text search: - The search now uses *fragment search* (a.k.a. *swoop*), e.g. `ear use mat` would match this line. - A fragment search is an AND using whitespace-delimited *fragments*. Their ordering in the query does not matter. - As before, the search query is matched over the whole message. - At least in my own experience, fragment search typically significantly cuts down on the user time spent on the search task. I've quickly jumped to *individual lines in a 500-page book manuscript* just by fragment search over the whole file (by typing short fragments of a few words that occur somewhere on that line). Didn't need other navigation methods much. - Inspired by the *HELM Swoop* function in the Helm package for Emacs. - Search results are now highlighted in the tooltip and in the full info panel. - In case of common substrings, such as `las laser`, the longest fragments are matched first to ensure correct highlighting. - Search now triggers just by focusing the search field, too. - Searching slightly optimized, by lowercasing the query just once. - The graph builder now understands nodes that have multiple parent nodes. - This means timelines can now converge as well as diverge. - This occurs when you send the same canned reply at the same chat depth in different chat sessions - for example, when using the script I posted in https://github.com/SillyTavern/SillyTavern/issues/1777. - If you're polite when talking to AI, this can also happen when you send just *"Thanks!"* and that happens to be at the same chat depth as an earlier "Thanks!" in some other timeline. - Previous versions simply connected the node only to its first detected parent. - The node ranking algorithm can now be chosen in the settings - Previous versions used `network-simplex`, new default is `tight-tree` - `tight-tree` better deals with the resulting mess when nodes with multiple parents exist. - Hover over an edge to highlight it. - Hover over node (or click it open) to highlight all its connected edges. - Click an edge to jump to its far end. - "Far" is measured from the clicked position to the positions of the connected nodes, picking the one further away. - This is convenient for navigating along long edges in the graph. - Node tooltip improved; edge tooltip added. - Tooltips now have instructions for what happens when you click etc. - Node tooltip uses the same message formatting (for the truncated message) as the full info panel. - Message truncation for the node tooltip now always occurs at a word boundary. - Node full info panel: - Added buttons, per timeline, to jump to next/previous message in that timeline. - This is convenient when edges overlap in the layout. - The button rows are now in the same visual order as the nodes in the graph (when using default layout settings). - It's alphabetical, so the newest items appear at the bottom for now. - The buttons in each row now auto-size themselves to the same vertical height (tallest one wins). - This yields a visually more pleasing layout when the label in the main button becomes so long it takes multiple lines. - Clicking a legend entry again to unfocus it now zooms out, for consistency with text search behavior (clearing the search zooms out). - Fixed bugs in padding size computation for the auto-zooms. - Respects zoom limits correctly. - Limits the amount of padding when zooming in really close, so that there is always enough space for at least one node. **Screenshot** Multiple parent nodes, edge highlighting, and the new navigation buttons. ![image](https://github.com/SillyTavern/SillyTavern-Timelines/assets/16972251/26970cf6-1bc2-4e8f-b83b-af9bf9a2aa35) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-15 18:07:56 +00:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
SillyTavern/SillyTavern-Timelines#27
No description provided.