skip to content
ainoya.dev

Enhancing Personal Knowledge Management with Pocket and Obsidian Integration

/ 3 min read

Introduction

For my personal and professional needs, I rely on two powerful tools: Pocket for collecting and storing articles, and Obsidian for organizing and synthesizing my thoughts. This blog post explores how I integrated these tools to streamline my workflow and enhance productivity.

Using Pocket for Information Collection

Pocket is my go-to tool for gathering information from the internet. It’s incredibly convenient to save articles and use them later for discussions with colleagues or casual conversations. The ability to have a curated library of articles at my fingertips significantly enhances the quality of my interactions and keeps me well-informed.

Organizing Thoughts with Obsidian

For organizing my personal thoughts and research, I use Obsidian. This powerful note-taking app allows me to create a structured and interconnected knowledge base. When transferring content from Pocket to Obsidian, I often refer back to the articles I’ve saved in Pocket. However, manually adding links from Pocket to my Obsidian notes was becoming time-consuming.

Automating the Workflow

I wanted to find a way to automate the process of linking Pocket articles to my Obsidian notes. Since my Obsidian files are stored on iCloud and synced across my devices, I considered creating a script to fetch articles from Pocket locally.

Choosing an Independent Implementation

While implementing this directly as an Obsidian plugin was an option, I decided to take an independent approach. This would make it easier to batch process markdown files and maintain flexibility in how I manage my notes.

Implementing dom-distiller API and PocketMD

To achieve my goal, I developed two key components: the dom-distiller API and PocketMD.

dom-distiller API

I needed a way to extract essential content from saved HTML articles and convert them to markdown. This would also help reduce context length when processing with LLMs. By leveraging the chromium/dom-distiller implementation and executing content extraction scripts with Puppeteer, I achieved the desired functionality.

I developed the API to run on Cloudflare Workers, avoiding local machine load and making future integrations with tools like make (Integromat) and Zapier possible.

PocketMD

Next, I created a set of scripts called PocketMD to handle local processing of articles saved in Pocket. You can find the repository here: ainoya/PocketMD. This setup involves storing data in SQLite for easy processing and includes the following features:

  • Retrieve articles from Pocket and save them in SQLite.
  • Extract URLs from SQLite, fetch full text using the Distiller API, and save it.
  • Generate summaries of articles using Google Vertex AI based on the information stored in SQLite.
  • Convert the information to markdown format for use with Obsidian or similar applications.

By using LLMs (Google Vertex AI), I generate summaries and Obsidian keywords, automatically creating links to existing notes. This interlinking enhances my thought organization in Obsidian.

Conclusion

The integration of Pocket and Obsidian through custom scripts has significantly improved my note management and information retrieval processes. With keyword links in Obsidian, I can quickly reference saved articles, enhancing the efficiency of my thought organization.

Furthermore, the knowledge graph constructed in Obsidian aligns well with tools like Graph RAG. This allows for implementing solutions that leverage LLMs to propose resolutions across multiple articles, addressing common topics of interest.

By automating the workflow between Pocket and Obsidian, I have created a seamless, efficient system that enhances my productivity and keeps my knowledge base robust and interconnected.