@50arms/plugin-sdk 0.2.70 → 0.2.72

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 (2) hide show
  1. package/dist/card-kit.d.ts +69 -52
  2. package/package.json +1 -1
@@ -31,11 +31,6 @@ declare module "@danxbot/card-kit@1" {
31
31
  }
32
32
 
33
33
  type CardTypeKey = string;
34
-
35
- interface Justification {
36
- quote: string;
37
- reasoning: string;
38
- }
39
34
  type MirrorProviderId = "trello" | "slack" | "asana" | "linear";
40
35
  type SourceOrigin = "danxbot" | MirrorProviderId | "";
41
36
  type DecisionRecordKind = "business_rule" | "architecture" | "design" | "other";
@@ -61,7 +56,7 @@ declare module "@danxbot/card-kit@1" {
61
56
  made_by_name: string | null;
62
57
  made_by_author: AuthorV2;
63
58
  made_by_is_writer: boolean;
64
- provenance: ProvenanceRecordV2[];
59
+ provenance: ProvenanceRecordV2 | null;
65
60
  author: string;
66
61
  by: AuthorV2;
67
62
  via_key: ViaKey | null;
@@ -104,9 +99,9 @@ declare module "@danxbot/card-kit@1" {
104
99
  values: StatusReasonValues;
105
100
  }
106
101
  type PacingLimit = "five_hour" | "weekly" | "spend";
107
- type ProvenanceSourceKind = "card" | "comment" | "session_thread" | "problem" | "url" | "evidence";
102
+ type ProvenanceSourceKind = "design" | "agent" | "plan" | "card" | "comment" | "session_thread" | "problem" | "evidence" | "url" | "decision" | "plan_record" | "plan_section" | "behavior_rule" | "behavior_policy" | "docs_page" | "commit" | "user" | "system";
108
103
  type ProvenancePartyKind = "agent" | "person";
109
- type ResourceType = "design" | "plan" | "problem" | "evidence" | "issue" | "plan_record" | "plan_section" | "decision" | "behavior_policy" | "behavior_policy_group";
104
+ type ResourceType = "design" | "plan" | "problem" | "evidence" | "decision" | "plan_record" | "plan_section" | "behavior_policy" | "issue" | "behavior_policy_group";
110
105
  interface ResourceRef {
111
106
  type: ResourceType;
112
107
  id: string;
@@ -257,7 +252,7 @@ declare module "@danxbot/card-kit@1" {
257
252
  subjects: string[];
258
253
  reasoning: string;
259
254
  confidence: number;
260
- provenance: ProvenanceRecordV2[];
255
+ provenance: ProvenanceRecordV2 | null;
261
256
  }
262
257
  interface EvidenceKeyFigure {
263
258
  value: string;
@@ -271,12 +266,12 @@ declare module "@danxbot/card-kit@1" {
271
266
  version_no: number;
272
267
  answer: string;
273
268
  confidence: number;
274
- reasoning: string;
275
- cites: string[];
269
+ provenance: ProvenanceRecordV2;
276
270
  key_figures: EvidenceKeyFigure[];
277
271
  confidence_reason: string | null;
278
272
  unverified: string[];
279
273
  method: string | null;
274
+ reproduced_failure: boolean;
280
275
  }
281
276
  interface EvidenceRaisedProblemView {
282
277
  card_id: string;
@@ -318,7 +313,7 @@ declare module "@danxbot/card-kit@1" {
318
313
  ref: string;
319
314
  card_id: string;
320
315
  }
321
- type WorkMarkResourceType = "design" | "plan" | "problem" | "plan_record" | "plan_section" | "decision";
316
+ type WorkMarkResourceType = "design" | "plan" | "problem" | "decision" | "plan_record" | "plan_section";
322
317
  type ClaimResourceType = "design" | "evidence";
323
318
  interface ClaimResource extends ResourceRef {
324
319
  type: ClaimResourceType;
@@ -328,6 +323,7 @@ declare module "@danxbot/card-kit@1" {
328
323
  }
329
324
 
330
325
  type QualityGatePhase = "plan" | "code";
326
+
331
327
  type ControlValue = boolean | string;
332
328
 
333
329
  type ControlSource = "card" | "plan" | "board" | "team" | "system";
@@ -489,7 +485,7 @@ declare module "@danxbot/card-kit@1" {
489
485
  made_by_email: string | null;
490
486
  made_by_name: string | null;
491
487
  made_by_team_agent: string | null;
492
- provenance: V2CopyProvenanceRecord[];
488
+ provenance: V2CopyProvenanceRecord | null;
493
489
  author: string;
494
490
  team_agent: string | null;
495
491
  created_at: string;
@@ -535,7 +531,7 @@ declare module "@danxbot/card-kit@1" {
535
531
  exhibits: V2CopyEvidenceExhibit[];
536
532
  subjects: string[];
537
533
  approvals: V2CopyEvidenceApproval[];
538
- provenance: V2CopyProvenanceRecord[];
534
+ provenance: V2CopyProvenanceRecord | null;
539
535
  }
540
536
  interface V2CopyEvidenceKeyFigure {
541
537
  value: string;
@@ -548,12 +544,12 @@ declare module "@danxbot/card-kit@1" {
548
544
  version_no: number;
549
545
  answer: string;
550
546
  confidence: number;
551
- reasoning: string;
552
- cites: number[];
547
+ provenance: V2CopyProvenanceRecord;
553
548
  key_figures: V2CopyEvidenceKeyFigure[];
554
549
  confidence_reason: string | null;
555
550
  unverified: string[];
556
551
  method: string | null;
552
+ reproduced_failure: boolean;
557
553
  approvals: V2CopyEvidenceApproval[];
558
554
  }
559
555
  interface V2CopyEvidenceBlockAttachment {
@@ -615,6 +611,7 @@ declare module "@danxbot/card-kit@1" {
615
611
  interface V2CopyBehaviorSignoff {
616
612
  policy_index: number;
617
613
  rule_index: number;
614
+ pin_no: number;
618
615
  slot: string;
619
616
  status: "compliant" | "incompliant" | "rejected" | "not_applicable";
620
617
  note: string | null;
@@ -738,17 +735,26 @@ declare module "@danxbot/card-kit@1" {
738
735
  interface V2CopyProvenanceSource {
739
736
  kind: ProvenanceSourceKind;
740
737
  ref: string;
738
+ quote: string | null;
739
+ quote_verified: boolean;
741
740
  comment_index: number | null;
742
741
  problem_index: number | null;
743
742
  evidence_index: number | null;
743
+ design_index: number | null;
744
744
  card_linked: boolean;
745
745
  author: V2CopyProvenanceParty | null;
746
746
  at: string | null;
747
+ added_by: V2CopyProvenanceParty;
748
+ added_at: string;
749
+ }
750
+ interface V2CopyJustification {
751
+ card_type: string;
752
+ provenance: V2CopyProvenanceRecord;
747
753
  }
748
754
  interface V2CopyProvenanceRecord {
749
- quote: string | null;
750
755
  reasoning: string | null;
751
- source: V2CopyProvenanceSource | null;
756
+ confidence: number | null;
757
+ sources: V2CopyProvenanceSource[];
752
758
  recorded_by: V2CopyProvenanceParty;
753
759
  recorded_at: string;
754
760
  }
@@ -791,8 +797,10 @@ declare module "@danxbot/card-kit@1" {
791
797
  comments: V2CopyComment[];
792
798
  agent_notes: V2CopyAgentNote[];
793
799
  decision_records: V2CopyDecisionRecord[];
800
+ justifications: V2CopyJustification[];
794
801
  evidence_records: V2CopyEvidenceRecord[];
795
802
  behavior_policies_pinned_at: string | null;
803
+ behavior_policies_pin_no: number | null;
796
804
  behavior_policies: V2CopyBehaviorPolicy[];
797
805
  behavior_signoffs: V2CopyBehaviorSignoff[];
798
806
  created_tags: V2CopyCommentTag[];
@@ -909,9 +917,10 @@ declare module "@danxbot/card-kit@1" {
909
917
  readonly review: "surfaced" | "auto_approved" | null;
910
918
  readonly signer: {
911
919
  readonly kind: "person" | "agent";
912
- readonly name: string;
913
920
  readonly user_id: number | null;
914
921
  };
922
+ readonly by: AuthorV2;
923
+ readonly pin_no: number;
915
924
  readonly signed_at: string;
916
925
  }
917
926
  interface BehaviorSlotView {
@@ -923,6 +932,8 @@ declare module "@danxbot/card-kit@1" {
923
932
  readonly confidence: number | null;
924
933
  readonly review: "surfaced" | "auto_approved" | null;
925
934
  readonly signer: BehaviorDecisionView["signer"] | null;
935
+ readonly by: BehaviorDecisionView["by"] | null;
936
+ readonly pin_no: number | null;
926
937
  readonly signed_at: string | null;
927
938
  readonly problem: {
928
939
  readonly ref: string;
@@ -937,6 +948,7 @@ declare module "@danxbot/card-kit@1" {
937
948
  readonly rule_version: string;
938
949
  readonly requires_reasoning: boolean;
939
950
  readonly confidence_threshold: number;
951
+ readonly provenance: ProvenanceRecordV2;
940
952
  readonly slots: BehaviorSlotView[];
941
953
  }
942
954
  interface BehaviorPolicyView {
@@ -944,12 +956,15 @@ declare module "@danxbot/card-kit@1" {
944
956
  readonly name: string;
945
957
  readonly quality_gate_types: string[] | null;
946
958
  readonly attached_at: string | null;
959
+ readonly stale: boolean;
947
960
  readonly violation_instructions: string;
948
961
  readonly confidence_threshold: number;
949
962
  readonly rules: BehaviorRuleView[];
950
963
  }
951
964
  interface CardBehaviorPoliciesView {
952
965
  readonly behavior_policies_pinned_at: string | null;
966
+ readonly behavior_policies_pin_no: number | null;
967
+ readonly stale: boolean;
953
968
  readonly open_slot_count: number;
954
969
  readonly policies: BehaviorPolicyView[];
955
970
  }
@@ -978,27 +993,12 @@ declare module "@danxbot/card-kit@1" {
978
993
  readonly evaluated_count: number;
979
994
  readonly rows: BehaviorRuleRowView[];
980
995
  }
981
- interface BehaviorRuleEscalationView {
982
- readonly rule_id: number;
983
- readonly rule_ref: string;
984
- readonly rule_text: string;
985
- readonly policy_ref: string;
986
- readonly policy_name: string;
987
- readonly slot: string;
988
- readonly gate_on_card: boolean;
989
- readonly confidence: number;
990
- readonly why: string;
991
- readonly escalated_by: string;
992
- readonly escalated_at: string;
993
- readonly state: "waiting_on_person" | "settled";
994
- readonly decision: BehaviorDecisionView | null;
995
- }
996
996
  interface BehaviorRulesProblemView {
997
997
  readonly total_count: number;
998
998
  readonly evaluated_count: number;
999
999
  readonly waiting_count: number;
1000
+ readonly pin_no: number | null;
1000
1001
  readonly groups: BehaviorRuleGroupView[];
1001
- readonly escalations: BehaviorRuleEscalationView[];
1002
1002
  }
1003
1003
  interface DesignSourceFile {
1004
1004
  path: string;
@@ -1222,6 +1222,15 @@ declare module "@danxbot/card-kit@1" {
1222
1222
  readonly card_id: CardRef;
1223
1223
  readonly card_title: string;
1224
1224
  readonly card_status: string;
1225
+ readonly card_priority: number;
1226
+ readonly card_created_at: string;
1227
+ readonly card_updated_at: string;
1228
+ readonly parent: {
1229
+ readonly id: CardRef;
1230
+ readonly title: string;
1231
+ readonly created_at: string;
1232
+ readonly updated_at: string;
1233
+ } | null;
1225
1234
  readonly problems: readonly {
1226
1235
  readonly ref_num: number;
1227
1236
  readonly type: IssueProblemType;
@@ -1500,6 +1509,7 @@ declare module "@danxbot/card-kit@1" {
1500
1509
  via_key: null | ViaKey;
1501
1510
  timestamp: string;
1502
1511
  updated_at: string;
1512
+ content_hash?: undefined | string;
1503
1513
  text: string;
1504
1514
  reduced?: undefined | true;
1505
1515
  reduced_text?: undefined | null | string;
@@ -1592,7 +1602,8 @@ declare module "@danxbot/card-kit@1" {
1592
1602
  risk_reason?: undefined | null | string;
1593
1603
  risk_set?: undefined | null | { at: string; by: AuthorV2; };
1594
1604
  risk_raise_reason?: undefined | null | string;
1595
- justification?: undefined | null | Justification;
1605
+ justification?: undefined | null | ProvenanceRecordV2;
1606
+ justification_history?: undefined | Array<ProvenanceRecordV2>;
1596
1607
  bump_size?: undefined | "patch" | "minor" | "major";
1597
1608
  start_commit?: undefined | null | { at: string; sha: string | null; error: "no_repo" | "not_github_repo" | "no_token" | "github_refused" | "github_unreachable" | "unreadable_tip" | "unexpected" | null; error_detail: string | null; };
1598
1609
  problem_total?: undefined | number;
@@ -1699,7 +1710,7 @@ declare module "@danxbot/card-kit@1" {
1699
1710
  made_by_name: null | string;
1700
1711
  made_by_author: AuthorV2;
1701
1712
  made_by_is_writer: boolean;
1702
- provenance: Array<ProvenanceRecordV2>;
1713
+ provenance: null | ProvenanceRecordV2;
1703
1714
  comment_count: number;
1704
1715
  unread_comment_count: number;
1705
1716
  versions?: undefined | (Array<{
@@ -1721,7 +1732,7 @@ declare module "@danxbot/card-kit@1" {
1721
1732
  made_by_name: null | string;
1722
1733
  made_by_author: AuthorV2;
1723
1734
  made_by_is_writer: boolean;
1724
- provenance: Array<ProvenanceRecordV2>;
1735
+ provenance: null | ProvenanceRecordV2;
1725
1736
  version_no: number;
1726
1737
  }>);
1727
1738
  approvals?: undefined | (Array<{
@@ -1770,7 +1781,7 @@ declare module "@danxbot/card-kit@1" {
1770
1781
  subjects: Array<string>;
1771
1782
  reasoning: string;
1772
1783
  confidence: number;
1773
- provenance: Array<ProvenanceRecordV2>;
1784
+ provenance: null | ProvenanceRecordV2;
1774
1785
  author: string;
1775
1786
  by: AuthorV2;
1776
1787
  via_key: null | ViaKey;
@@ -1789,12 +1800,12 @@ declare module "@danxbot/card-kit@1" {
1789
1800
  version_no: number;
1790
1801
  answer: string;
1791
1802
  confidence: number;
1792
- reasoning: string;
1793
- cites: Array<string>;
1803
+ provenance: ProvenanceRecordV2;
1794
1804
  key_figures: Array<EvidenceKeyFigure>;
1795
1805
  confidence_reason: null | string;
1796
1806
  unverified: Array<string>;
1797
1807
  method: null | string;
1808
+ reproduced_failure: boolean;
1798
1809
  author: string;
1799
1810
  by: AuthorV2;
1800
1811
  via_key: null | ViaKey;
@@ -1828,7 +1839,7 @@ declare module "@danxbot/card-kit@1" {
1828
1839
  made_by_name: null | string;
1829
1840
  made_by_author: AuthorV2;
1830
1841
  made_by_is_writer: boolean;
1831
- provenance: Array<ProvenanceRecordV2>;
1842
+ provenance: null | ProvenanceRecordV2;
1832
1843
  version_no: number;
1833
1844
  }>);
1834
1845
  decision_record_approvals?: undefined | (Array<{
@@ -2014,7 +2025,7 @@ declare module "@danxbot/card-kit@1" {
2014
2025
  made_by_name: null | string;
2015
2026
  made_by_author: AuthorV2;
2016
2027
  made_by_is_writer: boolean;
2017
- provenance: Array<ProvenanceRecordV2>;
2028
+ provenance: null | ProvenanceRecordV2;
2018
2029
  version_no: number;
2019
2030
  }>);
2020
2031
  }>);
@@ -2036,7 +2047,7 @@ declare module "@danxbot/card-kit@1" {
2036
2047
  subjects: Array<string>;
2037
2048
  reasoning: string;
2038
2049
  confidence: number;
2039
- provenance: Array<ProvenanceRecordV2>;
2050
+ provenance: null | ProvenanceRecordV2;
2040
2051
  author: string;
2041
2052
  by: AuthorV2;
2042
2053
  via_key: null | ViaKey;
@@ -2055,12 +2066,12 @@ declare module "@danxbot/card-kit@1" {
2055
2066
  version_no: number;
2056
2067
  answer: string;
2057
2068
  confidence: number;
2058
- reasoning: string;
2059
- cites: Array<string>;
2069
+ provenance: ProvenanceRecordV2;
2060
2070
  key_figures: Array<EvidenceKeyFigure>;
2061
2071
  confidence_reason: null | string;
2062
2072
  unverified: Array<string>;
2063
2073
  method: null | string;
2074
+ reproduced_failure: boolean;
2064
2075
  author: string;
2065
2076
  by: AuthorV2;
2066
2077
  via_key: null | ViaKey;
@@ -2205,10 +2216,9 @@ declare module "@danxbot/card-kit@1" {
2205
2216
  risk_set_via_key_name: string | null;
2206
2217
  risk_set_team_agent_id: number | null;
2207
2218
  risk_raise_reason: string | null;
2208
- justification_quote: string | null;
2209
- justification_reasoning: string | null;
2210
2219
  bump_size: BumpSize;
2211
2220
  behavior_policies_pinned_at: string | null;
2221
+ behavior_policies_pin_no: number | null;
2212
2222
  start_commit_sha: string | null;
2213
2223
  start_commit_at: string | null;
2214
2224
  start_commit_error: StartCommitError | null;
@@ -2411,18 +2421,24 @@ declare module "@danxbot/card-kit@1" {
2411
2421
  }
2412
2422
  interface ProvenanceRecordV2 {
2413
2423
  id: number;
2414
- quote: string | null;
2415
2424
  reasoning: string | null;
2416
- source: ProvenanceSourceV2 | null;
2425
+ confidence: number | null;
2426
+ sources: ProvenanceSourceV2[];
2417
2427
  recorded_by: AuthorV2;
2418
2428
  recorded_at: string;
2419
2429
  }
2420
2430
  interface ProvenanceSourceV2 {
2421
2431
  kind: ProvenanceSourceKind;
2422
2432
  ref: string;
2423
- card_id: CardRef | null;
2433
+ quote: string | null;
2434
+ quote_verified: boolean;
2435
+ label: string;
2436
+ url: string | null;
2437
+ external: boolean;
2424
2438
  author: AuthorV2 | null;
2425
2439
  at: string | null;
2440
+ added_by: AuthorV2;
2441
+ added_at: string;
2426
2442
  }
2427
2443
 
2428
2444
  function useIssueDetail(id: string): LiveQueryResult<IssueViewV2>;
@@ -2589,10 +2605,11 @@ declare module "@danxbot/card-kit@1" {
2589
2605
  removedSolutionIds: ReadonlySet<number>;
2590
2606
  decisions: DecisionViewV2[];
2591
2607
  choiceLocked: boolean;
2608
+ answerable: boolean;
2592
2609
  }
2593
2610
 
2594
2611
  interface ProblemsSectionProps {
2595
- card: ProblemCard;
2612
+ card: ProblemCard & Partial<Pick<IssueViewV2, "archived_at">>;
2596
2613
  problems: ProblemAttention[];
2597
2614
  canAnswer: boolean;
2598
2615
  designGatePending: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@50arms/plugin-sdk",
3
- "version": "0.2.70",
3
+ "version": "0.2.72",
4
4
  "description": "SDK for building 50 Arms plugins (DX-5170): the card kit's type declarations, the Widget declaration kit, a Vite preset that builds a plugin against the app's shared runtime and writes its manifest, and the danx-plugin CLI.",
5
5
  "license": "MIT",
6
6
  "type": "module",