@quantiya/codevibe-core 2.0.1 → 2.0.3
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/__tests__/prompt-parser.test.d.ts +1 -0
- package/dist/adapter/registry.d.ts +69 -2
- package/dist/appsync/__tests__/appsync-client-event-source-filter.test.d.ts +1 -0
- package/dist/appsync/__tests__/appsync-client-task-group.test.d.ts +1 -0
- package/dist/appsync/__tests__/cleanup-subscription.test.d.ts +1 -0
- package/dist/appsync/__tests__/coerce-awsjson-and-review-summary.test.d.ts +1 -0
- package/dist/appsync/__tests__/cp1f-quorum-sdk.test.d.ts +1 -0
- package/dist/appsync/__tests__/event-throttle.test.d.ts +1 -0
- package/dist/appsync/appsync-client.d.ts +621 -10
- package/dist/appsync/event-throttle.d.ts +28 -0
- package/dist/appsync/index.d.ts +3 -0
- package/dist/appsync/queries.d.ts +19 -0
- package/dist/audit-keys/index.d.ts +32 -0
- package/dist/auth/auth-service.d.ts +32 -2
- package/dist/auth/auth-telemetry.d.ts +19 -1
- package/dist/auth/index.d.ts +1 -0
- package/dist/companion-mode/__tests__/detect-parallel.test.d.ts +1 -0
- package/dist/companion-mode/index.d.ts +4 -3
- package/dist/companion-mode/persist-preference.d.ts +1 -1
- package/dist/config/config.d.ts +8 -1
- package/dist/continuation/__tests__/dirty-state-collector.test.d.ts +1 -0
- package/dist/continuation/__tests__/integration.test.d.ts +1 -0
- package/dist/continuation/__tests__/packet-reader.test.d.ts +1 -0
- package/dist/continuation/__tests__/packet-writer.test.d.ts +1 -0
- package/dist/continuation/__tests__/parity.test.d.ts +1 -0
- package/dist/continuation/__tests__/status-cli.test.d.ts +1 -0
- package/dist/continuation/dirty-state-collector.d.ts +46 -0
- package/dist/continuation/index.d.ts +8 -0
- package/dist/continuation/packet-reader.d.ts +33 -0
- package/dist/continuation/packet-writer.d.ts +86 -0
- package/dist/continuation/types.d.ts +239 -0
- package/dist/credential-broker/__tests__/broker.test.d.ts +1 -0
- package/dist/credential-broker/__tests__/canonical.test.d.ts +1 -0
- package/dist/credential-broker/__tests__/scrubber.test.d.ts +1 -0
- package/dist/credential-broker/__tests__/upstream-client.test.d.ts +1 -0
- package/dist/credential-broker/__tests__/vendor-key-store.test.d.ts +1 -0
- package/dist/credential-broker/audit-sink.d.ts +69 -0
- package/dist/credential-broker/broker-config.d.ts +39 -0
- package/dist/credential-broker/broker-token.d.ts +123 -0
- package/dist/credential-broker/broker.d.ts +165 -0
- package/dist/credential-broker/canonical.d.ts +119 -0
- package/dist/credential-broker/index.d.ts +15 -0
- package/dist/credential-broker/scrubber.d.ts +45 -0
- package/dist/credential-broker/types.d.ts +141 -0
- package/dist/credential-broker/upstream-client.d.ts +20 -0
- package/dist/credential-broker/vendor-key-store.d.ts +54 -0
- package/dist/index.d.ts +6 -1
- package/dist/index.js +427 -124
- package/dist/keychain/__tests__/keychain-backend.test.d.ts +1 -0
- package/dist/keychain/keychain-backend.d.ts +82 -0
- package/dist/local-executor/__tests__/agentic-disposable-repo.test.d.ts +1 -0
- package/dist/local-executor/__tests__/agentic-resolve.test.d.ts +1 -0
- package/dist/local-executor/__tests__/agentic-resolver-flag.test.d.ts +1 -0
- package/dist/local-executor/__tests__/class-a-sign.test.d.ts +1 -0
- package/dist/local-executor/__tests__/class1-reconcilers.test.d.ts +1 -0
- package/dist/local-executor/__tests__/class2-resolver.test.d.ts +1 -0
- package/dist/local-executor/__tests__/confined-model-caller.test.d.ts +1 -0
- package/dist/local-executor/__tests__/conflict-classifier.test.d.ts +1 -0
- package/dist/local-executor/__tests__/conflict-resolution-durable-store.test.d.ts +1 -0
- package/dist/local-executor/__tests__/conflict-resolution-store.test.d.ts +1 -0
- package/dist/local-executor/__tests__/cp1f-quorum-consumer.test.d.ts +1 -0
- package/dist/local-executor/__tests__/cp7-audit-writer.test.d.ts +1 -0
- package/dist/local-executor/__tests__/durable-store.test.d.ts +1 -0
- package/dist/local-executor/__tests__/git-lock-retry.test.d.ts +1 -0
- package/dist/local-executor/__tests__/implementor-argv.test.d.ts +1 -0
- package/dist/local-executor/__tests__/local-executor-teams.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-conflict-extract.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-conflict-git.integration.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-conflict-resolve-agentic.integration.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-conflict-resolve.integration.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-journal-store.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-train-agentic-recovery.integration.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-train-w3.integration.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-train-waveb.integration.test.d.ts +1 -0
- package/dist/local-executor/__tests__/merge-train.test.d.ts +1 -0
- package/dist/local-executor/__tests__/promote-wal-store.test.d.ts +1 -0
- package/dist/local-executor/__tests__/revert-reconcile.test.d.ts +1 -0
- package/dist/local-executor/__tests__/revert-runner.test.d.ts +1 -0
- package/dist/local-executor/__tests__/shared-contract-detector.test.d.ts +1 -0
- package/dist/local-executor/__tests__/substrate-engage.test.d.ts +1 -0
- package/dist/local-executor/__tests__/team-execution-flag.test.d.ts +1 -0
- package/dist/local-executor/__tests__/track-registry.test.d.ts +1 -0
- package/dist/local-executor/__tests__/wb2-review-bundle.test.d.ts +1 -0
- package/dist/local-executor/__tests__/wb2-substrate-spawn.live.test.d.ts +1 -0
- package/dist/local-executor/__tests__/workspace-shadow.test.d.ts +1 -0
- package/dist/local-executor/__tests__/worktree-merge.test.d.ts +1 -0
- package/dist/local-executor/agentic-disposable-repo.d.ts +52 -0
- package/dist/local-executor/agentic-resolve.d.ts +54 -0
- package/dist/local-executor/agentic-resolver-flag.d.ts +9 -0
- package/dist/local-executor/authority.d.ts +33 -1
- package/dist/local-executor/class-a-emit.d.ts +3 -1
- package/dist/local-executor/class-a-sign.d.ts +57 -0
- package/dist/local-executor/class-b-consumer.d.ts +159 -4
- package/dist/local-executor/class-b-verify.d.ts +30 -0
- package/dist/local-executor/class1-reconcilers.d.ts +58 -0
- package/dist/local-executor/class2-resolver.d.ts +74 -0
- package/dist/local-executor/confined-model-caller.d.ts +39 -0
- package/dist/local-executor/conflict-classifier.d.ts +21 -0
- package/dist/local-executor/conflict-resolution-durable-store.d.ts +61 -0
- package/dist/local-executor/conflict-resolution-store.d.ts +210 -0
- package/dist/local-executor/conflict-types.d.ts +86 -0
- package/dist/local-executor/cp7-audit-writer.d.ts +152 -0
- package/dist/local-executor/durable-store.d.ts +334 -0
- package/dist/local-executor/git-lock-retry.d.ts +40 -0
- package/dist/local-executor/hook-bridge.d.ts +1 -1
- package/dist/local-executor/implementor-argv.d.ts +183 -0
- package/dist/local-executor/index.d.ts +44 -3
- package/dist/local-executor/local-executor-impl.d.ts +645 -4
- package/dist/local-executor/merge-conflict-extract.d.ts +34 -0
- package/dist/local-executor/merge-conflict-resolve.d.ts +101 -0
- package/dist/local-executor/merge-journal-store.d.ts +311 -0
- package/dist/local-executor/merge-train.d.ts +713 -0
- package/dist/local-executor/promote-wal-store.d.ts +301 -0
- package/dist/local-executor/resolution-set-index.d.ts +51 -0
- package/dist/local-executor/revert-reconcile.d.ts +89 -0
- package/dist/local-executor/revert-runner.d.ts +17 -0
- package/dist/local-executor/shared-contract-detector.d.ts +57 -0
- package/dist/local-executor/spawn.d.ts +29 -1
- package/dist/local-executor/task-group-types.d.ts +346 -0
- package/dist/local-executor/team-execution-flag.d.ts +21 -0
- package/dist/local-executor/track-registry.d.ts +50 -0
- package/dist/local-executor/types.d.ts +238 -4
- package/dist/local-executor/wb2-review-bundle.d.ts +59 -0
- package/dist/local-executor/workspace-shadow.d.ts +290 -0
- package/dist/local-executor/worktree-merge.d.ts +601 -0
- package/dist/local-model/__tests__/installer.test.d.ts +1 -0
- package/dist/local-model/__tests__/manager.test.d.ts +1 -0
- package/dist/local-model/__tests__/ollama.test.d.ts +1 -0
- package/dist/local-model/__tests__/runtime.test.d.ts +1 -0
- package/dist/local-model/__tests__/state.test.d.ts +1 -0
- package/dist/local-model/manager.d.ts +119 -0
- package/dist/local-model/ollama.d.ts +27 -0
- package/dist/local-model/runtime.d.ts +27 -0
- package/dist/local-model/state.d.ts +32 -0
- package/dist/orchestration/detect-agents.d.ts +15 -2
- package/dist/orchestration/setup-types.d.ts +2 -1
- package/dist/orchestration-shell/__tests__/attachments.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/audit-browser.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/audited-path-fixes.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/bracketed-paste.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cli-group-halt-wiring.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cli-orchestration-session-bootstrap.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cli-probe-group-status.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cli-quorum-loop-tier.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cli-verdict-classifier-wiring.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/context-store.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp10-585-accept-echo-target.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp10-585-loop.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp10-585-prompts.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp12-w2b-team-loop.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp12-w4-team-recovery.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp1f-quorum-loop.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp606-team-track-user-resolved.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/cp7-reviewer-substrate.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/declared-test-runner.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/familiarize-routing.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/gate-decision-submit.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/gate-details-panel.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/gate-verdict-details-dispatch.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/group-decision-submit.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/image-attach-e2e.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/input-bar-autocomplete.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/live-region-cap.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/live-static-order.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/model-cli.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/non-gate-prompt-routing.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/orchestration-app-group-decision-transport.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/orchestration-app-layout.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/reissue-team-retained-spec.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/review-summary-render.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/reviewer-wizard.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/reviewers-format.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/root-discovery.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/serialize-submissions.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/slash-suggest.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/status-format.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/task-progress.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/team-decompose-routing.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/team-decompose-types.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/team-decompose.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/team-e2e-smoke.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/tier2-reviewer-selection.test.d.ts +1 -0
- package/dist/orchestration-shell/__tests__/web-browsing.test.d.ts +1 -0
- package/dist/orchestration-shell/attachments.d.ts +152 -0
- package/dist/orchestration-shell/audit-browser.d.ts +115 -0
- package/dist/orchestration-shell/audit-runner.d.ts +59 -0
- package/dist/orchestration-shell/bracketed-paste.d.ts +26 -0
- package/dist/orchestration-shell/cli.d.ts +336 -1
- package/dist/orchestration-shell/cli.js +40580 -4692
- package/dist/orchestration-shell/components/AuditLogPanel.d.ts +11 -0
- package/dist/orchestration-shell/components/ConversationPane.d.ts +7 -1
- package/dist/orchestration-shell/components/GateDetailsPanel.d.ts +57 -0
- package/dist/orchestration-shell/components/GatePanelEntry.d.ts +9 -0
- package/dist/orchestration-shell/components/GatePromptEntry.d.ts +7 -0
- package/dist/orchestration-shell/components/InputBar.d.ts +17 -3
- package/dist/orchestration-shell/components/LiveProgressLine.d.ts +8 -0
- package/dist/orchestration-shell/components/MultiTrackStatusNode.d.ts +8 -0
- package/dist/orchestration-shell/components/OrchestrationApp.d.ts +81 -15
- package/dist/orchestration-shell/components/ReviewerSetupWizard.d.ts +24 -0
- package/dist/orchestration-shell/components/StatusBar.d.ts +15 -2
- package/dist/orchestration-shell/context-store.d.ts +389 -0
- package/dist/orchestration-shell/declared-test-runner.d.ts +84 -0
- package/dist/orchestration-shell/emit-shell-event.d.ts +1 -1
- package/dist/orchestration-shell/gate-decision-submit.d.ts +245 -0
- package/dist/orchestration-shell/gate-prompts.d.ts +361 -3
- package/dist/orchestration-shell/index.d.ts +613 -1
- package/dist/orchestration-shell/ink-runtime.d.ts +21 -1
- package/dist/orchestration-shell/live-region-cap.d.ts +70 -0
- package/dist/orchestration-shell/live-static-order.d.ts +22 -0
- package/dist/orchestration-shell/non-tty-fallback.d.ts +21 -0
- package/dist/orchestration-shell/quorum-loop.d.ts +1900 -0
- package/dist/orchestration-shell/root-discovery.d.ts +25 -0
- package/dist/orchestration-shell/route-browse.d.ts +20 -0
- package/dist/orchestration-shell/slash-router.d.ts +20 -1
- package/dist/orchestration-shell/slash-routes/continuation.d.ts +71 -0
- package/dist/orchestration-shell/slash-routes/reviewers.d.ts +41 -0
- package/dist/orchestration-shell/slash-suggest.d.ts +29 -0
- package/dist/orchestration-shell/status-format.d.ts +59 -0
- package/dist/orchestration-shell/task-progress.d.ts +122 -0
- package/dist/orchestration-shell/team-decompose.d.ts +196 -0
- package/dist/orchestration-shell/types.d.ts +363 -3
- package/dist/orchestration-shell/vendor/ink-parse-keypress.d.ts +42 -0
- package/dist/orchestration-shell/web/extract.d.ts +11 -0
- package/dist/orchestration-shell/web/fetch.d.ts +15 -0
- package/dist/orchestration-shell/web/ip.d.ts +26 -0
- package/dist/orchestration-shell/web/sanitize.d.ts +14 -0
- package/dist/orchestration-shell/web/search.d.ts +16 -0
- package/dist/planner/__tests__/local-gemma.test.d.ts +1 -0
- package/dist/planner/index.d.ts +2 -0
- package/dist/planner/local-advisory.d.ts +84 -0
- package/dist/planner/local-gemma.d.ts +23 -0
- package/dist/planner/types.d.ts +16 -6
- package/dist/reviewer/__tests__/antigravity-provider.test.d.ts +1 -0
- package/dist/reviewer/__tests__/claude-provider-json.test.d.ts +1 -0
- package/dist/reviewer/__tests__/cp7-reviewer-sandbox.test.d.ts +1 -0
- package/dist/reviewer/__tests__/output-parser-classifier-helpers.test.d.ts +1 -0
- package/dist/reviewer/__tests__/verdict-classifier.test.d.ts +1 -0
- package/dist/reviewer/index.d.ts +2 -0
- package/dist/reviewer/output-parser.d.ts +48 -12
- package/dist/reviewer/provider.d.ts +107 -3
- package/dist/reviewer/providers/__tests__/failure-classifier.test.d.ts +1 -0
- package/dist/reviewer/providers/antigravity.d.ts +49 -0
- package/dist/reviewer/providers/claude.d.ts +19 -4
- package/dist/reviewer/providers/codex.d.ts +47 -5
- package/dist/reviewer/providers/failure-classifier.d.ts +26 -0
- package/dist/reviewer/providers/gemini.d.ts +5 -4
- package/dist/reviewer/registry.d.ts +5 -5
- package/dist/reviewer/subprocess.d.ts +37 -0
- package/dist/reviewer/token-usage.d.ts +32 -0
- package/dist/reviewer/types.d.ts +5 -5
- package/dist/reviewer/verdict-classifier.d.ts +62 -0
- package/dist/session/__tests__/prepare-event-timestamp.test.d.ts +1 -0
- package/dist/session/index.d.ts +1 -0
- package/dist/session/prepare-event-timestamp.d.ts +30 -0
- package/dist/substrate/__tests__/docker.test.d.ts +1 -0
- package/dist/substrate/__tests__/forwarder.test.d.ts +1 -0
- package/dist/substrate/__tests__/git-proxy.test.d.ts +1 -0
- package/dist/substrate/__tests__/sandbox-exec.test.d.ts +1 -0
- package/dist/substrate/__tests__/substrate-e2e.integration.test.d.ts +1 -0
- package/dist/substrate/command-runner.d.ts +19 -0
- package/dist/substrate/docker.d.ts +134 -0
- package/dist/substrate/errors.d.ts +33 -0
- package/dist/substrate/forwarder.d.ts +67 -0
- package/dist/substrate/git-proxy.d.ts +35 -0
- package/dist/substrate/index.d.ts +12 -0
- package/dist/substrate/relay-script.d.ts +27 -0
- package/dist/substrate/sandbox-exec.d.ts +116 -0
- package/dist/substrate/types.d.ts +218 -0
- package/dist/substrate-launch/__tests__/apikey-bootstrap.test.d.ts +1 -0
- package/dist/substrate-launch/__tests__/creditless-loop.integration.test.d.ts +1 -0
- package/dist/substrate-launch/__tests__/engage-substrate.test.d.ts +1 -0
- package/dist/substrate-launch/__tests__/fallback-ladder.test.d.ts +1 -0
- package/dist/substrate-launch/__tests__/le-env-scrub.test.d.ts +1 -0
- package/dist/substrate-launch/__tests__/sanitized-env.test.d.ts +1 -0
- package/dist/substrate-launch/apikey-bootstrap.d.ts +84 -0
- package/dist/substrate-launch/engage-substrate.d.ts +102 -0
- package/dist/substrate-launch/fallback-ladder.d.ts +49 -0
- package/dist/substrate-launch/index.d.ts +12 -0
- package/dist/substrate-launch/le-env-scrub.d.ts +77 -0
- package/dist/substrate-launch/sanitized-env.d.ts +73 -0
- package/dist/types/auth.d.ts +6 -1
- package/dist/types/events.d.ts +3 -1
- package/dist/types/reviewer.d.ts +6 -6
- package/package.json +7 -3
|
@@ -9,11 +9,23 @@ interface InkExports {
|
|
|
9
9
|
useApp: () => {
|
|
10
10
|
exit: (err?: Error) => void;
|
|
11
11
|
};
|
|
12
|
-
useInput: (handler: (input: string, key: any) => void
|
|
12
|
+
useInput: (handler: (input: string, key: any) => void, options?: {
|
|
13
|
+
isActive?: boolean;
|
|
14
|
+
}) => void;
|
|
13
15
|
useStdin: () => {
|
|
14
16
|
stdin: any;
|
|
15
17
|
setRawMode: (raw: boolean) => void;
|
|
16
18
|
isRawModeSupported: boolean;
|
|
19
|
+
internal_eventEmitter?: import('node:events').EventEmitter;
|
|
20
|
+
};
|
|
21
|
+
useStdout: () => {
|
|
22
|
+
stdout: {
|
|
23
|
+
columns?: number;
|
|
24
|
+
rows?: number;
|
|
25
|
+
isTTY?: boolean;
|
|
26
|
+
writable?: boolean;
|
|
27
|
+
write?: (s: string) => unknown;
|
|
28
|
+
};
|
|
17
29
|
};
|
|
18
30
|
}
|
|
19
31
|
interface InkTextInputExports {
|
|
@@ -44,6 +56,14 @@ export declare function __setEsmLoaderForTest(loader: <T>(name: string) => Promi
|
|
|
44
56
|
* Resets the ESM loader to the production default.
|
|
45
57
|
*/
|
|
46
58
|
export declare function __resetEsmLoaderForTest(): void;
|
|
59
|
+
/**
|
|
60
|
+
* Generic ESM-only module loader, routed through the same test seam as the ink
|
|
61
|
+
* runtime so a single audited site bypasses TS's `module: commonjs` import→require
|
|
62
|
+
* rewrite (see the trampoline comment above). Exported so other CJS modules that need
|
|
63
|
+
* an ESM-only dependency (e.g. `parse5` in `web/extract.ts`) load it the same way and
|
|
64
|
+
* honor `__setEsmLoaderForTest`/`__resetEsmLoaderForTest`.
|
|
65
|
+
*/
|
|
66
|
+
export declare function loadEsm<T>(name: string): Promise<T>;
|
|
47
67
|
/**
|
|
48
68
|
* Loads the ESM-only ink packages. Idempotent — second call returns
|
|
49
69
|
* the cached runtime. Throws if any package fails to load.
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { ConversationEntry } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* DEFAULT rows reserved below the live `<ConversationPane>` for the rest of the
|
|
4
|
+
* chrome: the spinner line (1) + the input bar (~2) + the status bar (1) + the
|
|
5
|
+
* multi-track status node (~3) + a margin. Conservative on purpose — better to
|
|
6
|
+
* keep the live region a row or two shorter than the terminal than to risk the
|
|
7
|
+
* `outputHeight >= rows` reprint path.
|
|
8
|
+
*
|
|
9
|
+
* This is the FALLBACK for callers that don't pass a precise reserve.
|
|
10
|
+
* `<OrchestrationApp>` passes an EXACT reserve via `capLiveEntries(…, reserved)`,
|
|
11
|
+
* growing it by the bordered `MultiTrackStatusNode`'s real footprint when a team
|
|
12
|
+
* is mounted (Stage-1 r1 LOW: a 2-track bordered node is ~6 rows, exceeding the
|
|
13
|
+
* static ~3 budgeted here) — see `OrchestrationApp.tsx`.
|
|
14
|
+
*/
|
|
15
|
+
export declare const RESERVED_ROWS = 8;
|
|
16
|
+
/** Floor on the live-region budget so a very short terminal still shows
|
|
17
|
+
* something (and the active gate control is never starved). */
|
|
18
|
+
export declare const MIN_LIVE_ROWS = 6;
|
|
19
|
+
/**
|
|
20
|
+
* Conservative per-entry rendered-line estimate. Over-estimating is safe (keeps
|
|
21
|
+
* the live region shorter); under-estimating risks the reprint path, so these
|
|
22
|
+
* lean high.
|
|
23
|
+
* - `gate-prompt` → [#469 gate-pin] the bordered PINNED gate card.
|
|
24
|
+
* `GatePromptEntry` truncates each option's server
|
|
25
|
+
* description to the render width, so every option
|
|
26
|
+
* renders on EXACTLY one row — this is therefore an
|
|
27
|
+
* EXACT height, not a heuristic: round border (2) +
|
|
28
|
+
* header (1) + status (1) + one row per option while
|
|
29
|
+
* unresolved + a queue row (if buffered) + the
|
|
30
|
+
* reply-hint row while awaiting a number. Resolved:
|
|
31
|
+
* options + hint drop (the record migrates to
|
|
32
|
+
* <Static>) → border(2) + header + status = 4 (+ a
|
|
33
|
+
* queue row if buffered). NB header/status/hint are
|
|
34
|
+
* short fixed-vocab strings (the header's variable
|
|
35
|
+
* halt-reason is itself truncated to fit) → 1 row on
|
|
36
|
+
* any terminal ≳ ~50 cols; on a narrower terminal the
|
|
37
|
+
* gate is still force-kept (the documented overflow
|
|
38
|
+
* exception — #469's "can't guarantee width" stance).
|
|
39
|
+
* - `reviewer-status-node`→ 2 + one row per seat
|
|
40
|
+
* - `gate-status-node` → 3
|
|
41
|
+
* - `gate-panel` → never appears here (it is final → <Static>)
|
|
42
|
+
* - default → 2
|
|
43
|
+
*/
|
|
44
|
+
export declare function estimateEntryLines(entry: ConversationEntry): number;
|
|
45
|
+
export interface CapLiveEntriesResult {
|
|
46
|
+
/** The kept entries, in their ORIGINAL order. */
|
|
47
|
+
rendered: ConversationEntry[];
|
|
48
|
+
/** How many entries were dropped off the head (oldest) to fit the budget. */
|
|
49
|
+
hiddenCount: number;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Cap the live entries so the live `<ConversationPane>` never makes Ink's
|
|
53
|
+
* dynamic `outputHeight >= terminalRows`.
|
|
54
|
+
*
|
|
55
|
+
* Algorithm:
|
|
56
|
+
* budget = max(terminalRows - reservedRows, MIN_LIVE_ROWS)
|
|
57
|
+
* Walk from the TAIL, summing `estimateEntryLines`; keep an entry while the
|
|
58
|
+
* running sum ≤ budget; stop at the first entry that would exceed it. Return
|
|
59
|
+
* the kept entries in original order + the dropped count.
|
|
60
|
+
*
|
|
61
|
+
* `reservedRows` defaults to {@link RESERVED_ROWS}; the caller SHOULD pass the
|
|
62
|
+
* exact below-pane chrome height (the precise reserve grows with the mounted
|
|
63
|
+
* MultiTrackStatusNode when a team is active — see `OrchestrationApp.tsx`).
|
|
64
|
+
*
|
|
65
|
+
* INVARIANT: the tail-most `kind:'gate-prompt'` entry (the active control) is
|
|
66
|
+
* ALWAYS kept, even if it alone exceeds the budget — it is the user's only way
|
|
67
|
+
* to resolve the gate. If it sits below the tail-budget cut, it is force-kept
|
|
68
|
+
* and counted as kept (NOT hidden).
|
|
69
|
+
*/
|
|
70
|
+
export declare function capLiveEntries(entries: ConversationEntry[], terminalRows: number, reservedRows?: number): CapLiveEntriesResult;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ConversationEntry } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Append-only accumulator of finalized static items, in finalization order.
|
|
4
|
+
* `ids` is the membership guard; `items` is the append-only, never-shrinking
|
|
5
|
+
* array handed (after the logo) to `<Static>`. Generic over the rendered item
|
|
6
|
+
* type so this module stays React-free.
|
|
7
|
+
*/
|
|
8
|
+
export interface StaticOrderAccum<T> {
|
|
9
|
+
readonly ids: Set<string>;
|
|
10
|
+
readonly items: T[];
|
|
11
|
+
}
|
|
12
|
+
/** Fresh empty accumulator (call once; persist across renders via a ref). */
|
|
13
|
+
export declare function makeStaticOrderAccum<T>(): StaticOrderAccum<T>;
|
|
14
|
+
/**
|
|
15
|
+
* For each entry that is `final` and not yet recorded, BUILD its item ONCE (the
|
|
16
|
+
* entry is guaranteed present THIS call) and append it — in conversation order
|
|
17
|
+
* among the new ones, which equals finalization order. Idempotent: an id already
|
|
18
|
+
* recorded is skipped, so repeat calls never duplicate, reorder, or shrink
|
|
19
|
+
* `items`. `items` is owned here and is independent of any later trimming of
|
|
20
|
+
* `conversation`.
|
|
21
|
+
*/
|
|
22
|
+
export declare function appendNewlyFinal<T>(accum: StaticOrderAccum<T>, conversation: ReadonlyArray<ConversationEntry>, build: (entry: ConversationEntry) => T): void;
|
|
@@ -16,6 +16,18 @@ export interface RunLineLogFallbackArgs {
|
|
|
16
16
|
output?: NodeJS.WritableStream;
|
|
17
17
|
/** Optional onUserInput handler (host wires this to the slash router / planner classifier). */
|
|
18
18
|
onUserInput?: (text: string) => Promise<void> | void;
|
|
19
|
+
/**
|
|
20
|
+
* Audited-path fix (Fix 8) — gate-resolution interceptor. When an unresolved
|
|
21
|
+
* gate-prompt is active, a typed line that resolves it MUST go through the
|
|
22
|
+
* SAME decision-submit path the TTY uses, NOT the planner. The host wires this
|
|
23
|
+
* to `routeGatePromptInput` (the shared module). It is called BEFORE
|
|
24
|
+
* `onUserInput`; when it returns `{ handled: true }` the line was consumed by
|
|
25
|
+
* gate resolution and is NOT forwarded to the planner. ABSENT (CP-1.a callers /
|
|
26
|
+
* non-loop sessions) → every line goes to `onUserInput` (legacy behavior).
|
|
27
|
+
*/
|
|
28
|
+
resolveGateInput?: (text: string) => Promise<{
|
|
29
|
+
handled: boolean;
|
|
30
|
+
}>;
|
|
19
31
|
/**
|
|
20
32
|
* CP-1.b IMPL r4 H-3 — Optional abort signal so the surrounding
|
|
21
33
|
* shell can break the readline loop on SIGINT/SIGTERM. Aborting
|
|
@@ -23,6 +35,15 @@ export interface RunLineLogFallbackArgs {
|
|
|
23
35
|
*/
|
|
24
36
|
signal?: AbortSignal;
|
|
25
37
|
}
|
|
38
|
+
/**
|
|
39
|
+
* Whether the internal planner-classification entry (`[planner] <action>:
|
|
40
|
+
* <rationale>` / the TTY "Planner classified …" node) is shown to the user.
|
|
41
|
+
* OFF by default — it's internal mechanics that duplicate the actual response /
|
|
42
|
+
* clarification the user already sees, and leaks taxonomy jargon ("classify").
|
|
43
|
+
* Opt in with `CODEVIBE_PLANNER_DEBUG=1` when debugging the planner. The entry is
|
|
44
|
+
* ALWAYS kept in conversation state (audit / logic / tests) — only the VIEW is gated.
|
|
45
|
+
*/
|
|
46
|
+
export declare function plannerDecisionRenderEnabled(env?: NodeJS.ProcessEnv): boolean;
|
|
26
47
|
/**
|
|
27
48
|
* Renders a single `ConversationEntry` as a line-prefixed text string.
|
|
28
49
|
* Strict text only — no ANSI escapes, no colors, no `\r` rewrites.
|