微算力 · API 导航与自营网关
API 接入 EN
未登录登录
📝

Apple Notes 本地提取与实时同步

Apple Notes Extractor · v1.0.0
办公 安全 A 级 作者 ianderrington 公开目录收录
1.3k 下载 0 安装 6k 收藏 15 浏览

简介

本地提取和监控 Apple Notes 内容,支持批量导出、实时同步和多格式转换,隐私优先设计。

原始描述

Extract and monitor Apple Notes content for workflow integration. Supports bulk extraction, real-time monitoring, and export to various formats.

通过你的 Agent 添加

点「快速安装」复制一段指令,粘给你正在用的 Agent(Claude Code、Codex、OpenClaw 等),它会自己完成安装。

或者手动安装

Claude Codeunzip -o skill.zip -d ~/.claude/skills/apple-notes-extractor/
其它 Agent解压到它自己的 skills 目录,目录名用 apple-notes-extractor

包里是 SKILL.md 加作者附带的文件,解压后目录名就是技能名。 技能申请的权限由作者决定,装之前请确认它能读什么、能执行什么。

中文使用说明 来自收录源

核心用法

Apple Notes Skill 是一套专为 macOS 设计的本地化工具集,通过 Python 脚本与 AppleScript 桥接,实现对 Apple Notes 应用的全方位数据提取与监控。用户可通过命令行执行三种核心操作:

  1. 提取(Extract):支持简单文本提取或完整提取(含附件),可按文件夹筛选,输出格式包括 JSON、Markdown、HTML、SQLite 等
  2. 监控(Monitor):以守护进程模式运行,检测笔记变更并支持自动导出,轮询间隔可自定义
  3. 处理与导出(Process & Export):提供笔记后处理、Obsidian 知识库直导、以及知识图谱生成能力

配置层面采用 JSON 驱动的设计,configs/extractor.json 控制提取行为与隐私过滤器,configs/monitor.json 管理监控策略与自动处理规则。

显著优点

  • 完全本地化:所有处理在本地完成,零云端依赖,符合隐私优先原则
  • 多格式生态:原生支持 Obsidian、Logseq、Notion 等主流知识管理工具
  • 实时同步能力:守护进程模式可实现准实时的工作流集成
  • 元数据完整保留:提取创建/修改时间、文件夹层级等关键信息
  • 增量更新机制:避免全量重复提取,提升效率

潜在缺点与局限性

  • 平台锁定:仅支持 macOS,无法跨平台使用
  • 权限依赖:需用户手动授予 Notes 访问权限,企业环境可能受限
  • 非官方 API:依赖 AppleScript 桥接,存在随 macOS 更新失效的风险
  • 监控性能:轮询机制(非真正事件驱动)在高频写入场景下存在资源开销
  • 附件处理限制:复杂格式附件的完整性依赖 AppleScript 暴露能力

适合人群

  • 需要将 Apple Notes 迁移至 Obsidian/Logseq 等第三方知识库的重度笔记用户
  • 构建个人知识管理(PKM)自动化工作流的效率工具爱好者
  • 对数据主权敏感、拒绝云端同步方案的隐私优先用户
  • 开发 AI 处理管道、需要将笔记内容结构化喂给大语言模型的技术用户

常规风险

  • 权限撤销风险:macOS 安全更新可能重置隐私权限,导致功能中断
  • API 兼容性:AppleScript 接口非公开承诺,存在未来版本不兼容可能
  • 数据一致性:监控模式下的轮询间隔若设置不当,可能遗漏快速连续变更
  • 敏感内容暴露:虽有隐私过滤器配置,但本地导出文件仍需用户自行管控访问权限
  • 依赖维护:Python 3.8+ 及特定包版本要求,长期维护需关注依赖链健康度

技能正文


name: apple-notes description: Extract and monitor Apple Notes content for workflow integration. Supports bulk extraction, real-time monitoring, and export to various formats. metadata: {"openclaw": {"requires": {"bins": ["python3", "osascript"]}, "emoji": "📝"}}

Apple Notes Skill

Extract and monitor Apple Notes content for workflow integration with support for bulk extraction, real-time monitoring, and export to various formats.

Prerequisites

  • macOS with Apple Notes app
  • Python 3.8+ (for coordination scripts)
  • osascript (built-in macOS)
  • Proper macOS permissions for Notes access

Installation

# Run the installation script
./scripts/setup.sh

# Or manual setup
chmod +x scripts/*.py
pip3 install -r requirements.txt

Commands

Extract Notes

# Basic extraction (all notes)
python3 scripts/extract-notes.py --method simple

# Full extraction with attachments
python3 scripts/extract-notes.py --method full

# Extract specific folder
python3 scripts/extract-notes.py --folder "Work Notes"

# Output to specific format
python3 scripts/extract-notes.py --format markdown --output ~/notes

Monitor Notes

# Start monitoring daemon
python3 scripts/monitor-notes.py --daemon

# Single check for changes
python3 scripts/monitor-notes.py --check-once

# Monitor with custom interval (seconds)
python3 scripts/monitor-notes.py --interval 30

Processing and Export

# Process extracted notes
python3 scripts/notes-processor.py output/raw -o output/processed

# Export to Obsidian
python3 scripts/export-obsidian.py --vault ~/MyVault

# Generate knowledge graph
python3 scripts/knowledge-graph.py --input output/processed

Configuration

Edit configs/extractor.json for:

  • Output formats (JSON, Markdown, HTML)
  • Privacy filters
  • Folder selection
  • Processing options

Edit configs/monitor.json for:

  • Monitoring intervals
  • Change detection settings
  • Auto-processing rules

Features

  • ✅ Extract text content from all notes
  • ✅ Handle embedded images and attachments
  • ✅ Process note metadata (dates, folders)
  • ✅ Multiple output formats (JSON, Markdown, SQLite)
  • ✅ Real-time monitoring for changes
  • ✅ Privacy-first design with local processing
  • ✅ Integration with knowledge management tools
  • ✅ Automatic deduplication
  • ✅ Incremental updates

Output Formats

Format Description Use Case
json Structured data with metadata API integration
markdown Human-readable text files Documentation
sqlite Database format Searchable archive
obsidian Obsidian vault format Knowledge management

Examples

# Quick start - extract all notes to Markdown
python3 scripts/extract-notes.py --format markdown --output ~/extracted-notes

# Monitor and auto-export to Obsidian
python3 scripts/monitor-notes.py --daemon --auto-export obsidian

# Extract work notes with full content
python3 scripts/extract-notes.py --method full --folder "Work Notes" --format json

# Process and create knowledge graph
python3 scripts/extract-notes.py --method full
python3 scripts/notes-processor.py output/raw -o output/processed
python3 scripts/knowledge-graph.py --input output/processed --output knowledge-graph.json

Security & Privacy

  • All processing happens locally on your machine
  • No data sent to external services
  • Respects macOS security permissions
  • Configurable privacy filters for sensitive content
  • Optional encryption for exported data

Integration

Compatible with:

  • Obsidian (direct vault export)
  • Logseq (Markdown export)
  • Notion (JSON import)
  • Custom workflows (JSON/CSV output)
  • AI processing pipelines
  • Search engines (full-text indexing)

Troubleshooting

Common issues:

  • Permission denied: Grant Notes access in System Preferences → Security & Privacy
  • Import errors: Ensure Python 3.8+ and required packages installed
  • AppleScript errors: Check if Notes app is running and accessible
  • Empty output: Verify folder names and note permissions

See README.md for detailed troubleshooting guide.

正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。

标签

apple-notesproductivityknowledge-managementobsidianlocal-firstmacosexportautomation

同类 Skill