@roarkanalytics/cli 0.20.0 → 0.22.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/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.22.0](https://github.com/roarkhq/cli-roark-analytics/compare/v0.21.0...v0.22.0) (2026-09-18)
4
+
5
+
6
+ ### Features
7
+
8
+ * **cli:** cli update ([#52](https://github.com/roarkhq/cli-roark-analytics/issues/52)) ([5efaf54](https://github.com/roarkhq/cli-roark-analytics/commit/5efaf54e4c88b10cf1e03aed8eefabef30935f22))
9
+
10
+ ## [0.21.0](https://github.com/roarkhq/cli-roark-analytics/compare/v0.20.0...v0.21.0) (2026-09-17)
11
+
12
+
13
+ ### Features
14
+
15
+ * **cli:** cli update ([#50](https://github.com/roarkhq/cli-roark-analytics/issues/50)) ([e2c2aa2](https://github.com/roarkhq/cli-roark-analytics/commit/e2c2aa29510711adcd277a08ac7e9906475e0135))
16
+
3
17
  ## [0.20.0](https://github.com/roarkhq/cli-roark-analytics/compare/v0.19.0...v0.20.0) (2026-09-16)
4
18
 
5
19
 
package/README.md CHANGED
@@ -122,6 +122,19 @@ roark completion fish | source
122
122
  | `roark agent prompt version list <agent-id> <prompt-id>` | List a prompt's versions |
123
123
  | `roark agent update <agent-id>` | Update an agent |
124
124
 
125
+ ### autoimprove
126
+
127
+ | Command | Description |
128
+ | -------------------------------------------------------------------------------------------------------------------- | ------------------------------------ |
129
+ | `roark autoimprove fix answer <fix-id> --text <value>` | Answer Roark's question |
130
+ | `roark autoimprove fix cancel <fix-id>` | Cancel a fix |
131
+ | `roark autoimprove fix create --agent-id <value> --objective-metric-definition-id <value> --objective-label <value>` | Start an Autoimprove fix |
132
+ | `roark autoimprove fix dismiss <fix-id>` | Dismiss a verified fix |
133
+ | `roark autoimprove fix get <fix-id>` | Get an Autoimprove fix |
134
+ | `roark autoimprove fix guidance send <fix-id> --text <value>` | Send guidance to a running fix |
135
+ | `roark autoimprove fix list` | List Autoimprove fixes |
136
+ | `roark autoimprove fix promote <fix-id>` | Promote a verified fix to production |
137
+
125
138
  ### benchmark
126
139
 
127
140
  | Command | Description |
package/commands.js CHANGED
@@ -12,6 +12,9 @@ exports.GROUPS = {
12
12
  'agent endpoint': 'Manage agent endpoints',
13
13
  'agent prompt': 'Manage agent prompts',
14
14
  'agent prompt version': 'Read agent prompt versions',
15
+ autoimprove: 'Manage autoimproves',
16
+ 'autoimprove fix': 'Manage autoimprove fixes',
17
+ 'autoimprove fix guidance': 'Read autoimprove fix guidance',
15
18
  benchmark: 'Read benchmarks',
16
19
  'benchmark leaderboard': 'Read benchmark leaderboard',
17
20
  'benchmark metric': 'Read benchmark metrics',
@@ -480,6 +483,274 @@ exports.COMMANDS = [
480
483
  acceptsBody: true,
481
484
  requiresAuth: true,
482
485
  },
486
+ {
487
+ commandPath: ['autoimprove', 'fix', 'answer'],
488
+ clientProperty: 'autoimproveFix',
489
+ methodName: 'answerQuestion',
490
+ httpMethod: 'post',
491
+ httpPath: '/v1/autoimprove/fix/{fixId}/answer',
492
+ summary: "Answer Roark's question",
493
+ description: 'Answer the question a fix is blocked on. Only meaningful while the fix status is NEEDS_INPUT (the open QUESTION entry carries the offered options; free text is also accepted). Otherwise returns a conflict.',
494
+ positionals: [
495
+ {
496
+ name: 'fix-id',
497
+ paramKey: 'fixId',
498
+ },
499
+ ],
500
+ flags: [
501
+ {
502
+ name: 'text',
503
+ path: ['text'],
504
+ location: 'body',
505
+ required: true,
506
+ description: 'The message for Roark.',
507
+ valueKind: 'string',
508
+ repeatable: false,
509
+ },
510
+ ],
511
+ hasParams: true,
512
+ paramsAllOptional: false,
513
+ bodyOpaque: false,
514
+ bodyVariants: [],
515
+ acceptsBody: true,
516
+ requiresAuth: true,
517
+ },
518
+ {
519
+ commandPath: ['autoimprove', 'fix', 'cancel'],
520
+ clientProperty: 'autoimproveFix',
521
+ methodName: 'cancel',
522
+ httpMethod: 'post',
523
+ httpPath: '/v1/autoimprove/fix/{fixId}/cancel',
524
+ summary: 'Cancel a fix',
525
+ description: 'Stop a live fix. Production is never changed by a cancel; everything the fix set up (the shadow agent, its phone number, authored test flows and run plan) is cleaned up automatically.',
526
+ positionals: [
527
+ {
528
+ name: 'fix-id',
529
+ paramKey: 'fixId',
530
+ },
531
+ ],
532
+ flags: [],
533
+ hasParams: false,
534
+ paramsAllOptional: true,
535
+ bodyOpaque: false,
536
+ bodyVariants: [],
537
+ acceptsBody: false,
538
+ requiresAuth: true,
539
+ },
540
+ {
541
+ commandPath: ['autoimprove', 'fix', 'create'],
542
+ clientProperty: 'autoimproveFix',
543
+ methodName: 'create',
544
+ httpMethod: 'post',
545
+ httpPath: '/v1/autoimprove/fix',
546
+ summary: 'Start an Autoimprove fix',
547
+ description: 'Commission Roark on an objective. It clones the agent into a staging shadow (or uses your designated staging agent), authors a validation suite of simulated callers, measures a baseline, changes the staging configuration, and re-tests until the objective metric passes its target. Production is never touched by the loop; a verified fix waits for promotion. Requires an active provider integration (Vapi or Retell) with agent config writes enabled. One live fix per agent: starting a second returns a conflict. The fix runs asynchronously; poll GET /v1/autoimprove/fix/{fixId} or watch it in the dashboard. When its status is NEEDS_INPUT, answer via the answer endpoint; when AWAITING_PROMOTE, promote or dismiss.',
548
+ positionals: [],
549
+ flags: [
550
+ {
551
+ name: 'agent-id',
552
+ path: ['agentId'],
553
+ location: 'body',
554
+ required: true,
555
+ description: 'The production agent to improve. It is never modified until you promote.',
556
+ valueKind: 'string',
557
+ repeatable: false,
558
+ },
559
+ {
560
+ name: 'objective-metric-definition-id',
561
+ path: ['objectiveMetricDefinitionId'],
562
+ location: 'body',
563
+ required: true,
564
+ description: 'The metric that defines success: a pass/fail metric, or a threshold variant of a scale metric (for example "PII Handling >= 4"). Roark measures the pass rate of this metric across simulated calls.',
565
+ valueKind: 'string',
566
+ repeatable: false,
567
+ },
568
+ {
569
+ name: 'objective-label',
570
+ path: ['objectiveLabel'],
571
+ location: 'body',
572
+ required: true,
573
+ description: 'Human-readable label for the objective, shown everywhere the fix appears.',
574
+ valueKind: 'string',
575
+ repeatable: false,
576
+ },
577
+ {
578
+ name: 'target-value',
579
+ path: ['targetValue'],
580
+ location: 'body',
581
+ required: false,
582
+ description: 'The pass-rate percentage that counts as fixed. Defaults to 90.',
583
+ valueKind: 'number',
584
+ repeatable: false,
585
+ },
586
+ {
587
+ name: 'staging-agent-id',
588
+ path: ['stagingAgentId'],
589
+ location: 'body',
590
+ required: false,
591
+ description: 'An existing agent to stage changes on instead of the default shadow clone. Must be a different agent from agentId, on the same provider.',
592
+ valueKind: 'string',
593
+ repeatable: false,
594
+ },
595
+ {
596
+ name: 'customer-integration-id',
597
+ path: ['customerIntegrationId'],
598
+ location: 'body',
599
+ required: false,
600
+ description: "The provider integration whose credentials Roark uses. Omit to use the project's active integration for the agent's provider. The integration must have agent config writes enabled.",
601
+ valueKind: 'string',
602
+ repeatable: false,
603
+ },
604
+ {
605
+ name: 'validation-run-plan-id',
606
+ path: ['validationRunPlanId'],
607
+ location: 'body',
608
+ required: false,
609
+ description: 'An existing simulation run plan to validate with. Omit to let Roark author its own suite.',
610
+ valueKind: 'string',
611
+ repeatable: false,
612
+ },
613
+ {
614
+ name: 'max-iterations',
615
+ path: ['maxIterations'],
616
+ location: 'body',
617
+ required: false,
618
+ description: 'Cap on decision turns. Defaults to 10.',
619
+ valueKind: 'integer',
620
+ repeatable: false,
621
+ },
622
+ {
623
+ name: 'max-sim-calls',
624
+ path: ['maxSimCalls'],
625
+ location: 'body',
626
+ required: false,
627
+ description: 'Cap on simulated calls dialed. Defaults to 200.',
628
+ valueKind: 'integer',
629
+ repeatable: false,
630
+ },
631
+ ],
632
+ hasParams: true,
633
+ paramsAllOptional: false,
634
+ bodyOpaque: false,
635
+ bodyVariants: [],
636
+ acceptsBody: true,
637
+ requiresAuth: true,
638
+ },
639
+ {
640
+ commandPath: ['autoimprove', 'fix', 'dismiss'],
641
+ clientProperty: 'autoimproveFix',
642
+ methodName: 'dismiss',
643
+ httpMethod: 'post',
644
+ httpPath: '/v1/autoimprove/fix/{fixId}/dismiss',
645
+ summary: 'Dismiss a verified fix',
646
+ description: 'Discard a verified fix without promoting: production stays untouched and the staging resources are cleaned up. Only a fix in AWAITING_PROMOTE can be dismissed.',
647
+ positionals: [
648
+ {
649
+ name: 'fix-id',
650
+ paramKey: 'fixId',
651
+ },
652
+ ],
653
+ flags: [],
654
+ hasParams: false,
655
+ paramsAllOptional: true,
656
+ bodyOpaque: false,
657
+ bodyVariants: [],
658
+ acceptsBody: false,
659
+ requiresAuth: true,
660
+ },
661
+ {
662
+ commandPath: ['autoimprove', 'fix', 'get'],
663
+ clientProperty: 'autoimproveFix',
664
+ methodName: 'getByID',
665
+ httpMethod: 'get',
666
+ httpPath: '/v1/autoimprove/fix/{fixId}',
667
+ summary: 'Get an Autoimprove fix',
668
+ description: 'Fetch one fix with its full worklog: every step Roark took, the validation batches with their pass-rate movement, any question it is waiting on, and its final report once concluded.',
669
+ positionals: [
670
+ {
671
+ name: 'fix-id',
672
+ paramKey: 'fixId',
673
+ },
674
+ ],
675
+ flags: [],
676
+ hasParams: false,
677
+ paramsAllOptional: true,
678
+ bodyOpaque: false,
679
+ bodyVariants: [],
680
+ acceptsBody: false,
681
+ requiresAuth: true,
682
+ },
683
+ {
684
+ commandPath: ['autoimprove', 'fix', 'guidance', 'send'],
685
+ clientProperty: 'autoimproveFix',
686
+ methodName: 'sendGuidance',
687
+ httpMethod: 'post',
688
+ httpPath: '/v1/autoimprove/fix/{fixId}/guidance',
689
+ summary: 'Send guidance to a running fix',
690
+ description: 'Steer Roark mid-fix. The message is folded into its next decision and is binding. Accepted while the fix is live (RUNNING, NEEDS_INPUT, or PAUSED); a concluded fix returns a conflict.',
691
+ positionals: [
692
+ {
693
+ name: 'fix-id',
694
+ paramKey: 'fixId',
695
+ },
696
+ ],
697
+ flags: [
698
+ {
699
+ name: 'text',
700
+ path: ['text'],
701
+ location: 'body',
702
+ required: true,
703
+ description: 'The message for Roark.',
704
+ valueKind: 'string',
705
+ repeatable: false,
706
+ },
707
+ ],
708
+ hasParams: true,
709
+ paramsAllOptional: false,
710
+ bodyOpaque: false,
711
+ bodyVariants: [],
712
+ acceptsBody: true,
713
+ requiresAuth: true,
714
+ },
715
+ {
716
+ commandPath: ['autoimprove', 'fix', 'list'],
717
+ clientProperty: 'autoimproveFix',
718
+ methodName: 'list',
719
+ httpMethod: 'get',
720
+ httpPath: '/v1/autoimprove/fix',
721
+ summary: 'List Autoimprove fixes',
722
+ description: 'List the Autoimprove fixes in this project, most recent first, capped at 100. A fix is one autonomous engagement: Roark improving one agent toward one objective metric on a staging copy, with a human-gated promote to production at the end.',
723
+ positionals: [],
724
+ flags: [],
725
+ hasParams: false,
726
+ paramsAllOptional: true,
727
+ bodyOpaque: false,
728
+ bodyVariants: [],
729
+ acceptsBody: false,
730
+ requiresAuth: true,
731
+ },
732
+ {
733
+ commandPath: ['autoimprove', 'fix', 'promote'],
734
+ clientProperty: 'autoimproveFix',
735
+ methodName: 'promote',
736
+ httpMethod: 'post',
737
+ httpPath: '/v1/autoimprove/fix/{fixId}/promote',
738
+ summary: 'Promote a verified fix to production',
739
+ description: 'Apply the verified staging changes to the PRODUCTION agent. Only a fix in AWAITING_PROMOTE can be promoted. A snapshot of the production configuration is taken immediately before the write, so the promote is fully rollbackable. After the promote the staging shadow and its phone number are cleaned up.',
740
+ positionals: [
741
+ {
742
+ name: 'fix-id',
743
+ paramKey: 'fixId',
744
+ },
745
+ ],
746
+ flags: [],
747
+ hasParams: false,
748
+ paramsAllOptional: true,
749
+ bodyOpaque: false,
750
+ bodyVariants: [],
751
+ acceptsBody: false,
752
+ requiresAuth: true,
753
+ },
483
754
  {
484
755
  commandPath: ['benchmark', 'leaderboard', 'get'],
485
756
  clientProperty: 'benchmark',
@@ -3567,11 +3838,21 @@ exports.COMMANDS = [
3567
3838
  path: ['responseTiming'],
3568
3839
  location: 'body',
3569
3840
  required: false,
3570
- description: 'Controls how quickly the persona responds to pauses in conversation (QUICK, NORMAL, RELAXED). BARGE_IN also talks over the agent once it has held the floor for several seconds.',
3841
+ description: 'Deprecated and inert: it no longer affects the call. It set how long the persona waited once the agent stopped talking, and measured across production simulations it moved the reply gap by less than the noise floor, because model and speech latency dominate it. Every persona now uses one voice-activity profile. Use `interruption` for a caller who talks over the agent. Still accepted and stored so existing clients keep working. BARGE_IN is stored as `responseTiming: QUICK` with `interruption: OCCASIONAL`.',
3571
3842
  valueKind: 'string',
3572
3843
  enumValues: ['RELAXED', 'NORMAL', 'QUICK', 'BARGE_IN'],
3573
3844
  repeatable: false,
3574
3845
  },
3846
+ {
3847
+ name: 'interruption',
3848
+ path: ['interruption'],
3849
+ location: 'body',
3850
+ required: false,
3851
+ description: 'How much the persona talks over the agent. Defaults to OFF, a caller that waits its turn.',
3852
+ valueKind: 'string',
3853
+ enumValues: ['OFF', 'BACKCHANNEL', 'OCCASIONAL', 'HEAVY'],
3854
+ repeatable: false,
3855
+ },
3575
3856
  {
3576
3857
  name: 'backstory-prompt',
3577
3858
  path: ['backstoryPrompt'],
@@ -3972,11 +4253,21 @@ exports.COMMANDS = [
3972
4253
  path: ['responseTiming'],
3973
4254
  location: 'body',
3974
4255
  required: false,
3975
- description: 'Controls how quickly the persona responds to pauses in conversation (QUICK, NORMAL, RELAXED). BARGE_IN also talks over the agent once it has held the floor for several seconds.',
4256
+ description: 'Deprecated and inert: it no longer affects the call. It set how long the persona waited once the agent stopped talking, and measured across production simulations it moved the reply gap by less than the noise floor, because model and speech latency dominate it. Every persona now uses one voice-activity profile. Use `interruption` for a caller who talks over the agent. Still accepted and stored so existing clients keep working. BARGE_IN is stored as `responseTiming: QUICK` with `interruption: OCCASIONAL`.',
3976
4257
  valueKind: 'string',
3977
4258
  enumValues: ['RELAXED', 'NORMAL', 'QUICK', 'BARGE_IN'],
3978
4259
  repeatable: false,
3979
4260
  },
4261
+ {
4262
+ name: 'interruption',
4263
+ path: ['interruption'],
4264
+ location: 'body',
4265
+ required: false,
4266
+ description: 'How much the persona talks over the agent while it is still speaking. OFF waits its turn. BACKCHANNEL makes listening noises ("mm-hm") over the agent without taking the floor, which tests whether the agent wrongly stops for them. OCCASIONAL adds cutting in on some long agent turns, HEAVY on most of them. Timing is randomised per turn, so two runs of the same persona do not interrupt at identical moments.',
4267
+ valueKind: 'string',
4268
+ enumValues: ['OFF', 'BACKCHANNEL', 'OCCASIONAL', 'HEAVY'],
4269
+ repeatable: false,
4270
+ },
3980
4271
  {
3981
4272
  name: 'backstory-prompt',
3982
4273
  path: ['backstoryPrompt'],
@@ -4155,7 +4446,7 @@ exports.COMMANDS = [
4155
4446
  path: ['flows'],
4156
4447
  location: 'body',
4157
4448
  required: false,
4158
- description: 'Customer flows to include in this run plan. The same flow can appear more than once with a different persona override or different variables.',
4449
+ description: 'Customer flows to include in this run plan. The same flow can appear more than once with a different persona override, different variables, or different `overrides`: attaching it once per value of one property is how you compare that property without a template.',
4159
4450
  valueKind: 'array',
4160
4451
  repeatable: false,
4161
4452
  },
@@ -4221,6 +4512,7 @@ exports.COMMANDS = [
4221
4512
  'GENDER',
4222
4513
  'INTENT_CLARITY',
4223
4514
  'LANGUAGE',
4515
+ 'INTERRUPTION',
4224
4516
  'MEMORY_RELIABILITY',
4225
4517
  'RESPONSE_TIMING',
4226
4518
  'SPEECH_CLARITY',
@@ -4743,6 +5035,7 @@ exports.COMMANDS = [
4743
5035
  'GENDER',
4744
5036
  'INTENT_CLARITY',
4745
5037
  'LANGUAGE',
5038
+ 'INTERRUPTION',
4746
5039
  'MEMORY_RELIABILITY',
4747
5040
  'RESPONSE_TIMING',
4748
5041
  'SPEECH_CLARITY',