@tnnevol/dsh-codex-auth 0.1.0-rc.7.2 → 0.1.0-rc.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
@@ -1,54 +1,5 @@
1
1
  # @tnnevol/dsh-codex-auth
2
2
 
3
- 一个独立的 DeepSeek Harness Codex OAuth 插件,适配 DSH `0.1.0-rc.7`。
3
+ Codex Auth 插件的功能、交互、安装和调试文档已统一迁移到文档站的 [Harness 插件](https://fnapps-doc.tnnevol.cn/plugins/) 章节。
4
4
 
5
- ## 功能
6
-
7
- - 在 DSH Web 的“插件”设置中提供 ChatGPT 登录和退出登录入口。
8
- - 通过 `@earendil-works/pi-ai` 发起 Codex device-code 授权,由插件展示一次性授权码并轮询登录结果。
9
- - 授权页面不要求选择工作空间;用户只需在 Codex 授权页面提交插件生成的一次性代码。
10
- - 复用 `dsh-codex-connect` 的凭据文件格式:`$DSH_HOME/.openai-codex-auth.json`。
11
- - 复用 `dsh-llm-pi-ai` 的官方模型设置入口,使 OpenAI Codex 在模型列表中显示登录状态,并直接展示可编辑的模型目录。
12
- - OAuth 登录成功后,将当前 access token 同步到 `OPENAI_CODEX_AUTH_TOKEN` 凭据引用;OAuth 文件仍是唯一登录源,凭据引用只是给通用 pi-ai adapter 和官方模型页使用的镜像。
13
- - Codex 编辑页隐藏通用的 API 密钥和 API 地址字段,避免用户误改 OAuth 管理的认证与端点;模型目录仍使用 DSH 官方编辑器。
14
- - 模型列表弹框增加“全选”,确认按钮文案为“确定”,并使用官方保存按钮的主色。
15
- - 在“设置 → 插件 → Codex Auth”中提供图片识别开关;开启后按 DSH 附件规范注册 `view_image`,仅允许当前图片模型读取经过文件系统权限控制的本地图片。
16
- - 图像生成开关会明确显示为当前不可用:DSH `rc.7` 的 Codex provider 只声明图片输入,不提供图像输出能力。
17
- - 通过 DSH `rc.7` 的 keyed slot `settings.plugin.item` 注册 UI,并显式提供 `key`。
18
-
19
- ## 本地构建
20
-
21
- 在仓库根目录执行:
22
-
23
- ```sh
24
- pnpm --filter @tnnevol/dsh-codex-auth install
25
- pnpm --filter @tnnevol/dsh-codex-auth run check
26
- ```
27
-
28
- ## 使用本地 DSH CLI 调试
29
-
30
- 先确保本地 DSH 源码已经安装依赖并可运行,然后在 DSH 仓库目录执行:
31
-
32
- ```sh
33
- pnpm --filter @tnnevol/dsh-codex-auth run build
34
- pnpm dsh web --patch /absolute/path/to/fn-os-apps/plugins/dsh-codex-auth-plugin/cordis.patch.yml
35
- ```
36
-
37
- `cordis.patch.yml` 使用包名加载 Host bundle;如果要调试尚未构建的源码,可将 patch 中的 `name` 改成源码入口的绝对路径,并使用 DSH skill 中的 `--patch` 调试流程。
38
-
39
- ## 发布 rc 版本
40
-
41
- 当前版本为 npm prerelease,发布时必须使用 `rc` dist-tag:
42
-
43
- ```sh
44
- npm run publish:rc
45
- ```
46
-
47
- ## 安装到 profile
48
-
49
- ```sh
50
- dsh plugin --profile web add @tnnevol/dsh-codex-auth
51
- dsh --profile web --dump-config
52
- ```
53
-
54
- 安装后重新启动 Web profile。该插件不应与旧的 `dsh-codex-connect` 同时注册同一套 Codex 模型能力;迁移时请先停用旧插件,再启用本插件。
5
+ README 仅保留插件识别信息,不再维护具体功能说明。
@@ -4,7 +4,7 @@
4
4
  "node": "^22.19.0 || >=24.0.0"
5
5
  },
6
6
  "dshPluginApi": {
7
- "version": "0.1.0-rc.7",
7
+ "version": "0.1.0-rc.8",
8
8
  "packages": [
9
9
  "@deepseek-ai/dsh-atomic-write",
10
10
  "@deepseek-ai/dsh-attachment",
package/lib/index.js CHANGED
@@ -715,6 +715,8 @@ function viewImageTool(ctx) {
715
715
  /** OpenAI Codex adapter assembled from dsh's public pi-ai extension seam. */
716
716
  /** Keep the Codex stream open while the provider is still producing output. */
717
717
  const CODEX_STREAM_IDLE_TIMEOUT_MS = 3e5;
718
+ /** Match dsh rc.8's default request-level image payload bound. */
719
+ const CODEX_MAX_REQUEST_IMAGE_BYTES = 20971520;
718
720
  /**
719
721
  * Give dsh's generic adapter the bearer token resolved by the plugin-owned
720
722
  * OAuth store. This keeps the provider-native login flow separate from model
@@ -745,6 +747,7 @@ function createCodexAdapter(credentials, resolveAttachments) {
745
747
  provider: CODEX_PROVIDER,
746
748
  displayName: "OpenAI Codex",
747
749
  streamIdleTimeoutMs: CODEX_STREAM_IDLE_TIMEOUT_MS,
750
+ maxRequestImageBytes: CODEX_MAX_REQUEST_IMAGE_BYTES,
748
751
  retryPolicy: resolveRetryPolicy(void 0, "dsh-codex-auth-plugin retryPolicy"),
749
752
  configuredMaxTokens: /* @__PURE__ */ new Map(),
750
753
  piProvider: requestProvider(provider)
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@tnnevol/dsh-codex-auth",
3
3
  "displayName": "Codex Auth",
4
4
  "description": "Standalone ChatGPT OAuth account management for DeepSeek Harness.",
5
- "version": "0.1.0-rc.7.2",
5
+ "version": "0.1.0-rc.8",
6
6
  "author": "tnnevol",
7
7
  "repository": {
8
8
  "type": "git",
@@ -74,52 +74,52 @@
74
74
  "peerDependencies": {
75
75
  "@earendil-works/pi-ai": "0.82.1",
76
76
  "@deepseek-ai/cordis": "^4.0.1-rc.1",
77
- "@deepseek-ai/dsh-attachment": "0.1.0-rc.7",
78
- "@deepseek-ai/dsh-atomic-write": "0.1.0-rc.7",
79
- "@deepseek-ai/dsh-home-paths": "0.1.0-rc.7",
80
- "@deepseek-ai/dsh-host-webserver": "0.1.0-rc.7",
81
- "@deepseek-ai/dsh-invariants": "0.1.0-rc.7",
82
- "@deepseek-ai/dsh-llm": "0.1.0-rc.7",
83
- "@deepseek-ai/dsh-llm-pi-ai": "0.1.0-rc.7",
84
- "@deepseek-ai/dsh-settings": "0.1.0-rc.7",
85
- "@deepseek-ai/dsh-tools": "0.1.0-rc.7",
86
- "@deepseek-ai/dsh-client-locale": "0.1.0-rc.7",
87
- "@deepseek-ai/dsh-client-runtime": "0.1.0-rc.7",
88
- "@deepseek-ai/dsh-client-ui-settings": "0.1.0-rc.7",
89
- "@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.0-rc.7",
90
- "@deepseek-ai/dsh-client-ui-slots": "0.1.0-rc.7",
91
- "@deepseek-ai/dsh-credentials": "0.1.0-rc.7",
92
- "@deepseek-ai/dsh-fs": "0.1.0-rc.7",
93
- "@deepseek-ai/dsh-launch-environment": "0.1.0-rc.7",
94
- "@deepseek-ai/dsh-timeout": "0.1.0-rc.7",
77
+ "@deepseek-ai/dsh-attachment": "0.1.0-rc.8",
78
+ "@deepseek-ai/dsh-atomic-write": "0.1.0-rc.8",
79
+ "@deepseek-ai/dsh-home-paths": "0.1.0-rc.8",
80
+ "@deepseek-ai/dsh-host-webserver": "0.1.0-rc.8",
81
+ "@deepseek-ai/dsh-invariants": "0.1.0-rc.8",
82
+ "@deepseek-ai/dsh-llm": "0.1.0-rc.8",
83
+ "@deepseek-ai/dsh-llm-pi-ai": "0.1.0-rc.8",
84
+ "@deepseek-ai/dsh-settings": "0.1.0-rc.8",
85
+ "@deepseek-ai/dsh-tools": "0.1.0-rc.8",
86
+ "@deepseek-ai/dsh-client-locale": "0.1.0-rc.8",
87
+ "@deepseek-ai/dsh-client-runtime": "0.1.0-rc.8",
88
+ "@deepseek-ai/dsh-client-ui-settings": "0.1.0-rc.8",
89
+ "@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.0-rc.8",
90
+ "@deepseek-ai/dsh-client-ui-slots": "0.1.0-rc.8",
91
+ "@deepseek-ai/dsh-credentials": "0.1.0-rc.8",
92
+ "@deepseek-ai/dsh-fs": "0.1.0-rc.8",
93
+ "@deepseek-ai/dsh-launch-environment": "0.1.0-rc.8",
94
+ "@deepseek-ai/dsh-timeout": "0.1.0-rc.8",
95
95
  "@deepseek-ai/schemastery": "3.18.1",
96
96
  "react": "^18.2.0"
97
97
  },
98
98
  "devDependencies": {
99
99
  "@earendil-works/pi-ai": "0.82.1",
100
100
  "@deepseek-ai/cordis": "^4.0.1",
101
- "@deepseek-ai/dsh-api-remotes": "0.1.0-rc.7",
102
- "@deepseek-ai/dsh-attachment": "0.1.0-rc.7",
103
- "@deepseek-ai/dsh-atomic-write": "0.1.0-rc.7",
104
- "@deepseek-ai/dsh-client-connection": "0.1.0-rc.7",
105
- "@deepseek-ai/dsh-client-locale": "0.1.0-rc.7",
106
- "@deepseek-ai/dsh-client-runtime": "0.1.0-rc.7",
107
- "@deepseek-ai/dsh-client-ui-conversation": "0.1.0-rc.7",
108
- "@deepseek-ai/dsh-client-ui-model-selection": "0.1.0-rc.7",
109
- "@deepseek-ai/dsh-client-ui-settings": "0.1.0-rc.7",
110
- "@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.0-rc.7",
111
- "@deepseek-ai/dsh-client-ui-slots": "0.1.0-rc.7",
112
- "@deepseek-ai/dsh-credentials": "0.1.0-rc.7",
113
- "@deepseek-ai/dsh-home-paths": "0.1.0-rc.7",
114
- "@deepseek-ai/dsh-fs": "0.1.0-rc.7",
115
- "@deepseek-ai/dsh-host-webserver": "0.1.0-rc.7",
116
- "@deepseek-ai/dsh-invariants": "0.1.0-rc.7",
117
- "@deepseek-ai/dsh-launch-environment": "0.1.0-rc.7",
118
- "@deepseek-ai/dsh-llm": "0.1.0-rc.7",
119
- "@deepseek-ai/dsh-llm-pi-ai": "0.1.0-rc.7",
120
- "@deepseek-ai/dsh-settings": "0.1.0-rc.7",
121
- "@deepseek-ai/dsh-tools": "0.1.0-rc.7",
122
- "@deepseek-ai/dsh-timeout": "0.1.0-rc.7",
101
+ "@deepseek-ai/dsh-api-remotes": "0.1.0-rc.8",
102
+ "@deepseek-ai/dsh-attachment": "0.1.0-rc.8",
103
+ "@deepseek-ai/dsh-atomic-write": "0.1.0-rc.8",
104
+ "@deepseek-ai/dsh-client-connection": "0.1.0-rc.8",
105
+ "@deepseek-ai/dsh-client-locale": "0.1.0-rc.8",
106
+ "@deepseek-ai/dsh-client-runtime": "0.1.0-rc.8",
107
+ "@deepseek-ai/dsh-client-ui-conversation": "0.1.0-rc.8",
108
+ "@deepseek-ai/dsh-client-ui-model-selection": "0.1.0-rc.8",
109
+ "@deepseek-ai/dsh-client-ui-settings": "0.1.0-rc.8",
110
+ "@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.0-rc.8",
111
+ "@deepseek-ai/dsh-client-ui-slots": "0.1.0-rc.8",
112
+ "@deepseek-ai/dsh-credentials": "0.1.0-rc.8",
113
+ "@deepseek-ai/dsh-home-paths": "0.1.0-rc.8",
114
+ "@deepseek-ai/dsh-fs": "0.1.0-rc.8",
115
+ "@deepseek-ai/dsh-host-webserver": "0.1.0-rc.8",
116
+ "@deepseek-ai/dsh-invariants": "0.1.0-rc.8",
117
+ "@deepseek-ai/dsh-launch-environment": "0.1.0-rc.8",
118
+ "@deepseek-ai/dsh-llm": "0.1.0-rc.8",
119
+ "@deepseek-ai/dsh-llm-pi-ai": "0.1.0-rc.8",
120
+ "@deepseek-ai/dsh-settings": "0.1.0-rc.8",
121
+ "@deepseek-ai/dsh-tools": "0.1.0-rc.8",
122
+ "@deepseek-ai/dsh-timeout": "0.1.0-rc.8",
123
123
  "@deepseek-ai/schemastery": "3.18.1",
124
124
  "@types/node": "^22.20.0",
125
125
  "@types/react": "~18.3.1",