The Notemd plugin transforms your note-taking experience by integrating AI-powered processing and knowledge graph automation. It connects to both cloud and local LLM providers like OpenAI, Anthropic, Ollama, and LMStudio to intelligently chunk and process documents, insert context-aware wiki-links, and auto-generate concept notes. It includes features like web search summarization using Tavily or DuckDuckGo, duplicate detection and cleanup, and batch Mermaid/LaTeX syntax correction. Notes can be processed in bulk, with customizable file naming and storage paths. The plugin also supports retry logic for failed API calls, stable connection testing, and detailed configuration of provider settings. It's ideal for users building a personal knowledge base or conducting research-driven writing with structured link graphs.
API key for LLM providers like OpenAI, Anthropic, DeepSeek, Google, Mistral, Azure, or OpenRouter.
API key for Tavily (if using web research).
LMStudio or Ollama server running locally (if using local LLMs).
Notemd v1.5.1 Change Log
This document summarizes the major functional and architectural changes implemented.
Code/Architecture Update
English
- Improved Progress Bar Logic: Enhanced the logic for progress bar updates to ensure it accurately reflects the completion status of operations, preventing it from getting stuck at intermediate percentages.
Chinese (中文)
- 改进的进度条逻辑: 增强了进度条更新逻辑,确保其准确反映操作的完成状态,防止其卡在中间百分比。
Implementation of Functionality
English
- Accurate UI Feedback for Wiki-Link Command: The "Create Wiki-Link & Generate Note from Selection" command now provides accurate progress updates, reaching 100% completion and automatically closing the progress modal upon successful execution.
Chinese (中文)
- Wiki-Link命令的准确UI反馈: “从选中文本创建维基链接并生成笔记”命令现在提供准确的进度更新,在成功执行后达到100%完成并自动关闭进度模态框。
Code/Architecture Update
English
- Refined Concurrent Processing: Implemented a staggered launch mechanism in the
createConcurrentProcessorutility. This ensures that API calls within a parallel batch are spaced out by the configuredapiCallIntervalMs, preventing request bursts and resolving potential 429 rate-limit errors from LLM providers. - Modularized Syntax Fixing: Refactored the
batchFixMermaidSyntaxInFolderfunction by extracting the core logic into a new, reusablefixMermaidSyntaxInFilefunction. This improves code modularity and maintainability.
Chinese (中文)
- 优化并发处理: 在
createConcurrentProcessor工具函数中实现了交错启动机制。这确保了并行批处理中的API调用能根据配置的apiCallIntervalMs间隔执行,防止了请求爆发并解决了来自LLM提供商的潜在429速率限制错误。 - 模块化语法修复: 重构了
batchFixMermaidSyntaxInFolder函数,将核心逻辑提取到一个新的、可复用的fixMermaidSyntaxInFile函数中。这提高了代码的模块化和可维护性。
Implementation of Functionality
English
- Enabled "Auto Mermaid Fix" Feature: Implemented the core logic for the "Auto Mermaid Fix" feature by adding the
fixMermaidSyntaxInFilefunction. This feature, when enabled in settings, automatically corrects Mermaid and LaTeX syntax in notes generated by various commands, ensuring diagram validity. - Updated Documentation: Updated
README.mdandREADME_zh.mdto reflect the improved reliability of batch processing.
Chinese (中文)
- 启用“自动Mermaid修复”功能: 通过添加
fixMermaidSyntaxInFile函数,实现了“自动Mermaid修复”功能的核心逻辑。该功能在设置中启用后,会自动校正由各种命令生成的笔记中的Mermaid和LaTeX语法,确保图表的有效性。 - 更新文档: 更新了
README.md和README_zh.md,以反映批处理可靠性的提升。
Code/Architecture Update
English
- Parallel Processing Framework: Introduced a parallel processing framework for batch operations. This was achieved by implementing a custom
Semaphorefor concurrency control and acreateConcurrentProcessorfactory function inutils.ts. - Refactored Batch Commands: Refactored all major batch processing commands (
processFolderWithNotemdCommand,batchGenerateContentForTitles,batchExtractConceptsForFolderCommand) inmain.tsandfileUtils.ts. These commands now utilize the new concurrent processor, allowing for serial I/O operations while executing LLM API calls in parallel. This significantly improves performance for large folders. - Enhanced Progress Reporting: Updated the
ProgressReporterinterface and its UI implementations (ProgressModal,NotemdSidebarView) to display the number of active parallel tasks, providing users with more detailed feedback during batch operations. - Robustness and Error Handling:
- Resolved various TypeScript build errors, including incorrect import paths for
normalizeNameForFilePathand type mismatches forview.file?.basename. - Added safeguards to prevent runtime errors, such as ensuring a note is successfully created before attempting to generate content for it.
- Resolved various TypeScript build errors, including incorrect import paths for
Chinese (中文)
- 并行处理框架: 为批量操作引入了并行处理框架。通过在
utils.ts中实现自定义的Semaphore(信号量) 和createConcurrentProcessor工厂函数来完成此项工作。 - 重构批量处理命令: 重构了
main.ts和fileUtils.ts中的所有主要批量处理命令 (processFolderWithNotemdCommand,batchGenerateContentForTitles,batchExtractConceptsForFolderCommand)。这些命令现在利用新的并发处理器,允许在并行执行 LLM API 调用的同时进行串行 I/O 操作,从而显著提高了处理大文件夹时的性能。 - 增强的进度报告: 更新了
ProgressReporter接口及其 UI 实现 (ProgressModal,NotemdSidebarView),以显示活动并行任务的数量,在批量操作期间为用户提供更详细的反馈。 - 健壮性与错误处理:
- 解决了多个 TypeScript 构建错误,包括
normalizeNameForFilePath的不正确导入路径以及view.file?.basename的类型不匹配问题。 - 增加了安全措施以防止运行时错误,例如在尝试为笔记生成内容之前,确保笔记已成功创建。
- 解决了多个 TypeScript 构建错误,包括
Implementation of Functionality
English
- New Batch Processing Settings: Added new user settings in the UI to control the parallel processing behavior:
Enable Batch ParallelismBatch ConcurrencyBatch SizeDelay Between Batches (ms)API Call Interval (ms)
- New Command: "Create Wiki-Link & Generate Note from Selection":
- This new command streamlines the knowledge creation workflow.
- It allows a user to select text, which is then automatically converted to a
[[wiki-link]]. - A corresponding concept note is created in the designated "Concept Note Folder". If the note already exists, a backlink is added instead.
- Finally, its content is automatically generated by the LLM using the "Generate Content from Title" functionality.
- New Setting: "Auto-run Mermaid Syntax Fix": Added a setting to automatically run a syntax-fixing pass on notes after content generation tasks to ensure generated Mermaid diagrams are valid.
- Updated Documentation: Updated
README.mdandREADME_zh.mdto comprehensively document all new settings and the new "Create Wiki-Link & Generate Note" command.
Chinese (中文)
- 新增批量处理设置: 在UI中添加了新的用户设置以控制并行处理行为:
启用批处理并行化批处理并发数批处理大小批处理间隔延迟 (毫秒)API 调用间隔 (毫秒)
- 新命令:“从选中文本创建维基链接并生成笔记”:
- 这个新命令简化了知识创建的工作流程。
- 它允许用户选择文本,然后自动将其转换为
[[维基链接]]。 - 在指定的“概念笔记文件夹”中创建一个相应的概念笔记。如果笔记已存在,则会添加反向链接。
- 最后,使用“根据标题生成内容”功能,由 LLM 自动为该笔记生成内容。
- 新设置:“生成后自动修复Mermaid语法”: 添加了一个设置,用于在内容生成任务后自动对笔记运行语法修复,以确保生成的Mermaid图表有效。
obsidian-NoteMD_1.5.1.zip