dsh-plugin-prompt-tool 2.0.1 → 3.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.
- package/README.md +100 -233
- package/engine/actions/append-context.mjs +3 -24
- package/engine/actions/assembly.mjs +70 -94
- package/engine/actions/catalog.mjs +65 -28
- package/engine/actions/content.mjs +8 -152
- package/engine/actions/examples.mjs +8 -4
- package/engine/actions/inbox-prepend.mjs +5 -7
- package/engine/actions/index.mjs +17 -9
- package/engine/actions/inject-text.mjs +24 -4
- package/engine/actions/pre-step-filter.mjs +3 -4
- package/engine/actions/registration.mjs +20 -28
- package/engine/actions/request-params.mjs +21 -1
- package/engine/actions/shared.mjs +23 -15
- package/engine/actions/stream-output.mjs +26 -0
- package/engine/actions/tool-gate.mjs +31 -0
- package/engine/actions/tool-result.mjs +36 -0
- package/engine/actions/tool-visibility.mjs +248 -0
- package/engine/agent-capability.mjs +67 -0
- package/engine/anchor-match.mjs +14 -21
- package/engine/audience.d.mts +2 -0
- package/engine/audience.mjs +102 -0
- package/engine/branch.d.mts +4 -0
- package/engine/branch.mjs +62 -19
- package/engine/compaction-epoch.d.mts +25 -0
- package/engine/compaction-epoch.mjs +27 -4
- package/engine/compositions/source/local/filesystem-editor.yml +3 -3
- package/engine/compositions/source/local/instruction-hint.yml +4 -7
- package/engine/compositions/source/local/module-file-tools.yml +2 -0
- package/engine/compositions/source/local/module-import-tools.yml +4 -0
- package/engine/compositions/source/local/module-manifest-tools.yml +2 -0
- package/engine/compositions/source/local/module-rule-tools.yml +5 -0
- package/engine/compositions/source/local/module-variable-tools.yml +5 -0
- package/engine/compositions/source/local/present-as.yml +26 -0
- package/engine/compositions/source/local/tool-config-engine.yml +2 -3
- package/engine/compositions/source/local/tool-search.yml +11 -0
- package/engine/condition-facts.mjs +84 -0
- package/engine/conditions/anchor.mjs +63 -23
- package/engine/conditions/availability.mjs +1 -1
- package/engine/conditions/composite.mjs +4 -4
- package/engine/conditions/count.mjs +43 -13
- package/engine/conditions/evaluation.mjs +74 -19
- package/engine/conditions/examples.mjs +2 -1
- package/engine/conditions/index.d.mts +15 -0
- package/engine/conditions/index.mjs +23 -9
- package/engine/conditions/operators.mjs +4 -0
- package/engine/conditions/phase.mjs +10 -5
- package/engine/conditions/preset.mjs +1 -1
- package/engine/conditions/session.mjs +8 -2
- package/engine/conditions/subject.mjs +144 -65
- package/engine/conditions/text.mjs +26 -8
- package/engine/conditions/variable.mjs +83 -0
- package/engine/context-activation.d.mts +11 -0
- package/engine/{st-world-book.mjs → context-activation.mjs} +104 -64
- package/engine/delivery.d.mts +2 -0
- package/engine/delivery.mjs +93 -0
- package/engine/discovery.d.mts +38 -0
- package/engine/discovery.mjs +146 -0
- package/engine/env-safety.mjs +14 -0
- package/engine/executor.d.mts +28 -0
- package/engine/executor.mjs +290 -205
- package/engine/fillers.mjs +39 -8
- package/engine/fixed-registration.mjs +12 -0
- package/engine/history.mjs +71 -0
- package/engine/instruction-blocks.d.mts +13 -0
- package/engine/instruction-blocks.mjs +21 -0
- package/engine/instruction-files.d.mts +5 -0
- package/engine/instruction-files.mjs +97 -0
- package/engine/instruction-hint.mjs +69 -103
- package/engine/interpolate.d.mts +7 -0
- package/engine/interpolate.mjs +44 -13
- package/engine/layers.mjs +165 -230
- package/engine/machine-paths.mjs +40 -0
- package/engine/module-file-tools.mjs +8 -0
- package/engine/module-import-tools.mjs +10 -0
- package/engine/module-manifest-tools.mjs +8 -0
- package/engine/module-rule-tools.mjs +10 -0
- package/engine/module-variable-tools.mjs +10 -0
- package/engine/order.d.mts +14 -0
- package/engine/order.mjs +0 -3
- package/engine/path-safety.d.mts +2 -0
- package/engine/path-safety.mjs +58 -0
- package/engine/pre-step-source.d.mts +69 -0
- package/engine/pre-step-source.mjs +103 -0
- package/engine/present-as.mjs +77 -0
- package/engine/promotion-pool.d.mts +9 -0
- package/engine/promotion-pool.mjs +69 -0
- package/engine/record.mjs +2 -0
- package/engine/rule-engine.mjs +3 -2
- package/engine/rule-facts.d.mts +11 -0
- package/engine/rule-facts.mjs +60 -0
- package/engine/rule-runtime.d.mts +46 -0
- package/engine/rule-runtime.mjs +98 -13
- package/engine/rule-spec.d.mts +106 -0
- package/engine/rule-spec.mjs +302 -28
- package/engine/run-code-env.mjs +73 -19
- package/engine/schema.mjs +165 -243
- package/engine/sdk-strip.mjs +2 -2
- package/engine/service-names.d.mts +10 -0
- package/engine/service-names.mjs +10 -0
- package/engine/shared.d.mts +21 -0
- package/engine/shared.mjs +47 -26
- package/engine/skill-search.mjs +125 -53
- package/engine/source-kind.d.mts +9 -0
- package/engine/source-kind.mjs +16 -0
- package/engine/strategy-ids.mjs +5 -0
- package/engine/template-evaluation.d.mts +16 -0
- package/engine/template-evaluation.mjs +178 -0
- package/engine/template-frame.d.mts +16 -0
- package/engine/template-frame.mjs +69 -0
- package/engine/tool-config-engine.mjs +39 -35
- package/engine/tool-definition.d.mts +4 -0
- package/engine/tool-definition.mjs +5 -1
- package/engine/tool-git-bash.mjs +5 -1
- package/engine/tool-scope.mjs +22 -0
- package/engine/{dev-tool-search.mjs → tool-search.mjs} +63 -65
- package/engine/trigger.mjs +15 -270
- package/engine/vendor/yaml/dist/compose/resolve-flow-scalar.js +19 -18
- package/engine/vendor/yaml/dist/nodes/Alias.js +25 -23
- package/engine/vendor/yaml/package.json +1 -1
- package/lib/client.js +8312 -6724
- package/lib/client.js.map +1 -1
- package/lib/index.d.mts +37 -762
- package/lib/index.mjs +26919 -5791
- package/modules/ponytail/module.yml +83 -203
- package/modules/ptc-mode/module.yml +45 -0
- package/modules/soul/assets/core-hard.md +6 -0
- package/modules/soul/assets/criteria.md +12 -0
- package/modules/soul/assets/echo.md +12 -0
- package/modules/soul/assets/layers.md +11 -0
- package/modules/soul/assets/ledger.md +9 -0
- package/modules/soul/assets/manifest.yml +20 -0
- package/modules/soul/assets/reference/00-layers.md +27 -0
- package/modules/soul/assets/reference/01-criteria.md +32 -0
- package/modules/soul/assets/reference/02-echo.md +158 -0
- package/modules/soul/assets/reference/03-vital.md +183 -0
- package/modules/soul/assets/reference/04-manifest.json +106 -0
- package/modules/soul/assets/reference/05-doctor.md +67 -0
- package/modules/soul/assets/reference/06-reference.md +189 -0
- package/modules/soul/assets/reference/07-bundle.json +431 -0
- package/modules/soul/assets/reference/08-/350/270/251/345/235/221/345/256/236/345/275/225.md +59 -0
- package/modules/soul/assets/reference/09-dev-workflow.md +109 -0
- package/modules/soul/assets/reference/10-echo-anatomy.md +100 -0
- package/modules/soul/assets/reference/11-self.md +80 -0
- package/modules/soul/assets/reference/12-ledger.md +159 -0
- package/modules/soul/assets/reference/README.md +10 -0
- package/modules/soul/assets/templates/agents-template.md +6 -0
- package/modules/soul/assets/vital.md +9 -0
- package/modules/soul/module.yml +311 -0
- package/modules/superpowers/module.yml +122 -0
- package/modules/tool-surface/module.yml +51 -47
- package/package.json +40 -41
- package/skills/dsh-module/SKILL.md +119 -0
- package/skills/dsh-module/reference.md +185 -0
- package/templates/10-pre-step.yml +2 -3
- package/templates/14-first-turn-anchor.yml +10 -14
- package/templates/15-guide-auto.yml +32 -28
- package/templates/16-custom-fallback.yml +33 -21
- package/templates/20-system-section.yml +1 -4
- package/templates/50-llm-stream.yml +4 -10
- package/templates/60-tool-pipeline.yml +12 -10
- package/templates/63-append-context.yml +20 -0
- package/templates/64-pre-step-filter.yml +23 -0
- package/templates/65-turn-stop.yml +2 -2
- package/templates/67-inbox-prepend.yml +22 -0
- package/templates/70-subagent-maintenance.yml +9 -10
- package/templates/75-subagent-end.yml +2 -2
- package/templates/80-tool-surface.yml +41 -57
- package/templates/tools/40-delegate-module-import.yml +22 -0
- package/templates/tools/50-delegate-module-rules.yml +14 -0
- package/templates/tools/60-delegate-module-variables.yml +17 -0
- package/templates/tools/70-delegate-module-rules-edit.yml +31 -0
- package/engine/actions/decision.mjs +0 -54
- package/engine/actions/guard.mjs +0 -80
- package/engine/actions/sdk-strip.mjs +0 -30
- package/engine/character-tools.mjs +0 -8
- package/engine/classify-task.mjs +0 -53
- package/engine/compositions/library/agent-instructions.yml +0 -9
- package/engine/compositions/library/command-goal.yml +0 -7
- package/engine/compositions/library/compaction.yml +0 -22
- package/engine/compositions/library/delegation-ptc.yml +0 -58
- package/engine/compositions/library/delegation.yml +0 -56
- package/engine/compositions/library/persistent-shell.yml +0 -50
- package/engine/compositions/library/planning.yml +0 -26
- package/engine/compositions/library/skill-filesystem-cordis.yml +0 -10
- package/engine/compositions/library/skill-filesystem.yml +0 -7
- package/engine/compositions/library/tool-ask-user.yml +0 -7
- package/engine/compositions/library/tool-bash.yml +0 -8
- package/engine/compositions/library/tool-cordis.yml +0 -7
- package/engine/compositions/library/tool-fs-search.yml +0 -9
- package/engine/compositions/library/tool-fs.yml +0 -7
- package/engine/compositions/library/tool-goal.yml +0 -7
- package/engine/compositions/library/tool-jobs.yml +0 -7
- package/engine/compositions/library/tool-plugin-manager-disabled.yml +0 -8
- package/engine/compositions/library/tool-plugin-manager.yml +0 -8
- package/engine/compositions/library/tool-present.yml +0 -7
- package/engine/compositions/library/tool-presentation.yml +0 -9
- package/engine/compositions/library/tool-pwsh.yml +0 -8
- package/engine/compositions/library/tool-skill.yml +0 -7
- package/engine/compositions/library/tool-todo.yml +0 -9
- package/engine/compositions/library/tool-web.yml +0 -10
- package/engine/compositions/source/local/character-tools.yml +0 -5
- package/engine/compositions/source/local/declared-triggers.yml +0 -12
- package/engine/compositions/source/local/dev-tool-search.yml +0 -11
- package/engine/compositions/source/local/session-var-tools.yml +0 -5
- package/engine/compositions/source/local/subagent-tool-policy.yml +0 -21
- package/engine/compositions/source/local/world-book-tools.yml +0 -5
- package/engine/condition.mjs +0 -96
- package/engine/declared-triggers.mjs +0 -93
- package/engine/session-var-tools.mjs +0 -8
- package/engine/session-vars.mjs +0 -54
- package/engine/st-macros.d.mts +0 -22
- package/engine/st-macros.mjs +0 -208
- package/engine/st-render.mjs +0 -109
- package/engine/st-world-book.d.mts +0 -10
- package/engine/subagent-tool-policy-core.mjs +0 -400
- package/engine/subagent-tool-policy.mjs +0 -352
- package/engine/trigger-spec.mjs +0 -173
- package/engine/world-book-tools.mjs +0 -8
- package/lib/migrate-rules.d.mts +0 -1
- package/lib/migrate-rules.mjs +0 -39
- package/lib/module-package-CHPFweqK.mjs +0 -2
- package/lib/module-package-Cnd1_mwx.mjs +0 -2872
- package/lib/paths-CyP0IkaM.d.mts +0 -1390
- package/lib/preset-transfer.d.mts +0 -2
- package/lib/preset-transfer.mjs +0 -3
- package/lib/rules-migration-DJ6vASB5.mjs +0 -15334
- package/templates/policies/legacy-defaults.yml +0 -34
- package/templates/tools/40-delegate-character.yml +0 -15
- package/templates/tools/50-delegate-worldbook.yml +0 -15
- package/templates/tools/60-delegate-session-var.yml +0 -15
- package/templates/tools/70-delegate-worldbook-upsert.yml +0 -36
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
#旧业务默认的精确数据快照,仅供模板生成和显式离线迁移读取。引擎运行时不得读取此文件。
|
|
2
|
-
|
|
3
|
-
version: 1
|
|
4
|
-
fillers:
|
|
5
|
-
envFacts:
|
|
6
|
-
text: |-
|
|
7
|
-
Environment facts:
|
|
8
|
-
{{ENV_FACTS}}
|
|
9
|
-
skillCatalog:
|
|
10
|
-
text: |-
|
|
11
|
-
Available skills ({{SKILL_COUNT}}):
|
|
12
|
-
{{SKILLS_TEXT}}
|
|
13
|
-
params:
|
|
14
|
-
limit: 20
|
|
15
|
-
fields: name,description
|
|
16
|
-
whenToUseLabel: 适用:
|
|
17
|
-
unnamedLabel: (unnamed)
|
|
18
|
-
instructionHint:
|
|
19
|
-
projectTemplate: "Reference documents exist: {{FILES}} (project root: {{ROOT}})."
|
|
20
|
-
globalTemplate: "A user reference document exists: {{FILES}}."
|
|
21
|
-
suffixTemplate: They are reference documents about the user's environment and
|
|
22
|
-
workspace conventions, not task instructions. Reading the relevant file
|
|
23
|
-
before workspace tasks is recommended, but consult them only when you need
|
|
24
|
-
those details; the task itself never depends on them.
|
|
25
|
-
messageTemplate: |-
|
|
26
|
-
<system-reminder>
|
|
27
|
-
Reference documents exist: {{FILES}}. {{SUFFIX}}
|
|
28
|
-
</system-reminder>
|
|
29
|
-
promotionGate:
|
|
30
|
-
reasoningPattern: \bwe\b
|
|
31
|
-
reasoningNegativePattern: \blet me\b
|
|
32
|
-
reasoningFlags: gi
|
|
33
|
-
customFallback:
|
|
34
|
-
fallbackAfter: 1
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# 自定义工具模板:委托内置 character_list(自定义名称/描述/参数面;
|
|
2
|
-
# 保存该模板时自动装配 character-tools,原工具仍可用)。
|
|
3
|
-
id: delegate-character-list
|
|
4
|
-
name: my_character_list
|
|
5
|
-
description: 查看角色卡库(委托内置工具)
|
|
6
|
-
output:
|
|
7
|
-
schema:
|
|
8
|
-
type: object
|
|
9
|
-
additionalProperties: true
|
|
10
|
-
properties:
|
|
11
|
-
ok: { type: boolean }
|
|
12
|
-
value: { type: json }
|
|
13
|
-
execute:
|
|
14
|
-
kind: delegate
|
|
15
|
-
tool: character_list
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# 自定义工具模板:委托内置 world_book_list(自定义名称/描述/参数面;
|
|
2
|
-
# 保存该模板时自动装配 world-book-tools,原工具仍可用)。
|
|
3
|
-
id: delegate-worldbook-list
|
|
4
|
-
name: my_worldbook_list
|
|
5
|
-
description: 查看当前模块的世界书条目(委托内置工具)
|
|
6
|
-
output:
|
|
7
|
-
schema:
|
|
8
|
-
type: object
|
|
9
|
-
additionalProperties: true
|
|
10
|
-
properties:
|
|
11
|
-
ok: { type: boolean }
|
|
12
|
-
value: { type: json }
|
|
13
|
-
execute:
|
|
14
|
-
kind: delegate
|
|
15
|
-
tool: world_book_list
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# 自定义工具模板:委托内置 session_var(自定义名称/描述/参数面;
|
|
2
|
-
# 保存该模板时自动装配 session-var-tools,原工具仍可用)。
|
|
3
|
-
id: delegate-session-var
|
|
4
|
-
name: my_session_var
|
|
5
|
-
description: 会话变量管理(委托内置工具)
|
|
6
|
-
output:
|
|
7
|
-
schema:
|
|
8
|
-
type: object
|
|
9
|
-
additionalProperties: true
|
|
10
|
-
properties:
|
|
11
|
-
ok: { type: boolean }
|
|
12
|
-
value: { type: json }
|
|
13
|
-
execute:
|
|
14
|
-
kind: delegate
|
|
15
|
-
tool: session_var
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
# 自定义工具模板:委托内置 world_book_upsert(有参包装示例)。
|
|
2
|
-
# 模型只见本模板声明的参数(name/content/keys),其余字段走 execute.args 固定映射:
|
|
3
|
-
# constant/order/layer/position 由模板锁定——参数面 = 官方工具定义的 parameters 定制。
|
|
4
|
-
# 保存该模板时自动装配 world-book-tools,原工具仍可用(delegate 仅自定义名称/描述/参数面)。
|
|
5
|
-
id: delegate-worldbook-upsert
|
|
6
|
-
name: my_worldbook_upsert
|
|
7
|
-
description: 新增/更新一条世界书条目(委托内置工具,常驻注入)
|
|
8
|
-
parameters:
|
|
9
|
-
name:
|
|
10
|
-
type: string
|
|
11
|
-
required: true
|
|
12
|
-
description: 条目名称/注释
|
|
13
|
-
content:
|
|
14
|
-
type: string
|
|
15
|
-
required: true
|
|
16
|
-
description: 条目内容(命中后注入)
|
|
17
|
-
keys:
|
|
18
|
-
type: array
|
|
19
|
-
items: { type: string }
|
|
20
|
-
description: 触发关键字
|
|
21
|
-
output:
|
|
22
|
-
schema:
|
|
23
|
-
type: object
|
|
24
|
-
additionalProperties: true
|
|
25
|
-
properties:
|
|
26
|
-
ok: { type: boolean }
|
|
27
|
-
value: { type: json }
|
|
28
|
-
execute:
|
|
29
|
-
kind: delegate
|
|
30
|
-
tool: world_book_upsert
|
|
31
|
-
args:
|
|
32
|
-
name: '{{args.name}}'
|
|
33
|
-
content: '{{args.content}}'
|
|
34
|
-
keys: '{{args.keys}}'
|
|
35
|
-
constant: true
|
|
36
|
-
order: 100
|