Access to suggested links with Action Code

dear all,
I’ve the project to fetch the content of an academic website (course documents), each document being represented as a note: pretty easy to do with the AutoFetch command. Then I want to automatically link the notes according to their semantic proximity. I guess that the “suggested links” would be of help to do that (Links window), but I cannot get which Action Code to use in order to do bulk LinkTo from a note to its most content-related notes (or all those suggested). Would you like to help me? thanks!

The action code similarTo() should be the conduit for this, but I can’t get it to work and can’t find a working code sample.

Essentially, you want to collect a note of the items similar to the current note then iterate the list to make links.

You cannot (yet) do this easily. And, to be sure, I’m not confident you want to do it; the Suggested Links metric is interesting and it’s sometimes worth pondering its suggestions, but I’m not sure you would want to adopt them wholesale!

A related tasks might be to take the $NLNames or $NLPlaces of a note and link them to other notes that mention the same names or places.

If there is sentiment for supporting this in action code, I’d be open to giving it a try.

dear Mark,
thx for this hint, which I’ll explore. Not exactly: I don’t want to produce any new note. Just want to automatically link existing notes (each representing a doc in a website and containing its text) with their semantically closest ones, thru “suggested links”. Then, the idea is to visualize them w/ the hyperbolic view. Is it clearer? thx and best.
Philippe.

FWIW, clicking on a suggested link creates that link. That’s as automated as it gets at present. But, I think that’s actually a pretty good filter. Clicking the listing item offers just enough friction, in the moment, to think “yes, I’ll; not use that suggestion” and avoid introducing linkage noise.

dear Mark,
thx for your reply. Very few locations in the considered texts, but $NLNames would do (partly) the job because they reference to academic works and the cited papers’ authors would be captured… but not the texts’ content by itself.
My opinion is that feature (automatic linking of “related” notes using a semantic engine) would be very useful… maybe also to other readers?
thanks & best,
philippe

I’m reviving this “old” topic, because I didn’t want to start a new one if there was one that mostly set the relevant context. This one looks right.

I had never used the Links view before. (Suggestion: Should go in the Note menu with all the other link items.) I’d seen it demo’ed of course, but since I don’t do any interior linking in my Tinderbox blog file (the marmot), I never paid much attention to it.

Today, during the meet-up, someone typed CMD-7 in the chat. Out of curiosity, I went to the marmot and hit CMD-7. Holy crap! This thing’s amazing!

The marmot as it exists as of this writing is 966 notes, 377,351 words. In the Suggested pane of this morning’s post were 10 notes. The earliest one, I believe, went back to November '21.

Question: What is the scope of the query? How far back does it look for suggested links? I have notes going back to 2013. It only suggested back to 2021.

If you read Michael Tsai’s blog, he often offers links to related posts in his posts.

This makes it easy to gather potentially related posts and offer a similar feature.

Thinking about this briefly, in my use case I would be exporting links to posts already on the web in the marmot’s archives. I don’t need interior links. But it is useful to have the note names already gathered, which I would then have to manually apply the web links if I wanted to post “related” items.

I wonder if it might be possible to do something like this: After I review the notes and decide which ones I might wish to post as related, I option-click to select those notes (some method of selection, boolean check-box, whatever) then Copy those titles, just the titles, to the clipboard. I would then Paste them into the $Text of the post, and then create the relevant web links.

I’ll have to think about the formatting, maybe some kind of separate div in the stylesheet or something. But it would save me from mousing over to each note I wanted to create an html link to, copy its title, paste it into the text. I mean, they’re all right there in the Suggested pane, albeit perhaps not contiguous, so non-contiguous selection would be nice, but deleting unwanted ones in the $Text of the note wouldn’t be unduly onerous.

Finally, I want to say how useful this feature is for people who use Tinderbox as a form of journal. To be able to look back and reflect on previous notes. Even from a blogging perspective, it’s useful to see what I’ve written before and how my views may be inconsistent or evolving or whatever.

I think this is amazing! But maybe it’s just me, I’m easily amazed or something!

1 Like

No problem with dusting off old threads.

To clarify (having been at today’s meet), above you are referring to the Links panel—rather than the Browse Links pop-over.

The scope of the links pane is the whole document; there are no user controls for altering that scope, the created date range (also whole doc) or how the list is generated.The ‘suggested’ links are gnomically documented as:

These are notes to which Tinderbox assesses the user might usefully create new links.

I don’t think that’s intended to be cryptic but I is I suspect a slowly evolving set of heuristics. Turning the problem around, are there suggestions you think are missing?

Currently, the interaction is a UI affordance: see it and or click to create the link. I think your usage might imply a feature request for an action code to return a list of suggested links. I see the time ‘saving’ to the user of picking from a list but I suspect the engineering might be disproportionate. Also for all that work, even if added to the clipboard ISTM it makes sense it is stored somewhere else too. Being able to pick from this list is doubtless a factor in how such a feature might be implemented.

I think the ‘bridge’ from UI to your blog is a list of $Path data giving you rapid/easy access to existing export methods.

In the short term an action code to return a list of paths of suggested link(ed note) items might be a first step down this path.

Being able to leverage value from past endeavour is useful, if only as it makes the effort that might be put into the original work more worthwhile (when the zeitgeist is “give it to me NOW, my time is too valuable to waste with work”).

Glad today was useful. I find show and tell goo, it leads to new insights. Like the fun of the Web in the 90s and daily finding cool new things to do. :slight_smile:

Hard to say, but I’m guessing that sometime in the years before 2021 I may have opined on similar matters! I was wondering if the algorithm only looked back x-months, or if the UI was limited to the 10 most recent notes, or something like that.

I love being able to view and read the notes, with all their displayed attributes, in separate windows. This is also something that has never been part of my process before; but seems to demand becoming a part of it now.

I suspect there is a way to automatically construct the html for related links using export code (Action code?), perhaps from the $Path attribute.

Well, “It’s only a blog!” Which is to say, as ephermal matters go, perhaps I shouldn’t think that I’m dealing with deathless prose. But I have at least a modicum of self-curiosity, and the thought that something like this might offer new avenues for perhaps “light” introspection appeals to me. To allow me to “see what I think,” as it has occurred over time.

The related links for export functionality is really just a nice to have feature, compared to having this facility literally at my fingertips, even in its present form. In all the reading I’ve done about Tinderbox in a long relationship with the app, I don’t recall anyone ever discussing it this way. I think Beck Tench mentioned something about getting random notes as points of departure or inspiration, but I don’t think I’ve seen it mentioned as a tool for introspection. But I can’t say I’ve read everything.

Perhaps others have done so with other apps, like DevonThink or something.

Yes, today was worthwhile, in the “surprise and delight” kind of way.

My point re the zeitgeist, is that many things (Q.V. the dynamic map demo today) are do-able with some action/export code wrangling. Not dissing The Marmot! I was suggesting that ideas like you suggest give extra value to the work you’ve already put into the blog.

However, at present I think there is neither a UI nor action code method to select items in the suggested link list. I fear all you want hinges on that missing functionality.

HTH.

I took your meaning correctly! I was just being, perhaps excessively, self-deprecating. No worries.

And, yes, I believe this functionality is a significant value-added feature to doing any kind of blogging or journaling in Tinderbox, by leveraging all the preceding work. I’m sort of surprised and dismayed it’s taken me to now to learn about it.

1 Like

Don’t be dismayed. With such a big toolbox, some of the less familiar tools get lost at the bottom of the box and overlooked. In that vein, today’s meetup map demo arose out of me starting an answer to another thread to say something wasn’t possible before I realised it was … using approaches I’d overlooked. :slight_smile:

1 Like

I don’t think this cares about older notes. It does limit itself to the ten (I think) most similar notes, and it’s possibly your more recent notes are more similar to each other than to older notes. It’s certainly a curious phenomenon.

I’ve always had a weakness for my very early paper on The Link Apprentice, nice summarized here: Elements of Hypermedia Design - 6.3 Automatic Link Generation - the Link Apprentice.

(Aside: This was a rare experience of real science: I set out to show that an approach advocated by some very senior people (Gerard Salton, Bruce Croft) wouldn’t work in realistic conditions. I didn’t have the computing power to do the algorithm correctly, so I found a clever fast approximation. But the paper I meant to write was a demonstration: “this doesn’t work.” But it did work surprisingly well, not only for blog posts but even for stuff like distinguishing Madison’s Federalist papers from Hamilton’s, which I can’t do myself.)

Currently, Tinderbox uses one of the more orthodox variants, nearly strict tf-idf. I’d like to play with something more interesting and heuristic.

2 Likes

Apropos the above, I happened to come across this in an out-of-print book(!) that the publisher doesn’t sell any more … possibly relevant :wink:

Active consideration of PKM, pre-Web, who knew such a thing was possible?

Extra credit links:: the above refers to a 1998 hypertext written in the now-gone hypertext tool by Eastgate inc. that by the wonders of the Web, and the wonderful ELL at WSU, can be seen in a traversal here: The Election of 1912.

†. Professor Grigar’s wonderful Electonic Literature Laboratory is here; History – Electronic Literature Lab

Yep, it limits the suggestions to 10 notes, which is fine. It doesn’t seem to care about dates, as I tested a 2018 note that had a 2013 note in the suggestions, along with one from 2021.

1 Like