sieve-notes 0.1.0__tar.gz → 0.2.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/CHANGELOG.md +14 -0
  2. {sieve_notes-0.1.0/sieve_notes.egg-info → sieve_notes-0.2.0}/PKG-INFO +10 -5
  3. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/README.ja.md +9 -4
  4. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/README.md +9 -4
  5. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/docs/convert.md +8 -6
  6. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/docs/formats.md +6 -2
  7. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/docs/vocabulary.md +42 -5
  8. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/pyproject.toml +1 -1
  9. {sieve_notes-0.1.0 → sieve_notes-0.2.0/sieve_notes.egg-info}/PKG-INFO +10 -5
  10. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/sieve_notes.py +207 -15
  11. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/tests/test_notes_nt.py +830 -15
  12. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/tests/test_public_text.py +2 -0
  13. sieve_notes-0.2.0/tools/check_release_assets.py +126 -0
  14. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/tools/check_release_version.py +25 -10
  15. sieve_notes-0.1.0/tools/check_release_assets.py +0 -68
  16. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/LICENSE +0 -0
  17. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/MANIFEST.in +0 -0
  18. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/conftest.py +0 -0
  19. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/docs/resolution.md +0 -0
  20. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/README.md +0 -0
  21. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_mixed/meeting.md +0 -0
  22. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_mixed/overview.md +0 -0
  23. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_outline/meeting.md +0 -0
  24. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_outline/reading.md +0 -0
  25. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_wikilink/daily/2026-11-28.md +0 -0
  26. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_wikilink/ideas/plan.md +0 -0
  27. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/examples/vault_wikilink/index.md +0 -0
  28. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/setup.cfg +0 -0
  29. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/sieve_notes.egg-info/SOURCES.txt +0 -0
  30. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/sieve_notes.egg-info/dependency_links.txt +0 -0
  31. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/sieve_notes.egg-info/entry_points.txt +0 -0
  32. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/sieve_notes.egg-info/top_level.txt +0 -0
  33. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/tests/public_text_baseline.json +0 -0
  34. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/tools/check_public_text.py +0 -0
  35. {sieve_notes-0.1.0 → sieve_notes-0.2.0}/tools/extract_changelog.py +0 -0
@@ -1,3 +1,17 @@
1
+ ## [0.2.0] - 2026-12-01
2
+
3
+ ### Added
4
+
5
+ - Math is observed: display math (`$$…$$`) is a `math` block in `blocks`, and `index` reports the `math_blocks` and `math_inline` counts for the whole vault and for each note. Math bodies are never emitted.
6
+
7
+ ### Changed
8
+
9
+ - Links, comments and block references inside math are no longer counted; 0.1.0 counted them. The same symbols outside math are counted as before.
10
+
11
+ ### Fixed
12
+
13
+ - The supported-formats list no longer claims tags (0.1.0 does not observe tags), and math is added to the list.
14
+
1
15
  ## [0.1.0] - 2026-11-29
2
16
 
3
17
  ### Added
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sieve-notes
3
- Version: 0.1.0
3
+ Version: 0.2.0
4
4
  Summary: Deterministic observation and conversion for Markdown note vaults: note relations, block trees, and document-outline round trips
5
5
  Author: Kai IWASAKI
6
6
  License-Expression: MIT
@@ -20,7 +20,9 @@ Description-Content-Type: text/markdown
20
20
  License-File: LICENSE
21
21
  Dynamic: license-file
22
22
 
23
- # Sieve Notes v0.1.0
23
+ # Sieve Notes v0.2.0
24
+
25
+ English | [日本語](https://github.com/neguseatama/sieve-notes/blob/main/README.ja.md)
24
26
 
25
27
  A command-line tool that reads a folder of Markdown notes (the vault of a
26
28
  note-taking app, called a vault below) and deterministically produces:
@@ -45,7 +47,9 @@ link_states resolved=5 broken=1 ambiguous=0 fragment_missing=1
45
47
  orphan_notes 1
46
48
  excluded_dirs 2
47
49
  skipped symlink_skipped=0 too_large=0 unreadable=0 unsupported_encoding=0 file_limit=0
48
- note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2
50
+ math_blocks 2
51
+ math_inline 3
52
+ note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2 math_blocks=1 math_inline=2
49
53
  broken a.md:7 wikilink broken ghost
50
54
  ```
51
55
 
@@ -58,7 +62,8 @@ dialect document
58
62
  block frontmatter depth=0 lines=1-3
59
63
  block heading depth=0 lines=4-4
60
64
  block paragraph depth=1 lines=6-7
61
- block list_item depth=2 lines=9-9
65
+ block math depth=1 lines=9-12
66
+ block list_item depth=2 lines=14-14
62
67
  ...
63
68
  ```
64
69
 
@@ -102,9 +107,9 @@ From Python, the three functions `index_vault` / `block_tree` /
102
107
  - Markdown-form relative-path links
103
108
  - Block references (the `((id))` form)
104
109
  - Comments (`%%…%%` and HTML comments)
110
+ - Math (inline `$…$`, display `$$…$$`) — observed as ranges and counts; math bodies are never emitted
105
111
  - Properties (frontmatter and `key:: value` lines)
106
112
  - Callouts (including folded `> [!x]-`)
107
- - Tags
108
113
  - File placement and folder layout (default exclusions:
109
114
  `.obsidian/`, `.trash/`, `logseq/`, `.git/`)
110
115
  - Indentation characters (one tab or two spaces per level)
@@ -1,4 +1,6 @@
1
- # Sieve Notes v0.1.0
1
+ # Sieve Notes v0.2.0
2
+
3
+ [English](https://github.com/neguseatama/sieve-notes/blob/main/README.md) | 日本語
2
4
 
3
5
  Markdown のノートを集めたフォルダ(ノート用アプリの保管庫。以下 vault)を
4
6
  読み、次の 3 つを、決定論的に出すコマンドラインの道具です。
@@ -20,7 +22,9 @@ link_states resolved=5 broken=1 ambiguous=0 fragment_missing=1
20
22
  orphan_notes 1
21
23
  excluded_dirs 2
22
24
  skipped symlink_skipped=0 too_large=0 unreadable=0 unsupported_encoding=0 file_limit=0
23
- note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2
25
+ math_blocks 2
26
+ math_inline 3
27
+ note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2 math_blocks=1 math_inline=2
24
28
  broken a.md:7 wikilink broken ghost
25
29
  ```
26
30
 
@@ -33,7 +37,8 @@ dialect document
33
37
  block frontmatter depth=0 lines=1-3
34
38
  block heading depth=0 lines=4-4
35
39
  block paragraph depth=1 lines=6-7
36
- block list_item depth=2 lines=9-9
40
+ block math depth=1 lines=9-12
41
+ block list_item depth=2 lines=14-14
37
42
  ...
38
43
  ```
39
44
 
@@ -77,9 +82,9 @@ Python からは `index_vault` / `block_tree` / `convert_text` の
77
82
  - Markdown 形式の相対パスのリンク
78
83
  - ブロックの参照(`((id))` の形)
79
84
  - コメント(`%%…%%` と HTML コメント)
85
+ - 数式(インライン `$…$`、表示 `$$…$$`)— 範囲と件数を観測します(本文は出しません)
80
86
  - プロパティ(frontmatter と `key:: value` の行)
81
87
  - コールアウト(折りたたみ `> [!x]-` を含む)
82
- - タグ
83
88
  - ファイルの置き場所とフォルダの構成(既定の除外:
84
89
  `.obsidian/`・`.trash/`・`logseq/`・`.git/`)
85
90
  - 字下げの文字(タブまたは空白 2 個を 1 段として扱います)
@@ -1,4 +1,6 @@
1
- # Sieve Notes v0.1.0
1
+ # Sieve Notes v0.2.0
2
+
3
+ English | [日本語](https://github.com/neguseatama/sieve-notes/blob/main/README.ja.md)
2
4
 
3
5
  A command-line tool that reads a folder of Markdown notes (the vault of a
4
6
  note-taking app, called a vault below) and deterministically produces:
@@ -23,7 +25,9 @@ link_states resolved=5 broken=1 ambiguous=0 fragment_missing=1
23
25
  orphan_notes 1
24
26
  excluded_dirs 2
25
27
  skipped symlink_skipped=0 too_large=0 unreadable=0 unsupported_encoding=0 file_limit=0
26
- note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2
28
+ math_blocks 2
29
+ math_inline 3
30
+ note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2 math_blocks=1 math_inline=2
27
31
  broken a.md:7 wikilink broken ghost
28
32
  ```
29
33
 
@@ -36,7 +40,8 @@ dialect document
36
40
  block frontmatter depth=0 lines=1-3
37
41
  block heading depth=0 lines=4-4
38
42
  block paragraph depth=1 lines=6-7
39
- block list_item depth=2 lines=9-9
43
+ block math depth=1 lines=9-12
44
+ block list_item depth=2 lines=14-14
40
45
  ...
41
46
  ```
42
47
 
@@ -80,9 +85,9 @@ From Python, the three functions `index_vault` / `block_tree` /
80
85
  - Markdown-form relative-path links
81
86
  - Block references (the `((id))` form)
82
87
  - Comments (`%%…%%` and HTML comments)
88
+ - Math (inline `$…$`, display `$$…$$`) — observed as ranges and counts; math bodies are never emitted
83
89
  - Properties (frontmatter and `key:: value` lines)
84
90
  - Callouts (including folded `> [!x]-`)
85
- - Tags
86
91
  - File placement and folder layout (default exclusions:
87
92
  `.obsidian/`, `.trash/`, `logseq/`, `.git/`)
88
93
  - Indentation characters (one tab or two spaces per level)
@@ -21,8 +21,8 @@ output file is never overwritten (exit code 2, `output_exists`).
21
21
  continuation lines under the item).
22
22
  - A list item becomes a child item of the preceding paragraph (or heading).
23
23
  Nesting is kept as item nesting.
24
- - Code, tables, quotes and HTML are placed as they are inside one item
25
- (continuation lines are indented).
24
+ - Code, math, tables, quotes and HTML are placed as they are inside one item
25
+ (continuation lines are indented; blank lines inside math are kept).
26
26
  - An ordered item (`1.` / `1)`) loses its number, becomes a plain item, and
27
27
  is counted in `ordered_list_became_bullets`.
28
28
  - A list directly under a heading (or the root) becomes a paragraph when
@@ -38,8 +38,10 @@ output file is never overwritten (exit code 2, `output_exists`).
38
38
  - An item with children becomes a paragraph followed by a list of the children.
39
39
  - An item without children becomes a paragraph.
40
40
  - Deep nesting becomes nested lists (two-space indentation, canonical form).
41
- - When the content of an item starts with a fence, quote, table, comment or
42
- HTML marker, it is restored as a block of literal text.
41
+ - When the content of an item starts with a fence, `$$`, quote, table,
42
+ comment or HTML marker, it is restored as a block of literal text. A math
43
+ range inside an item is restored as its own block of literal lines, so
44
+ that the round trip stays a fixed point.
43
45
  - Continuation lines are restored by stripping the item's depth + 1 levels
44
46
  of indentation.
45
47
  - Raw root lines (kept lines) are preserved in place, with consecutive ones
@@ -70,8 +72,8 @@ placed inside an item in the same form as a quote (the text does not change).
70
72
 
71
73
  - **P1**: A canonical document (LF line endings, ATX headings, `-` lists, one
72
74
  blank line between blocks) made only of headings, paragraphs, nested lists
73
- with an introductory paragraph, code, tables and quotes is byte-identical
74
- after document → outline → document.
75
+ with an introductory paragraph, code, math, tables and quotes is
76
+ byte-identical after document → outline → document.
75
77
  - **P2**: For any input, every round trip after the first matches the
76
78
  output of the first (a fixed point).
77
79
  - A structure whose shape changes on a round trip is never changed silently;
@@ -1,6 +1,6 @@
1
1
  # Supported formats and sources
2
2
 
3
- The formats that Sieve Notes 0.1.0 covers, with their sources (official
3
+ The formats that Sieve Notes 0.2.0 covers, with their sources (official
4
4
  documentation). Formats are described by the name of the format itself. A
5
5
  format that could not be confirmed in official documentation is listed under
6
6
  "Not covered" and is not implemented in this version.
@@ -12,8 +12,8 @@ format that could not be confirmed in official documentation is listed under
12
12
  | Internal links `[[note]]`, aliases `[[note\|alias]]`, headings `[[note#section]]`, block IDs `[[note#^id]]`, embeds `![[file]]`, Markdown-form relative-path links `[text](path)` | Internal links — https://obsidian.md/help/links |
13
13
  | Callouts (including folded `> [!faq]-` and default-open `+`) | Callouts — https://obsidian.md/help/callouts |
14
14
  | Comments `%%…%%` (inline and block) and HTML comments `<!--…-->` | Comments in Obsidian Flavored Markdown — https://help.obsidian.md/syntax |
15
+ | Math (inline `$…$`, display `$$…$$`) — observed as ranges and counts; the formulas are not interpreted or rendered | Math — https://help.obsidian.md/syntax |
15
16
  | Properties (frontmatter: YAML between `---` lines) | Properties — https://obsidian.md/help/properties |
16
- | Tags (`#tag`, nested `#a/b`, `tags:` in frontmatter) | Tags — https://obsidian.md/help/tags |
17
17
  | Vault and the settings folder `.obsidian/` | How Obsidian stores data — https://obsidian.md/help/data-storage |
18
18
  | Attachment locations (default, a given folder, the note's own folder, a subfolder of it) | Attachments — https://obsidian.md/help/attachments |
19
19
  | Page references `[[page name]]`, block references `((block-uuid))`, properties `property:: value` | Markdown / Properties — https://docs.logseq.com (sources: `pages/Markdown.md` and `pages/Properties.md` in https://github.com/logseq/docs) |
@@ -39,3 +39,7 @@ format that could not be confirmed in official documentation is listed under
39
39
  6. **Bullets starting with `+` or `*` inside blocks.** They appear in the
40
40
  official bullet page, but the list marker of this version is limited to
41
41
  `- `. Lines starting with `+` or `*` are treated as text (paragraphs).
42
+ 7. **Tags (`#tag`, nested `#a/b`, `tags:` in frontmatter).** They appear in
43
+ the official documentation, but this version does not observe tags.
44
+
45
+ Obsidian and Logseq are trademarks of their respective owners. This project is not affiliated with or endorsed by them.
@@ -1,6 +1,6 @@
1
1
  # Closed vocabulary and output contract
2
2
 
3
- The words that appear in the output of Sieve Notes 0.1.0 are limited to the
3
+ The words that appear in the output of Sieve Notes 0.2.0 are limited to the
4
4
  closed lists below. No other word is emitted.
5
5
 
6
6
  ## Link kinds
@@ -11,7 +11,8 @@ closed lists below. No other word is emitted.
11
11
  - `block_ref` — the `((id))` form
12
12
 
13
13
  External URLs are not counted. Links inside code blocks and inline code are
14
- not counted. The form `![alt](image.png)` is counted as `markdown_link`; the
14
+ not counted. Links inside math ranges are not counted either (see Math
15
+ below). The form `![alt](image.png)` is counted as `markdown_link`; the
15
16
  word `embed` is reserved for `![[…]]`.
16
17
 
17
18
  ## Link states
@@ -23,12 +24,46 @@ word `embed` is reserved for `![[…]]`.
23
24
 
24
25
  ## Block kinds
25
26
 
26
- `heading`, `paragraph`, `list_item`, `code`, `quote`, `callout`, `table`,
27
- `html`, `rule`, `frontmatter`, `comment`, `properties`.
27
+ `heading`, `paragraph`, `list_item`, `code`, `math`, `quote`, `callout`,
28
+ `table`, `html`, `rule`, `frontmatter`, `comment`, `properties`.
28
29
 
29
30
  Each block has a kind, a depth and a line range (1-based, both ends
30
31
  inclusive). Note bodies are never emitted.
31
32
 
33
+ ## Math
34
+
35
+ Math is observed as ranges and counts only. Formulas are never interpreted,
36
+ rendered or emitted.
37
+
38
+ - Display math `$$…$$` is the block kind `math` when the opening `$$` stands
39
+ at the start of a line (up to three spaces of indentation), the same place
40
+ a fenced code block can start. One line that opens and closes (`$$ x $$`,
41
+ also the adjacent form `$$$$`) is one `math` block. A multi-line range
42
+ runs to the next line that contains `$$`; blank lines may be inside and
43
+ belong to the range. Like a fenced code block, an opening `$$` that
44
+ actually closes splits the paragraph it would continue: the paragraph
45
+ ends on the line before, and the `math` block starts on that line.
46
+ - A `$$…$$` pair in the middle of a line does not split anything; it counts
47
+ as one inline math range.
48
+ - An unclosed `$$` is not math and does not split: the lines stay what they
49
+ were (a paragraph).
50
+ - Display math inside a quote (`> $$…`) is not a `math` block. Inside
51
+ outline items, a `$$` item holds its range in the item (like code); no
52
+ `math` row is emitted for it, but it is counted in `math_blocks`.
53
+ - Inline math `$…$` lives inside one line: the character after the opening
54
+ `$` is not a blank, the character before the closing `$` is not a blank,
55
+ and the character after the closing `$` is not a digit. A `$` with `\`
56
+ right before it is a character. A `$$…$$` pair on one line that is not at
57
+ a block position (mid-paragraph, in a quote, table or heading) counts as
58
+ one inline math range.
59
+ - `$` and `$$` inside code blocks and inline code never start math. In a
60
+ table row the cells are split on `|`, so math never spans a cell boundary.
61
+ - Links (all kinds), comments and block references inside math are not
62
+ counted. Math outside code is protected as one range; its body is never
63
+ emitted.
64
+ - `index` reports `math_blocks` (display math ranges) and `math_inline`
65
+ (inline math ranges) for the whole vault and for each note, as counts.
66
+
32
67
  ## Dialects
33
68
 
34
69
  - `document` — headings and paragraphs are the basic shape.
@@ -86,7 +121,9 @@ those four. The number of excluded folders is reported as `excluded_dirs`
86
121
  - No absolute path appears in the output. Paths are relative to the given
87
122
  folder (POSIX form, `/` separated).
88
123
  - Per-note fields of `index`: relative path, link counts (by state), counts by
89
- kind, backlink count, number of folded blocks, number of comments.
124
+ kind, backlink count, number of folded blocks, number of comments, number
125
+ of display math ranges (`math_blocks`) and of inline math ranges
126
+ (`math_inline`).
90
127
  Contents are never emitted, only counts.
91
128
  - List of broken links: the note's relative path, line number, link kind and
92
129
  state word. Link target names are shown by default (intended for local
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "sieve-notes"
7
- version = "0.1.0"
7
+ version = "0.2.0"
8
8
  description = "Deterministic observation and conversion for Markdown note vaults: note relations, block trees, and document-outline round trips"
9
9
  readme = "README.md"
10
10
  authors = [{ name = "Kai IWASAKI" }]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sieve-notes
3
- Version: 0.1.0
3
+ Version: 0.2.0
4
4
  Summary: Deterministic observation and conversion for Markdown note vaults: note relations, block trees, and document-outline round trips
5
5
  Author: Kai IWASAKI
6
6
  License-Expression: MIT
@@ -20,7 +20,9 @@ Description-Content-Type: text/markdown
20
20
  License-File: LICENSE
21
21
  Dynamic: license-file
22
22
 
23
- # Sieve Notes v0.1.0
23
+ # Sieve Notes v0.2.0
24
+
25
+ English | [日本語](https://github.com/neguseatama/sieve-notes/blob/main/README.ja.md)
24
26
 
25
27
  A command-line tool that reads a folder of Markdown notes (the vault of a
26
28
  note-taking app, called a vault below) and deterministically produces:
@@ -45,7 +47,9 @@ link_states resolved=5 broken=1 ambiguous=0 fragment_missing=1
45
47
  orphan_notes 1
46
48
  excluded_dirs 2
47
49
  skipped symlink_skipped=0 too_large=0 unreadable=0 unsupported_encoding=0 file_limit=0
48
- note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2
50
+ math_blocks 2
51
+ math_inline 3
52
+ note a.md resolved=2 broken=1 ambiguous=0 fragment_missing=0 backlinks=1 collapsed=1 comments=2 math_blocks=1 math_inline=2
49
53
  broken a.md:7 wikilink broken ghost
50
54
  ```
51
55
 
@@ -58,7 +62,8 @@ dialect document
58
62
  block frontmatter depth=0 lines=1-3
59
63
  block heading depth=0 lines=4-4
60
64
  block paragraph depth=1 lines=6-7
61
- block list_item depth=2 lines=9-9
65
+ block math depth=1 lines=9-12
66
+ block list_item depth=2 lines=14-14
62
67
  ...
63
68
  ```
64
69
 
@@ -102,9 +107,9 @@ From Python, the three functions `index_vault` / `block_tree` /
102
107
  - Markdown-form relative-path links
103
108
  - Block references (the `((id))` form)
104
109
  - Comments (`%%…%%` and HTML comments)
110
+ - Math (inline `$…$`, display `$$…$$`) — observed as ranges and counts; math bodies are never emitted
105
111
  - Properties (frontmatter and `key:: value` lines)
106
112
  - Callouts (including folded `> [!x]-`)
107
- - Tags
108
113
  - File placement and folder layout (default exclusions:
109
114
  `.obsidian/`, `.trash/`, `logseq/`, `.git/`)
110
115
  - Indentation characters (one tab or two spaces per level)