@luffysolution/omnischolar-pi 0.1.6 → 0.1.8

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 CHANGED
@@ -60,7 +60,7 @@ In the ChatGPT desktop app, restart the app, open **Plugins**, select the **Omni
60
60
  The plugin bundles all eight Skills and starts its local MCP server with the pinned PyPI release:
61
61
 
62
62
  ```sh
63
- uvx --from luffysolution-omnischolar==0.1.6 omnischolar mcp
63
+ uvx --from luffysolution-omnischolar==0.1.8 omnischolar mcp
64
64
  ```
65
65
 
66
66
  No separate `pip install` is required for this plugin path. The first MCP start needs network access so `uvx` can download and cache the package. Provider credentials and optional service settings remain in your OmniScholar configuration; plugin installation does not collect them.
@@ -136,6 +136,8 @@ Create a labelled illustration of this mechanism. Treat it as a draft, not exper
136
136
 
137
137
  On the first MCP start or installer run, if no discoverable config exists, OmniScholar creates a complete user-level `omnischolar.config.json` template with all service sections and credential fields. You can also create it explicitly with `omnischolar config init`. API keys may be entered directly as `apiKey`; `apiKeyEnv` is an optional alternative when you prefer environment variables.
138
138
 
139
+ Customize the Obsidian output location and new-paper naming with `output.rootDirectory`, `output.literatureDirectory`, `output.filenameTemplate`, and `output.filenameSeparator`; see [literature and output configuration](docs/RESEARCH.en.md).
140
+
139
141
  A small local configuration can start with Zotero and the output directory:
140
142
 
141
143
  ```json
package/README.zh-CN.md CHANGED
@@ -58,7 +58,7 @@ codex plugin add omnischolar@omnischolar
58
58
  插件会同时安装 8 个 Skills,并使用固定的 PyPI 版本启动本地 MCP:
59
59
 
60
60
  ```sh
61
- uvx --from luffysolution-omnischolar==0.1.6 omnischolar mcp
61
+ uvx --from luffysolution-omnischolar==0.1.8 omnischolar mcp
62
62
  ```
63
63
 
64
64
  采用插件安装方式时无需另外执行 `pip install`。第一次启动 MCP 需要联网,以便 `uvx` 下载并缓存包。各服务的凭据与可选配置仍保存在 OmniScholar 配置中,插件安装不会收集这些信息。
@@ -134,6 +134,8 @@ omnischolar mcp
134
134
 
135
135
  首次启动 MCP 或执行安装命令时,如果没有可发现的配置,程序会在用户配置目录自动创建包含所有服务区块和认证字段的完整 `omnischolar.config.json` 模板。也可以用 `omnischolar config init` 主动创建。API key 可以直接填写在配置文件的 `apiKey` 中;如果希望使用环境变量,也可以填写 `apiKeyEnv`。
136
136
 
137
+ 文献导入到 Obsidian 的位置和新文件命名可通过 `output.rootDirectory`、`output.literatureDirectory`、`output.filenameTemplate` 和 `output.filenameSeparator` 自定义,详见[文献与输出配置](docs/RESEARCH.md)。
138
+
137
139
  最小的本地配置可以只写 Zotero 和输出目录:
138
140
 
139
141
  ```json
@@ -39,6 +39,21 @@ If none of the first four sources exists, the first MCP start or installer run c
39
39
 
40
40
  `workspaceRoots` limits local file reads. `output.rootDirectory` limits file writes. To use Obsidian, set the output directory to a folder inside the vault.
41
41
 
42
+ The new-paper subfolder and file name can be customized as well:
43
+
44
+ ```json
45
+ {
46
+ "output": {
47
+ "rootDirectory": "F:/Personal Knowledge Base",
48
+ "literatureDirectory": "Literature/Parsed",
49
+ "filenameTemplate": "{year}{separator}{author}{separator}{title}",
50
+ "filenameSeparator": "+"
51
+ }
52
+ }
53
+ ```
54
+
55
+ The filename template supports `{author}`, `{year}`, `{title}`, and `{separator}`; the separator currently accepts `-` or `+`. These settings affect new publications only; existing sync records keep the path stored in the manifest.
56
+
42
57
  ## API keys
43
58
 
44
59
  API keys may be entered directly in the provider's `apiKey` field:
@@ -39,6 +39,21 @@ OmniScholar 使用 `schemaVersion: 1` 的 JSON 配置。可直接复制根目录
39
39
 
40
40
  `workspaceRoots` 限定可读取的本地文件,`output.rootDirectory` 限定写入位置。若要直接写入 Obsidian,可把输出目录设为 Vault 中的一个文件夹。
41
41
 
42
+ 新文献的子文件夹和文件名可以继续细分:
43
+
44
+ ```json
45
+ {
46
+ "output": {
47
+ "rootDirectory": "F:/个人知识库",
48
+ "literatureDirectory": "文献/已解析",
49
+ "filenameTemplate": "{year}{separator}{author}{separator}{title}",
50
+ "filenameSeparator": "+"
51
+ }
52
+ }
53
+ ```
54
+
55
+ 文件名模板支持 `{author}`、`{year}`、`{title}`、`{separator}`;连接符目前支持 `-` 和 `+`。这些设置只影响新建文献,已有同步记录沿用 manifest 中的路径。
56
+
42
57
  ## API key
43
58
 
44
59
  API key 可以直接写入对应服务的 `apiKey`。例如:
@@ -44,7 +44,7 @@ Restart the ChatGPT desktop app after adding the marketplace. Open **Plugins**,
44
44
  The installed plugin contains `plugin.json`, `skills/`, and `mcp.json`. Its MCP entry executes:
45
45
 
46
46
  ```sh
47
- uvx --from luffysolution-omnischolar==0.1.5 omnischolar mcp
47
+ uvx --from luffysolution-omnischolar==0.1.8 omnischolar mcp
48
48
  ```
49
49
 
50
50
  `uvx` creates an isolated environment and caches the exact release, so this route does not require a separate `pip install`. The first start requires package-index access. To fetch updates to the Git marketplace, run:
@@ -83,7 +83,7 @@ Choose `--scope project` to share the enabled plugin through repository settings
83
83
  Claude Code copies the repository-root plugin into its versioned cache, discovers the eight folders under `skills/`, and starts `.mcp.json` automatically when the plugin is enabled. The MCP command is pinned to:
84
84
 
85
85
  ```sh
86
- uvx --from luffysolution-omnischolar==0.1.5 omnischolar mcp
86
+ uvx --from luffysolution-omnischolar==0.1.8 omnischolar mcp
87
87
  ```
88
88
 
89
89
  The first MCP start needs package-index access. Skills are namespaced with `omnischolar`, for example `/omnischolar:scholar-search` and `/omnischolar:zotero-research`.
@@ -44,7 +44,7 @@ codex plugin add omnischolar@omnischolar
44
44
  安装后的插件包含 `plugin.json`、`skills/` 和 `mcp.json`。其 MCP 配置执行:
45
45
 
46
46
  ```sh
47
- uvx --from luffysolution-omnischolar==0.1.5 omnischolar mcp
47
+ uvx --from luffysolution-omnischolar==0.1.8 omnischolar mcp
48
48
  ```
49
49
 
50
50
  `uvx` 会创建隔离环境并缓存该精确版本,因此无需另行运行 `pip install`。第一次启动需要能够访问 Python 包索引。若要更新 Git Marketplace:
@@ -83,7 +83,7 @@ claude plugin install omnischolar@omnischolar --scope user
83
83
  Claude Code 会把仓库根插件复制到版本化缓存,发现 `skills/` 下的 8 个 Skills,并在插件启用时自动启动 `.mcp.json`。MCP 命令固定为:
84
84
 
85
85
  ```sh
86
- uvx --from luffysolution-omnischolar==0.1.5 omnischolar mcp
86
+ uvx --from luffysolution-omnischolar==0.1.8 omnischolar mcp
87
87
  ```
88
88
 
89
89
  第一次启动 MCP 需要能够访问 Python 包索引。Skills 使用 `omnischolar` 命名空间,例如 `/omnischolar:scholar-search` 和 `/omnischolar:zotero-research`。
@@ -74,6 +74,21 @@ A correctly formatted reference does not prove the claim. Ai4Scholar's Google Sc
74
74
 
75
75
  ## Markdown and Obsidian output
76
76
 
77
+ The output location and new-file naming can be customized in the global configuration:
78
+
79
+ ```json
80
+ {
81
+ "output": {
82
+ "rootDirectory": "F:/Personal Knowledge Base",
83
+ "literatureDirectory": "Literature/Parsed",
84
+ "filenameTemplate": "{year}{separator}{author}{separator}{title}",
85
+ "filenameSeparator": "+"
86
+ }
87
+ }
88
+ ```
89
+
90
+ Supported filename variables are `{author}`, `{year}`, `{title}`, and `{separator}`; `filenameSeparator` currently accepts `-` or `+`. New papers are written under `rootDirectory/literatureDirectory`, with images under each paper directory's `assets/` folder. Existing manifest records keep their original paths so changing the configuration does not break incremental synchronization.
91
+
77
92
  `omnischolar_sync` shows a plan before writing under `output.rootDirectory`. The directory can be a regular folder or part of an Obsidian vault.
78
93
 
79
94
  Sync distinguishes new content, no change, metadata changes, parse changes, render changes, missing files, conflicts, exclusions, and interrupted recovery. Metadata repair, rerendering, and transaction recovery do not upload a PDF.
package/docs/RESEARCH.md CHANGED
@@ -74,6 +74,21 @@ OmniScholar 不会自动把 Zotero 附件上传到 MinerU。应先确认具体
74
74
 
75
75
  ## 保存到 Markdown 或 Obsidian
76
76
 
77
+ 输出位置和新文件命名可以在全局配置中自定义:
78
+
79
+ ```json
80
+ {
81
+ "output": {
82
+ "rootDirectory": "F:/个人知识库",
83
+ "literatureDirectory": "文献/已解析",
84
+ "filenameTemplate": "{year}{separator}{author}{separator}{title}",
85
+ "filenameSeparator": "+"
86
+ }
87
+ }
88
+ ```
89
+
90
+ 支持的文件名变量为 `{author}`、`{year}`、`{title}` 和 `{separator}`;`filenameSeparator` 当前支持 `-` 或 `+`。新文献会写入 `rootDirectory/literatureDirectory`,图片放在每篇文献目录下的 `assets/`。已有 manifest 记录会沿用原路径,避免改配置后破坏增量同步。
91
+
77
92
  `omnischolar_sync` 会先给出计划,再写入 `output.rootDirectory`。该目录可以是普通文件夹,也可以位于 Obsidian Vault 中。
78
93
 
79
94
  同步会区分新建、无需更新、元数据变化、解析变化、渲染变化、文件缺失、冲突、排除和中断恢复。仅修复元数据、渲染或中断事务时不会上传 PDF。
@@ -232,6 +232,9 @@
232
232
  },
233
233
  "output": {
234
234
  "rootDirectory": "omnischolar-output",
235
+ "literatureDirectory": "Literatures",
236
+ "filenameTemplate": "{author}{separator}{year}{separator}{title}",
237
+ "filenameSeparator": "-",
235
238
  "conflictDirectory": ".conflicts",
236
239
  "safeWrites": true
237
240
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@luffysolution/omnischolar-pi",
3
- "version": "0.1.6",
3
+ "version": "0.1.8",
4
4
  "description": "Pi MCP bridge for the OmniScholar research toolkit",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -1,7 +1,7 @@
1
1
  import { Client } from "@modelcontextprotocol/sdk/client/index.js";
2
2
  import { StdioClientTransport } from "@modelcontextprotocol/sdk/client/stdio.js";
3
3
  import { Type } from "typebox";
4
- const CLIENT_INFO = { name: "omnischolar-pi", version: "0.1.6" };
4
+ const CLIENT_INFO = { name: "omnischolar-pi", version: "0.1.8" };
5
5
  export function resultText(result) {
6
6
  return result.content
7
7
  .map((item) => {
@@ -39,7 +39,7 @@ export default function omnischolarExtension(pi) {
39
39
  connection = (async () => {
40
40
  transport = new StdioClientTransport({
41
41
  command: "uvx",
42
- args: ["--from", "luffysolution-omnischolar==0.1.6", "omnischolar", "mcp"],
42
+ args: ["--from", "luffysolution-omnischolar==0.1.8", "omnischolar", "mcp"],
43
43
  stderr: "pipe",
44
44
  });
45
45
  client = new Client(CLIENT_INFO);