@x1a0f3n9/dsh-file-reference 0.1.5-rc.5 → 0.1.7-rc.3

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.i18n.yaml CHANGED
@@ -1,6 +1,55 @@
1
- # Bilingual-pair consistency record (docs/i18n/README.md): the git blob hash of each
2
- # side as of the last confirmed-consistent state. Both languages carry equal authority;
3
- # after editing either side, bring the other along and re-record with:
1
+ # Bilingual-pair consistency record for README.md (docs/i18n/README.md): per heading
2
+ # section, a hash of its English and Chinese blocks outside code blocks and generated regions.
3
+ # After editing either side, bring the other along and re-record with:
4
4
  # pnpm run verify-translation-pairing --write packages/context/file-reference/README.md
5
- README.md: ce84a91e96988fb662ee665707d1ce2ad1651327
6
- README.zh.md: ffdce668dd1b4a5a39a076d6abc998ec6db2ce92
5
+ /:
6
+ en: 21c486a1839068f4
7
+ zh: 0333ad7c4f984794
8
+ /x1a0f3n9-dsh-file-reference:
9
+ en: ef08ad1a032bcfb9
10
+ zh: bd224e79fe749bc0
11
+ /x1a0f3n9-dsh-file-reference/summary:
12
+ en: 3b541adf3b8e5536
13
+ zh: 2b280a5f97a63cb2
14
+ /x1a0f3n9-dsh-file-reference/table-of-contents:
15
+ en: d152484eb41ac6b4
16
+ zh: 09388d293f9be9cb
17
+ /x1a0f3n9-dsh-file-reference/use-this-package:
18
+ en: e37b5d4bf0020063
19
+ zh: 2eb37494ea43228f
20
+ /x1a0f3n9-dsh-file-reference/use-this-package/mention-grammar:
21
+ en: efbe0e9233f402a4
22
+ zh: e3ec7c6ae2335a41
23
+ /x1a0f3n9-dsh-file-reference/use-this-package/getting-candidates:
24
+ en: 4dc2d6289f532225
25
+ zh: af06ce75299f23e5
26
+ /x1a0f3n9-dsh-file-reference/use-this-package/pairing-with-a-provider:
27
+ en: e2000d7e7cf3fb44
28
+ zh: d9a7386e26fda52d
29
+ /x1a0f3n9-dsh-file-reference/understand-the-implementation:
30
+ en: 92049fb7a6c345c3
31
+ zh: 86efc4d17127f97f
32
+ /x1a0f3n9-dsh-file-reference/understand-the-implementation/design-concept:
33
+ en: 191332951f81b136
34
+ zh: 8336659a9ffa20f1
35
+ /x1a0f3n9-dsh-file-reference/understand-the-implementation/source-map:
36
+ en: c4abf9f6f86cf29f
37
+ zh: 60d15ef1acd20b93
38
+ /x1a0f3n9-dsh-file-reference/understand-the-implementation/main-flow:
39
+ en: fd65f309c940de96
40
+ zh: c1517e592d646d6c
41
+ /x1a0f3n9-dsh-file-reference/further-exploration:
42
+ en: 90447bd5ebd2c47f
43
+ zh: dae6d0005ab9779d
44
+ /x1a0f3n9-dsh-file-reference/model-experience:
45
+ en: ab69d93c10a1572c
46
+ zh: b63720b1e6182805
47
+ /x1a0f3n9-dsh-file-reference/model-experience/kv-cache-effect:
48
+ en: 0aba47b2a2828b78
49
+ zh: 83a1af441dac3074
50
+ /x1a0f3n9-dsh-file-reference/known-limitations-and-deferred-work:
51
+ en: cc83a00bd7d4ccc9
52
+ zh: 130ba16bb567db5a
53
+ /x1a0f3n9-dsh-file-reference/known-limitations-and-deferred-work/dev-note:
54
+ en: e67f633dc6fe7773
55
+ zh: 3bb0c20c93f16f98
package/README.md CHANGED
@@ -29,7 +29,7 @@ Choose this package when a host-backed UI (web or terminal) should offer `@file`
29
29
 
30
30
  ### Mention grammar
31
31
 
32
- An `@path` token at the start of input or after whitespace triggers completion; an `@` inside another token, such as an email address, does not. `@"path with spaces"` opens a quoted mention, and a directory candidate keeps that quote open after its trailing slash so completion can descend another level. The formatter rejects paths with control characters or embedded quotes that the grammar cannot represent safely.
32
+ An `@path` token at the start of input or after whitespace triggers completion; an `@` inside another token, such as an email address, does not. `@"path with spaces"` opens a quoted mention, and a directory candidate keeps that quote open after its trailing slash so completion can descend another level. Completed directory chips close the quote after the trailing slash. Relative mentions resolve from the workspace root; absolute mentions retain the host path. The formatter rejects paths with control characters or embedded quotes that the grammar cannot represent safely.
33
33
 
34
34
  ### Getting candidates
35
35
 
package/README.zh.md CHANGED
@@ -29,7 +29,7 @@ kind: "package-reference"
29
29
 
30
30
  ### mention 语法
31
31
 
32
- 输入开头或空白后的 `@path` token 会触发补全;其他 token 内部的 `@`(如电子邮件地址)不会。`@"path with spaces"` 打开带引号的 mention,目录候选在其尾斜杠后保持引号打开,使补全可以继续深入下一层。格式化器会拒绝含有语法无法安全表示的控制字符或内嵌引号的路径。
32
+ 输入开头或空白后的 `@path` token 会触发补全;其他 token 内部的 `@`(如电子邮件地址)不会。`@"path with spaces"` 打开带引号的 mention,目录候选在其尾斜杠后保持引号打开,使补全可以继续深入下一层。格式化器会拒绝含有语法无法安全表示的控制字符或内嵌引号的路径。 已完成的目录 chip 在末尾斜杠之后闭合引号。相对引用从工作区根目录解析,绝对引用保留主机路径。
33
33
 
34
34
  ### 获取候选
35
35
 
package/lib/index.js CHANGED
@@ -51,7 +51,7 @@ function formatFileMention(candidate, preserveQuote) {
51
51
  * @module @x1a0f3n9/dsh-file-reference
52
52
  */
53
53
  /** Model guidance for path-only references selected by a user interface. */
54
- const FILE_REFERENCE_PROMPT = "Tokens prefixed with @ are workspace paths the user explicitly referenced, relative to the workspace root. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @\"...\" quotes a path containing spaces.";
54
+ const FILE_REFERENCE_PROMPT = "Tokens prefixed with @ are paths the user explicitly referenced. Relative paths resolve from the workspace root; absolute paths identify files or directories on the host. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @\"...\" quotes a path containing spaces.";
55
55
  /** Host capability for cancellable file-reference discovery. */
56
56
  var FileReferenceService = class extends Service {
57
57
  constructor(ctx) {
@@ -10,7 +10,7 @@ export { activeAtToken, formatFileMention } from './grammar.ts';
10
10
  export type { ActiveAtToken } from './grammar.ts';
11
11
  export type { FileReferenceCandidate } from './types.ts';
12
12
  /** Model guidance for path-only references selected by a user interface. */
13
- export declare const FILE_REFERENCE_PROMPT = "Tokens prefixed with @ are workspace paths the user explicitly referenced, relative to the workspace root. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @\"...\" quotes a path containing spaces.";
13
+ export declare const FILE_REFERENCE_PROMPT = "Tokens prefixed with @ are paths the user explicitly referenced. Relative paths resolve from the workspace root; absolute paths identify files or directories on the host. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @\"...\" quotes a path containing spaces.";
14
14
  declare module '@deepseek-ai/cordis' {
15
15
  interface Context {
16
16
  fileReferences: FileReferenceService;
@@ -6,7 +6,7 @@
6
6
  import { Service } from '@deepseek-ai/cordis';
7
7
  export { activeAtToken, formatFileMention } from "./grammar.js";
8
8
  /** Model guidance for path-only references selected by a user interface. */
9
- export const FILE_REFERENCE_PROMPT = 'Tokens prefixed with @ are workspace paths the user explicitly referenced, relative to the workspace root. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @"..." quotes a path containing spaces.';
9
+ export const FILE_REFERENCE_PROMPT = 'Tokens prefixed with @ are paths the user explicitly referenced. Relative paths resolve from the workspace root; absolute paths identify files or directories on the host. A trailing slash marks a directory: list it when its contents matter. Anything else is a file: use the read tool when its contents are needed, and do not claim to have inspected it before reading. @"..." quotes a path containing spaces.';
10
10
  /** Host capability for cancellable file-reference discovery. */
11
11
  export class FileReferenceService extends Service {
12
12
  constructor(ctx) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@x1a0f3n9/dsh-file-reference",
3
3
  "description": "File-reference discovery contract and shared @file grammar",
4
- "version": "0.1.5-rc.5",
4
+ "version": "0.1.7-rc.3",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -36,11 +36,11 @@
36
36
  ],
37
37
  "license": "MIT",
38
38
  "peerDependencies": {
39
- "@x1a0f3n9/dsh-agent": "^0.1.5-rc.5",
40
- "@deepseek-ai/cordis": "^4.0.2"
39
+ "@x1a0f3n9/dsh-agent": "0.1.7-rc.3",
40
+ "@deepseek-ai/cordis": "~4.0.4"
41
41
  },
42
42
  "devDependencies": {
43
- "@x1a0f3n9/dsh-agent": "^0.1.5-rc.5",
44
- "@deepseek-ai/cordis": "^4.0.2"
43
+ "@x1a0f3n9/dsh-agent": "0.1.7-rc.3",
44
+ "@deepseek-ai/cordis": "~4.0.4"
45
45
  }
46
46
  }