I recently screwed up a number of notes with a well-intentioned agent and I’m trying to figure out what I should have done instead. What I wanted was a list of all the Tags I had assigned to notes for a sub-project within a larger Tinderbox document. So the agent was
Query: $ForSubproject==true (to capture all notes with that Boolean attribute checked)
Action: $Text = values(“Tags”).format("\n");
This yielded an agent containing aliases of all the relevant notes. Its text was a tidy list of all the values of Tags that that list of notes contained.
Problem is, of course, that the the agent affected the text of every note for which the query was true. In other words, the list of attributes replaced the text of every note the agent collected.
Pretty dumb, in retrospect. But here’s what I can’t figure out: What would have been the right way to do this? How could I have instructed the agent to collect all $ForProject=True and generate the list of Tag attributes only in its own text field and not in every note it collected? I am sure it is glaringly obvious how to tell an agent to do something to its own text and not the text of all its notes. But I can’t figure it out.