{"id":48294193,"url":"https://github.com/davidwhittington/notes-manager","last_synced_at":"2026-04-04T23:28:49.018Z","repository":{"id":343585067,"uuid":"1178316119","full_name":"davidwhittington/notes-manager","owner":"davidwhittington","description":"A Python CLI for auditing and reorganizing Apple Notes — with Claude AI for batch triage and smart extraction. Export. Scan. Triage. Execute.","archived":false,"fork":false,"pushed_at":"2026-03-11T00:25:49.000Z","size":39,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-11T04:37:27.857Z","etag":null,"topics":["apple-notes","applescript","cli","macos","productivity","python"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/davidwhittington.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-10T22:57:30.000Z","updated_at":"2026-03-11T00:25:52.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/davidwhittington/notes-manager","commit_stats":null,"previous_names":["davidwhittington/notes-manager"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/davidwhittington/notes-manager","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidwhittington%2Fnotes-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidwhittington%2Fnotes-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidwhittington%2Fnotes-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidwhittington%2Fnotes-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/davidwhittington","download_url":"https://codeload.github.com/davidwhittington/notes-manager/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidwhittington%2Fnotes-manager/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31418984,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-04T20:09:54.854Z","status":"ssl_error","status_checked_at":"2026-04-04T20:09:44.350Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["apple-notes","applescript","cli","macos","productivity","python"],"created_at":"2026-04-04T23:28:48.432Z","updated_at":"2026-04-04T23:28:49.010Z","avatar_url":"https://github.com/davidwhittington.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# notes-manager\n\nA Python CLI for auditing and reorganizing Apple Notes. Export your library, scan for keywords, triage each candidate, then execute — moving notes directly into the right folders in Apple Notes.\n\nBuilt for anyone with years of accumulated notes who needs to systematically sort the useful from the noise without doing it manually one note at a time.\n\n## AI integration\n\nTwo commands use the Claude API (Anthropic):\n\n**`triage --auto`** — feeds each candidate note to Claude Haiku, which reads the title and body and returns a verdict with a reason. Useful for burning through a large backlog without sitting at a terminal. Use `--dry-run` first to preview before writing.\n\n**`execute` with extract verdict** — when a note is marked for extraction during triage, the execute step calls Claude Haiku to distill the useful idea into a clean, concise note. That summary lands in `Drafts`; the original gets archived. No more manually rewriting notes that are 90% noise.\n\nBoth require `ANTHROPIC_API_KEY` set in your environment or `.env`. All other commands run without it.\n\n## Current status\n\nPhase 1 — active development. Full pipeline (export → scan → triage → execute) is working. Not yet packaged for distribution.\n\n## Requirements\n\n- macOS (Apple Notes via AppleScript)\n- Python 3.10+\n- Anthropic API key (required for `--auto` triage and `extract` verdicts)\n\n## Installation\n\n```bash\ngit clone https://github.com/davidwhittington/notes-manager.git\ncd notes-manager\npython3 -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n```\n\n## Configuration\n\nnotes-manager uses a `.env` file for personal keywords. This keeps your contacts, accounts, and custom terms out of version control.\n\n```bash\ncp .env.example .env\n```\n\nEdit `.env` and fill in your keyword buckets:\n\n```\n# Extra terms beyond any default product keywords\nNM_EXTRA_KEYWORDS=your,custom,terms\n\n# People names to scan for\nNM_PEOPLE=first last,first last\n\n# Company or account names to scan for\nNM_ACCOUNTS=company name,another company\n\n# Current employer keywords (used for Active-Work routing)\nNM_ISLAND_KEYWORDS=your company,product name\nNM_ISLAND_PEOPLE=colleague name,colleague name\nNM_ISLAND_ACCOUNTS=key account\n\n# Date cutoff for Active-Work routing (notes must be on or after this date)\nNM_ACTIVE_WORK_CUTOFF=2025-09-01\n\n# Personal project names (used for Active-Personal routing)\nNM_PERSONAL_PROJECTS=project-one,project-two\n```\n\nIf you have an Anthropic API key for AI-powered triage and extract summaries:\n\n```\nANTHROPIC_API_KEY=sk-ant-...\n```\n\n## Usage\n\n### Step by step\n\n```bash\n# 1. Create the target folder structure in Apple Notes\n./run.sh setup\n\n# 2. Export all notes to ~/Desktop/NotesExport/\n./run.sh export\n\n# 3. Scan exported notes for your keywords\n./run.sh scan\n\n# 4. Or scan Apple Notes SQLite directly (no export needed, less content available)\n./run.sh scan --direct\n\n# 5. Triage interactively (no API key needed)\n./run.sh triage\n\n# 6. Or triage with Claude (preview first, then for real)\n./run.sh triage --auto --dry-run\n./run.sh triage --auto\n\n# 7. Preview what execute will do before touching Notes\n./run.sh execute --dry-run\n\n# 8. Execute — moves notes into their target folders in Apple Notes\n./run.sh execute\n\n# 9. Check progress at any point\n./run.sh status\n```\n\n### Triage verdicts\n\nDuring triage, each candidate note is shown with a content preview. Press one key to assign a verdict.\n\n| Key | Verdict | Destination |\n|-----|---------|-------------|\n| `w` | Promote — Work | `Active – Work` |\n| `p` | Promote — Personal | `Active – Personal` |\n| `f` | Archive — Fortinet | `Archive – Fortinet` + header stamped |\n| `a` | Archive — Personal | `Archive – Personal` + header stamped |\n| `e` | Extract | Gem → new note in `Drafts` (Claude writes clean summary), original archived |\n| `r` | Review | `INBOX` — needs a manual pass |\n| `d` | Discard | Deleted |\n| `s` | Skip | Leave untouched for now |\n| `q` | Quit | Save progress and exit |\n\n**Active-Work routing** checks two criteria: the note must match current-employer keywords and have a creation or modification date on or after `NM_ACTIVE_WORK_CUTOFF`. If either condition isn't met, execute warns but moves the note anyway since you made the call during triage.\n\n**Extract** uses Claude (Haiku) to distill the useful idea into a clean new note in `Drafts`, then archives the original.\n\n### Archive header\n\nNotes routed to any archive folder get a header stamped at the top:\n\n```\n────────────────────────────\nARCHIVED: 2025-11-04\nSource: Fortinet era (2011–2024)\n────────────────────────────\n```\n\n### Target folder structure\n\n`./run.sh setup` creates these folders in Apple Notes if they don't already exist:\n\n```\nINBOX               ← review verdicts land here\nActive – Work       ← current job, active accounts\nActive – Personal   ← personal projects\nDrafts              ← extracted gems, ideas in progress\nArchive – Fortinet  ← former employer notes\nArchive – Personal  ← old personal notes worth keeping\nArchive – General   ← everything else\nTemplates\n```\n\n### Output files\n\nAll output lands on `~/Desktop/`:\n\n| File | Contents |\n|------|----------|\n| `NotesExport/` | Exported notes as `.txt` files, organized by folder |\n| `fortinet_candidates.csv` | Notes that matched your keywords, with triage verdict column |\n| `fortinet_scan_summary.txt` | Breakdown by folder and keyword |\n| `fortinet_triage_log.csv` | Triage decisions with timestamp and reason |\n| `fortinet_execute_log.csv` | Execute results — what moved where, errors if any |\n\n## Repo layout\n\n```\nnotes-manager/\n├── notes_manager/              — Python package\n│   ├── cli.py                  — Click CLI entry point\n│   ├── config.py               — paths and keyword loading (.env)\n│   ├── export.py               — wraps export_notes.applescript\n│   ├── scan.py                 — keyword scanner (file-based + SQLite)\n│   ├── triage.py               — interactive and AI-powered triage\n│   ├── execute.py              — moves notes in Apple Notes per triage verdicts\n│   ├── setup_notes.py          — creates folder structure in Notes\n│   └── status.py               — progress summary\n├── scripts/\n│   ├── export_notes.applescript\n│   ├── create_folder_structure.applescript\n│   ├── install_templates.applescript\n│   ├── move_note.applescript\n│   ├── archive_note.applescript\n│   ├── create_note.applescript\n│   ├── delete_note.applescript\n│   └── grep_fortinet_notes.sh  — standalone bash alternative to nm scan\n├── commands/                   — Claude Code command definitions\n├── .env.example                — config template (copy to .env)\n├── requirements.txt\n└── run.sh\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidwhittington%2Fnotes-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdavidwhittington%2Fnotes-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidwhittington%2Fnotes-manager/lists"}