Menu

Using LLMs and LogSeq to create flashcards

13th February 2025 - AI
Using LLMs and LogSeq to create flashcards

LogSeq is a great little free application which uses markdown and tags to create a graph of information, allowing the user to make connected notes, diary items or flashcards.

A flashcard in the real world (imagine!) is a piece of card with a question or statement on one side and the answer on the other. Flashcards are used to practice recall, for subjects like language learning or any subject that requires recall of facts and figures.

Large Language Models (LLM) are machine learning applications which utilise Transformers to mine a stored model for potential responses to text based questions or requests.

So far, so 2025.

Logseq has a feature to create flashcards. All that is needed is a text block to be ended with a #card or a [[card]] tag.

An LLM can be used to create flashcards on your favourite subject. This usually works out the box, but you will get better results by priming a chat response before requesting for the flash cards. Priming the LLM puts more weight on the valid responses. Most of the time, LLMs do a good enough job though, but best give the questions a look before putting them in LogSeq.

Here is my standard prompt prior to asking for flashcards.

In LogSeq, a diary and note taking application, there is a feature where markdown can be used to create a flashcard, by adding a #card to the end of a block and then a child block becomes the answer to a question. The child block is usually a single line, meant for quick memory recall. 
e.g. 
- What is the colour of the sky #card 
   - Its blue

I will ask you for flashcards so I can use them in LogSeq. Supply them in markdown format.

The LLM (it really doesn’t matter which) will then give an example. Adjust its response if it is going down a Juju path.

Give me 5 flashcards for MS-900 Microsoft 365

The response from the LLM would be something like the following..

- What is Microsoft 365? #card  
  - A comprehensive suite of cloud-based productivity, collaboration, and security tools, including Office 365, Windows 10, and Enterprise Mobility + Security.

- What are the core components of Microsoft 365? #card  
  - Office 365 for productivity, Windows 10 for device management, and Enterprise Mobility + Security for identity and data protection.

- What are the three primary cloud service models? #card  
  - IaaS (Infrastructure as a Service), PaaS (Platform as a Service), and SaaS (Software as a Service).

- How does Microsoft 365 address security and compliance? #card  
  - By offering built-in features like multi-factor authentication, data loss prevention, encryption, and comprehensive compliance certifications via the Microsoft Trust Center.

- What are the benefits of adopting Microsoft 365 for businesses? #card  
  - Scalability, cost efficiency, automatic updates, global accessibility, and enhanced collaboration tools.

In LogSeq, create a new page called MS-900 Flashcards and paste in the markdown created by the LLM.

Now in LogSeq, you can click the flashcards item in the left hand menu.

But wait! What if you’re a total boss and want to learn two subjects at once? But you don’t want the flashcards to be shown. If you use the flashcards menu item, you will see all flashcards.

However, LogSeq has a feature called queries, which allows you to create another page, and have a section for each flashcard set based on a query that uses the page name. Create multiple pages, or create a page with multiple queries. Go wild, summer child!

{{cards [[MS-900 flashcards]]}}

In place of the query a flashcard will be shown from the page specified.

Very handy. Hope this helps.

Flashcards / Spaced Repetition | Logseq Tips & Tricks

Ollama

Leave a Reply