Automated highlighting using AI / Local LLM

Using DEVONthink 4 AI, would it be possible to automate editing a MarkDown document to highlight the most relevant sentences in an article?

Under batch processing for example, there is an option to automate renaming, provide a summary in bullet points, or append Chat responses to an annotation. However I can’t seem to find instructions how to use the AI to edit documents themselves.

Example Prompt

Analyze the selected Markdown document and identify the 5-7 most significant sentences that encapsulate:  
1. Core arguments or findings  
2. Critical data points or statistics  
3. Pivotal transitional statements  

Format the output as follows:  
- Preserve original document structure  
- Enclose identified sentences within {== ==} markers  
- Maintain all existing formatting except highlighted sections  
- Do not add commentary or explanations  

Prioritize sentences that demonstrate:  
- Conceptual complexity  
- Methodological importance  
- Thematic centrality to the document's purpose

That’s only possible via the chat assistant (if enabled in the settings and supported by the model) or by using your own script:

on scriptOutput(theRecord, theInput)
	tell application id "DNtp"
		save version of record theRecord
		update record theRecord with text theInput mode replacing
	end tell
end scriptOutput

But I would highly recommend one of the better models like GPT-4o or Claude Sonnet.

1 Like