notelight 0.1.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.
- notelight-0.1.0/CHANGELOG.md +102 -0
- notelight-0.1.0/Cargo.lock +972 -0
- notelight-0.1.0/Cargo.toml +27 -0
- notelight-0.1.0/LICENSE-APACHE +202 -0
- notelight-0.1.0/LICENSE-MIT +21 -0
- notelight-0.1.0/PKG-INFO +418 -0
- notelight-0.1.0/README.md +359 -0
- notelight-0.1.0/crates/notelight-core/Cargo.toml +32 -0
- notelight-0.1.0/crates/notelight-core/benches/search.rs +102 -0
- notelight-0.1.0/crates/notelight-core/src/bin_format.rs +127 -0
- notelight-0.1.0/crates/notelight-core/src/bm25.rs +448 -0
- notelight-0.1.0/crates/notelight-core/src/chunk.rs +485 -0
- notelight-0.1.0/crates/notelight-core/src/error.rs +61 -0
- notelight-0.1.0/crates/notelight-core/src/fuse.rs +68 -0
- notelight-0.1.0/crates/notelight-core/src/index/docs.rs +155 -0
- notelight-0.1.0/crates/notelight-core/src/index/manifest.rs +92 -0
- notelight-0.1.0/crates/notelight-core/src/index/mod.rs +124 -0
- notelight-0.1.0/crates/notelight-core/src/index/reader.rs +334 -0
- notelight-0.1.0/crates/notelight-core/src/index/storage.rs +71 -0
- notelight-0.1.0/crates/notelight-core/src/index/writer.rs +295 -0
- notelight-0.1.0/crates/notelight-core/src/lib.rs +29 -0
- notelight-0.1.0/crates/notelight-core/src/phrase.rs +179 -0
- notelight-0.1.0/crates/notelight-core/src/quant.rs +301 -0
- notelight-0.1.0/crates/notelight-core/src/tokenize.rs +138 -0
- notelight-0.1.0/crates/notelight-core/src/topk.rs +144 -0
- notelight-0.1.0/crates/notelight-core/src/vectors.rs +595 -0
- notelight-0.1.0/crates/notelight-core/tests/index.rs +401 -0
- notelight-0.1.0/crates/notelight-core/tests/properties.proptest-regressions +8 -0
- notelight-0.1.0/crates/notelight-core/tests/properties.rs +333 -0
- notelight-0.1.0/crates/notelight-py/Cargo.toml +23 -0
- notelight-0.1.0/crates/notelight-py/src/chunking.rs +80 -0
- notelight-0.1.0/crates/notelight-py/src/errors.rs +57 -0
- notelight-0.1.0/crates/notelight-py/src/index.rs +360 -0
- notelight-0.1.0/crates/notelight-py/src/lib.rs +95 -0
- notelight-0.1.0/pyproject.toml +102 -0
- notelight-0.1.0/python/notelight/__init__.py +49 -0
- notelight-0.1.0/python/notelight/_core.pyi +179 -0
- notelight-0.1.0/python/notelight/cli.py +439 -0
- notelight-0.1.0/python/notelight/documents.py +252 -0
- notelight-0.1.0/python/notelight/download.py +54 -0
- notelight-0.1.0/python/notelight/embed.py +345 -0
- notelight-0.1.0/python/notelight/errors.py +40 -0
- notelight-0.1.0/python/notelight/eval/__init__.py +48 -0
- notelight-0.1.0/python/notelight/eval/baseline.py +153 -0
- notelight-0.1.0/python/notelight/eval/datasets.py +238 -0
- notelight-0.1.0/python/notelight/eval/metrics.py +66 -0
- notelight-0.1.0/python/notelight/eval/report.py +68 -0
- notelight-0.1.0/python/notelight/eval/runner.py +347 -0
- notelight-0.1.0/python/notelight/indexer.py +509 -0
- notelight-0.1.0/python/notelight/ingest.py +157 -0
- notelight-0.1.0/python/notelight/mcp_server.py +623 -0
- notelight-0.1.0/python/notelight/paths.py +81 -0
- notelight-0.1.0/python/notelight/py.typed +0 -0
- notelight-0.1.0/python/notelight/search.py +420 -0
- notelight-0.1.0/python/notelight/web/__init__.py +174 -0
- notelight-0.1.0/python/notelight/web/static/app.js +293 -0
- notelight-0.1.0/python/notelight/web/static/index.html +54 -0
- notelight-0.1.0/python/notelight/web/static/style.css +294 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to notelight are listed here. The format follows
|
|
4
|
+
[Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and the project uses
|
|
5
|
+
[Semantic Versioning](https://semver.org/). Before 1.0, a minor version may
|
|
6
|
+
change the CLI, the Python API or the index format; an index from an older
|
|
7
|
+
format is detected and rebuilt by `notelight index`.
|
|
8
|
+
|
|
9
|
+
## [Unreleased]
|
|
10
|
+
|
|
11
|
+
## [0.1.0] - unreleased
|
|
12
|
+
|
|
13
|
+
The first release on PyPI: `pip install notelight`. It covers milestones 0 to 5
|
|
14
|
+
of the [roadmap](README.md#roadmap).
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
|
|
18
|
+
- **Rust retrieval core** (`notelight-core`, no Python, ML or async
|
|
19
|
+
dependencies):
|
|
20
|
+
- Markdown-aware chunking (sections, paragraphs, code fences) with heading
|
|
21
|
+
paths and exact line ranges for citations.
|
|
22
|
+
- BM25 with Unicode-aware terms and camelCase splitting, served directly
|
|
23
|
+
from the serialized index.
|
|
24
|
+
- Quantized vector search: binary or ternary codes pick candidates with
|
|
25
|
+
`popcount`, and int8 vectors re-score them. Ternary candidates with int8
|
|
26
|
+
rescoring is the default; on BEIR it matches exhaustive int8 nDCG@10 to
|
|
27
|
+
three decimals. The int8 dot product keeps 16 partial sums so the
|
|
28
|
+
compiler can use SIMD.
|
|
29
|
+
- Reciprocal rank fusion for hybrid (BM25 + vector) search.
|
|
30
|
+
- A versioned, memory-mapped index format
|
|
31
|
+
([spec](docs/index-format.md), schema version 2): immutable generations
|
|
32
|
+
with an atomic `CURRENT` swap, full validation on open, and recovery from
|
|
33
|
+
interrupted commits, including on Windows.
|
|
34
|
+
- Unit, integration and property tests against naive references, and
|
|
35
|
+
criterion benchmarks.
|
|
36
|
+
- **Python package** (abi3 wheels for Python 3.10+, built with PyO3 and
|
|
37
|
+
maturin):
|
|
38
|
+
- `sync(folder, embedder)` and `Searcher(folder, embedder)`, with typed
|
|
39
|
+
stubs for the Rust extension.
|
|
40
|
+
- `OnnxEmbedder`: BAAI/bge-small-en-v1.5 on ONNX Runtime, pinned to one
|
|
41
|
+
revision, verified by SHA-256 and downloaded once. `HashingEmbedder` for
|
|
42
|
+
tests and model-free use.
|
|
43
|
+
- An incremental indexer: only new or changed chunks are embedded, an
|
|
44
|
+
unchanged folder never loads the model, and a lock file allows one writer
|
|
45
|
+
per index. Indexes live in the user data directory (`NOTELIGHT_HOME`),
|
|
46
|
+
never in the indexed folder.
|
|
47
|
+
- Ingest of `.md`, `.markdown` and `.txt` in UTF-8 or Windows-1252, skipping
|
|
48
|
+
hidden and build folders and anything in `.notelightignore`.
|
|
49
|
+
- **CLI**: `notelight index`, `search` (with `--json`), `status`, `mcp`,
|
|
50
|
+
`serve`, `eval` and `version`; `--embedder bge-small|hashing|none` and
|
|
51
|
+
`--offline`. On a terminal, `search` highlights the matched words and
|
|
52
|
+
starts each snippet near the first match (`NO_COLOR` turns colour off).
|
|
53
|
+
- **Phrase ranking** in the core, for every interface: quoted phrases
|
|
54
|
+
(`'"lock file" windows'`) rank chunks containing them first, and a chunk
|
|
55
|
+
with all query terms in order gets a bonus worth one extra first place in
|
|
56
|
+
fusion. Neutral on BEIR (within 0.002 nDCG@10); aimed at short note queries.
|
|
57
|
+
- **PDF and DOCX** as optional extras (`notelight[pdf]`, `[docx]`,
|
|
58
|
+
`[documents]`; pypdf and python-docx). Citations stay `path:lines` of the
|
|
59
|
+
extracted text, with PDF pages shown beside them; DOCX headings become
|
|
60
|
+
heading paths. Without the extra, these files are skipped with a hint.
|
|
61
|
+
- **Localhost web UI** as an optional extra (`notelight[web]`,
|
|
62
|
+
`notelight serve`): one page over the same service as the MCP server,
|
|
63
|
+
bound to 127.0.0.1 with a Host-header check against DNS rebinding, no
|
|
64
|
+
build step and nothing loaded from the network.
|
|
65
|
+
- **MCP server** (`notelight mcp`, official Python SDK, stdio) with four
|
|
66
|
+
read-only tools: `search`, `read_context`, `list_sources` and
|
|
67
|
+
`index_status`. `read_context` reads only files that are in the index.
|
|
68
|
+
- **Evaluation**: `notelight eval` reports recall@10, nDCG@10 and latency for
|
|
69
|
+
every retrieval method on BEIR SciFact, NFCorpus and FiQA (datasets pinned
|
|
70
|
+
by SHA-256), and checks the Rust searches against a NumPy implementation
|
|
71
|
+
([results](docs/results.md)).
|
|
72
|
+
- Docs: design notes, the index format spec, and a Rust walkthrough per
|
|
73
|
+
milestone for readers coming from C# or Python.
|
|
74
|
+
- Prebuilt wheels for Linux x86_64 and aarch64, Windows x64 and macOS (Apple
|
|
75
|
+
silicon and Intel), each installed and smoke-tested in CI before publishing.
|
|
76
|
+
|
|
77
|
+
### Fixed
|
|
78
|
+
|
|
79
|
+
Findings from an independent review of milestones 2 to 4, each with a
|
|
80
|
+
regression test:
|
|
81
|
+
|
|
82
|
+
- `notelight index <folder>` without `--embedder` keeps the embedder the
|
|
83
|
+
index was built with, instead of switching a keyword-only or hashing index
|
|
84
|
+
to bge-small (a 133 MB download and a full re-embed).
|
|
85
|
+
- Files the indexer skips (binary, undecodable, unreadable) are remembered, so
|
|
86
|
+
`index_status` no longer reports them as new forever.
|
|
87
|
+
- An all-folder MCP `search` skips a folder whose index cannot be searched and
|
|
88
|
+
lists it in a `skipped` field, instead of failing for every folder.
|
|
89
|
+
- MCP results from several folders are merged by per-folder rank, so
|
|
90
|
+
keyword-only folders are no longer buried by raw fusion scores.
|
|
91
|
+
- Network errors while downloading the model raise `ModelNotAvailableError`
|
|
92
|
+
with a hint instead of a traceback.
|
|
93
|
+
- A keyword-only sync no longer wipes the embedding cache.
|
|
94
|
+
- A query whose vector is all zeros (hashing embedder, punctuation-only
|
|
95
|
+
query) falls back to BM25 instead of raising `ValueError`.
|
|
96
|
+
- `status` and the MCP server no longer crash when index files vanish during a
|
|
97
|
+
concurrent sync.
|
|
98
|
+
- Changing the chunk size no longer empties the file cache before the new
|
|
99
|
+
generation commits.
|
|
100
|
+
|
|
101
|
+
[Unreleased]: https://github.com/searope/notelight/compare/v0.1.0...HEAD
|
|
102
|
+
[0.1.0]: https://github.com/searope/notelight/releases/tag/v0.1.0
|