@chainlesschain/personal-data-hub 0.4.0 → 0.4.1
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.
- package/README.md +45 -25
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -4,25 +4,38 @@ Personal Data Hub — UnifiedSchema, validators, batch helpers, SQLCipher
|
|
|
4
4
|
LocalVault, and AdapterRegistry for the "data back to the individual"
|
|
5
5
|
middleware.
|
|
6
6
|
|
|
7
|
-
> **
|
|
8
|
-
>
|
|
9
|
-
>
|
|
10
|
-
>
|
|
11
|
-
>
|
|
12
|
-
>
|
|
13
|
-
> Phase
|
|
14
|
-
>
|
|
15
|
-
>
|
|
16
|
-
>
|
|
17
|
-
>
|
|
18
|
-
>
|
|
19
|
-
>
|
|
20
|
-
>
|
|
21
|
-
>
|
|
22
|
-
>
|
|
23
|
-
>
|
|
24
|
-
>
|
|
25
|
-
>
|
|
7
|
+
> **v0.4.0 (ships with ChainlessChain v5.0.3.99, 2026-06-08).** Phase 0–13
|
|
8
|
+
> of the 13-phase plan in
|
|
9
|
+
> [`docs/design/Personal_Data_Hub_Architecture.md`](../../docs/design/Personal_Data_Hub_Architecture.md)
|
|
10
|
+
> have landed, plus the multi-platform collection layer. The foundation is
|
|
11
|
+
> unchanged: schema + validation + UUID v7 (Phase 0); SQLCipher LocalVault +
|
|
12
|
+
> pluggable key providers + migrations (Phase 1); AdapterRegistry + KG/RAG
|
|
13
|
+
> derivation (Phase 2); the natural-language AnalysisEngine with a hard
|
|
14
|
+
> privacy gate that refuses non-local LLMs unless the caller opts in
|
|
15
|
+
> (Phase 3); and production bridges — **CcLLMAdapter** (wraps cc llm-manager:
|
|
16
|
+
> Ollama / Volcengine / Anthropic / Gemini / DeepSeek), **CcKgSink**, **CcRagSink**
|
|
17
|
+
> — injected at the desktop/CLI entry so this package stays decoupled (Phase 3.5).
|
|
18
|
+
>
|
|
19
|
+
> **51 adapters are now live** (no longer "later phases"): Email IMAP,
|
|
20
|
+
> Alipay bill, 9 AI-chat vendors, WeChat / QQ / Weibo / Bilibili / Douyin /
|
|
21
|
+
> Xiaohongshu / Toutiao / Kuaishou social, Telegram / WhatsApp messaging,
|
|
22
|
+
> Taobao / JD / Meituan / Pinduoduo shopping, Amap / Baidu-map / Tencent-map /
|
|
23
|
+
> Ctrip / 12306 travel, system-data (contacts / calls / sms / location),
|
|
24
|
+
> and the developer-activity set (git / shell / vscode / browser-history /
|
|
25
|
+
> local-files / win-recent).
|
|
26
|
+
>
|
|
27
|
+
> **New in v0.4.0 (v5.0.3.99):** adapter **readiness** — split out from the
|
|
28
|
+
> loose `healthCheck` sync gate into a real ready/needs_setup/unavailable
|
|
29
|
+
> judgment (`registry.readiness()`) with a one-line reason, so "config looks
|
|
30
|
+
> fine but nothing collects" is no longer silent; an `adapter-guide.js`
|
|
31
|
+
> single-source of import steps reused across web-shell / desktop / CLI /
|
|
32
|
+
> Android; new local-direct-read sources (Douyin, WeChat PC, QQ-NT, DingTalk,
|
|
33
|
+
> Feishu, WeRead, Apple Health, NetEase Music); email-bill LLM gap-fill
|
|
34
|
+
> (Phase 5.5); and iOS encrypted-backup decryption (Phase 7.5b).
|
|
35
|
+
>
|
|
36
|
+
> Editing `lib/**` requires bumping the package version + `npm publish` +
|
|
37
|
+
> the Android `USR_VERSION` sentinel, or real devices keep running stale code
|
|
38
|
+
> (see hidden-risk-traps #27/#28).
|
|
26
39
|
|
|
27
40
|
## What's in here
|
|
28
41
|
|
|
@@ -40,6 +53,14 @@ lib/
|
|
|
40
53
|
│ typed put/get, queryEvents, watermarks, audit, key
|
|
41
54
|
│ rotation (WAL-safe), destroy
|
|
42
55
|
├── adapter-spec.js PersonalDataAdapter contract + assertAdapter check
|
|
56
|
+
├── adapter-readiness.js readiness() — ready/needs_setup/unavailable + reason,
|
|
57
|
+
│ split out from the loose healthCheck sync gate
|
|
58
|
+
├── adapter-guide.js category-driven import guides (single source of import
|
|
59
|
+
│ steps reused across web-shell / desktop / CLI / Android)
|
|
60
|
+
├── adapters/ 51 live adapters (email-imap, alipay-bill, ai-chat-history,
|
|
61
|
+
│ wechat / wechat-pc, qq-pc, dingtalk-pc, feishu-pc, weread,
|
|
62
|
+
│ apple-health, netease-music, social-*, shopping-*,
|
|
63
|
+
│ travel-*, system-data, git-activity, vscode, ...)
|
|
43
64
|
├── kg-derive.js UnifiedSchema → KG triples (rdf:type / by / involves /
|
|
44
65
|
│ happened-at / etc.) — engine-agnostic
|
|
45
66
|
├── rag-derive.js UnifiedSchema → RAG (text, metadata) docs for indexing
|
|
@@ -217,7 +238,7 @@ cd packages/personal-data-hub
|
|
|
217
238
|
npm test
|
|
218
239
|
```
|
|
219
240
|
|
|
220
|
-
**
|
|
241
|
+
**2040 tests** across 121 files covering ID generation, all 5 entity validators,
|
|
221
242
|
batch helpers, key providers, vault open/migrations, entity round-trips,
|
|
222
243
|
transactional putBatch with rollback, raw_events archive, queryEvents
|
|
223
244
|
filters + pagination, sync watermarks, audit log, key rotation (WAL-safe),
|
|
@@ -230,11 +251,10 @@ tolerance), and the 1k events <30s ingest perf gate.
|
|
|
230
251
|
|
|
231
252
|
| Concern | Lives in |
|
|
232
253
|
|-----------------------|---------------------------------------------------|
|
|
233
|
-
| Platform KeyProviders (DPAPI/Keychain/Keystore) |
|
|
234
|
-
|
|
|
235
|
-
|
|
|
236
|
-
|
|
|
237
|
-
| AI analysis skills | Phase 11 — `skills/personal-analysis-*/` |
|
|
254
|
+
| Platform KeyProviders (DPAPI/Keychain/Keystore) | desktop-app-vue main-process bridge (the package ships the contract + InMemory/File providers) |
|
|
255
|
+
| Qdrant vector retrieval | wired into the existing RAG engine at the cc entry (BM25 derivation ships here) |
|
|
256
|
+
| AI analysis skills | `skills/personal-analysis-*/` (the 5 built-in analysis skills) |
|
|
257
|
+
| Native SQLCipher build | `better-sqlite3-multiple-ciphers` — host/Electron ABI dual-load handled at the cc entry |
|
|
238
258
|
|
|
239
259
|
## License
|
|
240
260
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chainlesschain/personal-data-hub",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Personal Data Hub — UnifiedSchema + validators + KG ingest helpers for the data-back-to-the-individual middleware",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"main": "lib/index.js",
|