@itsshadowai/refinery 0.1.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/LICENSE +21 -0
- package/README.md +228 -0
- package/coral/agents/claim-scout/coral-agent.toml +23 -0
- package/coral/agents/decision-synthesizer/coral-agent.toml +23 -0
- package/coral/agents/evidence-auditor/coral-agent.toml +23 -0
- package/coral/agents/memory-cartographer/coral-agent.toml +23 -0
- package/coral/agents/proposal-editor/coral-agent.toml +23 -0
- package/coral/agents/run-worker.sh +19 -0
- package/coral/refinery-config.toml +16 -0
- package/dist/adapters/codex-memory.d.ts +6 -0
- package/dist/adapters/codex-memory.js +264 -0
- package/dist/adapters/codex-memory.js.map +1 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +671 -0
- package/dist/cli.js.map +1 -0
- package/dist/coral/client.d.ts +107 -0
- package/dist/coral/client.js +214 -0
- package/dist/coral/client.js.map +1 -0
- package/dist/coral/definitions.d.ts +25 -0
- package/dist/coral/definitions.js +53 -0
- package/dist/coral/definitions.js.map +1 -0
- package/dist/coral/mcp.d.ts +17 -0
- package/dist/coral/mcp.js +71 -0
- package/dist/coral/mcp.js.map +1 -0
- package/dist/coral/review-conductor.d.ts +120 -0
- package/dist/coral/review-conductor.js +1290 -0
- package/dist/coral/review-conductor.js.map +1 -0
- package/dist/coral/smoke.d.ts +1 -0
- package/dist/coral/smoke.js +265 -0
- package/dist/coral/smoke.js.map +1 -0
- package/dist/coral/topology.d.ts +5 -0
- package/dist/coral/topology.js +15 -0
- package/dist/coral/topology.js.map +1 -0
- package/dist/coral/worker.d.ts +34 -0
- package/dist/coral/worker.js +671 -0
- package/dist/coral/worker.js.map +1 -0
- package/dist/core/adapter.d.ts +93 -0
- package/dist/core/adapter.js +112 -0
- package/dist/core/adapter.js.map +1 -0
- package/dist/core/artifacts.d.ts +93 -0
- package/dist/core/artifacts.js +200 -0
- package/dist/core/artifacts.js.map +1 -0
- package/dist/core/deliberation.d.ts +89 -0
- package/dist/core/deliberation.js +385 -0
- package/dist/core/deliberation.js.map +1 -0
- package/dist/core/errors.d.ts +26 -0
- package/dist/core/errors.js +50 -0
- package/dist/core/errors.js.map +1 -0
- package/dist/core/intents.d.ts +5 -0
- package/dist/core/intents.js +34 -0
- package/dist/core/intents.js.map +1 -0
- package/dist/core/live-review.d.ts +93 -0
- package/dist/core/live-review.js +269 -0
- package/dist/core/live-review.js.map +1 -0
- package/dist/core/model-client.d.ts +19 -0
- package/dist/core/model-client.js +45 -0
- package/dist/core/model-client.js.map +1 -0
- package/dist/core/paths.d.ts +16 -0
- package/dist/core/paths.js +43 -0
- package/dist/core/paths.js.map +1 -0
- package/dist/core/review.d.ts +93 -0
- package/dist/core/review.js +102 -0
- package/dist/core/review.js.map +1 -0
- package/dist/core/specialists/claim-scout.d.ts +2 -0
- package/dist/core/specialists/claim-scout.js +26 -0
- package/dist/core/specialists/claim-scout.js.map +1 -0
- package/dist/core/specialists/decision-synthesizer.d.ts +2 -0
- package/dist/core/specialists/decision-synthesizer.js +35 -0
- package/dist/core/specialists/decision-synthesizer.js.map +1 -0
- package/dist/core/specialists/evidence-auditor.d.ts +2 -0
- package/dist/core/specialists/evidence-auditor.js +35 -0
- package/dist/core/specialists/evidence-auditor.js.map +1 -0
- package/dist/core/specialists/harness.d.ts +2 -0
- package/dist/core/specialists/harness.js +13 -0
- package/dist/core/specialists/harness.js.map +1 -0
- package/dist/core/specialists/index.d.ts +8 -0
- package/dist/core/specialists/index.js +8 -0
- package/dist/core/specialists/index.js.map +1 -0
- package/dist/core/specialists/memory-cartographer.d.ts +2 -0
- package/dist/core/specialists/memory-cartographer.js +33 -0
- package/dist/core/specialists/memory-cartographer.js.map +1 -0
- package/dist/core/specialists/prompt.d.ts +3 -0
- package/dist/core/specialists/prompt.js +25 -0
- package/dist/core/specialists/prompt.js.map +1 -0
- package/dist/core/specialists/proposal-editor.d.ts +2 -0
- package/dist/core/specialists/proposal-editor.js +37 -0
- package/dist/core/specialists/proposal-editor.js.map +1 -0
- package/dist/core/specialists/types.d.ts +20 -0
- package/dist/core/specialists/types.js +2 -0
- package/dist/core/specialists/types.js.map +1 -0
- package/dist/env.d.ts +11 -0
- package/dist/env.js +53 -0
- package/dist/env.js.map +1 -0
- package/dist/mcp.d.ts +9 -0
- package/dist/mcp.js +147 -0
- package/dist/mcp.js.map +1 -0
- package/package.json +50 -0
- package/skills/refinery/SKILL.md +117 -0
- package/skills/refinery/agents/openai.yaml +4 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { type ChildProcessWithoutNullStreams } from "node:child_process";
|
|
2
|
+
import { type ReviewTopology } from "./topology.ts";
|
|
3
|
+
import { refineryReviewSchemaVersion, type MemoryStoreAdapter } from "../core/adapter.ts";
|
|
4
|
+
import { type ReviewRunResult, type ReviewSinkOptions, type ReviewSinkResult } from "../core/review.ts";
|
|
5
|
+
import { type ReviewIntent } from "../core/intents.ts";
|
|
6
|
+
export interface CoralReviewRuntimeOptions {
|
|
7
|
+
apiUrl?: string;
|
|
8
|
+
authKey?: string;
|
|
9
|
+
configPath?: string;
|
|
10
|
+
namespace?: string;
|
|
11
|
+
sessionId?: string;
|
|
12
|
+
threadId?: string;
|
|
13
|
+
startServer?: boolean;
|
|
14
|
+
noTeardown?: boolean;
|
|
15
|
+
coralPackage?: string;
|
|
16
|
+
timeoutMs?: number;
|
|
17
|
+
modelName?: string;
|
|
18
|
+
modelBaseUrl?: string;
|
|
19
|
+
reasoningEffort?: string;
|
|
20
|
+
maxTurns?: string;
|
|
21
|
+
topology?: ReviewTopology;
|
|
22
|
+
}
|
|
23
|
+
export interface CoralReviewRunOptions {
|
|
24
|
+
adapter: MemoryStoreAdapter;
|
|
25
|
+
project: string;
|
|
26
|
+
source: "codex-memory";
|
|
27
|
+
target: "codex-memory";
|
|
28
|
+
scope: string;
|
|
29
|
+
runId: string;
|
|
30
|
+
outputDir: string;
|
|
31
|
+
intent?: ReviewIntent;
|
|
32
|
+
request?: string | null;
|
|
33
|
+
sink?: ReviewSinkOptions;
|
|
34
|
+
sourceLimit?: number;
|
|
35
|
+
sourceCharLimit?: number;
|
|
36
|
+
coral?: CoralReviewRuntimeOptions;
|
|
37
|
+
}
|
|
38
|
+
export interface CoralReviewRunResult extends ReviewRunResult {
|
|
39
|
+
mode: "coral";
|
|
40
|
+
source: "codex-memory";
|
|
41
|
+
target: "codex-memory";
|
|
42
|
+
project: string;
|
|
43
|
+
evidenceReview: unknown;
|
|
44
|
+
coral: {
|
|
45
|
+
namespace: string;
|
|
46
|
+
sessionId: string;
|
|
47
|
+
threadId: string;
|
|
48
|
+
threadIds?: string[];
|
|
49
|
+
agents: string[];
|
|
50
|
+
};
|
|
51
|
+
sink?: ReviewSinkResult;
|
|
52
|
+
}
|
|
53
|
+
export interface CoralConsoleRunOptions {
|
|
54
|
+
adapter: MemoryStoreAdapter;
|
|
55
|
+
project: string;
|
|
56
|
+
source: "codex-memory";
|
|
57
|
+
target: "codex-memory";
|
|
58
|
+
scope: string;
|
|
59
|
+
runId: string;
|
|
60
|
+
intent?: ReviewIntent;
|
|
61
|
+
request?: string | null;
|
|
62
|
+
sourceLimit?: number;
|
|
63
|
+
sourceCharLimit?: number;
|
|
64
|
+
coral?: CoralReviewRuntimeOptions;
|
|
65
|
+
}
|
|
66
|
+
export interface CoralConsoleRunResult {
|
|
67
|
+
ok: true;
|
|
68
|
+
schemaVersion: typeof refineryReviewSchemaVersion;
|
|
69
|
+
command: "console run";
|
|
70
|
+
mode: "coral-console";
|
|
71
|
+
source: "codex-memory";
|
|
72
|
+
target: "codex-memory";
|
|
73
|
+
project: string;
|
|
74
|
+
adapter: {
|
|
75
|
+
name: string;
|
|
76
|
+
};
|
|
77
|
+
scope: string;
|
|
78
|
+
dryRun: true;
|
|
79
|
+
archive: false;
|
|
80
|
+
artifactDir: null;
|
|
81
|
+
writesAttempted: false;
|
|
82
|
+
runId: string;
|
|
83
|
+
consoleUrl: string;
|
|
84
|
+
schemaUrl: string;
|
|
85
|
+
counts: {
|
|
86
|
+
sources: number;
|
|
87
|
+
activeMemories: number;
|
|
88
|
+
seededMessages: number;
|
|
89
|
+
};
|
|
90
|
+
coral: {
|
|
91
|
+
apiUrl: string;
|
|
92
|
+
namespace: string;
|
|
93
|
+
sessionId: string;
|
|
94
|
+
threadId: string;
|
|
95
|
+
threadIds: string[];
|
|
96
|
+
proposalThreadId?: string;
|
|
97
|
+
critiqueThreadId?: string;
|
|
98
|
+
agents: string[];
|
|
99
|
+
topology: ReviewTopology;
|
|
100
|
+
serverMode: "managed" | "attached";
|
|
101
|
+
managedServerStarted: boolean;
|
|
102
|
+
};
|
|
103
|
+
seededMessages: Array<{
|
|
104
|
+
id: string;
|
|
105
|
+
threadId: string;
|
|
106
|
+
senderName: string;
|
|
107
|
+
mentionNames: string[];
|
|
108
|
+
textExcerpt: string;
|
|
109
|
+
}>;
|
|
110
|
+
next: string;
|
|
111
|
+
}
|
|
112
|
+
export interface CoralConsoleRunSession {
|
|
113
|
+
result: CoralConsoleRunResult;
|
|
114
|
+
managedServerStarted: boolean;
|
|
115
|
+
managedProcess: ChildProcessWithoutNullStreams | null;
|
|
116
|
+
close: () => Promise<void>;
|
|
117
|
+
}
|
|
118
|
+
export declare function defaultCoralReviewTimeoutMs(topology: ReviewTopology): number;
|
|
119
|
+
export declare function startCoralConsoleRun(options: CoralConsoleRunOptions): Promise<CoralConsoleRunSession>;
|
|
120
|
+
export declare function runCoralReview(options: CoralReviewRunOptions): Promise<CoralReviewRunResult>;
|