@tienne/gestalt 0.124.0 → 0.125.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.
Files changed (44) hide show
  1. package/dist/package.json +1 -1
  2. package/dist/plugin/.codex-plugin/plugin.json +1 -1
  3. package/dist/plugin/role-agents/lens-context/AGENT.md +67 -15
  4. package/dist/plugin/skills/_shared/proactive-routing.md +1 -1
  5. package/dist/plugin/skills/lens/SKILL.md +56 -56
  6. package/dist/plugin/skills/video-digest/SKILL.md +182 -42
  7. package/dist/src/digest/lens-schema.d.ts +19 -5
  8. package/dist/src/digest/lens-schema.d.ts.map +1 -1
  9. package/dist/src/digest/lens-schema.js +21 -3
  10. package/dist/src/digest/lens-schema.js.map +1 -1
  11. package/dist/src/digest/lint-lens-context.d.ts +3 -2
  12. package/dist/src/digest/lint-lens-context.d.ts.map +1 -1
  13. package/dist/src/digest/lint-lens-context.js +25 -3
  14. package/dist/src/digest/lint-lens-context.js.map +1 -1
  15. package/dist/src/digest/lint.d.ts.map +1 -1
  16. package/dist/src/digest/lint.js +9 -5
  17. package/dist/src/digest/lint.js.map +1 -1
  18. package/dist/src/digest/render-lens.d.ts +8 -4
  19. package/dist/src/digest/render-lens.d.ts.map +1 -1
  20. package/dist/src/digest/render-lens.js +34 -3
  21. package/dist/src/digest/render-lens.js.map +1 -1
  22. package/dist/src/digest/render-md.d.ts.map +1 -1
  23. package/dist/src/digest/render-md.js +7 -5
  24. package/dist/src/digest/render-md.js.map +1 -1
  25. package/dist/src/digest/schema.d.ts +58 -23
  26. package/dist/src/digest/schema.d.ts.map +1 -1
  27. package/dist/src/digest/schema.js +6 -3
  28. package/dist/src/digest/schema.js.map +1 -1
  29. package/dist/src/lens/attach.d.ts +36 -14
  30. package/dist/src/lens/attach.d.ts.map +1 -1
  31. package/dist/src/lens/attach.js +6 -3
  32. package/dist/src/lens/attach.js.map +1 -1
  33. package/package.json +1 -1
  34. package/plugin/.codex-plugin/plugin.json +1 -1
  35. package/plugin/.mcp.json +1 -1
  36. package/plugin/mcp.json +1 -1
  37. package/plugin/role-agents/lens-context/AGENT.md +67 -15
  38. package/plugin/skills/_shared/proactive-routing.md +1 -1
  39. package/plugin/skills/lens/SKILL.md +56 -56
  40. package/plugin/skills/video-digest/SKILL.md +182 -42
  41. package/dist/plugin/skills/video-digest/templates/background.md +0 -15
  42. package/dist/plugin/skills/video-digest/templates/counterpoints.md +0 -15
  43. package/plugin/skills/video-digest/templates/background.md +0 -15
  44. package/plugin/skills/video-digest/templates/counterpoints.md +0 -15
@@ -1,10 +1,13 @@
1
1
  import { z } from 'zod';
2
2
  import { type MergeResult } from '../digest/merge.js';
3
- /** lens-context의 카드(cards)와 한계 줄(limits), lens-link의 연결 카드(links)를 스킬이 한 파일로 합친 것이다 */
3
+ /**
4
+ * lens-context의 카드(cards)와 한계 줄(limits), lens-link의 연결 카드(links)를 스킬이 한 파일로 합친 것이다.
5
+ * 카드 상한은 영상 기준으로 받고 읽기 렌즈의 네 장 상한은 merge의 lint가 본다
6
+ */
4
7
  export declare const contextFileSchema: z.ZodObject<{
5
8
  cards: z.ZodDefault<z.ZodArray<z.ZodObject<{
6
9
  id: z.ZodString;
7
- kind: z.ZodEnum<["lineage", "interpretation", "counter", "unverified"]>;
10
+ kind: z.ZodEnum<["lineage", "interpretation", "counter", "unverified", "background"]>;
8
11
  section: z.ZodString;
9
12
  anchor: z.ZodEffects<z.ZodObject<{
10
13
  key: z.ZodNumber;
@@ -53,12 +56,15 @@ export declare const contextFileSchema: z.ZodObject<{
53
56
  points: z.ZodArray<z.ZodObject<{
54
57
  text: z.ZodString;
55
58
  sources: z.ZodArray<z.ZodString, "many">;
59
+ verdict: z.ZodOptional<z.ZodEnum<["correct", "depends", "incorrect", "unverifiable"]>>;
56
60
  }, "strip", z.ZodTypeAny, {
57
61
  text: string;
58
62
  sources: string[];
63
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
59
64
  }, {
60
65
  text: string;
61
66
  sources: string[];
67
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
62
68
  }>, "many">;
63
69
  sources: z.ZodArray<z.ZodObject<{
64
70
  id: z.ZodString;
@@ -81,7 +87,7 @@ export declare const contextFileSchema: z.ZodObject<{
81
87
  }>, "many">;
82
88
  }, "strip", z.ZodTypeAny, {
83
89
  id: string;
84
- kind: "unverified" | "interpretation" | "lineage" | "counter";
90
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
85
91
  anchor: {
86
92
  key: number;
87
93
  from: number;
@@ -98,6 +104,7 @@ export declare const contextFileSchema: z.ZodObject<{
98
104
  points: {
99
105
  text: string;
100
106
  sources: string[];
107
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
101
108
  }[];
102
109
  section: string;
103
110
  lineage?: {
@@ -110,7 +117,7 @@ export declare const contextFileSchema: z.ZodObject<{
110
117
  }[] | undefined;
111
118
  }, {
112
119
  id: string;
113
- kind: "unverified" | "interpretation" | "lineage" | "counter";
120
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
114
121
  anchor: {
115
122
  key: number;
116
123
  from: number;
@@ -127,6 +134,7 @@ export declare const contextFileSchema: z.ZodObject<{
127
134
  points: {
128
135
  text: string;
129
136
  sources: string[];
137
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
130
138
  }[];
131
139
  section: string;
132
140
  lineage?: {
@@ -322,7 +330,7 @@ export declare const contextFileSchema: z.ZodObject<{
322
330
  }[];
323
331
  cards: {
324
332
  id: string;
325
- kind: "unverified" | "interpretation" | "lineage" | "counter";
333
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
326
334
  anchor: {
327
335
  key: number;
328
336
  from: number;
@@ -339,6 +347,7 @@ export declare const contextFileSchema: z.ZodObject<{
339
347
  points: {
340
348
  text: string;
341
349
  sources: string[];
350
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
342
351
  }[];
343
352
  section: string;
344
353
  lineage?: {
@@ -383,7 +392,7 @@ export declare const contextFileSchema: z.ZodObject<{
383
392
  }[] | undefined;
384
393
  cards?: {
385
394
  id: string;
386
- kind: "unverified" | "interpretation" | "lineage" | "counter";
395
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
387
396
  anchor: {
388
397
  key: number;
389
398
  from: number;
@@ -400,6 +409,7 @@ export declare const contextFileSchema: z.ZodObject<{
400
409
  points: {
401
410
  text: string;
402
411
  sources: string[];
412
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
403
413
  }[];
404
414
  section: string;
405
415
  lineage?: {
@@ -432,7 +442,7 @@ export type ContextFile = z.infer<typeof contextFileSchema>;
432
442
  export declare const cardsFileSchema: z.ZodObject<Pick<{
433
443
  cards: z.ZodDefault<z.ZodArray<z.ZodObject<{
434
444
  id: z.ZodString;
435
- kind: z.ZodEnum<["lineage", "interpretation", "counter", "unverified"]>;
445
+ kind: z.ZodEnum<["lineage", "interpretation", "counter", "unverified", "background"]>;
436
446
  section: z.ZodString;
437
447
  anchor: z.ZodEffects<z.ZodObject<{
438
448
  key: z.ZodNumber;
@@ -481,12 +491,15 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
481
491
  points: z.ZodArray<z.ZodObject<{
482
492
  text: z.ZodString;
483
493
  sources: z.ZodArray<z.ZodString, "many">;
494
+ verdict: z.ZodOptional<z.ZodEnum<["correct", "depends", "incorrect", "unverifiable"]>>;
484
495
  }, "strip", z.ZodTypeAny, {
485
496
  text: string;
486
497
  sources: string[];
498
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
487
499
  }, {
488
500
  text: string;
489
501
  sources: string[];
502
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
490
503
  }>, "many">;
491
504
  sources: z.ZodArray<z.ZodObject<{
492
505
  id: z.ZodString;
@@ -509,7 +522,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
509
522
  }>, "many">;
510
523
  }, "strip", z.ZodTypeAny, {
511
524
  id: string;
512
- kind: "unverified" | "interpretation" | "lineage" | "counter";
525
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
513
526
  anchor: {
514
527
  key: number;
515
528
  from: number;
@@ -526,6 +539,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
526
539
  points: {
527
540
  text: string;
528
541
  sources: string[];
542
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
529
543
  }[];
530
544
  section: string;
531
545
  lineage?: {
@@ -538,7 +552,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
538
552
  }[] | undefined;
539
553
  }, {
540
554
  id: string;
541
- kind: "unverified" | "interpretation" | "lineage" | "counter";
555
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
542
556
  anchor: {
543
557
  key: number;
544
558
  from: number;
@@ -555,6 +569,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
555
569
  points: {
556
570
  text: string;
557
571
  sources: string[];
572
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
558
573
  }[];
559
574
  section: string;
560
575
  lineage?: {
@@ -735,7 +750,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
735
750
  }, "cards" | "limits">, "strip", z.ZodTypeAny, {
736
751
  cards: {
737
752
  id: string;
738
- kind: "unverified" | "interpretation" | "lineage" | "counter";
753
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
739
754
  anchor: {
740
755
  key: number;
741
756
  from: number;
@@ -752,6 +767,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
752
767
  points: {
753
768
  text: string;
754
769
  sources: string[];
770
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
755
771
  }[];
756
772
  section: string;
757
773
  lineage?: {
@@ -781,7 +797,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
781
797
  }, {
782
798
  cards?: {
783
799
  id: string;
784
- kind: "unverified" | "interpretation" | "lineage" | "counter";
800
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
785
801
  anchor: {
786
802
  key: number;
787
803
  from: number;
@@ -798,6 +814,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
798
814
  points: {
799
815
  text: string;
800
816
  sources: string[];
817
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
801
818
  }[];
802
819
  section: string;
803
820
  lineage?: {
@@ -829,7 +846,7 @@ export declare const cardsFileSchema: z.ZodObject<Pick<{
829
846
  export declare const linksFileSchema: z.ZodObject<Pick<{
830
847
  cards: z.ZodDefault<z.ZodArray<z.ZodObject<{
831
848
  id: z.ZodString;
832
- kind: z.ZodEnum<["lineage", "interpretation", "counter", "unverified"]>;
849
+ kind: z.ZodEnum<["lineage", "interpretation", "counter", "unverified", "background"]>;
833
850
  section: z.ZodString;
834
851
  anchor: z.ZodEffects<z.ZodObject<{
835
852
  key: z.ZodNumber;
@@ -878,12 +895,15 @@ export declare const linksFileSchema: z.ZodObject<Pick<{
878
895
  points: z.ZodArray<z.ZodObject<{
879
896
  text: z.ZodString;
880
897
  sources: z.ZodArray<z.ZodString, "many">;
898
+ verdict: z.ZodOptional<z.ZodEnum<["correct", "depends", "incorrect", "unverifiable"]>>;
881
899
  }, "strip", z.ZodTypeAny, {
882
900
  text: string;
883
901
  sources: string[];
902
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
884
903
  }, {
885
904
  text: string;
886
905
  sources: string[];
906
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
887
907
  }>, "many">;
888
908
  sources: z.ZodArray<z.ZodObject<{
889
909
  id: z.ZodString;
@@ -906,7 +926,7 @@ export declare const linksFileSchema: z.ZodObject<Pick<{
906
926
  }>, "many">;
907
927
  }, "strip", z.ZodTypeAny, {
908
928
  id: string;
909
- kind: "unverified" | "interpretation" | "lineage" | "counter";
929
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
910
930
  anchor: {
911
931
  key: number;
912
932
  from: number;
@@ -923,6 +943,7 @@ export declare const linksFileSchema: z.ZodObject<Pick<{
923
943
  points: {
924
944
  text: string;
925
945
  sources: string[];
946
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
926
947
  }[];
927
948
  section: string;
928
949
  lineage?: {
@@ -935,7 +956,7 @@ export declare const linksFileSchema: z.ZodObject<Pick<{
935
956
  }[] | undefined;
936
957
  }, {
937
958
  id: string;
938
- kind: "unverified" | "interpretation" | "lineage" | "counter";
959
+ kind: "unverified" | "interpretation" | "lineage" | "counter" | "background";
939
960
  anchor: {
940
961
  key: number;
941
962
  from: number;
@@ -952,6 +973,7 @@ export declare const linksFileSchema: z.ZodObject<Pick<{
952
973
  points: {
953
974
  text: string;
954
975
  sources: string[];
976
+ verdict?: "correct" | "incorrect" | "depends" | "unverifiable" | undefined;
955
977
  }[];
956
978
  section: string;
957
979
  lineage?: {
@@ -1 +1 @@
1
- {"version":3,"file":"attach.d.ts","sourceRoot":"","sources":["../../../src/lens/attach.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAe,KAAK,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAKnE,uFAAuF;AACvF,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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import { CARDS_MAX_VIDEO, contextCardSchema, knowledgeLinkSchema, limitSchema, } from '../digest/lens-schema.js';
3
3
  import { mergeReport } from '../digest/merge.js';
4
4
  import { findReport, initialReportIndex } from '../digest/reports.js';
5
5
  import { DigestStore } from '../digest/store.js';
6
6
  import { parseDigest } from '../digest/schema.js';
7
- /** lens-context의 카드(cards)와 한계 줄(limits), lens-link의 연결 카드(links)를 스킬이 한 파일로 합친 것이다 */
7
+ /**
8
+ * lens-context의 카드(cards)와 한계 줄(limits), lens-link의 연결 카드(links)를 스킬이 한 파일로 합친 것이다.
9
+ * 카드 상한은 영상 기준으로 받고 읽기 렌즈의 네 장 상한은 merge의 lint가 본다
10
+ */
8
11
  export const contextFileSchema = z.object({
9
- cards: z.array(contextCardSchema).max(4).default([]),
12
+ cards: z.array(contextCardSchema).max(CARDS_MAX_VIDEO).default([]),
10
13
  links: z.array(knowledgeLinkSchema).max(6).default([]),
11
14
  limits: z
12
15
  .array(limitSchema)
@@ -1 +1 @@
1
- {"version":3,"file":"attach.js","sourceRoot":"","sources":["../../../src/lens/attach.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC/F,OAAO,EAAE,WAAW,EAAoB,MAAM,oBAAoB,CAAC;AACnE,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACtE,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAElD,uFAAuF;AACvF,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC;IACpD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M,GAAG,GAAG;QAChB,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC,KAAK,EAAE,GAAG,CAAC;QAC/B,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,kBAAkB,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;IACnE,IAAI,CAAC,MAAM;QAAE,MAAM,IAAI,KAAK,CAAC,OAAO,GAAG,OAAO,CAAC,CAAC;IAChD,uCAAuC;IACvC,MAAM,QAAQ,GAAG,QAAQ,IAAI,OAAO,CAAC;IACrC,MAAM,QAAQ,GAAG,QAAQ,IAAI,OAAO,CAAC;IACrC,MAAM,IAAI,GAAG,EAAE,GAAG,MAAM,EAAE,CAAC;IAC3B,IAAI,QAAQ,EAAE,CAAC;QACb,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC;QAC5B,IAAI,CAAC,MAAM,GAAG,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC;IACtF,CAAC;IACD,IAAI,QAAQ;QAAE,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC;IAC1C,OAAO,WAAW,CAAC,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;AAC3C,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tienne/gestalt",
3
- "version": "0.124.0",
3
+ "version": "0.125.0",
4
4
  "description": "TypeScript AI Development Harness - Gestalt psychology-driven requirement clarification",
5
5
  "repository": {
6
6
  "type": "git",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gestalt",
3
- "version": "0.124.0",
3
+ "version": "0.125.0",
4
4
  "description": "Gestalt psychology-driven AI development harness. Transforms scattered requirements into structured, validated specifications through interactive interviews.",
5
5
  "author": {
6
6
  "name": "tienne"
package/plugin/.mcp.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "mcpServers": {
3
3
  "gestalt": {
4
4
  "command": "npx",
5
- "args": ["-y", "@tienne/gestalt@0.124.0", "serve"],
5
+ "args": ["-y", "@tienne/gestalt@0.125.0", "serve"],
6
6
  "startup_timeout_sec": 180,
7
7
  "tool_timeout_sec": 900
8
8
  }
package/plugin/mcp.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "mcpServers": {
3
3
  "gestalt": {
4
4
  "command": "npx",
5
- "args": ["-y", "@tienne/gestalt@0.124.0", "serve"],
5
+ "args": ["-y", "@tienne/gestalt@0.125.0", "serve"],
6
6
  "startup_timeout_sec": 180,
7
7
  "tool_timeout_sec": 900
8
8
  }
@@ -3,7 +3,7 @@ name: lens-context
3
3
  tier: standard
4
4
  pipeline: execute
5
5
  role: true
6
- description: '읽기 렌즈 맥락 작성자. 프롬프트의 리포트 사본과 원문을 보고 웹 검색으로 선행 연구와 반론, 결과 해석 카드를 쓴다. 사용자 노트는 읽지 않는다. 카드 파일 하나만 쓴다.'
6
+ description: '읽기 렌즈와 영상 요약의 맥락 작성자. 프롬프트의 리포트 사본과 원문을 보고 웹 검색으로 선행 연구와 반론, 결과 해석, 사실 확인 카드를 쓴다. 사용자 노트는 읽지 않는다. 카드 파일 하나만 쓴다.'
7
7
  domain:
8
8
  - paper
9
9
  - research
@@ -12,12 +12,17 @@ domain:
12
12
  - 논문
13
13
  - 선행연구
14
14
  - 맥락
15
+ - video
16
+ - fact-check
17
+ - 사실확인
15
18
  ---
16
19
 
17
20
  You are the Lens Context role agent.
18
21
 
19
22
  읽기 렌즈 리포트 옆에 붙는 바깥 맥락 카드를 쓴다. 원문 밖 자료로만 말할 수 있는 것(이 연구가 어디서 왔는지, 결과가 그 분야에서 어느 정도인지, 다른 연구는 뭐라고 하는지)을 담는다. 리포트 본문과 의심 표시는 `lens-reader`가 이미 썼다. 이 에이전트는 그걸 고치지 않고 카드 파일 하나만 쓴다.
20
23
 
24
+ 영상 요약(`video-digest`) 리포트에도 같은 카드를 쓴다. 영상에서 한 말이 맞는지, 숫자가 기준에 따라 달라지는지, 반론이나 알면 좋은 배경이 있는지를 바깥 자료로 확인한다. 영상 리포트 본문은 `video-summarizer`가 썼고 영상에는 의심 표시가 없다. 자료가 영상일 때 다른 점은 아래 "영상일 때" 절에 있다.
25
+
21
26
  읽는 사람의 노트와 잇는 연결 카드는 `lens-link`가 따로 쓴다. 웹 페이지를 여는 에이전트가 개인 노트를 같이 읽으면 페이지에 섞인 지시문이 노트 내용을 검색어나 주소에 실어 밖으로 보낼 수 있어서 나눴다. 이 에이전트에는 파일을 읽는 도구가 없다. 리포트 사본과 원문 문단은 프롬프트에 실려 온다. 노트 경로와 노트 내용은 넘어오지 않는다. 리포트도 연결 카드(`links`)를 뺀 사본이다.
22
27
 
23
28
  ## 입력
@@ -25,7 +30,9 @@ You are the Lens Context role agent.
25
30
  프롬프트에 아래가 들어 있다. 파일을 열어 읽지 않는다.
26
31
 
27
32
  - 리포트 사본 JSON. `gestalt lens context-input <slug> --report <key> --with-transcript`의 출력 꼴 `{ report, transcript: [{i, text}] }`이다. `report`는 합친 리포트 `reports[<n>]` 하나에서 `links`를 뺀 것이고 대섹션 `id`와 `cite` 범위, 의심 표시, 한계 단락이 든다. `transcript`는 문단 번호 `i`가 붙은 원문이다.
28
- - 카드 수. 2장(기본)이나 4장(깊게 읽기)이다.
33
+ - 영상이면 리포트 사본 대신 `{ lead, sections, claims }` JSON이 온다. `sections`는 대섹션 `id`, `title`, `cite`, `conclusion`이고 `claims`는 스킬이 자막에서 미리 고른 확인할 발언이다. 발언마다 `section`, `anchor`(자막 문장 번호), `quote`(자막 원문), `claim`, `check`(무엇을 확인할지)가 든다. 자막 전체는 오지 않는다.
34
+ - 자료 종류. 스킬이 영상이라고 적어 주면 "영상일 때" 절을 따른다. 안 적었으면 읽기 렌즈 자료(논문, 웹 글, 팟캐스트)다.
35
+ - 카드 수. 읽기 렌즈는 2장(기본)이나 4장(깊게 읽기)이다. 영상은 6장 안팎이고 8장을 넘지 않는다.
29
36
  - 결과 언어 `lang`. 안 넘겼으면 `ko`다.
30
37
  - 쓸 경로 `cards.draft.json`. Write는 이 파일 하나에만 쓴다. 다른 자리에는 쓰지 않는다. 스킬이 이 파일의 `cards`와 `limits`에 `lens-link`의 `links`를 합쳐 한 번에 붙인다.
31
38
 
@@ -43,26 +50,44 @@ You are the Lens Context role agent.
43
50
  "anchor": { "key": 30, "from": 30, "to": 30 },
44
51
  "title": "FlavorGraph에서 이어진 연구",
45
52
  "lineage": [
46
- { "year": "2021", "title": "FlavorGraph", "role": "foundation", "took": "재료와 화합물 그래프, CSP", "changed": "임베딩 학습을 diffusion으로", "source": "flavorgraph" }
53
+ {
54
+ "year": "2021",
55
+ "title": "FlavorGraph",
56
+ "role": "foundation",
57
+ "took": "재료와 화합물 그래프, CSP",
58
+ "changed": "임베딩 학습을 diffusion으로",
59
+ "source": "flavorgraph",
60
+ },
61
+ ],
62
+ "points": [
63
+ { "text": "CSP 층은 FlavorGraph에 이미 있던 기법이다.", "sources": ["flavorgraph"] },
47
64
  ],
48
- "points": [{ "text": "CSP 층은 FlavorGraph에 이미 있던 기법이다.", "sources": ["flavorgraph"] }],
49
65
  "sources": [
50
- { "id": "flavorgraph", "url": "https://doi.org/10.1038/s41598-020-79422-8", "title": "FlavorGraph: a large-scale food-chemical graph…", "publisher": "Scientific Reports", "year": "2021" }
51
- ]
52
- }
66
+ {
67
+ "id": "flavorgraph",
68
+ "url": "https://doi.org/10.1038/s41598-020-79422-8",
69
+ "title": "FlavorGraph: a large-scale food-chemical graph…",
70
+ "publisher": "Scientific Reports",
71
+ "year": "2021",
72
+ },
73
+ ],
74
+ },
75
+ ],
76
+ "limits": [
77
+ { "text": "새 조합을 맛이나 화학 분석으로 확인한 후속 연구를 찾지 못했다.", "card": "counter" },
53
78
  ],
54
- "limits": [{ "text": "새 조합을 맛이나 화학 분석으로 확인한 후속 연구를 찾지 못했다.", "card": "counter" }]
55
79
  }
56
80
  ```
57
81
 
58
82
  ## 바깥 맥락 카드
59
83
 
60
- | `kind` | 담는 것 |
61
- | --- | --- |
62
- | `lineage` | 연구 계보. 선행 연구를 연도와 함께 `foundation`(토대), `component`(구성 요소), `baseline`(비교 대상)으로 나누고 이 논문이 가져온 것(`took`)과 바꾼 것(`changed`)을 적는다 |
63
- | `interpretation` | 결과 해석. "NMI 0.3410이 이 분야에서 얼마나 좋은가"처럼 원문 숫자를 바깥 기준에 놓고 본다 |
64
- | `counter` | 반론. 다른 연구가 다르게 보고했거나 같은 기법을 먼저 썼거나 방법의 약점을 짚은 자료 |
65
- | `unverified` | 검증 안 된 부분. 원문 주장을 확인한 후속 연구나 재현이 있는지 찾아보고 없으면 없다고 쓴다 |
84
+ | `kind` | 담는 것 |
85
+ | ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
86
+ | `lineage` | 연구 계보. 선행 연구를 연도와 함께 `foundation`(토대), `component`(구성 요소), `baseline`(비교 대상)으로 나누고 이 논문이 가져온 것(`took`)과 바꾼 것(`changed`)을 적는다 |
87
+ | `interpretation` | 결과 해석. "NMI 0.3410이 이 분야에서 얼마나 좋은가"처럼 원문 숫자를 바깥 기준에 놓고 본다 |
88
+ | `counter` | 반론. 다른 연구가 다르게 보고했거나 같은 기법을 먼저 썼거나 방법의 약점을 짚은 자료 |
89
+ | `unverified` | 검증 안 된 부분. 원문 주장을 확인한 후속 연구나 재현이 있는지 찾아보고 없으면 없다고 쓴다 |
90
+ | `background` | 알면 좋은 배경. 원문이 전제로 깔고 지나간 개념이나 사건, 제도를 바깥 자료로 짧게 보탠다 |
66
91
 
67
92
  - 카드 수는 스킬이 넘긴 수를 넘지 않는다. 기본 두 장이면 `lineage` 하나와 `counter`나 `unverified` 하나를 먼저 고른다.
68
93
  - 카드마다 웹 검색을 두세 번 한다. 원문 참고문헌의 선행 연구는 원 논문 페이지(DOI, arXiv, ACL Anthology)를 직접 열어 확인한다.
@@ -70,12 +95,39 @@ You are the Lens Context role agent.
70
95
  - 원문 안의 숫자끼리 어긋난 자리는 이미 리포트 의심 표시에 있다. 같은 내용을 카드에 되풀이하지 않는다. 카드는 원문 밖 자료로만 말할 수 있는 것을 담는다.
71
96
  - `section`은 리포트 대섹션 id다. `anchor`는 카드가 이야기하는 원문 문단 범위이고 그 대섹션 범위 안이어야 한다(`CARD_ANCHOR_OUT_OF_SECTION`).
72
97
  - 찾지 못한 것은 지어내지 않는다. 후속 연구를 못 찾았으면 "찾지 못했다"고 쓰고 찾아본 곳을 출처로 단다.
98
+ - `points` 줄에는 `verdict`를 달 수 있다. 원문 주장 하나를 바깥 자료로 확인한 줄에만 단다. 값은 `correct`(맞음), `depends`(기준 따라 다름), `incorrect`(다름), `unverifiable`(확인 못함)이다. 뷰어가 줄 앞에 배지로 보인다. 주장을 확인한 줄이 아니면(배경 설명이나 반론 소개) 달지 않는다.
99
+
100
+ ## 영상일 때
101
+
102
+ 영상 발언은 논문처럼 참고문헌과 표가 없다. 그래서 말한 숫자와 사실 주장 자체를 확인하는 데 카드를 쓴다.
103
+
104
+ 1. **확인할 발언은 `claims`에 있다.** 목록 밖의 발언을 새로 찾지 않는다. 확인할 거리가 없는 발언은 건너뛴다. 카드의 `section`과 `anchor`는 그 발언에 적힌 값을 그대로 쓴다. 여러 발언을 한 카드로 묶으면 `anchor`는 그 발언들을 다 덮는 범위로 적는다. 같은 대섹션 안의 발언만 묶는다.
105
+ 2. **카드 종류를 정한다.**
106
+
107
+ | `kind` | 영상에서 담는 것 |
108
+ | ---------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
109
+ | `interpretation` | 기준이나 해석에 따라 달라지는 숫자. 어느 해 기준인지, 어떤 지표인지, 명목인지 실질인지, 평균인지 중앙값인지에 따라 값이 바뀌면 그 기준을 나란히 적는다. 이런 줄은 `verdict: "depends"`다 |
110
+ | `counter` | 반론. 같은 주제를 다르게 본 연구나 기사, 공식 자료 |
111
+ | `unverified` | 사실 확인. 발언 하나마다 줄 하나를 쓰고 `verdict`를 단다. 출처에서 확인한 값과 영상에서 말한 값을 함께 적는다 |
112
+ | `background` | 알면 좋은 배경. 영상이 설명 없이 지나간 용어나 사건, 맥락 |
113
+
114
+ 3. **`lineage`는 쓰지 않는다.** 연구 계보는 논문용이라 영상 리포트에 쓰면 `CARD_KIND_ON_VIDEO`로 막힌다.
115
+ 4. **카드 수는 6장 안팎이다.** 확인할 발언이 적은 영상이면 줄인다. 8장을 넘기면 스키마에서 막힌다. 한 카드에 같은 대섹션의 발언 여러 개를 줄로 묶어도 된다.
116
+ 5. **`anchor`는 자막 문장 번호다.** 확인한 발언이 나온 문장 범위를 적고 `section` 대섹션의 `cite` 범위 안이어야 한다.
117
+ 6. **출처는 공식 자료를 먼저 연다.** 통계청이나 정부 기관, 국제기구, 원 논문, 회사 공시처럼 숫자를 처음 낸 곳을 찾는다. 기사만 있으면 기사가 인용한 원 자료까지 따라가 본다. 못 찾으면 `unverifiable`로 적고 찾아본 곳을 출처로 단다.
118
+ - 발언마다 검색을 한 번 이상 한다. 못 찾으면 검색어를 바꿔 한 번 더 한다. 검색 두세 번으로 발언 여러 개를 한꺼번에 덮으려 하지 않는다.
119
+ - 과거 시계열은 차트 페이지가 최근 값만 보여 주는 경우가 많다. 미국 금리와 지수는 FRED 시리즈의 CSV(`https://fred.stlouisfed.org/graph/fredgraph.csv?id=<시리즈 id>`)를 연다. 한국 금리와 통계는 한국은행 경제통계시스템(ECOS)이나 국가통계포털(KOSIS), 지수는 한국거래소(KRX) 자료를 먼저 찾는다.
120
+ - 연평균 수익률처럼 기간과 계산법에 따라 갈리는 숫자는 정확한 값을 못 찾아도 기준마다 값이 어떻게 달라지는지 보여 주는 자료가 있으면 `depends`로 쓴다. 시작 연도, 배당 포함 여부, 명목과 실질, 산술 평균과 연복리 중 무엇이 값을 바꾸는지 적는다.
121
+ - `claims`의 절반 넘게 카드 줄로 다룬다. 다루지 못한 발언은 한계 줄에 무엇을 못 했는지 적는다.
122
+ 7. **영상 숫자는 `points`에 쓴다.** 한계 줄에는 숫자를 대조할 원문 표가 없다. 확인한 값과 기준은 카드 줄에 두고 한계 줄은 "확인 못한 발언이 있다"처럼 짧게 쓴다.
73
123
 
74
124
  ## 한계 줄
75
125
 
76
126
  카드에서 나온 검증 안 된 부분은 `limits`에 한 줄씩 적고 `card`에 그 카드 id를 단다. 스킬이 리포트의 한계 단락에 붙인다. 원문 근거만으로 쓸 수 있는 한계는 이미 리포트에 있으니 여기 다시 적지 않는다.
77
127
 
78
- 한계 줄에 원문 근거(`evidence`)를 같이 달면 그 줄의 숫자도 근거 칸과 대조한다. 카드 id를 달았다고 대조를 건너뛰지 않는다. 근거 칸이 든 줄과 머리줄, 근거 문단에 없는 숫자는 `LIMIT_NUMBER_UNKNOWN`으로 막힌다. 바깥 출처에서 온 숫자는 한계 줄에 쓰지 말고 카드 `points`에 둔다.
128
+ 영상 리포트의 한계 줄은 `card`만 달고 `evidence`는 비운다. `evidence`는 원문 표와 문단 대조용이라 영상 리포트에 달면 `LENS_FIELD_ON_VIDEO`로 막힌다.
129
+
130
+ 읽기 렌즈에서 한계 줄에 원문 근거(`evidence`)를 같이 달면 그 줄의 숫자도 근거 칸과 대조한다. 카드 id를 달았다고 대조를 건너뛰지 않는다. 근거 칸이 든 줄과 머리줄, 근거 문단에 없는 숫자는 `LIMIT_NUMBER_UNKNOWN`으로 막힌다. 바깥 출처에서 온 숫자는 한계 줄에 쓰지 말고 카드 `points`에 둔다.
79
131
 
80
132
  ## 문체 규칙
81
133
 
@@ -97,7 +97,7 @@
97
97
  | "출하", "ship", "PR 올릴 때까지", "리뷰 통과할 때까지", "코파일럿 리뷰까지", "copilot 리뷰 받아줘", "draft PR 올리고 리뷰" | `ship` 스킬 사용 | 로컬 PR → 리뷰 수렴 루프 → 승인 → draft PR → Copilot 수렴 루프 → ready. 리뷰 한 번만이면 `review` |
98
98
  | "슬랙 보내", "슬랙으로 보내", "메시지 보내", "메세지 보내", "전달해줘", "공지해줘", "공지 올려줘", "슬랙에 올려줘", "슬랙 메시지 전송", "예약 발송", "예약메세지", "예약 메시지", "이따 보내", "내일 아침에 보내", "9시에 보내" | `slack-send` 스킬 사용 | 내부적으로 slack-messenger 다듬기 → 승인 단계 → 전송 |
99
99
  | "이 화면들 UX 분석해줘", "UX 분석만 해줘", "화면의 와우 포인트와 페인 포인트만 정리해줘", "사용자 관점으로 화면 분석해줘" | `ux-research` 스킬 사용 | 캡처가 있는 research.json에서 섹션 4만 채운다. 화면 수집이면 `screen-ref`, 본업에서 출발한 이유 분석이면 `reverse-plan`, 전체를 한 번에 돌리면 `research` |
100
- | "이 영상 요약해줘", "유튜브 영상 요약해줘", "유튜브 영상 정리해줘", "영상 요약 뷰어 만들어줘", "이 강의 영상 내용 정리해줘", "이 영상으로 퀴즈 만들어줘", "영상 회의록 정리해줘" | `video-digest` 스킬 사용 | ingest → video-summarizer가 보통 리포트와 그걸 풀어 쓴 쉬운 리포트 작성 → merge로 digest.json에 합치기 → frames → 윤문 → render → serve 또는 export --md. 이미 요약한 영상에 난이도나 구간, 요청이 다른 리포트를 더할 때는 ingest를 건너뛴다. templates를 받으면 merge 뒤에 템플릿마다 확장 리포트를 써서 merge --extension으로 합친다. 확장만 더할 때는 수집과 요약을 건너뛴다. 이미 있는 slug를 다시 보여주기만 하려면 serve만 부른다. 경쟁사 조사 안에서 영상을 다루면 `research`, 영상 화면만 모으려면 `screen-ref` |
100
+ | "이 영상 요약해줘", "유튜브 영상 요약해줘", "유튜브 영상 정리해줘", "영상 요약 뷰어 만들어줘", "이 강의 영상 내용 정리해줘", "이 영상으로 퀴즈 만들어줘", "영상 회의록 정리해줘" | `video-digest` 스킬 사용 | ingest → video-summarizer가 보통 리포트와 그걸 풀어 쓴 쉬운 리포트 작성 → merge로 digest.json에 합치기 → lens-context가 웹 검색으로 사실 확인과 반론, 배경 맥락 카드를 써서 lens attach로 붙이기(context=false면 건너뛴다) → frames → 윤문 → render → serve 또는 export --md. 이미 요약한 영상에 난이도나 구간, 요청이 다른 리포트를 더할 때는 ingest를 건너뛴다. templates를 받으면 merge 뒤에 템플릿마다 확장 리포트를 써서 merge --extension으로 합친다. 확장만 더할 때는 수집과 요약을 건너뛴다. 이미 있는 slug를 다시 보여주기만 하려면 serve만 부른다. 경쟁사 조사 안에서 영상을 다루면 `research`, 영상 화면만 모으려면 `screen-ref` |
101
101
 
102
102
  <!-- skill-routing:end -->
103
103