dsh-zotero 0.14.1 → 1.0.0

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 (460) hide show
  1. package/README.en.md +60 -44
  2. package/README.md +65 -48
  3. package/lib/citation-key.d.ts +18 -0
  4. package/lib/citation-key.d.ts.map +1 -0
  5. package/lib/citation-key.js +34 -0
  6. package/lib/citation-key.js.map +1 -0
  7. package/lib/client.js +4893 -3250
  8. package/lib/client.js.map +4 -4
  9. package/lib/config.d.ts +12 -14
  10. package/lib/config.d.ts.map +1 -1
  11. package/lib/config.js +5 -5
  12. package/lib/config.js.map +1 -1
  13. package/lib/constants.d.ts +20 -8
  14. package/lib/constants.d.ts.map +1 -1
  15. package/lib/constants.js +23 -7
  16. package/lib/constants.js.map +1 -1
  17. package/lib/contract.d.ts +81 -10
  18. package/lib/contract.d.ts.map +1 -1
  19. package/lib/contract.js +72 -8
  20. package/lib/contract.js.map +1 -1
  21. package/lib/credential-names.d.ts +13 -0
  22. package/lib/credential-names.d.ts.map +1 -0
  23. package/lib/credential-names.js +13 -0
  24. package/lib/credential-names.js.map +1 -0
  25. package/lib/environment.d.ts +15 -0
  26. package/lib/environment.d.ts.map +1 -0
  27. package/lib/environment.js +25 -0
  28. package/lib/environment.js.map +1 -0
  29. package/lib/errors.d.ts +7 -1
  30. package/lib/errors.d.ts.map +1 -1
  31. package/lib/errors.js +10 -1
  32. package/lib/errors.js.map +1 -1
  33. package/lib/export-mapping.d.ts +7 -1
  34. package/lib/export-mapping.d.ts.map +1 -1
  35. package/lib/export-mapping.js +31 -13
  36. package/lib/export-mapping.js.map +1 -1
  37. package/lib/fiber-state.d.ts +30 -0
  38. package/lib/fiber-state.d.ts.map +1 -0
  39. package/lib/fiber-state.js +18 -0
  40. package/lib/fiber-state.js.map +1 -0
  41. package/lib/http-client.js +2 -2
  42. package/lib/http-client.js.map +1 -1
  43. package/lib/index.d.ts +1 -1
  44. package/lib/index.js +1 -1
  45. package/lib/job-runner.d.ts +40 -7
  46. package/lib/job-runner.d.ts.map +1 -1
  47. package/lib/job-runner.js +89 -9
  48. package/lib/job-runner.js.map +1 -1
  49. package/lib/library/service.d.ts +12 -2
  50. package/lib/library/service.d.ts.map +1 -1
  51. package/lib/library/service.js +13 -2
  52. package/lib/library/service.js.map +1 -1
  53. package/lib/library-views.d.ts.map +1 -1
  54. package/lib/library-views.js +18 -1
  55. package/lib/library-views.js.map +1 -1
  56. package/lib/library-write-denial.d.ts +45 -0
  57. package/lib/library-write-denial.d.ts.map +1 -0
  58. package/lib/library-write-denial.js +51 -0
  59. package/lib/library-write-denial.js.map +1 -0
  60. package/lib/library-write.d.ts.map +1 -1
  61. package/lib/library-write.js +20 -9
  62. package/lib/library-write.js.map +1 -1
  63. package/lib/local/attachment-location.d.ts +9 -5
  64. package/lib/local/attachment-location.d.ts.map +1 -1
  65. package/lib/local/attachment-location.js +35 -43
  66. package/lib/local/attachment-location.js.map +1 -1
  67. package/lib/local/attachment-messages.d.ts +3 -0
  68. package/lib/local/attachment-messages.d.ts.map +1 -0
  69. package/lib/local/attachment-messages.js +5 -0
  70. package/lib/local/attachment-messages.js.map +1 -0
  71. package/lib/local/browse-domain.d.ts.map +1 -1
  72. package/lib/local/browse-domain.js +9 -1
  73. package/lib/local/browse-domain.js.map +1 -1
  74. package/lib/local/children-wire.d.ts +26 -4
  75. package/lib/local/children-wire.d.ts.map +1 -1
  76. package/lib/local/children-wire.js +53 -18
  77. package/lib/local/children-wire.js.map +1 -1
  78. package/lib/local/collection-path.d.ts +13 -0
  79. package/lib/local/collection-path.d.ts.map +1 -0
  80. package/lib/local/collection-path.js +67 -0
  81. package/lib/local/collection-path.js.map +1 -0
  82. package/lib/local/detail.d.ts +11 -24
  83. package/lib/local/detail.d.ts.map +1 -1
  84. package/lib/local/detail.js +287 -178
  85. package/lib/local/detail.js.map +1 -1
  86. package/lib/local/export-domain.d.ts +8 -8
  87. package/lib/local/export-domain.d.ts.map +1 -1
  88. package/lib/local/export-domain.js +17 -15
  89. package/lib/local/export-domain.js.map +1 -1
  90. package/lib/local/get-batch-domain.d.ts +6 -0
  91. package/lib/local/get-batch-domain.d.ts.map +1 -0
  92. package/lib/local/get-batch-domain.js +80 -0
  93. package/lib/local/get-batch-domain.js.map +1 -0
  94. package/lib/local/limits.d.ts +4 -8
  95. package/lib/local/limits.d.ts.map +1 -1
  96. package/lib/local/match-references-domain.d.ts +7 -0
  97. package/lib/local/match-references-domain.d.ts.map +1 -0
  98. package/lib/local/match-references-domain.js +292 -0
  99. package/lib/local/match-references-domain.js.map +1 -0
  100. package/lib/local/pagination.d.ts +7 -14
  101. package/lib/local/pagination.d.ts.map +1 -1
  102. package/lib/local/pagination.js +17 -14
  103. package/lib/local/pagination.js.map +1 -1
  104. package/lib/local/path-resolution.d.ts +123 -0
  105. package/lib/local/path-resolution.d.ts.map +1 -0
  106. package/lib/local/path-resolution.js +342 -0
  107. package/lib/local/path-resolution.js.map +1 -0
  108. package/lib/local/provider.d.ts +11 -7
  109. package/lib/local/provider.d.ts.map +1 -1
  110. package/lib/local/provider.js +20 -8
  111. package/lib/local/provider.js.map +1 -1
  112. package/lib/local/retrieve.js +2 -2
  113. package/lib/local/retrieve.js.map +1 -1
  114. package/lib/local/scope-directory.d.ts +19 -0
  115. package/lib/local/scope-directory.d.ts.map +1 -1
  116. package/lib/local/scope-directory.js +23 -6
  117. package/lib/local/scope-directory.js.map +1 -1
  118. package/lib/local/search-domain.d.ts.map +1 -1
  119. package/lib/local/search-domain.js +24 -0
  120. package/lib/local/search-domain.js.map +1 -1
  121. package/lib/local/write-domain.d.ts +5 -3
  122. package/lib/local/write-domain.d.ts.map +1 -1
  123. package/lib/local/write-domain.js +21 -15
  124. package/lib/local/write-domain.js.map +1 -1
  125. package/lib/normalize-children.d.ts.map +1 -1
  126. package/lib/normalize-children.js +1 -0
  127. package/lib/normalize-children.js.map +1 -1
  128. package/lib/normalize-item-detail.d.ts +15 -0
  129. package/lib/normalize-item-detail.d.ts.map +1 -1
  130. package/lib/normalize-item-detail.js +19 -2
  131. package/lib/normalize-item-detail.js.map +1 -1
  132. package/lib/normalize-scope.d.ts +4 -0
  133. package/lib/normalize-scope.d.ts.map +1 -1
  134. package/lib/normalize-scope.js +6 -1
  135. package/lib/normalize-scope.js.map +1 -1
  136. package/lib/normalize-search.d.ts +1 -1
  137. package/lib/normalize-search.d.ts.map +1 -1
  138. package/lib/normalize-search.js +14 -7
  139. package/lib/normalize-search.js.map +1 -1
  140. package/lib/parameter-correction.d.ts +62 -0
  141. package/lib/parameter-correction.d.ts.map +1 -0
  142. package/lib/parameter-correction.js +164 -0
  143. package/lib/parameter-correction.js.map +1 -0
  144. package/lib/presentation-meta.d.ts +43 -23
  145. package/lib/presentation-meta.d.ts.map +1 -1
  146. package/lib/presentation-meta.js +99 -41
  147. package/lib/presentation-meta.js.map +1 -1
  148. package/lib/prompt.d.ts +66 -12
  149. package/lib/prompt.d.ts.map +1 -1
  150. package/lib/prompt.js +302 -23
  151. package/lib/prompt.js.map +1 -1
  152. package/lib/ref-grammar.d.ts +18 -0
  153. package/lib/ref-grammar.d.ts.map +1 -1
  154. package/lib/ref-grammar.js +22 -1
  155. package/lib/ref-grammar.js.map +1 -1
  156. package/lib/remediation/contract.d.ts +124 -0
  157. package/lib/remediation/contract.d.ts.map +1 -0
  158. package/lib/remediation/contract.js +11 -0
  159. package/lib/remediation/contract.js.map +1 -0
  160. package/lib/remediation/service.d.ts +40 -0
  161. package/lib/remediation/service.d.ts.map +1 -0
  162. package/lib/remediation/service.js +236 -0
  163. package/lib/remediation/service.js.map +1 -0
  164. package/lib/remediation/session-events.d.ts +15 -0
  165. package/lib/remediation/session-events.d.ts.map +1 -0
  166. package/lib/remediation/session-events.js +15 -0
  167. package/lib/remediation/session-events.js.map +1 -0
  168. package/lib/remote.d.ts +41 -1
  169. package/lib/remote.d.ts.map +1 -1
  170. package/lib/remote.js +146 -6
  171. package/lib/remote.js.map +1 -1
  172. package/lib/result-delivery.d.ts +104 -0
  173. package/lib/result-delivery.d.ts.map +1 -0
  174. package/lib/result-delivery.js +394 -0
  175. package/lib/result-delivery.js.map +1 -0
  176. package/lib/result-receipt.d.ts +31 -0
  177. package/lib/result-receipt.d.ts.map +1 -0
  178. package/lib/result-receipt.js +69 -0
  179. package/lib/result-receipt.js.map +1 -0
  180. package/lib/result-route.d.ts +6 -0
  181. package/lib/result-route.d.ts.map +1 -0
  182. package/lib/result-route.js +79 -0
  183. package/lib/result-route.js.map +1 -0
  184. package/lib/scholarly/config.d.ts +59 -22
  185. package/lib/scholarly/config.d.ts.map +1 -1
  186. package/lib/scholarly/config.js +72 -20
  187. package/lib/scholarly/config.js.map +1 -1
  188. package/lib/scholarly/credentials.d.ts +23 -0
  189. package/lib/scholarly/credentials.d.ts.map +1 -0
  190. package/lib/scholarly/credentials.js +54 -0
  191. package/lib/scholarly/credentials.js.map +1 -0
  192. package/lib/scholarly/diagnostics.d.ts +19 -0
  193. package/lib/scholarly/diagnostics.d.ts.map +1 -0
  194. package/lib/scholarly/diagnostics.js +25 -0
  195. package/lib/scholarly/diagnostics.js.map +1 -0
  196. package/lib/scholarly/prompt.d.ts +20 -3
  197. package/lib/scholarly/prompt.d.ts.map +1 -1
  198. package/lib/scholarly/prompt.js +133 -17
  199. package/lib/scholarly/prompt.js.map +1 -1
  200. package/lib/scholarly/service.d.ts +23 -6
  201. package/lib/scholarly/service.d.ts.map +1 -1
  202. package/lib/scholarly/service.js +40 -11
  203. package/lib/scholarly/service.js.map +1 -1
  204. package/lib/scholarly/tools/citations.js +1 -1
  205. package/lib/scholarly/tools/citations.js.map +1 -1
  206. package/lib/scholarly/tools/cite.d.ts.map +1 -1
  207. package/lib/scholarly/tools/cite.js +6 -3
  208. package/lib/scholarly/tools/cite.js.map +1 -1
  209. package/lib/scholarly/tools/common.d.ts +31 -1
  210. package/lib/scholarly/tools/common.d.ts.map +1 -1
  211. package/lib/scholarly/tools/common.js +16 -3
  212. package/lib/scholarly/tools/common.js.map +1 -1
  213. package/lib/scholarly/tools/get.d.ts.map +1 -1
  214. package/lib/scholarly/tools/get.js +4 -2
  215. package/lib/scholarly/tools/get.js.map +1 -1
  216. package/lib/scholarly/tools/jobs.d.ts +258 -0
  217. package/lib/scholarly/tools/jobs.d.ts.map +1 -0
  218. package/lib/scholarly/tools/jobs.js +72 -0
  219. package/lib/scholarly/tools/jobs.js.map +1 -0
  220. package/lib/scholarly/tools/read.d.ts.map +1 -1
  221. package/lib/scholarly/tools/read.js +137 -98
  222. package/lib/scholarly/tools/read.js.map +1 -1
  223. package/lib/scholarly/tools/save-to-zotero.d.ts.map +1 -1
  224. package/lib/scholarly/tools/save-to-zotero.js +6 -2
  225. package/lib/scholarly/tools/save-to-zotero.js.map +1 -1
  226. package/lib/scholarly/tools/search.d.ts.map +1 -1
  227. package/lib/scholarly/tools/search.js +80 -61
  228. package/lib/scholarly/tools/search.js.map +1 -1
  229. package/lib/scholarly/tools/verify.d.ts.map +1 -1
  230. package/lib/scholarly/tools/verify.js +66 -39
  231. package/lib/scholarly/tools/verify.js.map +1 -1
  232. package/lib/scholarly/types.d.ts +6 -4
  233. package/lib/scholarly/types.d.ts.map +1 -1
  234. package/lib/scholarly/types.js +8 -5
  235. package/lib/scholarly/types.js.map +1 -1
  236. package/lib/scholarly/zotero-link.d.ts +2 -0
  237. package/lib/scholarly/zotero-link.d.ts.map +1 -1
  238. package/lib/scholarly/zotero-link.js.map +1 -1
  239. package/lib/service-config.d.ts.map +1 -1
  240. package/lib/service-config.js +0 -2
  241. package/lib/service-config.js.map +1 -1
  242. package/lib/service-lifecycle.d.ts +8 -8
  243. package/lib/service-lifecycle.d.ts.map +1 -1
  244. package/lib/service-lifecycle.js +12 -12
  245. package/lib/service-lifecycle.js.map +1 -1
  246. package/lib/service.d.ts +45 -27
  247. package/lib/service.d.ts.map +1 -1
  248. package/lib/service.js +134 -50
  249. package/lib/service.js.map +1 -1
  250. package/lib/session-projection/source-ledger.d.ts +222 -0
  251. package/lib/session-projection/source-ledger.d.ts.map +1 -0
  252. package/lib/session-projection/source-ledger.js +256 -0
  253. package/lib/session-projection/source-ledger.js.map +1 -0
  254. package/lib/session-projection/types.d.ts +16 -0
  255. package/lib/session-projection/types.d.ts.map +1 -0
  256. package/lib/session-projection/types.js +9 -0
  257. package/lib/session-projection/types.js.map +1 -0
  258. package/lib/skills/citation-lineage.d.ts +3 -0
  259. package/lib/skills/citation-lineage.d.ts.map +1 -0
  260. package/lib/skills/citation-lineage.js +57 -0
  261. package/lib/skills/citation-lineage.js.map +1 -0
  262. package/lib/skills/core.d.ts +2 -0
  263. package/lib/skills/core.d.ts.map +1 -0
  264. package/lib/skills/core.js +5 -0
  265. package/lib/skills/core.js.map +1 -0
  266. package/lib/skills/definition.d.ts +55 -0
  267. package/lib/skills/definition.d.ts.map +1 -0
  268. package/lib/skills/definition.js +94 -0
  269. package/lib/skills/definition.js.map +1 -0
  270. package/lib/skills/evidence-synthesis.d.ts +3 -0
  271. package/lib/skills/evidence-synthesis.d.ts.map +1 -0
  272. package/lib/skills/evidence-synthesis.js +92 -0
  273. package/lib/skills/evidence-synthesis.js.map +1 -0
  274. package/lib/skills/library-governance.d.ts +3 -0
  275. package/lib/skills/library-governance.d.ts.map +1 -0
  276. package/lib/skills/library-governance.js +86 -0
  277. package/lib/skills/library-governance.js.map +1 -0
  278. package/lib/skills/literature-intake.d.ts +3 -0
  279. package/lib/skills/literature-intake.d.ts.map +1 -0
  280. package/lib/skills/literature-intake.js +93 -0
  281. package/lib/skills/literature-intake.js.map +1 -0
  282. package/lib/skills/manuscript-reference-audit.d.ts +3 -0
  283. package/lib/skills/manuscript-reference-audit.d.ts.map +1 -0
  284. package/lib/skills/manuscript-reference-audit.js +99 -0
  285. package/lib/skills/manuscript-reference-audit.js.map +1 -0
  286. package/lib/skills/publication-integrity.d.ts +3 -0
  287. package/lib/skills/publication-integrity.d.ts.map +1 -0
  288. package/lib/skills/publication-integrity.js +51 -0
  289. package/lib/skills/publication-integrity.js.map +1 -0
  290. package/lib/skills/register.d.ts +5 -0
  291. package/lib/skills/register.d.ts.map +1 -0
  292. package/lib/skills/register.js +14 -0
  293. package/lib/skills/register.js.map +1 -0
  294. package/lib/skills/research-landscape.d.ts +3 -0
  295. package/lib/skills/research-landscape.d.ts.map +1 -0
  296. package/lib/skills/research-landscape.js +56 -0
  297. package/lib/skills/research-landscape.js.map +1 -0
  298. package/lib/skills/scholarly.d.ts +2 -0
  299. package/lib/skills/scholarly.d.ts.map +1 -0
  300. package/lib/skills/scholarly.js +11 -0
  301. package/lib/skills/scholarly.js.map +1 -0
  302. package/lib/sources/bibtex.d.ts +12 -0
  303. package/lib/sources/bibtex.d.ts.map +1 -0
  304. package/lib/sources/bibtex.js +29 -0
  305. package/lib/sources/bibtex.js.map +1 -0
  306. package/lib/sources/block-types.d.ts +55 -0
  307. package/lib/sources/block-types.d.ts.map +1 -0
  308. package/lib/sources/block-types.js +10 -0
  309. package/lib/sources/block-types.js.map +1 -0
  310. package/lib/sources/decoders.d.ts +147 -0
  311. package/lib/sources/decoders.d.ts.map +1 -0
  312. package/lib/sources/decoders.js +296 -0
  313. package/lib/sources/decoders.js.map +1 -0
  314. package/lib/sources/event-ledger.d.ts +79 -0
  315. package/lib/sources/event-ledger.d.ts.map +1 -0
  316. package/lib/sources/event-ledger.js +230 -0
  317. package/lib/sources/event-ledger.js.map +1 -0
  318. package/lib/sources/evidence-match.d.ts +32 -0
  319. package/lib/sources/evidence-match.d.ts.map +1 -0
  320. package/lib/sources/evidence-match.js +58 -0
  321. package/lib/sources/evidence-match.js.map +1 -0
  322. package/lib/sources/export-decoder.d.ts +18 -0
  323. package/lib/sources/export-decoder.d.ts.map +1 -0
  324. package/lib/sources/export-decoder.js +68 -0
  325. package/lib/sources/export-decoder.js.map +1 -0
  326. package/lib/sources/ledger.d.ts +26 -0
  327. package/lib/sources/ledger.d.ts.map +1 -0
  328. package/lib/sources/ledger.js +644 -0
  329. package/lib/sources/ledger.js.map +1 -0
  330. package/lib/sources/model.d.ts +241 -0
  331. package/lib/sources/model.d.ts.map +1 -0
  332. package/lib/sources/model.js +12 -0
  333. package/lib/sources/model.js.map +1 -0
  334. package/lib/sources/presenters.d.ts +78 -0
  335. package/lib/sources/presenters.d.ts.map +1 -0
  336. package/lib/sources/presenters.js +188 -0
  337. package/lib/sources/presenters.js.map +1 -0
  338. package/lib/sources/receipt.d.ts +15 -0
  339. package/lib/sources/receipt.d.ts.map +1 -0
  340. package/lib/sources/receipt.js +25 -0
  341. package/lib/sources/receipt.js.map +1 -0
  342. package/lib/spill.d.ts +28 -0
  343. package/lib/spill.d.ts.map +1 -0
  344. package/lib/spill.js +51 -0
  345. package/lib/spill.js.map +1 -0
  346. package/lib/status-codec.d.ts +0 -6
  347. package/lib/status-codec.d.ts.map +1 -1
  348. package/lib/status-codec.js +2 -39
  349. package/lib/status-codec.js.map +1 -1
  350. package/lib/step-tools.d.ts +25 -0
  351. package/lib/step-tools.d.ts.map +1 -0
  352. package/lib/step-tools.js +34 -0
  353. package/lib/step-tools.js.map +1 -0
  354. package/lib/subagent-guard.d.ts +45 -0
  355. package/lib/subagent-guard.d.ts.map +1 -0
  356. package/lib/subagent-guard.js +192 -0
  357. package/lib/subagent-guard.js.map +1 -0
  358. package/lib/tool-diagnostics.d.ts +9 -0
  359. package/lib/tool-diagnostics.d.ts.map +1 -1
  360. package/lib/tool-diagnostics.js +33 -22
  361. package/lib/tool-diagnostics.js.map +1 -1
  362. package/lib/tool-registration.d.ts.map +1 -1
  363. package/lib/tool-registration.js +19 -10
  364. package/lib/tool-registration.js.map +1 -1
  365. package/lib/tools/browse.d.ts +27 -14
  366. package/lib/tools/browse.d.ts.map +1 -1
  367. package/lib/tools/browse.js +27 -18
  368. package/lib/tools/browse.js.map +1 -1
  369. package/lib/tools/changes.d.ts +11 -3
  370. package/lib/tools/changes.d.ts.map +1 -1
  371. package/lib/tools/changes.js +11 -10
  372. package/lib/tools/changes.js.map +1 -1
  373. package/lib/tools/child-records.d.ts +113 -2
  374. package/lib/tools/child-records.d.ts.map +1 -1
  375. package/lib/tools/child-records.js +39 -2
  376. package/lib/tools/child-records.js.map +1 -1
  377. package/lib/tools/export.d.ts +4 -2
  378. package/lib/tools/export.d.ts.map +1 -1
  379. package/lib/tools/export.js +130 -21
  380. package/lib/tools/export.js.map +1 -1
  381. package/lib/tools/get-batch.d.ts +125 -0
  382. package/lib/tools/get-batch.d.ts.map +1 -0
  383. package/lib/tools/get-batch.js +148 -0
  384. package/lib/tools/get-batch.js.map +1 -0
  385. package/lib/tools/get.d.ts +285 -16
  386. package/lib/tools/get.d.ts.map +1 -1
  387. package/lib/tools/get.js +97 -13
  388. package/lib/tools/get.js.map +1 -1
  389. package/lib/tools/match-references.d.ts +100 -0
  390. package/lib/tools/match-references.d.ts.map +1 -0
  391. package/lib/tools/match-references.js +116 -0
  392. package/lib/tools/match-references.js.map +1 -0
  393. package/lib/tools/retrieve.d.ts +6 -5
  394. package/lib/tools/retrieve.d.ts.map +1 -1
  395. package/lib/tools/retrieve.js +8 -7
  396. package/lib/tools/retrieve.js.map +1 -1
  397. package/lib/tools/saved-search.d.ts +7 -0
  398. package/lib/tools/saved-search.d.ts.map +1 -1
  399. package/lib/tools/saved-search.js +7 -0
  400. package/lib/tools/saved-search.js.map +1 -1
  401. package/lib/tools/search.d.ts +90 -19
  402. package/lib/tools/search.d.ts.map +1 -1
  403. package/lib/tools/search.js +61 -29
  404. package/lib/tools/search.js.map +1 -1
  405. package/lib/tools/update-item.d.ts +3 -1
  406. package/lib/tools/update-item.d.ts.map +1 -1
  407. package/lib/tools/update-item.js +13 -2
  408. package/lib/tools/update-item.js.map +1 -1
  409. package/lib/transport-bounds.d.ts +1 -1
  410. package/lib/transport-bounds.d.ts.map +1 -1
  411. package/lib/transport-bounds.js +3 -3
  412. package/lib/transport-bounds.js.map +1 -1
  413. package/lib/typert.d.ts.map +1 -1
  414. package/lib/typert.js +16 -1
  415. package/lib/typert.js.map +1 -1
  416. package/lib/types.d.ts +136 -41
  417. package/lib/types.d.ts.map +1 -1
  418. package/lib/types.js.map +1 -1
  419. package/lib/wire-schemas.d.ts +85 -8
  420. package/lib/wire-schemas.d.ts.map +1 -1
  421. package/lib/wire-schemas.js +90 -19
  422. package/lib/wire-schemas.js.map +1 -1
  423. package/lib/write-auth.d.ts +14 -4
  424. package/lib/write-auth.d.ts.map +1 -1
  425. package/lib/write-auth.js +27 -6
  426. package/lib/write-auth.js.map +1 -1
  427. package/lib/write-present.d.ts.map +1 -1
  428. package/lib/write-present.js +5 -0
  429. package/lib/write-present.js.map +1 -1
  430. package/locale/en.json +6 -2
  431. package/locale/zh.json +6 -2
  432. package/package.json +215 -165
  433. package/lib/command.d.ts +0 -43
  434. package/lib/command.d.ts.map +0 -1
  435. package/lib/command.js +0 -126
  436. package/lib/command.js.map +0 -1
  437. package/lib/normalize.d.ts +0 -8
  438. package/lib/normalize.d.ts.map +0 -1
  439. package/lib/normalize.js +0 -8
  440. package/lib/normalize.js.map +0 -1
  441. package/lib/projection-keys.d.ts +0 -28
  442. package/lib/projection-keys.d.ts.map +0 -1
  443. package/lib/projection-keys.js +0 -14
  444. package/lib/projection-keys.js.map +0 -1
  445. package/lib/session-events.d.ts +0 -39
  446. package/lib/session-events.d.ts.map +0 -1
  447. package/lib/session-events.js +0 -40
  448. package/lib/session-events.js.map +0 -1
  449. package/lib/status-projection.d.ts +0 -28
  450. package/lib/status-projection.d.ts.map +0 -1
  451. package/lib/status-projection.js +0 -68
  452. package/lib/status-projection.js.map +0 -1
  453. package/lib/tools/attachment.d.ts +0 -19
  454. package/lib/tools/attachment.d.ts.map +0 -1
  455. package/lib/tools/attachment.js +0 -113
  456. package/lib/tools/attachment.js.map +0 -1
  457. package/lib/tools/children.d.ts +0 -180
  458. package/lib/tools/children.d.ts.map +0 -1
  459. package/lib/tools/children.js +0 -167
  460. package/lib/tools/children.js.map +0 -1
package/README.en.md CHANGED
@@ -3,7 +3,7 @@
3
3
  # dsh-zotero
4
4
 
5
5
  <img
6
- src="https://readme-typing-svg.demolab.com?font=JetBrains+Mono&weight=500&size=18&pause=2000&color=CC2936&center=true&vCenter=true&width=760&lines=%3E+Search%2C+read%2C+and+cite+papers+from+local+Zotero."
6
+ src="https://readme-typing-svg.demolab.com?font=JetBrains+Mono&weight=500&size=18&pause=2000&color=CC2936&center=true&vCenter=true&width=760&lines=%3E+Search%2C+read%2C+and+trace+citations+from+local+Zotero.%3B%3E+Audit+every+source+and+passage+in+the+Literature+Trail.%3B%3E+Browse+collections+and+cite+instantly+in+the+Literature+Panel."
7
7
  alt="dsh-zotero"
8
8
  />
9
9
  <p align="center">
@@ -11,8 +11,9 @@
11
11
  <a href="https://www.npmjs.com/package/dsh-zotero"><img src="https://img.shields.io/npm/v/dsh-zotero" alt="npm version" style="max-width:100%;"></a>
12
12
  <a href="https://www.npmjs.com/package/dsh-zotero"><img src="https://img.shields.io/npm/dm/dsh-zotero" alt="npm downloads" style="max-width:100%;"></a>
13
13
  <a href="https://www.npmjs.com/package/dsh-zotero"><img src="https://img.shields.io/npm/l/dsh-zotero" alt="license" style="max-width:100%;"></a>
14
- <a href="https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.1-rc.3"><img src="https://img.shields.io/badge/dsh-0.2.1--rc.3-blue" alt="dsh version" style="max-width:100%;"></a>
14
+ <a href="https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.2-rc.1"><img src="https://img.shields.io/badge/dsh-0.2.2--rc.1-blue" alt="dsh version" style="max-width:100%;"></a>
15
15
  <a href="https://awesome-dsh-plugin.com"><img src="https://awesome-dsh-plugin.com/badge.svg" alt="Awesome DSH Plugin"></a>
16
+ <a href="https://github.com/hashgraph-online/hol-guard"><img src="https://img.shields.io/badge/HOL%20Guard-passing-00a67e" alt="HOL Guard Scanner"></a>
16
17
  </p>
17
18
  </div>
18
19
 
@@ -40,19 +41,28 @@ All operations interact with Zotero through its local API (`127.0.0.1:23119`). R
40
41
  - Details & reading: Inspect metadata, notes, and attachment lists, and open local PDFs directly in the reading pane.
41
42
  - Citations & handoff: Copy BibTeX entries, CSL citations, or item details directly from the action row, or send selected items into the chat draft with one click.
42
43
 
43
- See the [product model](docs/product-model.en.md) for how the two entry points and three components divide the work.
44
+ For details on interaction patterns, UI roles, and runtime boundaries, see the [product model](docs/product-model.en.md).
44
45
 
45
46
  ## Install
46
47
 
47
- From npm (recommended):
48
+ ### Desktop app (Plugin Manager)
49
+
50
+ In the DeepSeek Harness desktop app, open **Plugins** in the sidebar, click **Add Plugin**, and enter the package identifier:
51
+
52
+ - Latest version (recommended): `dsh-zotero`
53
+ - Specific version: `dsh-zotero@0.14.1`
54
+ - GitHub prebuilt branch: `github:Vncntvx/dsh-zotero#release`
55
+
56
+ ### Command line
48
57
 
49
58
  ```sh
59
+ # Install latest from npm (recommended)
50
60
  dsh plugin --profile <name> add dsh-zotero
51
- ```
52
61
 
53
- From GitHub prebuilt branch:
62
+ # Install a specific version
63
+ dsh plugin --profile <name> add dsh-zotero@<version>
54
64
 
55
- ```sh
65
+ # Install from GitHub prebuilt branch
56
66
  dsh plugin --profile <name> add github:Vncntvx/dsh-zotero#release
57
67
  ```
58
68
 
@@ -65,50 +75,57 @@ Start a new session after installation. Open the **dsh-zotero** detail page in t
65
75
  1. Zotero 7 or newer desktop app installed (writes require Zotero 10).
66
76
  2. Enable the local API in Zotero: **Settings → Advanced → check "Allow other applications on this computer to communicate with Zotero"**.
67
77
 
68
- ## Usage example
78
+ ## Usage examples
69
79
 
70
- Search first, then check:
80
+ ### 1. Research and trace citations in conversation
71
81
 
72
- ```text
73
- User: Find papers about Risk
74
- Agent → zotero_search(query: "Risk", itemTypes: ["journalArticle"])
75
- Returns 5 matches; the literature trail at the top of the session shows the same 5 papers
82
+ Ask questions about your research topics directly in chat. The agent automatically retrieves items from your local Zotero library, reads full texts, and extracts passages with original page numbers:
76
83
 
77
- User: Find the methodology discussion in this paper
78
- Agent → zotero_retrieve(ref: "zotero://user/0/item/ABCD1234", query: "methodology",
79
- sources: ["annotation", "fulltext"])
80
- Returns ranked passages with source labels (annotations carry original page numbers)
84
+ - **Literature search & QA**: Ask the agent about a research direction; the agent searches your local library and synthesizes answers using abstracts and metadata.
85
+ ```text
86
+ Agent → zotero_search(query: "Risk", itemTypes: ["journalArticle"])
87
+ ```
88
+ - **Locate original passages**: Ask deeper questions about paper details; the agent extracts relevant passages from local PDF full text and annotations, with original page numbers attached.
89
+ ```text
90
+ Agent → zotero_retrieve(ref: "zotero://user/0/item/ABCD1234", query: "methodology", sources: ["annotation", "fulltext"])
91
+ ```
92
+ - **Generate formatted citations**: Ask for formatted outputs; the agent generates BibTeX entries or CSL citations in your requested style.
93
+ ```text
94
+ Agent → zotero_export(refs: ["zotero://user/0/item/ABCD1234"], format: "bibtex")
95
+ ```
81
96
 
82
- User: Export these three as BibTeX
83
- Agent → zotero_export(refs: [...], format: "bibtex")
84
- Generates BibTeX entries, which can be copied or downloaded from the exports view
85
- of the literature trail
86
- ```
97
+ ### 2. Verify sources and export in the literature trail
87
98
 
88
- To use the literature while writing: find an item in the literature panel, click "Copy citation" or "Copy BibTeX" in the action row, and paste the citation text or entry into your paper's source file. To bring the agent in, click "Ask" or "Add to chat"; the content is prefilled into the session draft.
99
+ After a conversation, click the **Literature Trail** tab at the top of the session to inspect and verify all references used in that session:
89
100
 
90
- ## Tools
101
+ - **Review search criteria**: The overview screen displays every query term, search scope (whole library, collection, or saved search), filter conditions, and hit count invoked during the session.
102
+ - **Inspect sources item by item**: Check extracted passages against original page numbers and annotations in the item inspector to ensure every cited point is grounded in the source.
103
+ - **Deduplicated export aggregation**: Review all citations and BibTeX entries produced during the session in the Export view, automatically deduplicated across items and ready for one-click copying or downloading.
91
104
 
92
- The plugin provides eight read tools and fifteen write tools. Write tools are off by default; turn on `writeEnabled` in configuration to enable them.
105
+ ### 3. Browse, read, and cite in the literature panel
106
+
107
+ When writing papers or organizing literature independently, use the **Literature Panel** in the right sidebar without going through chat:
108
+
109
+ - **Independent browsing & filtering**: Browse the collection tree, tag system, saved searches, and Trash, with combined filtering by publication year and item type.
110
+ - **Inspect details & read PDFs**: Click any item to inspect metadata and associated notes, or open the local PDF directly in the reading pane.
111
+ - **Instant citations & chat handoff**: Click "Copy BibTeX" or "Copy citation" in the action row to paste directly into your manuscript; click "Ask" or "Add to chat" to send selected references into the chat draft for targeted discussions.
93
112
 
94
- | Tool | Purpose |
95
- | ------------------- | ------------------------------------------------------------------------------------------------------------------ |
96
- | `zotero_search` | Search papers by title, author, year, tag, or full text, with collection and tag filters |
97
- | `zotero_browse` | Browse the library structure, including the collection tree, tag list, and saved searches |
98
- | `zotero_get` | Read the metadata detail, abstract, attachments, and note list of a single paper |
99
- | `zotero_children` | View the child items associated with a paper, including standalone notes, PDF attachments, and reading annotations |
100
- | `zotero_retrieve` | Find passages relevant to a question in full text, notes, and annotations (annotations keep page numbers) |
101
- | `zotero_changes` | Check recent additions, modifications, and deletions in the library |
102
- | `zotero_attachment` | Get the local PDF file path associated with a paper |
103
- | `zotero_export` | Generate formatted citations or a bibliography, or export BibTeX, RIS, or CSL JSON |
113
+ ## Tools
104
114
 
105
- The fifteen write tools (notes, tags and collection membership, collections, items, saved searches, Trash restore, library-wide tags, and batch operations) are off by default. Once enabled they write only to the personal library, and every write needs approval. See the [tool reference](docs/tools.en.md) for the full contract of all 23 tools.
115
+ The plugin provides eight read tools and fifteen write tools. Write tools are off by default; turn on `writeEnabled` in configuration to enable them.
106
116
 
107
- ## Security and privacy
117
+ | Tool | Purpose |
118
+ | ------------------------- | --------------------------------------------------------------------------------------------------------- |
119
+ | `zotero_search` | Search papers by title, author, year, tag, or full text, with collection and tag filters |
120
+ | `zotero_browse` | Browse the library structure, including the collection tree, tag list, and saved searches |
121
+ | `zotero_get` | Read the metadata detail, abstract, attachments, and note list of a single paper |
122
+ | `zotero_get_batch` | Read known paper refs in order and report each result independently |
123
+ | `zotero_match_references` | Reconcile DOI, BibTeX, and reference fields against local items |
124
+ | `zotero_retrieve` | Find passages relevant to a question in full text, notes, and annotations (annotations keep page numbers) |
125
+ | `zotero_changes` | Check recent additions, modifications, and deletions in the library |
126
+ | `zotero_export` | Generate formatted citations or a bibliography, or export BibTeX, RIS, or CSL JSON |
108
127
 
109
- - The plugin sends requests only to the local Zotero API and does not call Zotero cloud services. External requests come only from the scholarly retrieval component, which is off by default.
110
- - Write tools are disabled by default. Once enabled, every library modification shows an approval and plan review card and runs only after the user confirms it. Writes are not retried automatically.
111
- - The plugin only resolves and validates local attachment paths. It runs no system commands and starts no background resident process.
128
+ The fifteen write tools (notes, tags and collection membership, collections, items, saved searches, Trash restore, library-wide tags, and batch operations) are off by default. Once enabled they write only to the personal library, and every write needs approval. See the [tool reference](docs/tools.en.md) for the full contract of all 23 local tools.
112
129
 
113
130
  ## Documentation
114
131
 
@@ -117,8 +134,9 @@ The fifteen write tools (notes, tags and collection membership, collections, ite
117
134
  | Document | Covers |
118
135
  | --------------------------------------------- | ------------------------------------------------------------------------------------------------------ |
119
136
  | [Getting started](docs/getting-started.en.md) | Installation, connection verification, and the first task |
120
- | [Product model](docs/product-model.en.md) | Two entry points, three concepts, three components, and four boundaries |
137
+ | [Product model](docs/product-model.en.md) | Two entry points, two UI surfaces, component division, and system boundaries |
121
138
  | [Features](docs/features.en.md) | Conversation capabilities, the literature trail, the literature panel, writes, and scholarly retrieval |
139
+ | [Research SOP skills](docs/skills.en.md) | Seven on-demand research workflows, batching budgets and evidence boundaries |
122
140
  | [Troubleshooting](docs/troubleshooting.en.md) | Common issues, diagnostic steps, and remedies |
123
141
 
124
142
  ### Maintenance
@@ -130,8 +148,6 @@ The fifteen write tools (notes, tags and collection membership, collections, ite
130
148
  | [Configuration reference](docs/configuration.en.md) | Fields, defaults, and hot-reload behavior of each settings namespace |
131
149
  | [Development guide](docs/development.en.md) | Build, test, debug, and release workflow |
132
150
 
133
- The acceptance scenarios ([docs/scenarios.en.md](docs/scenarios.en.md)) are for maintainers.
134
-
135
151
  ## License
136
152
 
137
- [MIT](./LICENSE)
153
+ This project is licensed under the [MIT License](./LICENSE).
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  # dsh-zotero
4
4
 
5
5
  <img
6
- src="https://readme-typing-svg.demolab.com?font=JetBrains+Mono&weight=500&size=20&pause=2000&color=CC2936&center=true&vCenter=true&width=760&lines=%3E+Search%2C+read%2C+and+cite+papers+from+local+Zotero."
6
+ src="https://readme-typing-svg.demolab.com?font=JetBrains+Mono&weight=500&size=18&pause=2000&color=CC2936&center=true&vCenter=true&width=760&lines=%3E+Search%2C+read%2C+and+trace+citations+from+local+Zotero.%3B%3E+Audit+every+source+and+passage+in+the+Literature+Trail.%3B%3E+Browse+collections+and+cite+instantly+in+the+Literature+Panel."
7
7
  alt="dsh-zotero"
8
8
  />
9
9
  <p align="center">
@@ -11,8 +11,9 @@
11
11
  <a href="https://www.npmjs.com/package/dsh-zotero"><img src="https://img.shields.io/npm/v/dsh-zotero" alt="npm version" style="max-width:100%;"></a>
12
12
  <a href="https://www.npmjs.com/package/dsh-zotero"><img src="https://img.shields.io/npm/dm/dsh-zotero" alt="npm downloads" style="max-width:100%;"></a>
13
13
  <a href="https://www.npmjs.com/package/dsh-zotero"><img src="https://img.shields.io/npm/l/dsh-zotero" alt="license" style="max-width:100%;"></a>
14
- <a href="https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.1-rc.3"><img src="https://img.shields.io/badge/dsh-0.2.1--rc.3-blue" alt="dsh 版本" style="max-width:100%;"></a>
14
+ <a href="https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.2-rc.1"><img src="https://img.shields.io/badge/dsh-0.2.2--rc.1-blue" alt="dsh 版本" style="max-width:100%;"></a>
15
15
  <a href="https://awesome-dsh-plugin.com"><img src="https://awesome-dsh-plugin.com/badge.svg" alt="Awesome DSH Plugin"></a>
16
+ <a href="https://github.com/hashgraph-online/hol-guard"><img src="https://img.shields.io/badge/HOL%20Guard-passing-00a67e" alt="HOL Guard Scanner"></a>
16
17
  </p>
17
18
  </div>
18
19
 
@@ -20,39 +21,48 @@
20
21
  <a href="README.en.md"><b>English</b></a> · <b>中文</b>
21
22
  </p>
22
23
 
23
- dsh-zotero 是面向 DeepSeek Harness 的本地 Zotero 插件。Agent 在对话里检索、阅读、引用并按需修改文献库;你在文献面板里浏览整个库并复制引用;文献轨迹则集中展示 Agent 在当前会话中查到的文献、提取的原文片段与导出内容,方便对照核对。
24
+ dsh-zotero 是面向 DeepSeek Harness 的本地 Zotero 插件。Agent 在对话里检索、阅读、引用并按需修改文献库;你在文献面板里浏览整个库并复制引用;文献轨迹展示 Agent 在当前会话中查到的文献、原文片段与导出内容,方便核对。
24
25
 
25
26
  所有操作均通过 Zotero 本地 API(`127.0.0.1:23119`)与桌面端交互,读取无需配置 API Key。
26
27
 
27
28
  ## 主要功能
28
29
 
29
30
  - **对话检索**
30
- - 检索与阅读:按标题、作者、年份或全文搜索文献,读取元数据、个人笔记与本地 PDF 全文。
31
- - 原文片段定位:围绕具体问题从全文、批注和笔记中提取相关段落,PDF 批注附带原始页码。
32
- - 引用与导出:按 CSL 样式生成行内引用或参考文献表,支持导出 BibTeX、RIS 与 CSL-JSON。
33
- - 写入与扩展(可选):开启后可创建笔记、修改标签与合集(每次均需会话审批);启用学术检索组件后可跨 7 个外部索引检索文献并核验引用。
31
+ - 检索阅读:按标题、作者、年份或全文搜索文献,读取元数据、个人笔记与本地 PDF 全文。
32
+ - 原文定位:围绕具体问题从全文、批注和笔记中提取相关段落,PDF 批注附带原始页码。
33
+ - 引用导出:按 CSL 样式生成行内引用或参考文献表,支持导出 BibTeX、RIS 与 CSL-JSON。
34
+ - 写入扩展(可选):开启后可创建笔记、修改标签与合集(每次均需会话审批);启用学术检索组件后可跨 7 个外部索引检索文献并核验引用。
34
35
  - **文献轨迹**
35
36
  - 检索记录:会话顶部首屏显示每次调用的查询词、范围、筛选条件与命中数。
36
37
  - 原文核对:按文献条目整理提取出的段落与批注,标明出处与原始页码,方便核对。
37
38
  - 导出汇总:跨条目汇总当前会话生成的所有引用与 BibTeX,自动去重,可直接复制或下载。
38
39
  - **文献面板**
39
- - 全库浏览:在右侧边栏浏览合集树、标签、保存的搜索与回收站,支持多条件组合筛选。
40
+ - 全库浏览:在右侧边栏浏览 Zotero 合集树、标签、保存的搜索与回收站,支持多条件组合筛选。
40
41
  - 详情与阅读:查看条目元数据、关联笔记与附件列表,支持在右侧阅读栏直接打开本地 PDF。
41
42
  - 引用与联动:动作行直接复制 BibTeX、CSL 引用或条目信息;支持将选中文献一键填入对话输入框。
42
43
 
43
- 两个入口与三个组件的分工见[产品模型](docs/product-model.md)。
44
+ 交互方式、界面分工与运行边界详见[产品模型](docs/product-model.md)。
44
45
 
45
46
  ## 安装
46
47
 
47
- 从 npm 安装(推荐):
48
+ ### 桌面端安装(插件管理器)
49
+
50
+ 在 DeepSeek Harness 桌面端打开侧栏的**插件**,点击**添加插件**,输入对应标识:
51
+
52
+ - 最新版(推荐):`dsh-zotero`
53
+ - 指定版本:`dsh-zotero@0.14.1`
54
+ - GitHub 预构建分支:`github:Vncntvx/dsh-zotero#release`
55
+
56
+ ### 命令行安装
48
57
 
49
58
  ```sh
59
+ # npm 安装最新版(推荐)
50
60
  dsh plugin --profile <name> add dsh-zotero
51
- ```
52
61
 
53
- 从 GitHub 预构建分支安装:
62
+ # 安装指定版本
63
+ dsh plugin --profile <name> add dsh-zotero@<version>
54
64
 
55
- ```sh
65
+ # 从 GitHub 预构建分支安装
56
66
  dsh plugin --profile <name> add github:Vncntvx/dsh-zotero#release
57
67
  ```
58
68
 
@@ -67,47 +77,55 @@ dsh plugin --profile <name> add github:Vncntvx/dsh-zotero#release
67
77
 
68
78
  ## 使用示例
69
79
 
70
- 先检索,再核对:
80
+ ### 1. 在对话中研读与定位出处
71
81
 
72
- ```text
73
- 用户:帮我找 Risk 相关的论文
74
- Agent → zotero_search(query: "Risk", itemTypes: ["journalArticle"])
75
- 返回 5 篇匹配结果;会话顶部的文献轨迹同步出现这 5 篇
82
+ 在日常会话中直接围绕研究问题提问,Agent 会自动调取本地文献库检索、精读全文并抓取带页码的原文段落:
76
83
 
77
- 用户:这篇里关于方法论的讨论,帮我找出来
78
- Agent → zotero_retrieve(ref: "zotero://user/0/item/ABCD1234", query: "methodology",
79
- sources: ["annotation", "fulltext"])
80
- 返回排序段落与来源标注(批注附带原始页码)
84
+ - **文献检索与问答**:向 Agent 询问某个研究方向,Agent 检索本地文献库,结合文献摘要与元数据生成回答。
85
+ ```text
86
+ Agent → zotero_search(query: "Risk", itemTypes: ["journalArticle"])
87
+ ```
88
+ - **定位原文段落**:深入追问论文细节,Agent 从本地 PDF 全文与批注中提取相关段落,并附带原始页码标注。
89
+ ```text
90
+ Agent → zotero_retrieve(ref: "zotero://user/0/item/ABCD1234", query: "methodology", sources: ["annotation", "fulltext"])
91
+ ```
92
+ - **生成标准引用**:要求格式化输出时,Agent 直接生成 BibTeX 条目或指定样式的 CSL 引用。
93
+ ```text
94
+ Agent → zotero_export(refs: ["zotero://user/0/item/ABCD1234"], format: "bibtex")
95
+ ```
81
96
 
82
- 用户:把这三篇导出为 BibTeX
83
- Agent → zotero_export(refs: [...], format: "bibtex")
84
- 生成 BibTeX 条目,可在文献轨迹的导出视图复制或下载
85
- ```
97
+ ### 2. 在文献轨迹中核对出处与导出
86
98
 
87
- 写论文时直接取用:在文献面板找到条目,动作行点「复制引用」或「复制 BibTeX」,把引用文本或词条粘贴到论文源文件中;需要 Agent 参与时点「提问」或「加入对话」,内容会预填进会话草稿。
99
+ 对话结束后,点击会话顶部的**文献轨迹**标签页,集中查看与核验本次对话调用的所有文献:
88
100
 
89
- ## 工具一览
101
+ - **查看检索条件**:首屏展示 Agent 在当前会话中每次调用的查询词、检索范围(全库/合集/保存搜索)、筛选条件与命中篇数。
102
+ - **逐条核对出处**:在条目检查器中核对引用的原文段落,比对原始页码与批注,确认论据真实无误。
103
+ - **去重汇总导出**:在「导出」视图中集中查看本轮会话生成的全部引用与 BibTeX,跨条目自动去重,支持一键批量复制或下载。
90
104
 
91
- 插件提供 8 个读取工具与 15 个写入工具。写入工具默认关闭,可在配置中开启 `writeEnabled`。
105
+ ### 3. 在文献面板中自主查阅与即时引用
106
+
107
+ 写论文或独立整理文献时,直接在右侧边栏使用**「文献面板」**,无需通过 Agent 对话:
108
+
109
+ - **自主翻阅与筛选**:浏览 Zotero 分类合集树、标签体系、保存的搜索与回收站,支持按年份与条目类型组合筛选。
110
+ - **检视详情与阅读 PDF**:点击条目查看详细元数据与关联笔记,在右侧阅读栏直接打开本地 PDF。
111
+ - **一键引用与对话联动**:在动作行点击「复制 BibTeX」或「复制引用」直接粘贴到论文源文件;点击「提问」或「加入对话」可将选中文献一键送入会话草稿,展开定向讨论。
92
112
 
93
- | 工具 | 用途 |
94
- | ------------------- | ------------------------------------------------------------ |
95
- | `zotero_search` | 按标题、作者、年份、标签或全文搜索文献,支持按分类与标签筛选 |
96
- | `zotero_browse` | 浏览文献库结构,包括分类合集树、标签列表和保存的搜索 |
97
- | `zotero_get` | 读取单篇文献的元数据详情、摘要、附件与笔记列表 |
98
- | `zotero_children` | 查看文献关联的子条目,包括独立笔记、PDF 附件和阅读批注 |
99
- | `zotero_retrieve` | 围绕问题从全文、笔记与批注中检索相关段落(批注保留页码) |
100
- | `zotero_changes` | 检查文献库最近的新增、修改或删除记录 |
101
- | `zotero_attachment` | 获取文献关联的本地 PDF 文件路径 |
102
- | `zotero_export` | 生成格式化引用、参考文献列表,或导出 BibTeX、RIS、CSL JSON |
113
+ ## 工具一览
103
114
 
104
- 15 个写入工具(笔记、标签与合集归属、合集、条目、保存搜索、Trash 恢复、全库标签、批量操作)默认关闭,开启后仅写入个人库,且每次写入都需要审批。全部 23 个工具的完整契约见[工具参考](docs/tools.md)。
115
+ 插件提供 8 个读取工具与 15 个写入工具。写入工具默认关闭,可在配置中开启 `writeEnabled`。
105
116
 
106
- ## 安全与隐私
117
+ | 工具 | 用途 |
118
+ | ------------------------- | ------------------------------------------------------------ |
119
+ | `zotero_search` | 按标题、作者、年份、标签或全文搜索文献,支持按分类与标签筛选 |
120
+ | `zotero_browse` | 浏览文献库结构,包括分类合集树、标签列表和保存的搜索 |
121
+ | `zotero_get` | 读取单篇文献的元数据详情、摘要、附件与笔记列表 |
122
+ | `zotero_get_batch` | 按顺序批量读取已知文献 ref,逐条报告结果 |
123
+ | `zotero_match_references` | 将 DOI/BibTeX/文献字段与本地条目对账 |
124
+ | `zotero_retrieve` | 围绕问题从全文、笔记与批注中检索相关段落(批注保留页码) |
125
+ | `zotero_changes` | 检查文献库最近的新增、修改或删除记录 |
126
+ | `zotero_export` | 生成格式化引用、参考文献列表,或导出 BibTeX、RIS、CSL JSON |
107
127
 
108
- - 插件只向本机 Zotero 接口发请求,不调用 Zotero 云端服务。外部请求只来自默认关闭的学术检索组件。
109
- - 写入工具默认禁用。开启后每次修改文献库都会展示审批与计划审查卡,用户确认后才执行;写入不自动重试。
110
- - 插件只解析和校验本地附件路径,不执行系统命令,也不启动后台常驻进程。
128
+ 15 个写入工具(笔记、标签与合集归属、合集、条目、保存搜索、Trash 恢复、全库标签、批量操作)默认关闭,开启后仅写入个人库,且每次写入都需要审批。全部 23 个本地工具的完整契约见[工具参考](docs/tools.md)。
111
129
 
112
130
  ## 说明文档
113
131
 
@@ -116,8 +134,9 @@ Agent → zotero_export(refs: [...], format: "bibtex")
116
134
  | 文档 | 内容 |
117
135
  | ----------------------------------- | -------------------------------------------- |
118
136
  | [快速入门](docs/getting-started.md) | 安装、连接验证与第一个任务 |
119
- | [产品模型](docs/product-model.md) | 两个入口、三个概念、三个组件与四条边界 |
137
+ | [产品模型](docs/product-model.md) | 两个入口、两大视图、组件分工与系统边界 |
120
138
  | [功能概览](docs/features.md) | 对话能力、文献轨迹、文献面板、写入与学术检索 |
139
+ | [研究 SOP 技能](docs/skills.md) | 七个按需研究流程、批处理预算与证据边界 |
121
140
  | [故障排查](docs/troubleshooting.md) | 常见问题、诊断步骤与处理方法 |
122
141
 
123
142
  ### 维护
@@ -129,8 +148,6 @@ Agent → zotero_export(refs: [...], format: "bibtex")
129
148
  | [配置参考](docs/configuration.md) | 各设置命名空间的字段、默认值与热更新机制 |
130
149
  | [开发指南](docs/development.md) | 构建、测试、调试与发布流程 |
131
150
 
132
- 验收场景([docs/scenarios.md](docs/scenarios.md))供维护者使用。
133
-
134
151
  ## 许可证
135
152
 
136
- [MIT](./LICENSE)
153
+ 本项目遵循 [MIT 许可证](./LICENSE)。
@@ -0,0 +1,18 @@
1
+ /** Structured citation-key facts shared by search, detail, and export views. */
2
+ export type CitationKeySource = 'native' | 'extra';
3
+ export interface CitationKeyConflict {
4
+ readonly native: string;
5
+ readonly extra: string;
6
+ }
7
+ export interface CitationKeyInfo {
8
+ readonly citationKey?: string;
9
+ readonly citationKeySource?: CitationKeySource;
10
+ readonly citationKeyConflict?: CitationKeyConflict;
11
+ }
12
+ /** Parse the citekey convention used by Better BibTeX and legacy exports. */
13
+ export declare function citekeyOf(extra?: string): string | undefined;
14
+ /** Resolve Zotero's native field first, while retaining an explicit conflict. */
15
+ export declare function citationKeyInfoOf(data: Record<string, unknown> | undefined): CitationKeyInfo;
16
+ /** Format a citation-key conflict as `native=<native>; extra=<extra>`. */
17
+ export declare function formatCitationKeyConflict(conflict: CitationKeyConflict): string;
18
+ //# sourceMappingURL=citation-key.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"citation-key.d.ts","sourceRoot":"","sources":["../src/citation-key.ts"],"names":[],"mappings":"AAAA,gFAAgF;AAEhF,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,OAAO,CAAA;AAElD,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;CACvB;AAED,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAA;IAC7B,QAAQ,CAAC,iBAAiB,CAAC,EAAE,iBAAiB,CAAA;IAC9C,QAAQ,CAAC,mBAAmB,CAAC,EAAE,mBAAmB,CAAA;CACnD;AAED,6EAA6E;AAC7E,wBAAgB,SAAS,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAI5D;AAQD,iFAAiF;AACjF,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,GAAG,eAAe,CAa5F;AAED,0EAA0E;AAC1E,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,mBAAmB,GAAG,MAAM,CAE/E"}
@@ -0,0 +1,34 @@
1
+ /** Structured citation-key facts shared by search, detail, and export views. */
2
+ /** Parse the citekey convention used by Better BibTeX and legacy exports. */
3
+ export function citekeyOf(extra) {
4
+ if (typeof extra !== 'string' || extra === '')
5
+ return undefined;
6
+ const value = /(?<![A-Za-z0-9_])(?:Citation Key|citekey):\s*([^\r\n\s,]+)/i.exec(extra)?.[1];
7
+ return value !== undefined && value !== '' ? value : undefined;
8
+ }
9
+ function clean(value) {
10
+ if (typeof value !== 'string')
11
+ return undefined;
12
+ const trimmed = value.trim();
13
+ return trimmed === '' ? undefined : trimmed;
14
+ }
15
+ /** Resolve Zotero's native field first, while retaining an explicit conflict. */
16
+ export function citationKeyInfoOf(data) {
17
+ const native = clean(data?.citationKey);
18
+ const extra = citekeyOf(clean(data?.extra));
19
+ if (native !== undefined) {
20
+ return {
21
+ citationKey: native,
22
+ citationKeySource: 'native',
23
+ ...(extra !== undefined && extra !== native
24
+ ? { citationKeyConflict: { native, extra } }
25
+ : {}),
26
+ };
27
+ }
28
+ return extra === undefined ? {} : { citationKey: extra, citationKeySource: 'extra' };
29
+ }
30
+ /** Format a citation-key conflict as `native=<native>; extra=<extra>`. */
31
+ export function formatCitationKeyConflict(conflict) {
32
+ return `native=${conflict.native}; extra=${conflict.extra}`;
33
+ }
34
+ //# sourceMappingURL=citation-key.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"citation-key.js","sourceRoot":"","sources":["../src/citation-key.ts"],"names":[],"mappings":"AAAA,gFAAgF;AAehF,6EAA6E;AAC7E,MAAM,UAAU,SAAS,CAAC,KAAc;IACtC,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,EAAE;QAAE,OAAO,SAAS,CAAA;IAC/D,MAAM,KAAK,GAAG,6DAA6D,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC,CAAA;IAC5F,OAAO,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAA;AAChE,CAAC;AAED,SAAS,KAAK,CAAC,KAAc;IAC3B,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,SAAS,CAAA;IAC/C,MAAM,OAAO,GAAG,KAAK,CAAC,IAAI,EAAE,CAAA;IAC5B,OAAO,OAAO,KAAK,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,OAAO,CAAA;AAC7C,CAAC;AAED,iFAAiF;AACjF,MAAM,UAAU,iBAAiB,CAAC,IAAyC;IACzE,MAAM,MAAM,GAAG,KAAK,CAAC,IAAI,EAAE,WAAW,CAAC,CAAA;IACvC,MAAM,KAAK,GAAG,SAAS,CAAC,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,CAAA;IAC3C,IAAI,MAAM,KAAK,SAAS,EAAE,CAAC;QACzB,OAAO;YACL,WAAW,EAAE,MAAM;YACnB,iBAAiB,EAAE,QAAQ;YAC3B,GAAG,CAAC,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,MAAM;gBACzC,CAAC,CAAC,EAAE,mBAAmB,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE;gBAC5C,CAAC,CAAC,EAAE,CAAC;SACR,CAAA;IACH,CAAC;IACD,OAAO,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,KAAK,EAAE,iBAAiB,EAAE,OAAO,EAAE,CAAA;AACtF,CAAC;AAED,0EAA0E;AAC1E,MAAM,UAAU,yBAAyB,CAAC,QAA6B;IACrE,OAAO,UAAU,QAAQ,CAAC,MAAM,WAAW,QAAQ,CAAC,KAAK,EAAE,CAAA;AAC7D,CAAC"}