@jmanuelcorral/openteam 0.1.41 → 0.2.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/.opencode/openteam.example.json +6 -1
- package/README.es.md +1 -1
- package/README.md +1 -1
- package/dist/capabilities/types.d.ts +4 -4
- package/dist/classifier/types.d.ts +3 -3
- package/dist/cli.js +430 -36
- package/dist/commands/doctor.d.ts +2 -0
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/graph.d.ts +36 -2
- package/dist/commands/graph.d.ts.map +1 -1
- package/dist/config/graphFeatureGate.d.ts +96 -0
- package/dist/config/graphFeatureGate.d.ts.map +1 -0
- package/dist/config/migrations.d.ts.map +1 -1
- package/dist/config/resolve.d.ts +20 -1
- package/dist/config/resolve.d.ts.map +1 -1
- package/dist/config/schema.d.ts +40 -19
- package/dist/config/schema.d.ts.map +1 -1
- package/dist/console/assets.d.ts +9 -1
- package/dist/console/assets.d.ts.map +1 -1
- package/dist/console/opencodeClient.d.ts +6 -0
- package/dist/console/opencodeClient.d.ts.map +1 -1
- package/dist/console/protocol.d.ts +8 -0
- package/dist/console/protocol.d.ts.map +1 -1
- package/dist/console/render.d.ts +25 -0
- package/dist/console/render.d.ts.map +1 -1
- package/dist/context/redaction.d.ts +23 -0
- package/dist/context/redaction.d.ts.map +1 -1
- package/dist/context/schema.d.ts +3 -3
- package/dist/contract/opencode.d.ts +2 -2
- package/dist/contract/opencode.d.ts.map +1 -1
- package/dist/graph/certificate.d.ts +505 -0
- package/dist/graph/certificate.d.ts.map +1 -0
- package/dist/graph/ids.d.ts +9 -0
- package/dist/graph/ids.d.ts.map +1 -1
- package/dist/graph/privacyPolicy.d.ts.map +1 -1
- package/dist/graph/reducer.d.ts.map +1 -1
- package/dist/graph/replay.d.ts.map +1 -1
- package/dist/graph/reviewerPolicy.d.ts.map +1 -1
- package/dist/graph/schema.d.ts +33 -33
- package/dist/graph/schema.d.ts.map +1 -1
- package/dist/graph/soakLedger.d.ts +144 -0
- package/dist/graph/soakLedger.d.ts.map +1 -0
- package/dist/graph/types.d.ts +2 -0
- package/dist/graph/types.d.ts.map +1 -1
- package/dist/graph/validate.d.ts.map +1 -1
- package/dist/index.d.ts +47 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2351 -180
- package/dist/local/registry.d.ts.map +1 -1
- package/dist/memory/types.d.ts +2 -2
- package/dist/orchestrator/graphFacade.d.ts +39 -0
- package/dist/orchestrator/graphFacade.d.ts.map +1 -0
- package/dist/orchestrator/graphIngress.d.ts +136 -0
- package/dist/orchestrator/graphIngress.d.ts.map +1 -0
- package/dist/orchestrator/graphShadow.d.ts +121 -0
- package/dist/orchestrator/graphShadow.d.ts.map +1 -0
- package/dist/orchestrator/ledger.d.ts +14 -2
- package/dist/orchestrator/ledger.d.ts.map +1 -1
- package/dist/orchestrator/opencodeSessionAdapter.d.ts.map +1 -1
- package/dist/orchestrator/roles.d.ts +3 -3
- package/dist/orchestrator/sdd.d.ts +55 -1
- package/dist/orchestrator/sdd.d.ts.map +1 -1
- package/dist/orchestrator/sddCompiler.d.ts +6 -2
- package/dist/orchestrator/sddCompiler.d.ts.map +1 -1
- package/dist/orchestrator/worktreeAdapter.d.ts +39 -0
- package/dist/orchestrator/worktreeAdapter.d.ts.map +1 -0
- package/dist/orchestrator/worktreeDispatch.d.ts +84 -0
- package/dist/orchestrator/worktreeDispatch.d.ts.map +1 -0
- package/dist/orchestrator/worktreeReconciler.d.ts +74 -0
- package/dist/orchestrator/worktreeReconciler.d.ts.map +1 -0
- package/dist/plugin/graphShadowIngress.d.ts +165 -0
- package/dist/plugin/graphShadowIngress.d.ts.map +1 -0
- package/dist/plugin/graphTool.d.ts +63 -0
- package/dist/plugin/graphTool.d.ts.map +1 -0
- package/dist/plugin/hooks.d.ts +6 -0
- package/dist/plugin/hooks.d.ts.map +1 -1
- package/dist/plugin/legacyRunProducer.d.ts +60 -0
- package/dist/plugin/legacyRunProducer.d.ts.map +1 -0
- package/dist/plugin/reportRunSchema.d.ts +60 -0
- package/dist/plugin/reportRunSchema.d.ts.map +1 -0
- package/dist/plugin/sessionTracker.d.ts +42 -0
- package/dist/plugin/sessionTracker.d.ts.map +1 -0
- package/dist/plugin/shadowPipeline.d.ts +49 -0
- package/dist/plugin/shadowPipeline.d.ts.map +1 -0
- package/dist/plugin/soakObserver.d.ts +73 -0
- package/dist/plugin/soakObserver.d.ts.map +1 -0
- package/dist/storage/graph/codec.d.ts.map +1 -1
- package/dist/storage/graph/migrateLegacyBriefs.d.ts.map +1 -1
- package/dist/storage/graph/migration.d.ts +91 -0
- package/dist/storage/graph/migration.d.ts.map +1 -0
- package/dist/storage/graph/provider.d.ts +1 -0
- package/dist/storage/graph/provider.d.ts.map +1 -1
- package/dist/storage/graph/recovery.d.ts.map +1 -1
- package/dist/storage/graph/runRegistry.d.ts.map +1 -1
- package/dist/storage/graph/soakRecorder.d.ts +59 -0
- package/dist/storage/graph/soakRecorder.d.ts.map +1 -0
- package/dist/storage/graph/workspaceLease.d.ts.map +1 -1
- package/dist/storage/graph/worktreeRegistry.d.ts +29 -0
- package/dist/storage/graph/worktreeRegistry.d.ts.map +1 -0
- package/dist/storage/graph/writer.d.ts +15 -0
- package/dist/storage/graph/writer.d.ts.map +1 -1
- package/dist/storage/path.d.ts.map +1 -1
- package/dist/telemetry/events.d.ts +12 -12
- package/dist/telemetry/graphRuntimeHealth.d.ts +53 -0
- package/dist/telemetry/graphRuntimeHealth.d.ts.map +1 -0
- package/dist/telemetry/graphView.d.ts +76 -0
- package/dist/telemetry/graphView.d.ts.map +1 -0
- package/dist/telemetry/types.d.ts +4 -4
- package/dist/web/console.d.ts +6 -0
- package/dist/web/console.d.ts.map +1 -1
- package/dist/web/graphRoute.d.ts +36 -0
- package/dist/web/graphRoute.d.ts.map +1 -0
- package/dist/web/server.d.ts +21 -2
- package/dist/web/server.d.ts.map +1 -1
- package/dist/web/start.d.ts +11 -0
- package/dist/web/start.d.ts.map +1 -1
- package/package.json +7 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../../src/local/registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAKtD,OAAO,KAAK,EACV,KAAK,EACL,SAAS,EACT,cAAc,EACd,oBAAoB,EACpB,cAAc,EACd,gBAAgB,EAEjB,MAAM,SAAS,CAAC;AAEjB,MAAM,MAAM,sBAAsB,GAAG;IACnC,KAAK,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,KAAK,CAAC;IACb,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC,QAAQ,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,cAAc,EAAE,cAAc,CAAC,CAAC,CAAC;CAC5D,CAAC;AAEF,qBAAa,eAAe;IAC1B,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAyC;IAClE,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAQ;IAC9B,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAY;IAClC,OAAO,CAAC,QAAQ,CAAC,gBAAgB,CAA+B;
|
|
1
|
+
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../../src/local/registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAKtD,OAAO,KAAK,EACV,KAAK,EACL,SAAS,EACT,cAAc,EACd,oBAAoB,EACpB,cAAc,EACd,gBAAgB,EAEjB,MAAM,SAAS,CAAC;AAEjB,MAAM,MAAM,sBAAsB,GAAG;IACnC,KAAK,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,KAAK,CAAC;IACb,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC,QAAQ,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,cAAc,EAAE,cAAc,CAAC,CAAC,CAAC;CAC5D,CAAC;AAEF,qBAAa,eAAe;IAC1B,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAyC;IAClE,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAQ;IAC9B,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAY;IAClC,OAAO,CAAC,QAAQ,CAAC,gBAAgB,CAA+B;IAEhE,YAAY,OAAO,EAAE,sBAAsB,EAU1C;IAEK,KAAK,CACT,QAAQ,EAAE,SAAS,YAAY,EAAE,GAChC,OAAO,CAAC,oBAAoB,EAAE,CAAC,CA2BjC;IAED,OAAO,CAAC,kBAAkB;CAuB3B;AAED,wBAAgB,2BAA2B,CACzC,SAAS,EAAE,SAAS,oBAAoB,EAAE,GACzC,cAAc,EAAE,CAWlB"}
|
package/dist/memory/types.d.ts
CHANGED
|
@@ -25,9 +25,9 @@ export declare const MEMORY_SCHEMA_VERSION: 1;
|
|
|
25
25
|
export declare const SHARED_OWNER_KEY: "*";
|
|
26
26
|
export declare const OwnerKeySchema: z.ZodString;
|
|
27
27
|
export declare const MemoryKindSchema: z.ZodEnum<{
|
|
28
|
+
entity: "entity";
|
|
28
29
|
fact: "fact";
|
|
29
30
|
preference: "preference";
|
|
30
|
-
entity: "entity";
|
|
31
31
|
}>;
|
|
32
32
|
/** Hecho estructurado como triple sujeto-predicado-objeto (dueño-scoped). */
|
|
33
33
|
export declare const FactSchema: z.ZodObject<{
|
|
@@ -130,9 +130,9 @@ export declare const MemoryRecordSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
130
130
|
export declare const RecallQuerySchema: z.ZodObject<{
|
|
131
131
|
ownerKey: z.ZodString;
|
|
132
132
|
kinds: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
133
|
+
entity: "entity";
|
|
133
134
|
fact: "fact";
|
|
134
135
|
preference: "preference";
|
|
135
|
-
entity: "entity";
|
|
136
136
|
}>>>;
|
|
137
137
|
asOf: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
138
138
|
limit: z.ZodDefault<z.ZodNumber>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type ShadowMirror, type ShadowMirrorErrorCode } from "./graphShadow";
|
|
2
|
+
/**
|
|
3
|
+
* **Fachada de contención del espejo shadow** (GE-043).
|
|
4
|
+
*
|
|
5
|
+
* El espejo observa al camino legacy; nunca lo gobierna. Esta frontera hace esa
|
|
6
|
+
* garantía estructural en vez de disciplinaria: `mirrorLegacyTrace` es
|
|
7
|
+
* **total** —no lanza para ningún valor de entrada, ni siquiera para objetos
|
|
8
|
+
* hostiles cuyos accesores exploten— y `mirrorAlongsideLegacy` devuelve el
|
|
9
|
+
* resultado legacy **por identidad**, sin copiarlo ni inspeccionarlo. Un fallo
|
|
10
|
+
* del espejo degrada a un resultado tipado que el llamante puede ignorar; no
|
|
11
|
+
* hay camino por el que altere el desenlace productivo.
|
|
12
|
+
*/
|
|
13
|
+
/** Resultado contenido del espejo: éxito con evidencia, o fallo tipado. */
|
|
14
|
+
export type ShadowMirrorResult = {
|
|
15
|
+
readonly ok: true;
|
|
16
|
+
readonly mirror: ShadowMirror;
|
|
17
|
+
} | {
|
|
18
|
+
readonly ok: false;
|
|
19
|
+
readonly code: ShadowMirrorErrorCode;
|
|
20
|
+
readonly detail: string;
|
|
21
|
+
};
|
|
22
|
+
/** Resultado productivo con su espejo adjunto, nunca fusionados. */
|
|
23
|
+
export type LegacyWithShadow<T> = {
|
|
24
|
+
readonly legacy: T;
|
|
25
|
+
readonly shadow: ShadowMirrorResult;
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* Construye el espejo de un trace de procedencia no confiable. Cualquier fallo
|
|
29
|
+
* —trace inválido, grafo irrepresentable, secuencia ilegal o error inesperado—
|
|
30
|
+
* se devuelve como valor.
|
|
31
|
+
*/
|
|
32
|
+
export declare function mirrorLegacyTrace(trace: unknown): ShadowMirrorResult;
|
|
33
|
+
/**
|
|
34
|
+
* Adjunta el espejo a un desenlace legacy ya calculado. El valor legacy se
|
|
35
|
+
* devuelve tal cual llegó: la identidad referencial es la prueba de que el
|
|
36
|
+
* espejo no lo pudo tocar.
|
|
37
|
+
*/
|
|
38
|
+
export declare function mirrorAlongsideLegacy<T>(legacy: T, trace: unknown): LegacyWithShadow<T>;
|
|
39
|
+
//# sourceMappingURL=graphFacade.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphFacade.d.ts","sourceRoot":"","sources":["../../src/orchestrator/graphFacade.ts"],"names":[],"mappings":"AAIA,OAAO,EAEL,KAAK,YAAY,EAEjB,KAAK,qBAAqB,EAC3B,MAAM,eAAe,CAAC;AAEvB;;;;;;;;;;GAUG;AAEH,2EAA2E;AAC3E,MAAM,MAAM,kBAAkB,GAC1B;IAAE,QAAQ,CAAC,EAAE,EAAE,IAAI,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAA;CAAE,GACpD;IACE,QAAQ,CAAC,EAAE,EAAE,KAAK,CAAC;IACnB,QAAQ,CAAC,IAAI,EAAE,qBAAqB,CAAC;IACrC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB,CAAC;AAEN,oEAAoE;AACpE,MAAM,MAAM,gBAAgB,CAAC,CAAC,IAAI;IAChC,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC;IACnB,QAAQ,CAAC,MAAM,EAAE,kBAAkB,CAAC;CACrC,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,GAAG,kBAAkB,CAuBpE;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,CAAC,EACrC,MAAM,EAAE,CAAC,EACT,KAAK,EAAE,OAAO,GACb,gBAAgB,CAAC,CAAC,CAAC,CAErB"}
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GE-050 — ingress activo de SDD detrás de una puerta cerrada por defecto.
|
|
3
|
+
*
|
|
4
|
+
* R1 entrega el punto de entrada de producción que el runtime activo nunca tuvo
|
|
5
|
+
* y lo deja **inalcanzable**. La propiedad central es que "inalcanzable por
|
|
6
|
+
* configuración soportada" es ESTRUCTURAL, no una promesa: la puerta es una
|
|
7
|
+
* capability que el parser de config no puede construir (su marca es un símbolo
|
|
8
|
+
* privado de este módulo), así que ningún `.opencode/openteam.json` — se escriba
|
|
9
|
+
* como se escriba — puede abrirla. Solo `unsafeGrantActiveIngress` la produce, y
|
|
10
|
+
* ningún módulo de producción lo llama.
|
|
11
|
+
*
|
|
12
|
+
* El motivo devuelto es siempre el bloqueo **más externo necesario**, para que
|
|
13
|
+
* un diagnóstico nunca sugiera un remedio que no funcionaría: en R1, apagar el
|
|
14
|
+
* kill switch o ampliar la allow-list no cambia nada mientras la puerta esté
|
|
15
|
+
* cerrada, y el ingress lo dice.
|
|
16
|
+
*
|
|
17
|
+
* Este módulo es una capa de **composición**: no reimplementa el runtime, la
|
|
18
|
+
* revisión ni la cancelación; los orquesta y traduce sus resultados a un
|
|
19
|
+
* resultado total (nunca lanza) y reference-only.
|
|
20
|
+
*/
|
|
21
|
+
import type { ResolvedGraphConfig } from "../config/resolve";
|
|
22
|
+
import type { GraphJournal } from "../storage/graph/provider";
|
|
23
|
+
import type { WorkspaceLease } from "../storage/graph/workspaceLease";
|
|
24
|
+
import type { GraphEffectExecutor } from "./graphEffects";
|
|
25
|
+
import type { RevisionPlan } from "./graphReview";
|
|
26
|
+
import { type RuntimeStepOutcome } from "./graphRuntime";
|
|
27
|
+
import type { SddTask } from "./sdd";
|
|
28
|
+
/** Marca privada del módulo: nada fuera de aquí puede fabricarla. */
|
|
29
|
+
declare const ACTIVE_INGRESS_BRAND: unique symbol;
|
|
30
|
+
/**
|
|
31
|
+
* Permiso interno para el ingress activo. Es opaco a propósito: al llevar una
|
|
32
|
+
* marca de símbolo privado, ningún objeto derivado de JSON (y por tanto ninguna
|
|
33
|
+
* config de usuario) es asignable a este tipo.
|
|
34
|
+
*/
|
|
35
|
+
export type ActiveIngressCapability = {
|
|
36
|
+
readonly [ACTIVE_INGRESS_BRAND]: true;
|
|
37
|
+
/** Motivo declarado de la concesión; solo para trazas internas. */
|
|
38
|
+
readonly grantedFor: string;
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* Único productor de la capability. No se invoca desde ningún módulo de
|
|
42
|
+
* producción; existe para que tests y futuros pilotos (R2+) puedan abrir la
|
|
43
|
+
* puerta explícitamente, dejando la concesión visible en el código que la usa.
|
|
44
|
+
*/
|
|
45
|
+
export declare function unsafeGrantActiveIngress(grantedFor: string): ActiveIngressCapability;
|
|
46
|
+
/** Motivo por el que una petición se queda en la ruta legacy. */
|
|
47
|
+
export type IngressLegacyReason = "gate-closed" | "kill-switch" | "graph-disabled" | "not-allow-listed";
|
|
48
|
+
/** Decisión de enrutado de una tarea SDD. */
|
|
49
|
+
export type IngressDecision = {
|
|
50
|
+
readonly route: "graph";
|
|
51
|
+
readonly taskID: string;
|
|
52
|
+
} | {
|
|
53
|
+
readonly route: "legacy";
|
|
54
|
+
readonly reason: IngressLegacyReason;
|
|
55
|
+
};
|
|
56
|
+
/** Política de admisión: config resuelta, allow-list y puerta interna. */
|
|
57
|
+
export type IngressPolicy = {
|
|
58
|
+
readonly graph: ResolvedGraphConfig;
|
|
59
|
+
readonly allowList: readonly string[];
|
|
60
|
+
readonly capability?: ActiveIngressCapability;
|
|
61
|
+
};
|
|
62
|
+
/**
|
|
63
|
+
* Decide la ruta de una tarea. Pura y determinista.
|
|
64
|
+
*
|
|
65
|
+
* Precedencia: `gate-closed` → `kill-switch` → `graph-disabled` →
|
|
66
|
+
* `not-allow-listed`, es decir, el bloqueo más externo primero.
|
|
67
|
+
*/
|
|
68
|
+
export declare function decideIngress(policy: IngressPolicy, taskID: string): IngressDecision;
|
|
69
|
+
/** Clase de fallo del ingress. Nunca transporta payload del usuario. */
|
|
70
|
+
export type IngressErrorCode = "compile-failed" | "unknown-run" | "no-reviewer" | "lease-held" | "journal-failed";
|
|
71
|
+
/** Resultado total de una operación del ingress. Reference-only. */
|
|
72
|
+
export type IngressOutcome = {
|
|
73
|
+
readonly kind: "legacy";
|
|
74
|
+
readonly reason: IngressLegacyReason;
|
|
75
|
+
} | {
|
|
76
|
+
readonly kind: "accepted";
|
|
77
|
+
readonly runID: string;
|
|
78
|
+
readonly step: RuntimeStepOutcome;
|
|
79
|
+
} | {
|
|
80
|
+
readonly kind: "revision";
|
|
81
|
+
readonly runID: string;
|
|
82
|
+
readonly plan: RevisionPlan;
|
|
83
|
+
} | {
|
|
84
|
+
readonly kind: "reassigned";
|
|
85
|
+
readonly runID: string;
|
|
86
|
+
readonly reviewerID: string;
|
|
87
|
+
readonly rerunImplementation: false;
|
|
88
|
+
} | {
|
|
89
|
+
readonly kind: "cancelled";
|
|
90
|
+
readonly runID: string;
|
|
91
|
+
readonly cancelledNodeIDs: readonly string[];
|
|
92
|
+
readonly abortNodeIDs: readonly string[];
|
|
93
|
+
} | {
|
|
94
|
+
readonly kind: "error";
|
|
95
|
+
readonly code: IngressErrorCode;
|
|
96
|
+
readonly detail: string;
|
|
97
|
+
};
|
|
98
|
+
/** Petición de rechazo de revisión: ancla la revisión en curso. */
|
|
99
|
+
export type IngressRejectRequest = {
|
|
100
|
+
readonly runID: string;
|
|
101
|
+
readonly nodeID: string;
|
|
102
|
+
readonly currentRevision: number;
|
|
103
|
+
readonly currentOperationID: string;
|
|
104
|
+
};
|
|
105
|
+
/** Petición de reasignación de reviewer tras un fallo técnico. */
|
|
106
|
+
export type IngressReassignRequest = {
|
|
107
|
+
readonly runID: string;
|
|
108
|
+
readonly authorID: string;
|
|
109
|
+
readonly failedReviewers: readonly string[];
|
|
110
|
+
readonly candidates: readonly string[];
|
|
111
|
+
};
|
|
112
|
+
/** Dependencias inyectadas del ingress. Todo el I/O entra por aquí. */
|
|
113
|
+
export type GraphIngressDeps = {
|
|
114
|
+
readonly policy: IngressPolicy;
|
|
115
|
+
readonly journal: GraphJournal;
|
|
116
|
+
readonly lease: WorkspaceLease;
|
|
117
|
+
readonly effects: GraphEffectExecutor;
|
|
118
|
+
readonly holder: string;
|
|
119
|
+
readonly revisionLimit?: number;
|
|
120
|
+
};
|
|
121
|
+
/**
|
|
122
|
+
* Superficie del ingress activo. Total para los fallos de infraestructura
|
|
123
|
+
* clasificados (compilación, journal, lease), que se devuelven como resultado.
|
|
124
|
+
* Un error no clasificado **sí** se propaga: un bug no debe disfrazarse de
|
|
125
|
+
* decisión de enrutado, porque entonces sería indistinguible de una política.
|
|
126
|
+
*/
|
|
127
|
+
export interface GraphIngress {
|
|
128
|
+
start(task: SddTask): Promise<IngressOutcome>;
|
|
129
|
+
resume(runID: string): Promise<IngressOutcome>;
|
|
130
|
+
reject(request: IngressRejectRequest): Promise<IngressOutcome>;
|
|
131
|
+
reassign(request: IngressReassignRequest): Promise<IngressOutcome>;
|
|
132
|
+
cancel(runID: string): Promise<IngressOutcome>;
|
|
133
|
+
}
|
|
134
|
+
export declare function createGraphIngress(deps: GraphIngressDeps): GraphIngress;
|
|
135
|
+
export {};
|
|
136
|
+
//# sourceMappingURL=graphIngress.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphIngress.d.ts","sourceRoot":"","sources":["../../src/orchestrator/graphIngress.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAE7D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAE9D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAGtE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAElD,OAAO,EAAsB,KAAK,kBAAkB,EAAE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MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,eAAe,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5C,QAAQ,CAAC,UAAU,EAAE,SAAS,MAAM,EAAE,CAAC;CACxC,CAAC;AAEF,uEAAuE;AACvE,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAC;IAC/B,QAAQ,CAAC,OAAO,EAAE,YAAY,CAAC;IAC/B,QAAQ,CAAC,KAAK,EAAE,cAAc,CAAC;IAC/B,QAAQ,CAAC,OAAO,EAAE,mBAAmB,CAAC;IACtC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC;CACjC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B,KAAK,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;IAC9C,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;IAC/C,MAAM,CAAC,OAAO,EAAE,oBAAoB,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;IAC/D,QAAQ,CAAC,OAAO,EAAE,sBAAsB,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;IACnE,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;CAChD;AAkBD,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,gBAAgB,GAAG,YAAY,CAyIvE"}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { type GraphEventV1, type GraphSpecV1 } from "../graph/schema";
|
|
2
|
+
import type { GraphState } from "../graph/types";
|
|
3
|
+
import type { LegacyExecutionTraceV1 } from "../plugin/graphShadowIngress";
|
|
4
|
+
import type { ShadowRunSummary } from "./shadowComparator";
|
|
5
|
+
/**
|
|
6
|
+
* **Espejo shadow sin efectos** (GE-043): compila el trace productivo de
|
|
7
|
+
* GE-042 a un `GraphSpecV1` validado, sintetiza el journal que ese run habría
|
|
8
|
+
* escrito y lo pliega con el **reducer real** para producir el
|
|
9
|
+
* `ShadowRunSummary` que consume el comparador de paridad (GE-044).
|
|
10
|
+
*
|
|
11
|
+
* El run legacy se ejecuta **una sola vez**: este módulo no tiene superficie de
|
|
12
|
+
* ejecución. No importa el puerto `GraphEffectExecutor`, ni el adaptador de
|
|
13
|
+
* sesión de opencode, ni el runtime, ni ningún origen de I/O, reloj o azar; el
|
|
14
|
+
* único builtin alcanzable es `node:crypto` para el cómputo de digests. Por eso
|
|
15
|
+
* el espejo no puede duplicar el trabajo que observa: no tiene con qué.
|
|
16
|
+
*
|
|
17
|
+
* **Qué prueba realmente cada dimensión de paridad** está declarado en
|
|
18
|
+
* `SHADOW_MIRROR_PROVENANCE`, y esa distinción es deliberada: certificar
|
|
19
|
+
* paridad sobre dimensiones que el espejo se limita a copiar del trace no
|
|
20
|
+
* probaría nada. Solo el nº de fixes se **recomputa** desde el grafo compilado
|
|
21
|
+
* (divergencia demostrable); el orden de nodos y los roles pasan por el
|
|
22
|
+
* compilador y validador del spec —que rechaza traces irrepresentables como
|
|
23
|
+
* `invalid-spec`— pero la compilación preserva ambos valores literalmente, así
|
|
24
|
+
* que la comparación no puede divergir (**compiled**); el estado terminal lo
|
|
25
|
+
* **valida** el reducer; el modelo y el outcome se **transportan** sin
|
|
26
|
+
* inspección.
|
|
27
|
+
*
|
|
28
|
+
* Los artefactos del journal espejo son **placeholders sintéticos y
|
|
29
|
+
* deterministas** (`shadow://<run>/<node>`): el espejo no tiene contenido que
|
|
30
|
+
* digerir y el comparador no contrasta artefactos. El esquema `shadow://` los
|
|
31
|
+
* hace inconfundibles con evidencia real.
|
|
32
|
+
*
|
|
33
|
+
* Módulo **puro y determinista**: el mismo trace produce el mismo spec, el
|
|
34
|
+
* mismo journal y el mismo resumen.
|
|
35
|
+
*/
|
|
36
|
+
/** Qué prueba el espejo sobre una dimensión de paridad concreta. */
|
|
37
|
+
export type ShadowParityProvenance = "recomputed" | "compiled" | "validated" | "carried";
|
|
38
|
+
/**
|
|
39
|
+
* Procedencia **demostrada** de cada dimensión que compara GE-044. Acota qué
|
|
40
|
+
* puede afirmar la certificación de shadow (GE-046) y qué no.
|
|
41
|
+
*
|
|
42
|
+
* - "recomputed": el espejo calcula el valor de forma independiente desde el
|
|
43
|
+
* spec compilado. La comparación PUEDE divergir → apta para conjunto crítico.
|
|
44
|
+
* Un test de alcanzabilidad en `demonstrated-divergence-provenance.test.ts`
|
|
45
|
+
* DEMUESTRA la divergencia atravesando el pipeline completo para cada código
|
|
46
|
+
* así clasificado. Si no se puede producir, no es "recomputed".
|
|
47
|
+
* - "compiled": la dimensión pasa por `GraphSpecV1Schema.parse` y
|
|
48
|
+
* `validateGraphSpec`, que rechazan traces irrepresentables (ids duplicados,
|
|
49
|
+
* reviewer sin implementer, ciclos → `invalid-spec`). La comparación NO
|
|
50
|
+
* puede divergir porque la compilación preserva el valor idéntico, pero un
|
|
51
|
+
* trace irrepresentable impide el espejo por completo. Esta es la
|
|
52
|
+
* **representabilidad** sobre la que se apoya R6.
|
|
53
|
+
* - "validated": el reducer valida la secuencia, pero ambos lados proyectan el
|
|
54
|
+
* mismo campo del trace. La comparación NO puede divergir.
|
|
55
|
+
* - "carried": ambos lados copian el mismo campo del trace sin que nadie lo
|
|
56
|
+
* inspeccione. La comparación NO puede divergir.
|
|
57
|
+
*
|
|
58
|
+
* Invariante: solo los códigos con procedencia "recomputed" pueden incluirse
|
|
59
|
+
* en `criticalDivergenceCodes` de la política soak, porque solo esos producen
|
|
60
|
+
* una comparación independiente. Los códigos "compiled", "validated" o
|
|
61
|
+
* "carried" no pueden divergir en la comparación; incluirlos inflaría la
|
|
62
|
+
* cobertura declarada sin medir nada real.
|
|
63
|
+
*/
|
|
64
|
+
export declare const SHADOW_MIRROR_PROVENANCE: {
|
|
65
|
+
readonly status: "validated";
|
|
66
|
+
readonly order: "compiled";
|
|
67
|
+
readonly roles: "compiled";
|
|
68
|
+
readonly models: "carried";
|
|
69
|
+
readonly fixes: "recomputed";
|
|
70
|
+
readonly outcome: "carried";
|
|
71
|
+
};
|
|
72
|
+
/** Motivo tipado por el que un trace no produce espejo. */
|
|
73
|
+
export type ShadowMirrorErrorCode = "invalid-trace" | "invalid-spec" | "illegal-sequence" | "mirror-error";
|
|
74
|
+
/** Error tipado del espejo. Nunca escapa de la fachada (`graphFacade`). */
|
|
75
|
+
export declare class ShadowMirrorError extends Error {
|
|
76
|
+
readonly code: ShadowMirrorErrorCode;
|
|
77
|
+
readonly detail: string;
|
|
78
|
+
constructor(code: ShadowMirrorErrorCode, detail: string);
|
|
79
|
+
}
|
|
80
|
+
/** Espejo completo: evidencia intermedia más el resumen comparable. */
|
|
81
|
+
export type ShadowMirror = {
|
|
82
|
+
readonly spec: GraphSpecV1;
|
|
83
|
+
readonly specDigest: string;
|
|
84
|
+
readonly journal: readonly GraphEventV1[];
|
|
85
|
+
readonly state: GraphState;
|
|
86
|
+
readonly summary: ShadowRunSummary;
|
|
87
|
+
};
|
|
88
|
+
/**
|
|
89
|
+
* Compila el trace a un DAG lineal: cada nodo depende del anterior y cada
|
|
90
|
+
* reviewer revisa el implementer que le precede. Un trace que el grafo no puede
|
|
91
|
+
* representar (reviewer sin implementer previo, ids duplicados, ciclo) es
|
|
92
|
+
* rechazado por el validador real como `invalid-spec`, antes de reducir nada.
|
|
93
|
+
*/
|
|
94
|
+
export declare function compileShadowSpec(trace: LegacyExecutionTraceV1): GraphSpecV1;
|
|
95
|
+
/**
|
|
96
|
+
* Sintetiza el journal que el run observado habría escrito: apertura, despacho
|
|
97
|
+
* y recibo por nodo en orden, y el evento terminal reclamado. `errorClass`
|
|
98
|
+
* distingue el recibo: ausente es éxito, `cancelled` cancela y el resto falla.
|
|
99
|
+
*/
|
|
100
|
+
export declare function mirrorJournal(spec: GraphSpecV1, trace: LegacyExecutionTraceV1): GraphEventV1[];
|
|
101
|
+
/**
|
|
102
|
+
* Pliega el journal espejo con el reducer real. Una secuencia que el reducer
|
|
103
|
+
* rechaza —un run que se dice completado con un nodo fallido, un despacho sobre
|
|
104
|
+
* una dependencia no satisfecha— es `illegal-sequence`: el grafo no pudo haber
|
|
105
|
+
* producido esa ejecución, y esa es justamente la evidencia que aporta.
|
|
106
|
+
*/
|
|
107
|
+
export declare function reduceMirror(spec: GraphSpecV1, journal: readonly GraphEventV1[]): GraphState;
|
|
108
|
+
/**
|
|
109
|
+
* Proyección 1:1 del **lado legacy**: lo que el run observado afirma de sí
|
|
110
|
+
* mismo, sin pasar por el grafo. Es el término que el comparador contrasta
|
|
111
|
+
* contra el espejo.
|
|
112
|
+
*/
|
|
113
|
+
export declare function projectLegacySummary(trace: LegacyExecutionTraceV1): ShadowRunSummary;
|
|
114
|
+
/**
|
|
115
|
+
* Construye el espejo sin efectos de una ejecución legacy observada. Lanza
|
|
116
|
+
* `ShadowMirrorError` cuando el grafo no puede representar o reproducir el
|
|
117
|
+
* trace; la fachada (`graphFacade`) contiene ese fallo para que nunca alcance
|
|
118
|
+
* al camino legacy.
|
|
119
|
+
*/
|
|
120
|
+
export declare function mirrorLegacyExecution(trace: LegacyExecutionTraceV1): ShadowMirror;
|
|
121
|
+
//# sourceMappingURL=graphShadow.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphShadow.d.ts","sourceRoot":"","sources":["../../src/orchestrator/graphShadow.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,KAAK,YAAY,EAEjB,KAAK,WAAW,EAEjB,MAAM,iBAAiB,CAAC;AACzB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAEjD,OAAO,KAAK,EACV,sBAAsB,EAEvB,MAAM,8BAA8B,CAAC;AACtC,OAAO,KAAK,EAEV,gBAAgB,EACjB,MAAM,oBAAoB,CAAC;AAE5B;;;;;;;;;;;;;;;;;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KAAK,EAAE,sBAAsB,GAC5B,gBAAgB,CAYlB;AA8BD;;;;;GAKG;AACH,wBAAgB,qBAAqB,CACnC,KAAK,EAAE,sBAAsB,GAC5B,YAAY,CAcd"}
|
|
@@ -40,8 +40,20 @@ export declare function latestStatuses(entries: readonly LedgerEntry[]): Map<str
|
|
|
40
40
|
export declare function isTaskComplete(entries: readonly LedgerEntry[], taskID: string): boolean;
|
|
41
41
|
/** Conjunto de `taskID` cuyo estado más reciente es `complete`. Puro. */
|
|
42
42
|
export declare function completedTaskIDs(entries: readonly LedgerEntry[]): Set<string>;
|
|
43
|
-
/**
|
|
43
|
+
/**
|
|
44
|
+
* Lee y parsea el ledger; `[]` si el fichero no existe.
|
|
45
|
+
*
|
|
46
|
+
* @deprecated As authority source — legacy SDD authority (progress.md as the
|
|
47
|
+
* task-completion ledger) will be removed in v1.0.0. The pure parsing
|
|
48
|
+
* functions (`parseLedger`, `parseLedgerLine`, etc.) remain available for
|
|
49
|
+
* terminal import into graph authority. See docs/guide/graph-migration.md.
|
|
50
|
+
*/
|
|
44
51
|
export declare function readLedger(storage: StorageProvider, path?: string): Promise<LedgerEntry[]>;
|
|
45
|
-
/**
|
|
52
|
+
/**
|
|
53
|
+
* Añade una entrada al ledger (crea el fichero si no existe).
|
|
54
|
+
*
|
|
55
|
+
* @deprecated Legacy SDD authority (progress.md as the task-completion ledger)
|
|
56
|
+
* will be removed in v1.0.0. See docs/guide/graph-migration.md.
|
|
57
|
+
*/
|
|
46
58
|
export declare function appendLedgerEntry(storage: StorageProvider, entry: LedgerEntry, path?: string): Promise<void>;
|
|
47
59
|
//# sourceMappingURL=ledger.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ledger.d.ts","sourceRoot":"","sources":["../../src/orchestrator/ledger.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAE3D;;;;;;;;;;;;;;;;GAgBG;AAEH,gEAAgE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oD;IACpD,SAAS,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;IACnD,uCAAuC;IACvC,YAAY,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,SAAS,OAAO,EAAE,CAAC,CAAC;IAC7D,oEAAoE;IACpE,KAAK,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;CAC5C;AAiBD,wBAAgB,4BAA4B,CAC1C,MAAM,EAAE,kBAAkB,GACzB,sBAAsB,CA4GxB"}
|
|
@@ -16,10 +16,10 @@ export declare const AgentRoleProfileSchema: z.ZodObject<{
|
|
|
16
16
|
roleID: z.ZodString;
|
|
17
17
|
opencodeAgent: z.ZodOptional<z.ZodString>;
|
|
18
18
|
defaultTier: z.ZodEnum<{
|
|
19
|
-
trivial: "trivial";
|
|
20
|
-
simple: "simple";
|
|
21
|
-
moderate: "moderate";
|
|
22
19
|
hard: "hard";
|
|
20
|
+
moderate: "moderate";
|
|
21
|
+
simple: "simple";
|
|
22
|
+
trivial: "trivial";
|
|
23
23
|
}>;
|
|
24
24
|
minReasoningTier: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>, z.ZodLiteral<4>, z.ZodLiteral<5>]>;
|
|
25
25
|
minCodeQualityTier: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>, z.ZodLiteral<4>, z.ZodLiteral<5>]>;
|
|
@@ -3,6 +3,41 @@ import { type ArtifactManifest, type ContextRef, type PrivacyClass } from "../co
|
|
|
3
3
|
import type { TaskSignals } from "../router/types";
|
|
4
4
|
import type { StorageProvider } from "../storage/provider";
|
|
5
5
|
import { type CoordinatorDeps, type RoleTaskResult } from "./coordinator";
|
|
6
|
+
/**
|
|
7
|
+
* Operator-facing deprecation notice for legacy SDD authority.
|
|
8
|
+
*
|
|
9
|
+
* Legacy authority means using `progress.md` as the authoritative ledger for
|
|
10
|
+
* task completion in the SDD loop (`runSddTask` / `runSddPlan`). The ability
|
|
11
|
+
* to **import** an existing `progress.md` into graph authority is NOT
|
|
12
|
+
* deprecated and will remain available after v1.0.0.
|
|
13
|
+
*
|
|
14
|
+
* **Reachability note (2026-08-23):** As of this date, neither `runSddTask`
|
|
15
|
+
* nor `runSddPlan` has a production caller — the two entry points
|
|
16
|
+
* (`src/index.ts`, `src/cli.ts`) do not import them. No operator will see
|
|
17
|
+
* this warning today. The warning exists as defence-in-depth: if a future
|
|
18
|
+
* change wires the SDD loop back into a production path, reachability and
|
|
19
|
+
* operator notification arrive together. An invariant test in
|
|
20
|
+
* `tests/orchestrator/sdd-unreachability.test.ts` enforces this.
|
|
21
|
+
*/
|
|
22
|
+
export declare const LEGACY_AUTHORITY_DEPRECATION_WARNING: string;
|
|
23
|
+
/**
|
|
24
|
+
* Emits the deprecation warning once per process when legacy SDD authority is
|
|
25
|
+
* exercised. The `warn` callback defaults to `console.warn`; tests inject a
|
|
26
|
+
* spy to verify the seam reaches the operator channel.
|
|
27
|
+
*
|
|
28
|
+
* Currently no production code path calls this function — it is defence-in-
|
|
29
|
+
* depth so that if `runSddTask` / `runSddPlan` are wired back into a
|
|
30
|
+
* production caller, the operator is immediately notified of the deprecation.
|
|
31
|
+
*
|
|
32
|
+
* @returns `true` if the warning was emitted on this call, `false` if it was
|
|
33
|
+
* already emitted in a prior call (once-only guard).
|
|
34
|
+
*/
|
|
35
|
+
export declare function emitLegacyAuthorityWarning(warn?: (message: string) => void): boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Resets the once-only deprecation state. **Test-only** — production code must
|
|
38
|
+
* never call this; the flag is per-process by design.
|
|
39
|
+
*/
|
|
40
|
+
export declare function _resetLegacyAuthorityWarning(): void;
|
|
6
41
|
/**
|
|
7
42
|
* Loop de **subagent-driven-development** (SDD), adaptado de obra/superpowers al
|
|
8
43
|
* boundary de openteam. Por cada tarea:
|
|
@@ -59,6 +94,11 @@ export type SddDeps = CoordinatorDeps & {
|
|
|
59
94
|
maxFixRounds?: number;
|
|
60
95
|
parentSessionID?: string;
|
|
61
96
|
directory?: string;
|
|
97
|
+
/**
|
|
98
|
+
* Callback for operator-facing warnings (defaults to `console.warn`).
|
|
99
|
+
* Used by the legacy authority deprecation to reach the operator channel.
|
|
100
|
+
*/
|
|
101
|
+
onWarning?: (message: string) => void;
|
|
62
102
|
};
|
|
63
103
|
export type SddTaskStatus = "complete" | "failed" | "skipped";
|
|
64
104
|
export type SddTaskOutcome = {
|
|
@@ -115,12 +155,26 @@ export declare function extractResponseText(response: unknown): string;
|
|
|
115
155
|
* propio intérprete vía `deps.interpretReview`.
|
|
116
156
|
*/
|
|
117
157
|
export declare function defaultReviewVerdict(review: RoleTaskResult): ReviewVerdict;
|
|
118
|
-
/**
|
|
158
|
+
/**
|
|
159
|
+
* Ejecuta una única tarea del loop SDD (con reanudación desde el ledger).
|
|
160
|
+
*
|
|
161
|
+
* @deprecated Legacy SDD authority (progress.md as task-completion ledger)
|
|
162
|
+
* will be removed in v1.0.0. Use graph authority instead.
|
|
163
|
+
* See docs/guide/graph-migration.md.
|
|
164
|
+
* **Note:** This function currently has no production caller — it is only
|
|
165
|
+
* invoked by tests. The deprecation warning is defence-in-depth.
|
|
166
|
+
*/
|
|
119
167
|
export declare function runSddTask(task: SddTask, deps: SddDeps): Promise<SddTaskOutcome>;
|
|
120
168
|
/**
|
|
121
169
|
* Ejecuta un plan SDD **en orden** (las tareas son secuenciales por diseño; la
|
|
122
170
|
* paralelización de tareas independientes es otra capa). Reanuda saltando las ya
|
|
123
171
|
* completas y resume el resultado por estado.
|
|
172
|
+
*
|
|
173
|
+
* @deprecated Legacy SDD authority (progress.md as task-completion ledger)
|
|
174
|
+
* will be removed in v1.0.0. Use graph authority instead.
|
|
175
|
+
* See docs/guide/graph-migration.md.
|
|
176
|
+
* **Note:** This function currently has no production caller — it is only
|
|
177
|
+
* invoked by tests. The deprecation warning is defence-in-depth.
|
|
124
178
|
*/
|
|
125
179
|
export declare function runSddPlan(tasks: readonly SddTask[], deps: SddDeps): Promise<SddPlanResult>;
|
|
126
180
|
//# sourceMappingURL=sdd.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdd.d.ts","sourceRoot":"","sources":["../../src/orchestrator/sdd.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAEvD,OAAO,EACL,KAAK,gBAAgB,EAErB,KAAK,UAAU,EACf,KAAK,YAAY,EAClB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EACL,KAAK,eAAe,EAEpB,KAAK,cAAc,EAEpB,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"sdd.d.ts","sourceRoot":"","sources":["../../src/orchestrator/sdd.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAEvD,OAAO,EACL,KAAK,gBAAgB,EAErB,KAAK,UAAU,EACf,KAAK,YAAY,EAClB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EACL,KAAK,eAAe,EAEpB,KAAK,cAAc,EAEpB,MAAM,eAAe,CAAC;AAqBvB;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,oCAAoC,QAI8B,CAAC;AAEhF;;;;;;;;;;;GAWG;AACH,wBAAgB,0BAA0B,CACxC,IAAI,GAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAmB,GAC7C,OAAO,CAOT;AAED;;;GAGG;AACH,wBAAgB,4BAA4B,IAAI,IAAI,CAEnD;AAED;;;;;;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,CAAC,CAoBxB"}
|
|
@@ -33,8 +33,12 @@ export type SddCompileOptions = {
|
|
|
33
33
|
/** Rondas de revisión revise/re-review a expandir (def: 1). */
|
|
34
34
|
revisionRounds?: number;
|
|
35
35
|
};
|
|
36
|
-
/**
|
|
37
|
-
|
|
36
|
+
/**
|
|
37
|
+
* Digest canónico del spec. Reexportado desde `graph/ids` para no romper a los
|
|
38
|
+
* consumidores del compilador; la implementación vive en la capa de grafo
|
|
39
|
+
* porque el espejo shadow la necesita sin alcanzar este módulo.
|
|
40
|
+
*/
|
|
41
|
+
export { graphSpecDigest } from "../graph/ids";
|
|
38
42
|
/**
|
|
39
43
|
* Compila una tarea SDD legacy a un `GraphSpecV1` validado. Lanza
|
|
40
44
|
* `SddCompileError` ante rol/autor/spec inválidos, siempre **antes** de
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sddCompiler.d.ts","sourceRoot":"","sources":["../../src/orchestrator/sddCompiler.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,WAAW,EAEjB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAA4B,KAAK,OAAO,EAAE,MAAM,OAAO,CAAC;AAE/D;;;;;;;;;;;;;;;;;GAiBG;AAEH,0EAA0E;AAC1E,MAAM,MAAM,mBAAmB,GAC3B,cAAc,GACd,oBAAoB,GACpB,cAAc,CAAC;AAEnB,iDAAiD;AACjD,qBAAa,eAAgB,SAAQ,KAAK;IACxC,QAAQ,CAAC,IAAI,EAAE,mBAAmB,CAAC;IACnC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"sddCompiler.d.ts","sourceRoot":"","sources":["../../src/orchestrator/sddCompiler.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,WAAW,EAEjB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAA4B,KAAK,OAAO,EAAE,MAAM,OAAO,CAAC;AAE/D;;;;;;;;;;;;;;;;;GAiBG;AAEH,0EAA0E;AAC1E,MAAM,MAAM,mBAAmB,GAC3B,cAAc,GACd,oBAAoB,GACpB,cAAc,CAAC;AAEnB,iDAAiD;AACjD,qBAAa,eAAgB,SAAQ,KAAK;IACxC,QAAQ,CAAC,IAAI,EAAE,mBAAmB,CAAC;IACnC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,YAAY,IAAI,EAAE,mBAAmB,EAAE,MAAM,EAAE,MAAM,EAKpD;CACF;AAED,+BAA+B;AAC/B,MAAM,MAAM,iBAAiB,GAAG;IAC9B,2DAA2D;IAC3D,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,+DAA+D;IAC/D,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB,CAAC;AAwBF;;;;GAIG;AACH,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAE/C;;;;GAIG;AACH,wBAAgB,cAAc,CAC5B,IAAI,EAAE,OAAO,EACb,OAAO,GAAE,iBAAsB,GAC9B,WAAW,CA0Db"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { ExecLike } from "../local/foundry-local";
|
|
2
|
+
/** Taxonomía cerrada de errores del adapter de worktrees. */
|
|
3
|
+
export type WorktreeErrorCode = "invalid-run" | "git-failed" | "corrupt-list";
|
|
4
|
+
/** Error tipado de una operación inválida del ciclo de vida del worktree. */
|
|
5
|
+
export declare class WorktreeError extends Error {
|
|
6
|
+
readonly code: WorktreeErrorCode;
|
|
7
|
+
readonly detail: string;
|
|
8
|
+
constructor(code: WorktreeErrorCode, detail: string);
|
|
9
|
+
}
|
|
10
|
+
/** Información observada de un worktree del namespace de openteam. */
|
|
11
|
+
export type WorktreeInfo = {
|
|
12
|
+
readonly runID: string;
|
|
13
|
+
/** Ruta reportada por git (separadores `/`, usable por `node:fs`). */
|
|
14
|
+
readonly path: string;
|
|
15
|
+
readonly head: string | undefined;
|
|
16
|
+
readonly detached: boolean;
|
|
17
|
+
readonly locked: boolean;
|
|
18
|
+
};
|
|
19
|
+
/** Configuración inyectada del adapter. */
|
|
20
|
+
export type WorktreeAdapterConfig = {
|
|
21
|
+
readonly exec: ExecLike;
|
|
22
|
+
/** Working tree principal del repositorio (destino de `git -C`). */
|
|
23
|
+
readonly repoRoot: string;
|
|
24
|
+
/** Directorio raíz del namespace de worktrees por run. */
|
|
25
|
+
readonly worktreesDir: string;
|
|
26
|
+
};
|
|
27
|
+
/** Contrato del ciclo de vida idempotente y crash-safe de worktrees. */
|
|
28
|
+
export interface WorktreeAdapter {
|
|
29
|
+
/** Crea (o adopta) el worktree del run; reconstruye tras crash. */
|
|
30
|
+
create(runID: string): Promise<WorktreeInfo>;
|
|
31
|
+
/** Lista los worktrees del namespace de openteam. */
|
|
32
|
+
list(): Promise<WorktreeInfo[]>;
|
|
33
|
+
/** Elimina el worktree del run (idempotente). */
|
|
34
|
+
remove(runID: string): Promise<void>;
|
|
35
|
+
/** Poda entradas administrativas huérfanas (idempotente). */
|
|
36
|
+
prune(): Promise<void>;
|
|
37
|
+
}
|
|
38
|
+
export declare function createWorktreeAdapter(config: WorktreeAdapterConfig): WorktreeAdapter;
|
|
39
|
+
//# sourceMappingURL=worktreeAdapter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"worktreeAdapter.d.ts","sourceRoot":"","sources":["../../src/orchestrator/worktreeAdapter.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAqCvD,6DAA6D;AAC7D,MAAM,MAAM,iBAAiB,GAAG,aAAa,GAAG,YAAY,GAAG,cAAc,CAAC;AAE9E,6EAA6E;AAC7E,qBAAa,aAAc,SAAQ,KAAK;IACtC,QAAQ,CAAC,IAAI,EAAE,iBAAiB,CAAC;IACjC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,YAAY,IAAI,EAAE,iBAAiB,EAAE,MAAM,EAAE,MAAM,EAKlD;CACF;AAED,sEAAsE;AACtE,MAAM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