{"_id":"@deepseek-ai/dsh-file-reference","_rev":"6074268-6a85d19d818495c13713093e","dist-tags":{"latest":"0.1.0-rc.8","next":"0.1.1-rc.2"},"name":"@deepseek-ai/dsh-file-reference","time":{"created":"2026-08-19T15:54:05.266Z","modified":"2026-08-21T12:31:53.781Z","0.1.0-rc.8":"2026-08-19T15:29:39.497Z","0.1.1-rc.1":"2026-08-21T06:38:32.149Z","0.1.1-rc.2":"2026-08-21T12:31:37.624Z"},"versions":{"0.1.0-rc.8":{"name":"@deepseek-ai/dsh-file-reference","description":"File-reference discovery contract and shared @file grammar","version":"0.1.0-rc.8","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/deepseek-ai/deepseek-harness.git","directory":"packages/context/file-reference"},"type":"module","main":"lib/index.js","types":"lib/types/index.d.ts","exports":{".":{"types":"./lib/types/index.d.ts","default":"./lib/index.js"},"./grammar":{"types":"./lib/types/grammar.d.ts","default":"./lib/types/grammar.js"},"./invariant":{"types":"./lib/types/invariant.d.ts","default":"./lib/invariant.js"},"./types":{"types":"./lib/types/types.d.ts","default":"./lib/types/types.js"},"./typert":{"types":"./lib/typert.host.d.ts","default":"./lib/typert.host.js"},"./remote":{"types":"./lib/typert.remote-client.d.ts","default":"./lib/typert.remote-client.js"},"./src/*":"./src/*","./package.json":"./package.json"},"license":"MIT","peerDependencies":{"@deepseek-ai/dsh-agent":"^0.1.0-rc.8","@deepseek-ai/dsh-invariants":"^0.1.0-rc.8","@deepseek-ai/dsh-typert-protocol":"^0.1.0-rc.8","@deepseek-ai/cordis":"^4.0.1"},"devDependencies":{"@deepseek-ai/dsh-invariants":"^0.1.0-rc.8","@deepseek-ai/dsh-typert-protocol":"^0.1.0-rc.8","@deepseek-ai/cordis":"^4.0.1","@deepseek-ai/dsh-agent":"^0.1.0-rc.8"},"dependencies":{"zod":"^4.4.3"},"_id":"@deepseek-ai/dsh-file-reference@0.1.0-rc.8","bugs":{"url":"https://github.com/deepseek-ai/deepseek-harness/issues"},"homepage":"https://github.com/deepseek-ai/deepseek-harness#readme","_integrity":"sha512-SoU4Zm7L8E9ud5nTs1tVAINFrgKvIKypCdOOMLBjJkjLUvXMYmKFxfCM7xaJjOmK/C5suEVUtpukZhZZvZALNA==","_resolved":"/home/runner/work/deepseek-harness/deepseek-harness/dist/npm/deepseek-ai-dsh-file-reference-0.1.0-rc.8.tgz","_from":"file:/home/runner/work/deepseek-harness/deepseek-harness/dist/npm/deepseek-ai-dsh-file-reference-0.1.0-rc.8.tgz","_nodeVersion":"24.19.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-SoU4Zm7L8E9ud5nTs1tVAINFrgKvIKypCdOOMLBjJkjLUvXMYmKFxfCM7xaJjOmK/C5suEVUtpukZhZZvZALNA==","shasum":"8de3e1c8ebb0362846f3a9c31eceb913623ab668","tarball":"https://registry.npmmirror.com/@deepseek-ai/dsh-file-reference/-/dsh-file-reference-0.1.0-rc.8.tgz","fileCount":19,"unpackedSize":56141,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIBXA++UPjxA8DiyfxPo8OH6mi5UBYxfhuidBkeObNiiLAiEA71mVmWZbZRBdgFIwrr+upObgeSD5NvSW0UmVo7zy1EA="}],"size":14211},"_npmUser":{"name":"imccyu","email":"imccyu@gmail.com"},"directories":{},"maintainers":[{"name":"imccyu","email":"imccyu@gmail.com"},{"name":"tianyicui-deepseek","email":"tianyi@deepseek.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/dsh-file-reference_0.1.0-rc.8_1787153379349_0.9679174928049916"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-08-19T15:29:39.497Z","publish_time":1787153379497,"_source_registry_name":"default"},"0.1.1-rc.1":{"name":"@deepseek-ai/dsh-file-reference","description":"File-reference discovery contract and shared @file grammar","version":"0.1.1-rc.1","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/deepseek-ai/deepseek-harness.git","directory":"packages/context/file-reference"},"type":"module","main":"lib/index.js","types":"lib/types/index.d.ts","exports":{".":{"types":"./lib/types/index.d.ts","default":"./lib/index.js"},"./grammar":{"types":"./lib/types/grammar.d.ts","default":"./lib/types/grammar.js"},"./invariant":{"types":"./lib/types/invariant.d.ts","default":"./lib/invariant.js"},"./types":{"types":"./lib/types/types.d.ts","default":"./lib/types/types.js"},"./typert":{"types":"./lib/typert.host.d.ts","default":"./lib/typert.host.js"},"./remote":{"types":"./lib/typert.remote-client.d.ts","default":"./lib/typert.remote-client.js"},"./src/*":"./src/*","./package.json":"./package.json"},"license":"MIT","peerDependencies":{"@deepseek-ai/dsh-agent":"^0.1.1-rc.1","@deepseek-ai/dsh-invariants":"^0.1.1-rc.1","@deepseek-ai/dsh-typert-protocol":"^0.1.1-rc.1","@deepseek-ai/cordis":"^4.0.1"},"devDependencies":{"@deepseek-ai/dsh-invariants":"^0.1.1-rc.1","@deepseek-ai/dsh-typert-protocol":"^0.1.1-rc.1","@deepseek-ai/dsh-agent":"^0.1.1-rc.1","@deepseek-ai/cordis":"^4.0.1"},"dependencies":{"zod":"^4.4.3"},"readmeFilename":"README.zh.md","_id":"@deepseek-ai/dsh-file-reference@0.1.1-rc.1","bugs":{"url":"https://github.com/deepseek-ai/deepseek-harness/issues"},"homepage":"https://github.com/deepseek-ai/deepseek-harness#readme","_integrity":"sha512-TitE4FzwV4JPWmXpI6Rinn+oVt+0c6DtjJCXdapafNHaYKUnYqFE4Bydvn2hDzLKnkwEgEKEugSZLRno6P91bg==","_resolved":"/home/runner/work/deepseek-harness/deepseek-harness/dist/npm/deepseek-ai-dsh-file-reference-0.1.1-rc.1.tgz","_from":"file:/home/runner/work/deepseek-harness/deepseek-harness/dist/npm/deepseek-ai-dsh-file-reference-0.1.1-rc.1.tgz","_nodeVersion":"24.19.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-TitE4FzwV4JPWmXpI6Rinn+oVt+0c6DtjJCXdapafNHaYKUnYqFE4Bydvn2hDzLKnkwEgEKEugSZLRno6P91bg==","shasum":"e9697bebec8a99c0d4eda147c8c1ee87bbe33f00","tarball":"https://registry.npmmirror.com/@deepseek-ai/dsh-file-reference/-/dsh-file-reference-0.1.1-rc.1.tgz","fileCount":19,"unpackedSize":56141,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDFFouPjQVJ24sL8sIa2rgW7c/plmgua72HX1limy3HTgIgBPofUpZh5PaFpXHNFskqDiB3klf8zqyliCsptyaW6/8="}],"size":14209},"_npmUser":{"name":"imccyu","email":"imccyu@gmail.com"},"directories":{},"maintainers":[{"name":"imccyu","email":"imccyu@gmail.com"},{"name":"tianyicui-deepseek","email":"tianyi@deepseek.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/dsh-file-reference_0.1.1-rc.1_1787294311982_0.21558253756285306"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-08-21T06:38:32.149Z","publish_time":1787294312149,"_source_registry_name":"default"},"0.1.1-rc.2":{"name":"@deepseek-ai/dsh-file-reference","description":"File-reference discovery contract and shared @file grammar","version":"0.1.1-rc.2","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/deepseek-ai/deepseek-harness.git","directory":"packages/context/file-reference"},"type":"module","main":"lib/index.js","types":"lib/types/index.d.ts","exports":{".":{"types":"./lib/types/index.d.ts","default":"./lib/index.js"},"./grammar":{"types":"./lib/types/grammar.d.ts","default":"./lib/types/grammar.js"},"./invariant":{"types":"./lib/types/invariant.d.ts","default":"./lib/invariant.js"},"./types":{"types":"./lib/types/types.d.ts","default":"./lib/types/types.js"},"./typert":{"types":"./lib/typert.host.d.ts","default":"./lib/typert.host.js"},"./remote":{"types":"./lib/typert.remote-client.d.ts","default":"./lib/typert.remote-client.js"},"./src/*":"./src/*","./package.json":"./package.json"},"license":"MIT","peerDependencies":{"@deepseek-ai/dsh-agent":"^0.1.1-rc.2","@deepseek-ai/dsh-invariants":"^0.1.1-rc.2","@deepseek-ai/dsh-typert-protocol":"^0.1.1-rc.2","@deepseek-ai/cordis":"^4.0.1"},"devDependencies":{"@deepseek-ai/dsh-agent":"^0.1.1-rc.2","@deepseek-ai/dsh-invariants":"^0.1.1-rc.2","@deepseek-ai/dsh-typert-protocol":"^0.1.1-rc.2","@deepseek-ai/cordis":"^4.0.1"},"dependencies":{"zod":"^4.4.3"},"readmeFilename":"README.zh.md","_id":"@deepseek-ai/dsh-file-reference@0.1.1-rc.2","bugs":{"url":"https://github.com/deepseek-ai/deepseek-harness/issues"},"homepage":"https://github.com/deepseek-ai/deepseek-harness#readme","_integrity":"sha512-8Pd4SNHhV6OlbwfV5K4qmFb709I0Z68qgaUQJ7zM4BTjClNe1/dktQnETtWPfqbPTx/2sNKXM1rz4WXuROrIfQ==","_resolved":"/home/runner/work/deepseek-harness/deepseek-harness/dist/npm/deepseek-ai-dsh-file-reference-0.1.1-rc.2.tgz","_from":"file:/home/runner/work/deepseek-harness/deepseek-harness/dist/npm/deepseek-ai-dsh-file-reference-0.1.1-rc.2.tgz","_nodeVersion":"24.19.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-8Pd4SNHhV6OlbwfV5K4qmFb709I0Z68qgaUQJ7zM4BTjClNe1/dktQnETtWPfqbPTx/2sNKXM1rz4WXuROrIfQ==","shasum":"473a4b5b7d8db411796a0869aa60534097884873","tarball":"https://registry.npmmirror.com/@deepseek-ai/dsh-file-reference/-/dsh-file-reference-0.1.1-rc.2.tgz","fileCount":19,"unpackedSize":56203,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIDtp0m+rpY2PlbsF4JH7B0FLoKlUtVTzhXHUMVGnpqqlAiAJ3HMj21ItfoQg4pIEqhO0x4DN8O52vwOKjWkgWp1cdw=="}],"size":14221},"_npmUser":{"name":"imccyu","email":"imccyu@gmail.com"},"directories":{},"maintainers":[{"name":"imccyu","email":"imccyu@gmail.com"},{"name":"tianyicui-deepseek","email":"tianyi@deepseek.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/dsh-file-reference_0.1.1-rc.2_1787315497488_0.13359268100123112"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-08-21T12:31:37.624Z","publish_time":1787315497624,"_source_registry_name":"default"}},"bugs":{"url":"https://github.com/deepseek-ai/deepseek-harness/issues"},"description":"File-reference discovery contract and shared @file grammar","homepage":"https://github.com/deepseek-ai/deepseek-harness#readme","license":"MIT","maintainers":[{"name":"tianyicui-deepseek","email":"tianyi@deepseek.com"},{"name":"imccyu","email":"imccyu@gmail.com"}],"readme":"# `@deepseek-ai/dsh-file-reference`\n\nEnglish | [中文](README.zh.md)\n\nFile-reference discovery seam and browser-safe `@file` grammar shared by host-backed user interfaces. `ctx.fileReferences.list(agent, query, signal)` returns path-only file or directory candidates for the addressed agent; concrete providers own namespace access, ranking, caching, and invalidation. The same contract is remotely callable as the unary `fileReferences/list` Remote method (`@Remote` on the Service Definition, cancelled through the reserved trailing signal), so browser consumers call `ctx.remote.fileReferences.list` without an API Proxy route.\n\n`activeAtToken()` recognizes an `@path` or open `@\"path with spaces` token only at the start of input or after whitespace, so email-like text does not open completion. `formatFileMention()` emits the matching prompt spelling, appends `/` to directory candidates, preserves an explicitly opened quote, and rejects control characters or embedded quotes that the editor grammar cannot represent safely.\n\nSelecting a candidate does not read or attach file contents. The exported `FILE_REFERENCE_PROMPT` is stable guidance that a provider may install when the addressed agent can call `read`.\n\n## Model Experience\n\nIndirectly, through `@deepseek-ai/dsh-file-reference-local`, which conditionally contributes this package's stable file-reference guidance.\n\n#### KV Cache effect\n\nThe interface and grammar add no request tokens themselves; a provider-owned prompt section determines cache behavior.\n\n## Known Limitations and Deferred Work\n\n- **Path candidates are advisory** — the seam does not prove that a later model-facing filesystem tool can access the same namespace; deployments must align the provider with the effective `read` implementation.\n- **No file-content reference object** — selected files remain ordinary prompt text and require an explicit model tool call before their contents become model-visible.\n","repository":{"type":"git","url":"git+https://github.com/deepseek-ai/deepseek-harness.git","directory":"packages/context/file-reference"},"_source_registry_name":"default"}