@buildaharness/aielia 0.3.8 → 0.3.9
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/README.md +6 -3
- package/dist/action-approval-service.d.ts +2 -0
- package/dist/ask-draft.d.ts +22 -0
- package/dist/assistant-options.d.ts +35 -0
- package/dist/assistant-session.d.ts +1 -1
- package/dist/{bin-DETwedpj.js → bin-CCwDFxDe.js} +118 -247
- package/dist/bin-CCwDFxDe.js.map +1 -0
- package/dist/cli-config.d.ts +2 -2
- package/dist/cli-session.d.ts +2 -1
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +1 -1
- package/dist/commands.d.ts +32 -0
- package/dist/config-keys.d.ts +43 -0
- package/dist/doctor-checks.d.ts +1 -2
- package/dist/fact-extraction.d.ts +4 -0
- package/dist/goal-graph-store.d.ts +6 -0
- package/dist/index.d.ts +17 -2
- package/dist/index.js +199 -148
- package/dist/index.js.map +1 -1
- package/dist/llm-client-factory.d.ts +13 -0
- package/dist/memory-service.d.ts +2 -0
- package/dist/model-pricing.d.ts +12 -9
- package/dist/node-display-names.d.ts +1 -1
- package/dist/project-command.d.ts +16 -0
- package/dist/{provider-setup-wX2IBw2X.js → provider-setup-Cy9dwqrd.js} +13504 -13034
- package/dist/provider-setup-Cy9dwqrd.js.map +1 -0
- package/dist/proxy-health.d.ts +8 -0
- package/dist/redact-url.d.ts +2 -0
- package/dist/reply-audit.d.ts +2 -0
- package/dist/response-service.d.ts +10 -0
- package/dist/run-explain.d.ts +58 -0
- package/dist/{tui-app-CcxiwZyM.js → tui-app-Dt72u8vZ.js} +3 -3
- package/dist/{tui-app-CcxiwZyM.js.map → tui-app-Dt72u8vZ.js.map} +1 -1
- package/dist/turn-cost.d.ts +12 -0
- package/dist/turn-presentation.d.ts +86 -0
- package/dist/undo-action-command.d.ts +12 -0
- package/dist/undo-plan.d.ts +13 -0
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
- package/dist/bin-DETwedpj.js.map +0 -1
- package/dist/provider-setup-wX2IBw2X.js.map +0 -1
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { DoctorCheck } from './cli-session.js';
|
|
2
|
+
/**
|
|
3
|
+
* GET <proxyUrl>/health, expecting {status:'ok'} (see packages/proxy/src/index.ts), hard-timed so a dead proxy
|
|
4
|
+
* cannot hang /doctor or Settings. Shared by the CLI's /doctor and the apps' Settings diagnostics. Credentials in
|
|
5
|
+
* the URL (user:password, query values) are masked in the label. Only fetch and AbortController, so it is
|
|
6
|
+
* browser-safe; the desktop app can pass Tauri's fetch.
|
|
7
|
+
*/
|
|
8
|
+
export declare function checkProxyHealth(proxyUrl: string, fetchImpl?: typeof fetch): Promise<DoctorCheck>;
|
package/dist/reply-audit.d.ts
CHANGED
|
@@ -59,6 +59,8 @@ export declare function replyAuditNotice(audit: ReplyAudit, actions: string[]):
|
|
|
59
59
|
* turns it off. Same shape as `semanticGroundingEnabled()`.
|
|
60
60
|
*/
|
|
61
61
|
export declare function replyAuditEnabled(env?: Record<string, string | undefined>): boolean;
|
|
62
|
+
/** Every automatic retry message starts with this; it is the system talking to the model, never something the user said. */
|
|
63
|
+
export declare const AUDIT_NUDGE_PREFIX = "[automatic reply check]";
|
|
62
64
|
/**
|
|
63
65
|
* The message for the one automatic retry, or undefined when the reply needs none. A claim or promise of work the system
|
|
64
66
|
* did not record asks for the work to be done now or the claim withdrawn; details that disagree with the command output
|
|
@@ -41,6 +41,16 @@ export declare class ResponseService {
|
|
|
41
41
|
* thread, not be silently dropped). A no-op when `memory` wasn't wired in, or the caller never
|
|
42
42
|
* resolved a `threadId` — exactly today's behavior either way (INV-43).
|
|
43
43
|
*/
|
|
44
|
+
/** Public entry for the tool-level approval path (a staged write/command pauses the turn before any result builder runs): records the tasks on the goal thread so Goals shows them. */
|
|
45
|
+
syncGoalThread(sessionId: string, threadId: string | undefined, tasks: {
|
|
46
|
+
id: string;
|
|
47
|
+
status: string;
|
|
48
|
+
description?: string;
|
|
49
|
+
depends_on?: string[];
|
|
50
|
+
risk_level?: string;
|
|
51
|
+
}[], onUsage?: (usage: TokenUsage) => void): Promise<void>;
|
|
52
|
+
/** Marks every counted task of `threadId` COMPLETE (the staged actions it was waiting on were approved and applied); a thread whose tasks all finish moves to DONE. */
|
|
53
|
+
completeGoalThread(sessionId: string, threadId: string | undefined, onUsage?: (usage: TokenUsage) => void): Promise<void>;
|
|
44
54
|
private syncGoalThreadEvidence;
|
|
45
55
|
buildTrivialResult(params: {
|
|
46
56
|
sessionId: string;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { AssistantTrace, AssistantSource, AssistantTurnResult } from './assistant.js';
|
|
2
|
+
import { AnswerClaim } from './answer-claim.js';
|
|
3
|
+
import { MemoryInjection } from './memory-service.js';
|
|
4
|
+
import { AssistantToolStep } from './tool-step.js';
|
|
5
|
+
import { GoalGraphState } from './goal-graph-service.js';
|
|
6
|
+
/**
|
|
7
|
+
* The one place that explains a finished turn ("why", "layers", "sources", "steps", "plan").
|
|
8
|
+
* The CLI prints these lines and chat-ui shows the same lines in a panel, so what the user is told
|
|
9
|
+
* about a turn cannot drift between surfaces. Everything here is a pure function of data the turn
|
|
10
|
+
* already produced — no I/O, no UI.
|
|
11
|
+
*/
|
|
12
|
+
/** What a surface remembers about the last turn. All fields are optional: a staged, declined or fast-path turn has no trace. */
|
|
13
|
+
export interface TurnExplainInput {
|
|
14
|
+
trace?: AssistantTrace;
|
|
15
|
+
/** True when the turn skipped the harness entirely (a self-contained trivial question). */
|
|
16
|
+
harnessSkipped?: boolean;
|
|
17
|
+
/** Why there is no trace, when the surface knows a more specific reason than the generic one. */
|
|
18
|
+
noTraceReason?: string;
|
|
19
|
+
answerClaim?: AnswerClaim;
|
|
20
|
+
memoryInjection?: MemoryInjection;
|
|
21
|
+
sources?: AssistantSource[];
|
|
22
|
+
toolSteps?: AssistantToolStep[];
|
|
23
|
+
planStatus?: AssistantTurnResult['planStatus'];
|
|
24
|
+
/** The session's goal threads. When there is no drafted plan but threads have tasks, /plan says the request was worked as tracked goal tasks instead of "No active plan". */
|
|
25
|
+
goalGraph?: GoalGraphState;
|
|
26
|
+
}
|
|
27
|
+
export declare const FAST_PATH_REASON = "No harness trace \u2014 the last turn was a simple, self-contained question answered directly without activating the harness (fast path).";
|
|
28
|
+
export declare const GENERIC_NO_TRACE_REASON = "No harness trace for the last turn (nothing to explain yet, or it took the fast path).";
|
|
29
|
+
export declare const NO_SOURCES_TEXT = "No sources for the last turn (it used no file/web tool calls).";
|
|
30
|
+
export declare const NO_STEPS_TEXT = "No tool steps for the last turn.";
|
|
31
|
+
export declare const NO_PLAN_TEXT = "No active plan for this session.";
|
|
32
|
+
export declare const NO_DRAFTED_PLAN_BUT_GOAL_TASKS_TEXT = "No drafted plan for this session. The request was worked as tracked goal tasks (/goals):";
|
|
33
|
+
/** Slash commands that open the explanations. Shared so the CLI's dispatch table and chat-ui's composer recognise the same words. */
|
|
34
|
+
export declare const EXPLAIN_COMMANDS: readonly ["/why", "/layers", "/sources", "/steps", "/plan"];
|
|
35
|
+
export type ExplainCommand = (typeof EXPLAIN_COMMANDS)[number];
|
|
36
|
+
export declare function verificationHealthLabel({ strength, feasibility }: AssistantTrace['verificationHealth']): string;
|
|
37
|
+
/**
|
|
38
|
+
* Turns AnswerClaim's mechanically-derived verification_status into the "this is true" vs "I found X
|
|
39
|
+
* but couldn't independently verify it" text. One pure function so a future change can't silently
|
|
40
|
+
* collapse the four branches back into one generic phrasing.
|
|
41
|
+
*/
|
|
42
|
+
export declare function answerClaimLabel(claim: AnswerClaim): string;
|
|
43
|
+
type BatchBudget = NonNullable<AssistantTrace['batchBudget']>;
|
|
44
|
+
/** One-line found / not found / truncated tally for a batch-research turn (absent on every other turn). */
|
|
45
|
+
export declare function batchBudgetSummaryLine(batchBudget: BatchBudget): string;
|
|
46
|
+
/** `/why` — confidence, whether the reply was checked against what was read, the layers that fired (in order), and what memory the prompt held. */
|
|
47
|
+
export declare function explainWhy(input: TurnExplainInput): string[];
|
|
48
|
+
/** `/layers` — every one of the 11 layers: fired or not, and why; plus the per-item batch breakdown on a batch turn. */
|
|
49
|
+
export declare function explainLayers(input: TurnExplainInput): string[];
|
|
50
|
+
/** `/sources` — the files and URLs the turn consulted, each once. */
|
|
51
|
+
export declare function explainSources(input: TurnExplainInput): string[];
|
|
52
|
+
/** `/steps` — the tool calls the turn made, in order. */
|
|
53
|
+
export declare function explainSteps(input: TurnExplainInput): string[];
|
|
54
|
+
/** `/plan` — the active plan's task checklist. */
|
|
55
|
+
export declare function explainPlan(input: TurnExplainInput): string[];
|
|
56
|
+
/** Dispatches a bare slash command to its explainer; undefined for anything else (including `/plan graph` and other arguments, which are not explanations). */
|
|
57
|
+
export declare function explainCommand(message: string, input: TurnExplainInput): string[] | undefined;
|
|
58
|
+
export {};
|
|
@@ -5,9 +5,9 @@ import { jsxs, jsx } from "react/jsx-runtime";
|
|
|
5
5
|
import { Readable, Writable } from "node:stream";
|
|
6
6
|
import { useState, useRef, useEffect, useMemo, useCallback, useSyncExternalStore } from "react";
|
|
7
7
|
import { useWindowSize, usePaste, useInput, Box, Text, render, Static } from "ink";
|
|
8
|
-
import { s as sanitizeLabel, r as renderPlan, t as toLines, a as runCli, P as PLAN_LINE_PREFIX, I as ICONS } from "./bin-
|
|
8
|
+
import { s as sanitizeLabel, r as renderPlan, t as toLines, a as runCli, P as PLAN_LINE_PREFIX, I as ICONS } from "./bin-CCwDFxDe.js";
|
|
9
9
|
import { format } from "node:util";
|
|
10
|
-
import {
|
|
10
|
+
import { v as DIFF_INDENT, cq as stripTerminalControls } from "./provider-setup-Cy9dwqrd.js";
|
|
11
11
|
function classify(raw, stream) {
|
|
12
12
|
if (raw.startsWith("\r")) {
|
|
13
13
|
return { type: "progress", text: raw.replace(/\r/g, "").trimEnd() };
|
|
@@ -1057,4 +1057,4 @@ export {
|
|
|
1057
1057
|
formatLivenessLabel,
|
|
1058
1058
|
runTuiApp
|
|
1059
1059
|
};
|
|
1060
|
-
//# sourceMappingURL=tui-app-
|
|
1060
|
+
//# sourceMappingURL=tui-app-Dt72u8vZ.js.map
|