harnessed 3.3.0 → 3.4.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/dist/index.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  // package.json
2
2
  var package_default = {
3
- version: "3.3.0"};
3
+ version: "3.4.0"};
4
4
 
5
5
  // src/index.ts
6
6
  var VERSION = package_default.version;
@@ -1 +1 @@
1
- {"version":3,"sources":["../package.json","../src/index.ts"],"names":[],"mappings":";AAAA,IAAA,eAAA,GAAA;AAAA,EAEE,OAAA,EAAW,OA8Fb,CAAA;;;AC3FO,IAAM,UAAU,eAAA,CAAI","file":"index.mjs","sourcesContent":["{\n \"name\": \"harnessed\",\n \"version\": \"3.3.0\",\n \"description\": \"AI coding harness package manager + composition orchestrator\",\n \"type\": \"module\",\n \"license\": \"Apache-2.0\",\n \"author\": \"easyinplay\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/easyinplay/harnessed.git\"\n },\n \"homepage\": \"https://github.com/easyinplay/harnessed#readme\",\n \"bugs\": \"https://github.com/easyinplay/harnessed/issues\",\n \"keywords\": [\n \"claude-code\",\n \"ai-harness\",\n \"package-manager\",\n \"composition\",\n \"skill-pack\",\n \"mcp\",\n \"orchestrator\"\n ],\n \"engines\": {\n \"node\": \">=22.0.0\"\n },\n \"packageManager\": \"pnpm@10.12.0\",\n \"bin\": {\n \"harnessed\": \"./dist/cli.mjs\"\n },\n \"main\": \"./dist/index.mjs\",\n \"types\": \"./dist/index.d.ts\",\n \"exports\": {\n \".\": {\n \"types\": \"./dist/index.d.ts\",\n \"import\": \"./dist/index.mjs\",\n \"default\": \"./dist/index.mjs\"\n },\n \"./schemas\": {\n \"types\": \"./dist/schemas/index.d.ts\",\n \"import\": \"./dist/schemas/index.mjs\"\n },\n \"./package.json\": \"./package.json\"\n },\n \"files\": [\n \"dist\",\n \"manifests\",\n \"workflows\",\n \"routing\",\n \"config-templates\",\n \"schemas\",\n \"README.md\",\n \"LICENSE\",\n \"NOTICE\"\n ],\n \"scripts\": {\n \"dev\": \"tsup --watch\",\n \"build\": \"tsc --noEmit && tsup\",\n \"build:schema\": \"node ./scripts/build-schema.mjs\",\n \"validate:schema\": \"node ./scripts/validate-schema.mjs\",\n \"typecheck\": \"tsc --noEmit\",\n \"test\": \"vitest run --passWithNoTests\",\n \"test:watch\": \"vitest\",\n \"test:coverage\": \"vitest run --coverage --passWithNoTests\",\n \"bench\": \"vitest bench --run\",\n \"lint\": \"biome check .\",\n \"lint:fix\": \"biome check --write .\",\n \"format\": \"biome format --write .\"\n },\n \"dependencies\": {\n \"@anthropic-ai/claude-agent-sdk\": \"0.3.142\",\n \"@clack/prompts\": \"^0.10.1\",\n \"@sinclair/typebox\": \"^0.34.49\",\n \"ajv\": \"^8.20.0\",\n \"ajv-errors\": \"^3.0.0\",\n \"ajv-formats\": \"^3.0.1\",\n \"commander\": \"^13.0.0\",\n \"diff\": \"^9.0.0\",\n \"expr-eval\": \"^2.0.2\",\n \"picocolors\": \"^1.1.1\",\n \"proper-lockfile\": \"^4.1.2\",\n \"yaml\": \"^2.9.0\"\n },\n \"devDependencies\": {\n \"@biomejs/biome\": \"^2.0.0\",\n \"@types/node\": \"^22.10.0\",\n \"@types/proper-lockfile\": \"^4.1.4\",\n \"@vitest/coverage-v8\": \"^4.0.0\",\n \"tsup\": \"^8.3.0\",\n \"typescript\": \"^5.6.0\",\n \"vitest\": \"^4.0.0\"\n },\n \"pnpm\": {\n \"onlyBuiltDependencies\": [\n \"esbuild\"\n ]\n }\n}\n","// Main library entry — re-exports public APIs.\n// phase 1.1 batch 1: skeleton only; schema validator wired in batch 2 (T3+).\n\nimport pkg from '../package.json' with { type: 'json' }\n\nexport const VERSION = pkg.version\n"]}
1
+ {"version":3,"sources":["../package.json","../src/index.ts"],"names":[],"mappings":";AAAA,IAAA,eAAA,GAAA;AAAA,EAEE,OAAA,EAAW,OA8Fb,CAAA;;;AC3FO,IAAM,UAAU,eAAA,CAAI","file":"index.mjs","sourcesContent":["{\n \"name\": \"harnessed\",\n \"version\": \"3.4.0\",\n \"description\": \"AI coding harness package manager + composition orchestrator\",\n \"type\": \"module\",\n \"license\": \"Apache-2.0\",\n \"author\": \"easyinplay\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/easyinplay/harnessed.git\"\n },\n \"homepage\": \"https://github.com/easyinplay/harnessed#readme\",\n \"bugs\": \"https://github.com/easyinplay/harnessed/issues\",\n \"keywords\": [\n \"claude-code\",\n \"ai-harness\",\n \"package-manager\",\n \"composition\",\n \"skill-pack\",\n \"mcp\",\n \"orchestrator\"\n ],\n \"engines\": {\n \"node\": \">=22.0.0\"\n },\n \"packageManager\": \"pnpm@10.12.0\",\n \"bin\": {\n \"harnessed\": \"./dist/cli.mjs\"\n },\n \"main\": \"./dist/index.mjs\",\n \"types\": \"./dist/index.d.ts\",\n \"exports\": {\n \".\": {\n \"types\": \"./dist/index.d.ts\",\n \"import\": \"./dist/index.mjs\",\n \"default\": \"./dist/index.mjs\"\n },\n \"./schemas\": {\n \"types\": \"./dist/schemas/index.d.ts\",\n \"import\": \"./dist/schemas/index.mjs\"\n },\n \"./package.json\": \"./package.json\"\n },\n \"files\": [\n \"dist\",\n \"manifests\",\n \"workflows\",\n \"routing\",\n \"config-templates\",\n \"schemas\",\n \"README.md\",\n \"LICENSE\",\n \"NOTICE\"\n ],\n \"scripts\": {\n \"dev\": \"tsup --watch\",\n \"build\": \"tsc --noEmit && tsup\",\n \"build:schema\": \"node ./scripts/build-schema.mjs\",\n \"validate:schema\": \"node ./scripts/validate-schema.mjs\",\n \"typecheck\": \"tsc --noEmit\",\n \"test\": \"vitest run --passWithNoTests\",\n \"test:watch\": \"vitest\",\n \"test:coverage\": \"vitest run --coverage --passWithNoTests\",\n \"bench\": \"vitest bench --run\",\n \"lint\": \"biome check .\",\n \"lint:fix\": \"biome check --write .\",\n \"format\": \"biome format --write .\"\n },\n \"dependencies\": {\n \"@anthropic-ai/claude-agent-sdk\": \"0.3.142\",\n \"@clack/prompts\": \"^0.10.1\",\n \"@sinclair/typebox\": \"^0.34.49\",\n \"ajv\": \"^8.20.0\",\n \"ajv-errors\": \"^3.0.0\",\n \"ajv-formats\": \"^3.0.1\",\n \"commander\": \"^13.0.0\",\n \"diff\": \"^9.0.0\",\n \"expr-eval\": \"^2.0.2\",\n \"picocolors\": \"^1.1.1\",\n \"proper-lockfile\": \"^4.1.2\",\n \"yaml\": \"^2.9.0\"\n },\n \"devDependencies\": {\n \"@biomejs/biome\": \"^2.0.0\",\n \"@types/node\": \"^22.10.0\",\n \"@types/proper-lockfile\": \"^4.1.4\",\n \"@vitest/coverage-v8\": \"^4.0.0\",\n \"tsup\": \"^8.3.0\",\n \"typescript\": \"^5.6.0\",\n \"vitest\": \"^4.0.0\"\n },\n \"pnpm\": {\n \"onlyBuiltDependencies\": [\n \"esbuild\"\n ]\n }\n}\n","// Main library entry — re-exports public APIs.\n// phase 1.1 batch 1: skeleton only; schema validator wired in batch 2 (T3+).\n\nimport pkg from '../package.json' with { type: 'json' }\n\nexport const VERSION = pkg.version\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "harnessed",
3
- "version": "3.3.0",
3
+ "version": "3.4.0",
4
4
  "description": "AI coding harness package manager + composition orchestrator",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
@@ -1,7 +1,7 @@
1
1
  # workflows/disciplines/language.yaml
2
- # 语言与输出规范 — 机器化 ~/.claude/CLAUDE.md 「语言与输出规范」 节
3
- # Phase v3.0-3.3 W0.4 ship per D-09
4
- # Snapshot of CLAUDE.md as of v3.0 ship date (K7 mitigation, verbatim)
2
+ # 语言与输出规范 — universal "follow user conversation language" (v3.4.0 update)
3
+ # Phase v3.0-3.3 W0.4 origin (zh-Hans default); v3.4.0 W1.1 semantic shift to
4
+ # language-agnostic + env.HARNESSED_USER_LANG config consumption (D-04 Part D).
5
5
 
6
6
  schema_version: harnessed.discipline.v1
7
7
  discipline: language
@@ -9,20 +9,26 @@ enforcement_layer: output
9
9
  auto_enforce: true
10
10
 
11
11
  rules:
12
- - id: default-language-zh-hans
13
- description: 默认输出语言简体中文 (zh-Hans);所有解释/分析/计划/总结/提问/状态更新一律中文
14
- enforcement: warn
15
- trigger: user.lang_request == null
16
- check_method: heuristic
17
- # heuristic response 中文 char 占比 > 60% (排除 code block);占比 < 30% → warn
12
+ - id: follow-user-language
13
+ description: |-
14
+ Response language follows env.HARNESSED_USER_LANG (set by `harnessed setup`
15
+ Step D — detected from OS locale or user override). If env not set,
16
+ fallback to the user's current conversation language (Claude Code
17
+ naturally mirrors user input; this discipline codifies the universal
18
+ intent). Output artifacts (findings.md / task_plan.md /
19
+ RETROSPECTIVE.md etc.) honor the same setting so workflow outputs
20
+ stay consistent with CLI tone.
21
+ enforcement: info
22
+ trigger: every Claude response
23
+ check_method: read ~/.claude/settings.json env.HARNESSED_USER_LANG, validate output lang matches
18
24
 
19
25
  - id: preserve-english-categories
20
- description: 8 类强制保留英文原文,不翻译不音译
26
+ description: 8 类强制保留英文原文,不翻译不音译 (语言无关 — 任何 user_lang 都适用)
21
27
  enforcement: warn
22
28
  trigger: always-on
23
29
  check_method: heuristic
24
- # 8 类 (verbatim CLAUDE.md):
25
- # 1. 代码/命令/shell/配置/正则/SQL
30
+ # 8 类 (verbatim CLAUDE.md, language-agnostic):
31
+ # 1. 代码/命令/shell/配置/正则/SQL / code / cmd / shell / config / regex / SQL
26
32
  # 2. 文件/目录/路径名 (src/components/Button.tsx 等)
27
33
  # 3. 工具/框架/库/产品/公司名 (Claude Code / GSD / React 等)
28
34
  # 4. API/函数/类/变量/字段/环境变量/配置键
@@ -31,8 +37,22 @@ rules:
31
37
  # 7. 业内固定缩写与通用术语 (TDD / CRUD / API / MCP / token 等)
32
38
  # 8. 引用原文 verbatim
33
39
 
40
+ - id: cross-cultural-humor
41
+ description: |-
42
+ Cultural adaptation of idioms / wordplay. When translating humorous
43
+ content across language boundaries, prefer culturally-resonant
44
+ analogues over literal translation. Example sister README pattern:
45
+ 中文借「鹦鹉学舌」成语 + 英文借 "parrot on shoulders / pirate trope"
46
+ — same concept, different cultural anchor. Avoid forced calques.
47
+ enforcement: info
48
+ trigger: humor_or_idiom_present
49
+ check_method: heuristic
50
+
34
51
  - id: lang-request-override
35
- description: 用户明确"用英文回答"/"reply in English"/"翻译成 X" → 整段切换目标语言
52
+ description: |-
53
+ User explicit override — "用英文回答" / "reply in English" / "翻译成 X"
54
+ / `--lang en|zh` CLI flag → switch the entire response to the
55
+ target language regardless of env.HARNESSED_USER_LANG.
36
56
  enforcement: info
37
57
  trigger: user.lang_request != null
38
58
  check_method: regex