mirror of
https://github.com/hellodigua/ChatLab.git
synced 2026-10-26 02:04:37 +08:00
Add @openchatlab/parser-native (napi-rs v3) with a shared byte-level JSON scanner and two format kernels. Parsing large exports is 4-10x faster in real-data benchmarks. The native module is an optional local build; the pure-TS parsers remain as automatic fallback when it is unavailable, disabled via CHATLAB_DISABLE_NATIVE_PERF=1, or rejects off-spec files. The ChatLab kernel also parses the members array structurally, fixing the TS head-regex heuristic that silently dropped avatars/roles for files with nested arrays or long member lists. Co-authored-by: Cursor <cursoragent@cursor.com>
18 lines
442 B
JSON
18 lines
442 B
JSON
{
|
|
"name": "@openchatlab/parser",
|
|
"version": "0.0.0",
|
|
"private": true,
|
|
"description": "ChatLab 多格式聊天记录解析器(14+ 格式)",
|
|
"type": "module",
|
|
"main": "./src/index.ts",
|
|
"types": "./src/index.ts",
|
|
"dependencies": {
|
|
"@openchatlab/parser-native": "workspace:*",
|
|
"@openchatlab/shared-types": "workspace:*",
|
|
"stream-json": "^1.9.1"
|
|
},
|
|
"devDependencies": {
|
|
"@types/stream-json": "^1.7.8"
|
|
}
|
|
}
|