erosolar-cli 1.7.13 → 1.7.15

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 (65) hide show
  1. package/dist/core/responseVerifier.d.ts +79 -0
  2. package/dist/core/responseVerifier.d.ts.map +1 -0
  3. package/dist/core/responseVerifier.js +443 -0
  4. package/dist/core/responseVerifier.js.map +1 -0
  5. package/dist/shell/interactiveShell.d.ts +5 -0
  6. package/dist/shell/interactiveShell.d.ts.map +1 -1
  7. package/dist/shell/interactiveShell.js +45 -14
  8. package/dist/shell/interactiveShell.js.map +1 -1
  9. package/dist/ui/ShellUIAdapter.d.ts +3 -0
  10. package/dist/ui/ShellUIAdapter.d.ts.map +1 -1
  11. package/dist/ui/ShellUIAdapter.js +4 -10
  12. package/dist/ui/ShellUIAdapter.js.map +1 -1
  13. package/dist/ui/display.d.ts +15 -0
  14. package/dist/ui/display.d.ts.map +1 -1
  15. package/dist/ui/display.js +57 -0
  16. package/dist/ui/display.js.map +1 -1
  17. package/dist/ui/persistentPrompt.d.ts +4 -0
  18. package/dist/ui/persistentPrompt.d.ts.map +1 -1
  19. package/dist/ui/persistentPrompt.js +10 -11
  20. package/dist/ui/persistentPrompt.js.map +1 -1
  21. package/package.json +1 -1
  22. package/dist/bin/core/agent.js +0 -362
  23. package/dist/bin/core/agentProfileManifest.js +0 -187
  24. package/dist/bin/core/agentProfiles.js +0 -34
  25. package/dist/bin/core/agentRulebook.js +0 -135
  26. package/dist/bin/core/agentSchemaLoader.js +0 -233
  27. package/dist/bin/core/contextManager.js +0 -412
  28. package/dist/bin/core/contextWindow.js +0 -122
  29. package/dist/bin/core/customCommands.js +0 -80
  30. package/dist/bin/core/errors/apiKeyErrors.js +0 -114
  31. package/dist/bin/core/errors/errorTypes.js +0 -340
  32. package/dist/bin/core/errors/safetyValidator.js +0 -304
  33. package/dist/bin/core/errors.js +0 -32
  34. package/dist/bin/core/modelDiscovery.js +0 -755
  35. package/dist/bin/core/preferences.js +0 -224
  36. package/dist/bin/core/schemaValidator.js +0 -92
  37. package/dist/bin/core/secretStore.js +0 -199
  38. package/dist/bin/core/sessionStore.js +0 -187
  39. package/dist/bin/core/toolRuntime.js +0 -290
  40. package/dist/bin/core/types.js +0 -1
  41. package/dist/bin/shell/bracketedPasteManager.js +0 -350
  42. package/dist/bin/shell/fileChangeTracker.js +0 -65
  43. package/dist/bin/shell/interactiveShell.js +0 -2908
  44. package/dist/bin/shell/liveStatus.js +0 -78
  45. package/dist/bin/shell/shellApp.js +0 -290
  46. package/dist/bin/shell/systemPrompt.js +0 -60
  47. package/dist/bin/shell/updateManager.js +0 -108
  48. package/dist/bin/ui/ShellUIAdapter.js +0 -459
  49. package/dist/bin/ui/UnifiedUIController.js +0 -183
  50. package/dist/bin/ui/animation/AnimationScheduler.js +0 -430
  51. package/dist/bin/ui/codeHighlighter.js +0 -854
  52. package/dist/bin/ui/designSystem.js +0 -121
  53. package/dist/bin/ui/display.js +0 -1222
  54. package/dist/bin/ui/interrupts/InterruptManager.js +0 -437
  55. package/dist/bin/ui/layout.js +0 -139
  56. package/dist/bin/ui/orchestration/StatusOrchestrator.js +0 -403
  57. package/dist/bin/ui/outputMode.js +0 -38
  58. package/dist/bin/ui/persistentPrompt.js +0 -183
  59. package/dist/bin/ui/richText.js +0 -338
  60. package/dist/bin/ui/shortcutsHelp.js +0 -87
  61. package/dist/bin/ui/telemetry/UITelemetry.js +0 -443
  62. package/dist/bin/ui/textHighlighter.js +0 -210
  63. package/dist/bin/ui/theme.js +0 -116
  64. package/dist/bin/ui/toolDisplay.js +0 -423
  65. package/dist/bin/ui/toolDisplayAdapter.js +0 -357
@@ -24,6 +24,7 @@ import { PersistentPrompt, PinnedChatBox } from '../ui/persistentPrompt.js';
24
24
  import { formatShortcutsHelp } from '../ui/shortcutsHelp.js';
25
25
  import { MetricsTracker } from '../alpha-zero/index.js';
26
26
  import { listAvailablePlugins } from '../plugins/index.js';
27
+ import { verifyResponse, formatVerificationReport, } from '../core/responseVerifier.js';
27
28
  const DROPDOWN_COLORS = [
28
29
  theme.primary,
29
30
  theme.info,
@@ -110,6 +111,7 @@ export class InteractiveShell {
110
111
  sessionStartTime = Date.now();
111
112
  activeSessionTitle = null;
112
113
  sessionResumeNotice = null;
114
+ lastAssistantResponse = null;
113
115
  customCommands;
114
116
  customCommandMap;
115
117
  sessionRestoreConfig;
@@ -170,19 +172,11 @@ export class InteractiveShell {
170
172
  // Update persistent prompt status bar with file changes
171
173
  this.updatePersistentPromptFileChanges();
172
174
  });
173
- // Set up tool status callback to update pinned chat box during tool execution
174
- // Note: We only update the status message but DON'T render during streaming
175
- // The status box would keep appending lines otherwise
175
+ // Set up tool status callback to update streaming status line during tool execution
176
+ // Uses Claude Code style: single line at bottom that updates in-place
176
177
  this.uiAdapter.setToolStatusCallback((status) => {
177
- if (status) {
178
- this.pinnedChatBox.setStatusMessage(status);
179
- }
180
- else {
181
- // Clear status but keep processing indicator if still processing
182
- this.pinnedChatBox.setStatusMessage(null);
183
- }
184
- // Don't call forceRender() - let streaming content flow naturally
185
- // Status will be shown when processing completes
178
+ // Update the streaming status line (Claude Code style)
179
+ display.updateStreamingStatus(status);
186
180
  });
187
181
  this.skillRepository = new SkillRepository({
188
182
  workingDir: this.workingDir,
@@ -1193,6 +1187,9 @@ export class InteractiveShell {
1193
1187
  case '/discover':
1194
1188
  await this.discoverModelsCommand();
1195
1189
  break;
1190
+ case '/verify':
1191
+ await this.handleVerifyCommand();
1192
+ break;
1196
1193
  default:
1197
1194
  if (!(await this.tryCustomSlashCommand(command, input))) {
1198
1195
  display.showWarning(`Unknown command "${command}".`);
@@ -1543,6 +1540,37 @@ export class InteractiveShell {
1543
1540
  const summary = this.alphaZeroMetrics.getPerformanceSummary();
1544
1541
  display.showSystemMessage(summary);
1545
1542
  }
1543
+ /**
1544
+ * Handle /verify command - verify the last assistant response
1545
+ */
1546
+ async handleVerifyCommand() {
1547
+ if (!this.lastAssistantResponse) {
1548
+ display.showWarning('No assistant response to verify. Send a message first.');
1549
+ return;
1550
+ }
1551
+ display.showSystemMessage('Verifying last response...\n');
1552
+ try {
1553
+ const report = await verifyResponse(this.lastAssistantResponse);
1554
+ const formattedReport = formatVerificationReport(report);
1555
+ display.showSystemMessage(formattedReport);
1556
+ // Show actionable summary
1557
+ if (report.overallVerdict === 'contradicted') {
1558
+ display.showError('Some claims in the response could not be verified!');
1559
+ }
1560
+ else if (report.overallVerdict === 'verified') {
1561
+ display.showInfo('All verifiable claims in the response were verified.');
1562
+ }
1563
+ else if (report.overallVerdict === 'partially_verified') {
1564
+ display.showWarning('Some claims were verified, but not all.');
1565
+ }
1566
+ else {
1567
+ display.showInfo('No verifiable claims found in the response.');
1568
+ }
1569
+ }
1570
+ catch (err) {
1571
+ display.showError(`Verification failed: ${err instanceof Error ? err.message : 'Unknown error'}`);
1572
+ }
1573
+ }
1546
1574
  showImprovementSuggestions() {
1547
1575
  const suggestions = this.alphaZeroMetrics.getImprovementSuggestions();
1548
1576
  if (suggestions.length === 0) {
@@ -2528,10 +2556,11 @@ What's the next action?`;
2528
2556
  // Clear the processing status and ensure persistent prompt is visible
2529
2557
  this.persistentPrompt.updateStatusBar({ message: undefined });
2530
2558
  this.persistentPrompt.show();
2531
- // Update pinned chat box to show ready state and force render
2559
+ // Clear streaming status line (Claude Code style)
2560
+ display.clearStreamingStatus();
2561
+ // Update pinned chat box to show ready state
2532
2562
  this.pinnedChatBox.setProcessing(false);
2533
2563
  this.pinnedChatBox.setStatusMessage(null);
2534
- this.pinnedChatBox.forceRender();
2535
2564
  // CRITICAL: Ensure readline prompt is active for user input
2536
2565
  // This is a safety net in case the caller doesn't call rl.prompt()
2537
2566
  this.rl.prompt();
@@ -2730,6 +2759,8 @@ What's the next action?`;
2730
2759
  if (finalContent) {
2731
2760
  display.showAssistantMessage(finalContent, enriched);
2732
2761
  }
2762
+ // Store last response for verification
2763
+ this.lastAssistantResponse = content;
2733
2764
  // Show status line at end (Claude Code style: "Session 5m • Context X% used • Ready for prompts (2s)")
2734
2765
  display.stopThinking();
2735
2766
  // Calculate context usage and session time