@phyzess/pappra 0.1.0-beta.13 → 0.1.0-beta.18
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 +134 -15
- package/assets/integrations/skills/pappra/SKILL.md +28 -7
- package/assets/integrations/skills/pappra/references/collaboration.md +633 -0
- package/assets/integrations/skills/pappra/references/environment.md +360 -0
- package/assets/integrations/skills/pappra/references/hosts.md +20 -0
- package/assets/integrations/skills/pappra/references/operations.md +36 -5
- package/dist/adapters/pi/recovery-extension.d.ts +65 -0
- package/dist/adapters/pi/recovery-extension.js +238 -0
- package/dist/adapters/pi/session-transition-extension.d.ts +30 -0
- package/dist/adapters/pi/session-transition-extension.js +265 -0
- package/dist/app/automatic-handoff-events.d.ts +26 -0
- package/dist/app/automatic-handoff-events.js +134 -0
- package/dist/app/bounded-file.d.ts +2 -0
- package/dist/app/bounded-file.js +2 -0
- package/dist/app/capability-evidence/claude.d.ts +37 -0
- package/dist/app/capability-evidence/claude.js +206 -0
- package/dist/app/capability-evidence/codex.d.ts +35 -0
- package/dist/app/capability-evidence/codex.js +193 -0
- package/dist/app/capability-evidence/index.d.ts +33 -0
- package/dist/app/capability-evidence/index.js +117 -0
- package/dist/app/capability-evidence/pi.d.ts +73 -0
- package/dist/app/capability-evidence/pi.js +669 -0
- package/dist/app/capability-evidence/shared.d.ts +69 -0
- package/dist/app/capability-evidence/shared.js +195 -0
- package/dist/app/collab-auto-handoff.d.ts +55 -0
- package/dist/app/collab-auto-handoff.js +384 -0
- package/dist/app/collab-bindings.d.ts +57 -0
- package/dist/app/collab-bindings.js +1006 -0
- package/dist/app/collab-bootstrap-transport.d.ts +163 -0
- package/dist/app/collab-bootstrap-transport.js +769 -0
- package/dist/app/collab-bootstrap.d.ts +137 -0
- package/dist/app/collab-bootstrap.js +3455 -0
- package/dist/app/collab-handoff.d.ts +12 -0
- package/dist/app/collab-handoff.js +511 -0
- package/dist/app/collab-messages.d.ts +2 -0
- package/dist/app/collab-messages.js +2 -0
- package/dist/app/collab-notify.d.ts +156 -0
- package/dist/app/collab-notify.js +1208 -0
- package/dist/app/collab-preflight.d.ts +34 -0
- package/dist/app/collab-preflight.js +96 -0
- package/dist/app/collab-recovery-executor.d.ts +161 -0
- package/dist/app/collab-recovery-executor.js +1153 -0
- package/dist/app/collab-recovery-projection.d.ts +103 -0
- package/dist/app/collab-recovery-projection.js +659 -0
- package/dist/app/collab-recovery.d.ts +25 -0
- package/dist/app/collab-recovery.js +429 -0
- package/dist/app/collab-resources.d.ts +16 -0
- package/dist/app/collab-resources.js +278 -0
- package/dist/app/collab-role-events.d.ts +22 -0
- package/dist/app/collab-role-events.js +329 -0
- package/dist/app/collab-role-orchestration.d.ts +53 -0
- package/dist/app/collab-role-orchestration.js +601 -0
- package/dist/app/collab-role-plan.d.ts +81 -0
- package/dist/app/collab-role-plan.js +504 -0
- package/dist/app/collab-role-repair.d.ts +109 -0
- package/dist/app/collab-role-repair.js +821 -0
- package/dist/app/collab-rollover.d.ts +263 -0
- package/dist/app/collab-rollover.js +1112 -0
- package/dist/app/collab-route.d.ts +64 -0
- package/dist/app/collab-route.js +240 -0
- package/dist/app/collab-session-transition.d.ts +221 -0
- package/dist/app/collab-session-transition.js +3334 -0
- package/dist/app/collab-state.d.ts +7 -0
- package/dist/app/collab-state.js +162 -0
- package/dist/app/collab-task-store.d.ts +22 -0
- package/dist/app/collab-task-store.js +204 -0
- package/dist/app/collab-work-execution.d.ts +127 -0
- package/dist/app/collab-work-execution.js +1027 -0
- package/dist/app/collab-work-plan.d.ts +87 -0
- package/dist/app/collab-work-plan.js +437 -0
- package/dist/app/collaboration.d.ts +8 -2
- package/dist/app/collaboration.js +101 -12
- package/dist/app/doctor.js +108 -5
- package/dist/app/host-mcp.js +34 -8
- package/dist/app/host-probe.js +4 -4
- package/dist/app/init.d.ts +58 -4
- package/dist/app/init.js +768 -155
- package/dist/app/managed-pi-bootstrap-admission.d.ts +14 -0
- package/dist/app/managed-pi-bootstrap-admission.js +104 -0
- package/dist/app/managed-pi-bootstrap-refresh.d.ts +10 -0
- package/dist/app/managed-pi-bootstrap-refresh.js +78 -0
- package/dist/app/managed-pi-delivery.d.ts +8 -0
- package/dist/app/managed-pi-delivery.js +110 -0
- package/dist/app/managed-pi-handoff-receiver.d.ts +15 -0
- package/dist/app/managed-pi-handoff-receiver.js +263 -0
- package/dist/app/managed-pi-handoff-reference.d.ts +3 -0
- package/dist/app/managed-pi-handoff-reference.js +60 -0
- package/dist/app/managed-pi-herdr.d.ts +21 -0
- package/dist/app/managed-pi-herdr.js +185 -0
- package/dist/app/managed-pi-initial-admission.d.ts +28 -0
- package/dist/app/managed-pi-initial-admission.js +416 -0
- package/dist/app/managed-pi-initial-launch.d.ts +5 -0
- package/dist/app/managed-pi-initial-launch.js +61 -0
- package/dist/app/managed-pi-native-observation.d.ts +36 -0
- package/dist/app/managed-pi-native-observation.js +191 -0
- package/dist/app/managed-pi-readiness.d.ts +29 -0
- package/dist/app/managed-pi-readiness.js +288 -0
- package/dist/app/managed-pi-repair-stop.d.ts +21 -0
- package/dist/app/managed-pi-repair-stop.js +371 -0
- package/dist/app/managed-pi-resume-admission.d.ts +32 -0
- package/dist/app/managed-pi-resume-admission.js +618 -0
- package/dist/app/managed-pi-retirement.d.ts +28 -0
- package/dist/app/managed-pi-retirement.js +112 -0
- package/dist/app/managed-pi-sdk-control.d.ts +7 -0
- package/dist/app/managed-pi-sdk-control.js +169 -0
- package/dist/app/managed-pi-sdk-runtime.d.ts +3 -0
- package/dist/app/managed-pi-sdk-runtime.js +483 -0
- package/dist/app/managed-pi-source-admission.d.ts +14 -0
- package/dist/app/managed-pi-source-admission.js +323 -0
- package/dist/app/managed-pi-transition-host.d.ts +36 -0
- package/dist/app/managed-pi-transition-host.js +292 -0
- package/dist/app/managed-pi.d.ts +54 -0
- package/dist/app/managed-pi.js +248 -0
- package/dist/app/shell-readiness.d.ts +66 -0
- package/dist/app/shell-readiness.js +368 -0
- package/dist/app/task-pin.d.ts +2 -23
- package/dist/app/task-pin.js +2 -113
- package/dist/cli/commands/collaboration-binding.d.ts +13 -0
- package/dist/cli/commands/collaboration-binding.js +118 -0
- package/dist/cli/commands/collaboration-bootstrap.d.ts +10 -0
- package/dist/cli/commands/collaboration-bootstrap.js +84 -0
- package/dist/cli/commands/collaboration-capabilities.d.ts +13 -0
- package/dist/cli/commands/collaboration-capabilities.js +127 -0
- package/dist/cli/commands/collaboration-handoff.d.ts +13 -0
- package/dist/cli/commands/collaboration-handoff.js +102 -0
- package/dist/cli/commands/collaboration-message.d.ts +17 -0
- package/dist/cli/commands/collaboration-message.js +177 -0
- package/dist/cli/commands/collaboration-plan.d.ts +8 -0
- package/dist/cli/commands/collaboration-plan.js +108 -0
- package/dist/cli/commands/collaboration-preflight.d.ts +10 -0
- package/dist/cli/commands/collaboration-preflight.js +167 -0
- package/dist/cli/commands/collaboration-recovery-run.d.ts +46 -0
- package/dist/cli/commands/collaboration-recovery-run.js +224 -0
- package/dist/cli/commands/collaboration-recovery.d.ts +11 -0
- package/dist/cli/commands/collaboration-recovery.js +104 -0
- package/dist/cli/commands/collaboration-resources.d.ts +11 -0
- package/dist/cli/commands/collaboration-resources.js +96 -0
- package/dist/cli/commands/collaboration-role-plan.d.ts +9 -0
- package/dist/cli/commands/collaboration-role-plan.js +69 -0
- package/dist/cli/commands/collaboration-role-run.d.ts +11 -0
- package/dist/cli/commands/collaboration-role-run.js +128 -0
- package/dist/cli/commands/collaboration-rollover.d.ts +10 -0
- package/dist/cli/commands/collaboration-rollover.js +103 -0
- package/dist/cli/commands/collaboration-state.d.ts +10 -0
- package/dist/cli/commands/collaboration-state.js +96 -0
- package/dist/cli/commands/collaboration-transition.d.ts +10 -0
- package/dist/cli/commands/collaboration-transition.js +75 -0
- package/dist/cli/commands/collaboration-work-run.d.ts +34 -0
- package/dist/cli/commands/collaboration-work-run.js +178 -0
- package/dist/cli/commands/collaboration.d.ts +4 -0
- package/dist/cli/commands/collaboration.js +39 -4
- package/dist/cli/commands/continuity.js +2 -6
- package/dist/cli/commands/docs.d.ts +2 -0
- package/dist/cli/commands/docs.js +89 -15
- package/dist/cli/commands/host.d.ts +7 -1
- package/dist/cli/commands/host.js +122 -7
- package/dist/cli/commands/init.d.ts +20 -3
- package/dist/cli/commands/init.js +897 -232
- package/dist/cli/commands/mcp.d.ts +1 -0
- package/dist/cli/commands/mcp.js +11 -5
- package/dist/cli/commands/repair.d.ts +12 -0
- package/dist/cli/commands/repair.js +41 -0
- package/dist/cli/commands/runtime.d.ts +1 -1
- package/dist/cli/commands/runtime.js +139 -38
- package/dist/cli/commands/session.d.ts +7 -0
- package/dist/cli/commands/session.js +82 -0
- package/dist/cli/commands/task.js +19 -5
- package/dist/cli/run.js +866 -24
- package/dist/code/identity.d.ts +7 -0
- package/dist/code/identity.js +7 -3
- package/dist/code/registration.js +7 -0
- package/dist/code/service.d.ts +9 -0
- package/dist/code/service.js +16 -3
- package/dist/code/text.js +19 -7
- package/dist/collab/admission.d.ts +91 -66
- package/dist/collab/admission.js +21 -6
- package/dist/collab/canonical.d.ts +1 -1
- package/dist/collab/canonical.js +44 -3
- package/dist/collab/envelope.d.ts +2 -2
- package/dist/collab/envelope.js +12 -12
- package/dist/collab/first-work.d.ts +3 -0
- package/dist/collab/first-work.js +15 -0
- package/dist/collab/handoff.d.ts +16 -0
- package/dist/collab/handoff.js +39 -5
- package/dist/collab/index.d.ts +97 -1
- package/dist/collab/index.js +9 -1
- package/dist/collab/messages.js +126 -3
- package/dist/collab/persisted-messages.d.ts +123 -0
- package/dist/collab/persisted-messages.js +496 -0
- package/dist/collab/preflight.d.ts +1 -1
- package/dist/collab/resources.d.ts +13 -3
- package/dist/collab/resources.js +37 -6
- package/dist/collab/rollover.d.ts +311 -0
- package/dist/collab/rollover.js +1024 -0
- package/dist/collab/store.d.ts +1 -0
- package/dist/collab/store.js +1 -4
- package/dist/collab/types.d.ts +2 -354
- package/dist/collab/validation.d.ts +2 -10
- package/dist/collab/validation.js +2 -303
- package/dist/collab/work-plan.d.ts +105 -0
- package/dist/collab/work-plan.js +843 -0
- package/dist/continuity/context.d.ts +11 -2
- package/dist/continuity/context.js +100 -13
- package/dist/continuity/handoff-bundle.d.ts +296 -0
- package/dist/continuity/handoff-bundle.js +477 -0
- package/dist/continuity/index.d.ts +2 -0
- package/dist/continuity/index.js +1 -0
- package/dist/continuity/paths.js +10 -2
- package/dist/continuity/service.js +91 -15
- package/dist/continuity/task-pin.d.ts +24 -0
- package/dist/continuity/task-pin.js +590 -0
- package/dist/doctor.d.ts +1 -0
- package/dist/doctor.js +6 -0
- package/dist/experimental/index.d.ts +13 -0
- package/dist/experimental/index.js +25 -0
- package/dist/experimental/pi.d.ts +4 -0
- package/dist/experimental/pi.js +12 -0
- package/dist/hosts/claude/native.js +1 -1
- package/dist/hosts/codex/native.js +1 -1
- package/dist/hosts/codex/protocol.js +1 -1
- package/dist/hosts/integration/bootstrap-config.d.ts +58 -0
- package/dist/hosts/integration/bootstrap-config.js +254 -0
- package/dist/hosts/integration/bundle-export.d.ts +44 -0
- package/dist/hosts/integration/bundle-export.js +366 -3
- package/dist/hosts/integration/bundle.js +3 -0
- package/dist/hosts/integration/hook.js +36 -9
- package/dist/hosts/integration/pappra-bootstrap-extension.mjs +80 -0
- package/dist/hosts/integration/pappra-extension-runtime.mjs +59 -24631
- package/dist/hosts/integration/pappra-hook.mjs +61 -24749
- package/dist/hosts/integration/pappra-recovery-extension.mjs +259 -0
- package/dist/hosts/integration/pappra-session-transition-extension.mjs +276 -0
- package/dist/hosts/integration/pi-bootstrap-extension.d.ts +36 -0
- package/dist/hosts/integration/pi-bootstrap-extension.js +101 -0
- package/dist/hosts/integration/pi-bootstrap-guard.d.ts +125 -0
- package/dist/hosts/integration/pi-bootstrap-guard.js +438 -0
- package/dist/hosts/integration/pi-bootstrap-runtime.d.ts +63 -0
- package/dist/hosts/integration/pi-bootstrap-runtime.js +223 -0
- package/dist/hosts/integration/pi-native-events.d.ts +112 -0
- package/dist/hosts/integration/pi-native-events.js +348 -0
- package/dist/hosts/integration/pi-rollover-extension.d.ts +166 -0
- package/dist/hosts/integration/pi-rollover-extension.js +431 -0
- package/dist/hosts/integration/recovery-config.d.ts +48 -0
- package/dist/hosts/integration/recovery-config.js +117 -0
- package/dist/hosts/integration/service.d.ts +6 -1
- package/dist/hosts/integration/service.js +485 -35
- package/dist/hosts/integration/support.d.ts +7 -0
- package/dist/hosts/integration/support.js +9 -1
- package/dist/hosts/integration/templates.d.ts +3 -0
- package/dist/hosts/integration/templates.js +26 -3
- package/dist/hosts/pi/managed-host-identity.d.ts +2 -0
- package/dist/hosts/pi/managed-host-identity.js +40 -0
- package/dist/hosts/pi/managed-provider-diagnostics.d.ts +6 -0
- package/dist/hosts/pi/managed-provider-diagnostics.js +184 -0
- package/dist/hosts/pi/managed-sdk-session.d.ts +335 -0
- package/dist/hosts/pi/managed-sdk-session.js +1639 -0
- package/dist/hosts/pi/managed-session-extension.d.ts +20 -0
- package/dist/hosts/pi/managed-session-extension.js +84 -0
- package/dist/hosts/pi/managed-session.d.ts +177 -0
- package/dist/hosts/pi/managed-session.js +1557 -0
- package/dist/hosts/pi/protocol.js +1 -1
- package/dist/hosts/pi/query-result.js +1 -1
- package/dist/hosts/pi/resume-capability.d.ts +41 -0
- package/dist/hosts/pi/resume-capability.js +33 -0
- package/dist/hosts/pi/rpc.d.ts +182 -134
- package/dist/hosts/pi/rpc.js +230 -37
- package/dist/hosts/pilot.d.ts +97 -74
- package/dist/hosts/pilot.js +5 -1
- package/dist/hosts/version.d.ts +3 -0
- package/dist/hosts/version.js +18 -0
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/infra/bounded-file.d.ts +19 -0
- package/dist/infra/bounded-file.js +66 -0
- package/dist/infra/fs.js +10 -2
- package/dist/infra/git.d.ts +29 -0
- package/dist/infra/git.js +45 -9
- package/dist/infra/json-property.d.ts +2 -0
- package/dist/infra/json-property.js +69 -0
- package/dist/infra/json.d.ts +4 -0
- package/dist/infra/json.js +24 -0
- package/dist/infra/owned-process-group.js +1 -1
- package/dist/infra/private-lock.d.ts +16 -0
- package/dist/infra/private-lock.js +148 -0
- package/dist/infra/private-state.d.ts +7 -0
- package/dist/infra/private-state.js +146 -0
- package/dist/infra/process-identity.d.ts +12 -0
- package/dist/infra/process-identity.js +142 -0
- package/dist/infra/validation.d.ts +5 -0
- package/dist/infra/validation.js +15 -0
- package/dist/init.d.ts +1 -0
- package/dist/init.js +6 -0
- package/dist/install/apply.d.ts +9 -1
- package/dist/install/apply.js +176 -12
- package/dist/install/dependencies.d.ts +38 -0
- package/dist/install/dependencies.js +282 -0
- package/dist/install/ownership.js +30 -1
- package/dist/install/references.d.ts +31 -0
- package/dist/install/references.js +208 -0
- package/dist/install/repair.d.ts +37 -0
- package/dist/install/repair.js +798 -0
- package/dist/install/reset-local.d.ts +16 -0
- package/dist/install/reset-local.js +304 -0
- package/dist/install/rollback.d.ts +3 -0
- package/dist/install/rollback.js +9 -3
- package/dist/install/runtime.d.ts +10 -6
- package/dist/install/runtime.js +299 -59
- package/dist/install/source-fingerprint.d.ts +2 -0
- package/dist/install/source-fingerprint.js +103 -0
- package/dist/knowledge/catalog.d.ts +1 -0
- package/dist/knowledge/catalog.js +143 -10
- package/dist/knowledge/journal.js +17 -7
- package/dist/knowledge/paths.js +2 -1
- package/dist/knowledge/refs.js +4 -0
- package/dist/knowledge/register-batch.d.ts +4 -0
- package/dist/knowledge/register-batch.js +225 -0
- package/dist/knowledge/relocate.d.ts +5 -0
- package/dist/knowledge/relocate.js +92 -0
- package/dist/knowledge/scan.js +103 -47
- package/dist/knowledge/service.d.ts +3 -0
- package/dist/knowledge/service.js +33 -1
- package/dist/knowledge/write.d.ts +4 -1
- package/dist/knowledge/write.js +1 -1
- package/dist/mcp/server.d.ts +4 -2
- package/dist/mcp/server.js +87 -136
- package/dist/schemas/collaboration-state-validation.d.ts +6 -0
- package/dist/schemas/collaboration-state-validation.js +342 -0
- package/dist/schemas/collaboration-state.d.ts +436 -0
- package/dist/schemas/collaboration-state.js +1 -0
- package/dist/schemas/collaboration.d.ts +335 -0
- package/dist/schemas/collaboration.js +272 -0
- package/dist/schemas/continuity.d.ts +8 -0
- package/dist/schemas/continuity.js +13 -3
- package/dist/schemas/doctor.d.ts +1 -0
- package/dist/schemas/doctor.js +1 -0
- package/dist/schemas/document.d.ts +61 -0
- package/dist/schemas/document.js +9 -0
- package/dist/schemas/errors.d.ts +1 -0
- package/dist/schemas/errors.js +1 -0
- package/dist/schemas/host.d.ts +24 -0
- package/dist/schemas/host.js +19 -0
- package/dist/schemas/install.d.ts +8 -2
- package/dist/schemas/install.js +11 -1
- package/dist/schemas/managed-pi-execution.d.ts +16 -0
- package/dist/schemas/managed-pi-execution.js +2 -0
- package/dist/schemas/outcome.d.ts +9 -5
- package/dist/workspace/config-file.js +1 -3
- package/dist/workspace/documents.js +12 -2
- package/dist/workspace/repositories.d.ts +7 -0
- package/dist/workspace/repositories.js +14 -5
- package/package.json +35 -35
- package/skills/pappra/SKILL.md +28 -7
- package/skills/pappra/references/collaboration.md +633 -0
- package/skills/pappra/references/environment.md +360 -0
- package/skills/pappra/references/hosts.md +20 -0
- package/skills/pappra/references/operations.md +36 -5
- package/dist/app/collab-from.d.ts +0 -35
- package/dist/app/collab-from.js +0 -84
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { type LocalProcessIdentity } from '../infra/process-identity.js';
|
|
2
3
|
export declare const DOCUMENT_SCHEMA = "pappra/document/1";
|
|
3
4
|
export declare const DOCUMENT_CATALOG_SCHEMA = "pappra/document-catalog/1";
|
|
4
5
|
export declare const DOCUMENT_WRITE_PROPOSAL_SCHEMA = "pappra/document-write-proposal/1";
|
|
@@ -115,6 +116,65 @@ export declare const documentRecordSchema: z.ZodObject<{
|
|
|
115
116
|
}>;
|
|
116
117
|
}, z.core.$strict>;
|
|
117
118
|
export type DocumentRecord = z.infer<typeof documentRecordSchema>;
|
|
119
|
+
export declare const documentRecordFileSchema: z.ZodObject<{
|
|
120
|
+
schema: z.ZodLiteral<"pappra/document-record-file/1">;
|
|
121
|
+
workspaceId: z.ZodUUID;
|
|
122
|
+
record: z.ZodObject<{
|
|
123
|
+
schema: z.ZodLiteral<"pappra/document/1">;
|
|
124
|
+
documentId: z.ZodUUID;
|
|
125
|
+
location: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
126
|
+
kind: z.ZodLiteral<"workspace">;
|
|
127
|
+
path: z.ZodString;
|
|
128
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
129
|
+
kind: z.ZodLiteral<"source">;
|
|
130
|
+
sourceId: z.ZodString;
|
|
131
|
+
path: z.ZodString;
|
|
132
|
+
}, z.core.$strict>], "kind">;
|
|
133
|
+
kind: z.ZodEnum<{
|
|
134
|
+
architecture: "architecture";
|
|
135
|
+
checkpoint: "checkpoint";
|
|
136
|
+
decision: "decision";
|
|
137
|
+
delivery: "delivery";
|
|
138
|
+
generated: "generated";
|
|
139
|
+
plan: "plan";
|
|
140
|
+
research: "research";
|
|
141
|
+
review: "review";
|
|
142
|
+
rule: "rule";
|
|
143
|
+
}>;
|
|
144
|
+
lifecycle: z.ZodEnum<{
|
|
145
|
+
active: "active";
|
|
146
|
+
archived: "archived";
|
|
147
|
+
superseded: "superseded";
|
|
148
|
+
}>;
|
|
149
|
+
maturity: z.ZodEnum<{
|
|
150
|
+
draft: "draft";
|
|
151
|
+
reviewed: "reviewed";
|
|
152
|
+
}>;
|
|
153
|
+
taskId: z.ZodNullable<z.ZodString>;
|
|
154
|
+
owner: z.ZodEnum<{
|
|
155
|
+
agent: "agent";
|
|
156
|
+
generator: "generator";
|
|
157
|
+
human: "human";
|
|
158
|
+
}>;
|
|
159
|
+
digest: z.ZodString;
|
|
160
|
+
sources: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
161
|
+
kind: z.ZodLiteral<"document">;
|
|
162
|
+
documentId: z.ZodUUID;
|
|
163
|
+
digest: z.ZodString;
|
|
164
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
165
|
+
kind: z.ZodLiteral<"code">;
|
|
166
|
+
repositoryId: z.ZodString;
|
|
167
|
+
path: z.ZodString;
|
|
168
|
+
version: z.ZodString;
|
|
169
|
+
}, z.core.$strict>], "kind">>;
|
|
170
|
+
supersededBy: z.ZodNullable<z.ZodUUID>;
|
|
171
|
+
lastReviewedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
172
|
+
visibility: z.ZodEnum<{
|
|
173
|
+
private: "private";
|
|
174
|
+
shareable: "shareable";
|
|
175
|
+
}>;
|
|
176
|
+
}, z.core.$strict>;
|
|
177
|
+
}, z.core.$strict>;
|
|
118
178
|
export declare const documentCatalogSchema: z.ZodObject<{
|
|
119
179
|
schema: z.ZodLiteral<"pappra/document-catalog/1">;
|
|
120
180
|
workspaceId: z.ZodUUID;
|
|
@@ -335,6 +395,7 @@ export declare const knowledgeLockSchema: z.ZodObject<{
|
|
|
335
395
|
"write-document": "write-document";
|
|
336
396
|
}>;
|
|
337
397
|
pid: z.ZodNumber;
|
|
398
|
+
process_identity: z.ZodOptional<z.ZodCustom<LocalProcessIdentity, LocalProcessIdentity>>;
|
|
338
399
|
createdAt: z.ZodISODateTime;
|
|
339
400
|
}, z.core.$strict>;
|
|
340
401
|
export type KnowledgeLock = z.infer<typeof knowledgeLockSchema>;
|
package/dist/schemas/document.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { isLocalProcessIdentity, } from '../infra/process-identity.js';
|
|
2
3
|
import { isPortableRelativePath, normalizePortableRelativePath, } from './paths.js';
|
|
3
4
|
export const DOCUMENT_SCHEMA = 'pappra/document/1';
|
|
4
5
|
export const DOCUMENT_CATALOG_SCHEMA = 'pappra/document-catalog/1';
|
|
@@ -102,6 +103,11 @@ export const documentRecordSchema = documentRecordBaseSchema.superRefine((record
|
|
|
102
103
|
});
|
|
103
104
|
}
|
|
104
105
|
});
|
|
106
|
+
export const documentRecordFileSchema = z.strictObject({
|
|
107
|
+
schema: z.literal('pappra/document-record-file/1'),
|
|
108
|
+
workspaceId: z.uuid(),
|
|
109
|
+
record: documentRecordSchema,
|
|
110
|
+
});
|
|
105
111
|
export const documentCatalogSchema = z.strictObject({
|
|
106
112
|
schema: z.literal(DOCUMENT_CATALOG_SCHEMA),
|
|
107
113
|
workspaceId: z.uuid(),
|
|
@@ -202,6 +208,9 @@ export const knowledgeLockSchema = z.strictObject({
|
|
|
202
208
|
token: z.uuid(),
|
|
203
209
|
operation: knowledgeOperationSchema,
|
|
204
210
|
pid: z.number().int().positive(),
|
|
211
|
+
process_identity: z
|
|
212
|
+
.custom(isLocalProcessIdentity)
|
|
213
|
+
.optional(),
|
|
205
214
|
createdAt: z.iso.datetime({ offset: true }),
|
|
206
215
|
});
|
|
207
216
|
export const knowledgeJournalSchema = z.strictObject({
|
package/dist/schemas/errors.d.ts
CHANGED
|
@@ -29,6 +29,7 @@ export declare const diagnosticCodes: {
|
|
|
29
29
|
readonly initApplyFailed: 'init_apply_failed';
|
|
30
30
|
readonly initApplyResidual: 'init_apply_residual';
|
|
31
31
|
readonly initRuntimeSourceRequired: 'init_runtime_source_required';
|
|
32
|
+
readonly runtimeStateIncompatible: 'runtime_state_incompatible';
|
|
32
33
|
readonly initCancelled: 'init_cancelled';
|
|
33
34
|
readonly fileInvalidEncoding: 'file_invalid_encoding';
|
|
34
35
|
readonly configMissing: 'config_missing';
|
package/dist/schemas/errors.js
CHANGED
|
@@ -29,6 +29,7 @@ export const diagnosticCodes = {
|
|
|
29
29
|
initApplyFailed: 'init_apply_failed',
|
|
30
30
|
initApplyResidual: 'init_apply_residual',
|
|
31
31
|
initRuntimeSourceRequired: 'init_runtime_source_required',
|
|
32
|
+
runtimeStateIncompatible: 'runtime_state_incompatible',
|
|
32
33
|
initCancelled: 'init_cancelled',
|
|
33
34
|
fileInvalidEncoding: 'file_invalid_encoding',
|
|
34
35
|
configMissing: 'config_missing',
|
package/dist/schemas/host.d.ts
CHANGED
|
@@ -434,3 +434,27 @@ export declare const hostInstallManifestSchema: z.ZodObject<{
|
|
|
434
434
|
trustRequired: z.ZodBoolean;
|
|
435
435
|
}, z.core.$strict>;
|
|
436
436
|
export type HostInstallManifest = z.infer<typeof hostInstallManifestSchema>;
|
|
437
|
+
export declare const hostUninstallResultSchema: z.ZodObject<{
|
|
438
|
+
schema: z.ZodLiteral<"pappra/host-uninstall/1">;
|
|
439
|
+
host: z.ZodEnum<{
|
|
440
|
+
claude: "claude";
|
|
441
|
+
codex: "codex";
|
|
442
|
+
pi: "pi";
|
|
443
|
+
}>;
|
|
444
|
+
hostRoot: z.ZodString;
|
|
445
|
+
ok: z.ZodBoolean;
|
|
446
|
+
status: z.ZodEnum<{
|
|
447
|
+
conflict: "conflict";
|
|
448
|
+
failed: "failed";
|
|
449
|
+
partial: "partial";
|
|
450
|
+
planned: "planned";
|
|
451
|
+
removed: "removed";
|
|
452
|
+
unchanged: "unchanged";
|
|
453
|
+
}>;
|
|
454
|
+
plannedFiles: z.ZodArray<z.ZodString>;
|
|
455
|
+
removedFiles: z.ZodArray<z.ZodString>;
|
|
456
|
+
retainedPaths: z.ZodArray<z.ZodString>;
|
|
457
|
+
quarantinedLocks: z.ZodArray<z.ZodString>;
|
|
458
|
+
diagnostics: z.ZodArray<z.ZodUnknown>;
|
|
459
|
+
}, z.core.$strict>;
|
|
460
|
+
export type HostUninstallResult = z.infer<typeof hostUninstallResultSchema>;
|
package/dist/schemas/host.js
CHANGED
|
@@ -201,3 +201,22 @@ export const hostInstallManifestSchema = z.strictObject({
|
|
|
201
201
|
reloadRequired: z.boolean(),
|
|
202
202
|
trustRequired: z.boolean(),
|
|
203
203
|
});
|
|
204
|
+
export const hostUninstallResultSchema = z.strictObject({
|
|
205
|
+
schema: z.literal('pappra/host-uninstall/1'),
|
|
206
|
+
host: hostNameSchema,
|
|
207
|
+
hostRoot: absolutePathSchema,
|
|
208
|
+
ok: z.boolean(),
|
|
209
|
+
status: z.enum([
|
|
210
|
+
'planned',
|
|
211
|
+
'removed',
|
|
212
|
+
'unchanged',
|
|
213
|
+
'partial',
|
|
214
|
+
'conflict',
|
|
215
|
+
'failed',
|
|
216
|
+
]),
|
|
217
|
+
plannedFiles: z.array(z.string().min(1).max(2048)).max(512),
|
|
218
|
+
removedFiles: z.array(z.string().min(1).max(2048)).max(512),
|
|
219
|
+
retainedPaths: z.array(absolutePathSchema).max(512),
|
|
220
|
+
quarantinedLocks: z.array(absolutePathSchema).max(32),
|
|
221
|
+
diagnostics: z.array(z.unknown()).max(32),
|
|
222
|
+
});
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
|
|
2
|
+
import { type LocalProcessIdentity } from '../infra/process-identity.js';
|
|
3
|
+
export declare const RUNTIME_MANIFEST_SCHEMA = "pappra/runtime-manifest/3";
|
|
4
|
+
export declare const RUNTIME_DIGEST_SCHEME = "sha256-utf8-byte-order-v1";
|
|
3
5
|
export declare const WORKSPACE_MANIFEST_SCHEMA = "pappra/install-manifest/1";
|
|
4
6
|
export declare const INSTALL_JOURNAL_SCHEMA = "pappra/install-journal/1";
|
|
5
7
|
export declare const LOCK_SCHEMA = "pappra/install-lock/1";
|
|
@@ -15,11 +17,13 @@ export declare const installLockSchema: z.ZodObject<{
|
|
|
15
17
|
"install-runtime": "install-runtime";
|
|
16
18
|
"remove-runtime": "remove-runtime";
|
|
17
19
|
"rollback-workspace-files": "rollback-workspace-files";
|
|
20
|
+
"set-auto-resume": "set-auto-resume";
|
|
18
21
|
"uninstall-workspace-files": "uninstall-workspace-files";
|
|
19
22
|
"update-machine-runtime": "update-machine-runtime";
|
|
20
23
|
}>;
|
|
21
24
|
target: z.ZodString;
|
|
22
25
|
pid: z.ZodNumber;
|
|
26
|
+
process_identity: z.ZodOptional<z.ZodCustom<LocalProcessIdentity, LocalProcessIdentity>>;
|
|
23
27
|
createdAt: z.ZodISODateTime;
|
|
24
28
|
}, z.core.$strict>;
|
|
25
29
|
export type InstallLock = z.infer<typeof installLockSchema>;
|
|
@@ -44,7 +48,7 @@ export declare const runtimeSourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
44
48
|
}, z.core.$strict>], "kind">;
|
|
45
49
|
export type RuntimeSource = z.infer<typeof runtimeSourceSchema>;
|
|
46
50
|
export declare const runtimeManifestSchema: z.ZodObject<{
|
|
47
|
-
schema: z.ZodLiteral<"pappra/runtime-manifest/
|
|
51
|
+
schema: z.ZodLiteral<"pappra/runtime-manifest/3">;
|
|
48
52
|
installId: z.ZodUUID;
|
|
49
53
|
packageName: z.ZodString;
|
|
50
54
|
runtimeVersion: z.ZodString;
|
|
@@ -70,6 +74,8 @@ export declare const runtimeManifestSchema: z.ZodObject<{
|
|
|
70
74
|
digest: z.ZodString;
|
|
71
75
|
}, z.core.$strict>], "kind">;
|
|
72
76
|
packageDigest: z.ZodString;
|
|
77
|
+
digestScheme: z.ZodLiteral<"sha256-utf8-byte-order-v1">;
|
|
78
|
+
sourceFingerprint: z.ZodString;
|
|
73
79
|
smoke: z.ZodObject<{
|
|
74
80
|
argv: z.ZodArray<z.ZodString>;
|
|
75
81
|
exitCode: z.ZodNumber;
|
package/dist/schemas/install.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
|
|
2
|
+
import { isLocalProcessIdentity, } from '../infra/process-identity.js';
|
|
3
|
+
export const RUNTIME_MANIFEST_SCHEMA = 'pappra/runtime-manifest/3';
|
|
4
|
+
export const RUNTIME_DIGEST_SCHEME = 'sha256-utf8-byte-order-v1';
|
|
3
5
|
export const WORKSPACE_MANIFEST_SCHEMA = 'pappra/install-manifest/1';
|
|
4
6
|
export const INSTALL_JOURNAL_SCHEMA = 'pappra/install-journal/1';
|
|
5
7
|
export const LOCK_SCHEMA = 'pappra/install-lock/1';
|
|
@@ -24,9 +26,15 @@ export const installLockSchema = z.strictObject({
|
|
|
24
26
|
'uninstall-workspace-files',
|
|
25
27
|
'remove-runtime',
|
|
26
28
|
'update-machine-runtime',
|
|
29
|
+
// Private hook preference toggle guarded by the workspace lock; shared
|
|
30
|
+
// configuration is never rewritten by this operation.
|
|
31
|
+
'set-auto-resume',
|
|
27
32
|
]),
|
|
28
33
|
target: z.string().min(1).max(4096),
|
|
29
34
|
pid: z.number().int().positive(),
|
|
35
|
+
process_identity: z
|
|
36
|
+
.custom(isLocalProcessIdentity)
|
|
37
|
+
.optional(),
|
|
30
38
|
createdAt: z.iso.datetime({ offset: true }),
|
|
31
39
|
});
|
|
32
40
|
export const runtimeSourceSchema = z.discriminatedUnion('kind', [
|
|
@@ -61,6 +69,8 @@ export const runtimeManifestSchema = z.strictObject({
|
|
|
61
69
|
executable: pathSchema,
|
|
62
70
|
source: runtimeSourceSchema,
|
|
63
71
|
packageDigest: digestSchema,
|
|
72
|
+
digestScheme: z.literal(RUNTIME_DIGEST_SCHEME),
|
|
73
|
+
sourceFingerprint: digestSchema,
|
|
64
74
|
smoke: z.strictObject({
|
|
65
75
|
argv: z.array(z.string().max(4096)).max(16),
|
|
66
76
|
exitCode: z.number().int(),
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/** Persisted execution pins shared by orchestration and native host adapters. */
|
|
2
|
+
export declare const MANAGED_PI_EXECUTION_SCOPE_SCHEMA = "pappra/managed-pi-execution-scope/1";
|
|
3
|
+
export interface ManagedPiExecutionScope {
|
|
4
|
+
readonly schema: typeof MANAGED_PI_EXECUTION_SCOPE_SCHEMA;
|
|
5
|
+
readonly task_id: string;
|
|
6
|
+
readonly task_root: string;
|
|
7
|
+
readonly session_id: string;
|
|
8
|
+
readonly cwd: string;
|
|
9
|
+
readonly subtask_id: string;
|
|
10
|
+
readonly attempt: number;
|
|
11
|
+
readonly owner_epoch: number;
|
|
12
|
+
readonly claim_epochs: readonly {
|
|
13
|
+
readonly claim_id: string;
|
|
14
|
+
readonly resource_epoch: number;
|
|
15
|
+
}[];
|
|
16
|
+
}
|
|
@@ -1,15 +1,19 @@
|
|
|
1
1
|
import type { DiagnosticCode } from './errors.js';
|
|
2
2
|
/** Expected rejection; unexpected exceptions are converted at application boundaries. */
|
|
3
|
-
export
|
|
4
|
-
readonly ok: true;
|
|
5
|
-
readonly value: T;
|
|
6
|
-
} | {
|
|
3
|
+
export interface ExpectedFailure {
|
|
7
4
|
readonly ok: false;
|
|
8
5
|
readonly code: DiagnosticCode;
|
|
9
6
|
readonly message: string;
|
|
10
7
|
readonly retryable: boolean;
|
|
11
8
|
readonly nextAction: string | null;
|
|
12
|
-
}
|
|
9
|
+
}
|
|
10
|
+
/** Value-bearing boundaries share one shape; protocol-specific failures retain their typed fields. */
|
|
11
|
+
export type Outcome<T, Rejection extends {
|
|
12
|
+
readonly ok: false;
|
|
13
|
+
} = ExpectedFailure> = {
|
|
14
|
+
readonly ok: true;
|
|
15
|
+
readonly value: T;
|
|
16
|
+
} | Rejection;
|
|
13
17
|
export interface FailureOptions {
|
|
14
18
|
readonly retryable?: boolean;
|
|
15
19
|
readonly nextAction?: string | null;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { object as isRecord } from '../infra/validation.js';
|
|
1
2
|
import { join, resolve } from 'node:path';
|
|
2
3
|
import { createDiagnostic, hasErrors, pointer, } from '../schemas/diagnostics.js';
|
|
3
4
|
import { diagnosticCodes } from '../schemas/errors.js';
|
|
@@ -35,9 +36,6 @@ function issueDiagnostics(issues, source) {
|
|
|
35
36
|
}
|
|
36
37
|
return diagnostics;
|
|
37
38
|
}
|
|
38
|
-
function isRecord(value) {
|
|
39
|
-
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
40
|
-
}
|
|
41
39
|
/**
|
|
42
40
|
* Reads, decodes, validates, and semantically checks one strict JSON
|
|
43
41
|
* configuration file. Missing configuration is reported instead of defaulted.
|
|
@@ -250,6 +250,16 @@ export async function discoverDocuments(input) {
|
|
|
250
250
|
if (entry.isDirectory()) {
|
|
251
251
|
if (depth < depthLimit)
|
|
252
252
|
await visit(child, depth + 1);
|
|
253
|
+
else {
|
|
254
|
+
truncated = true;
|
|
255
|
+
diagnostics.push(createDiagnostic({
|
|
256
|
+
code: diagnosticCodes.discoveryLimitReached,
|
|
257
|
+
severity: 'warning',
|
|
258
|
+
message: `Document directory depth limit reached: ${child}`,
|
|
259
|
+
source: child,
|
|
260
|
+
hint: 'Increase the explicit discovery depth or narrow the knowledge source.',
|
|
261
|
+
}));
|
|
262
|
+
}
|
|
253
263
|
continue;
|
|
254
264
|
}
|
|
255
265
|
if (!entry.isFile() || !isMarkdown(child))
|
|
@@ -294,7 +304,7 @@ export async function discoverDocuments(input) {
|
|
|
294
304
|
const docs = join(directory, 'docs');
|
|
295
305
|
const docsObservation = await observePath(docs);
|
|
296
306
|
if (docsObservation.kind === 'directory') {
|
|
297
|
-
await scanDirectory(docs, 3, repository === null ? 'directory-scan' : 'repository-scan', `${declaredPrefix}:docs`, containmentRoot, null);
|
|
307
|
+
await scanDirectory(docs, Math.max(3, options.scanDepth), repository === null ? 'directory-scan' : 'repository-scan', `${declaredPrefix}:docs`, containmentRoot, null);
|
|
298
308
|
}
|
|
299
309
|
};
|
|
300
310
|
if (config !== null) {
|
|
@@ -342,7 +352,7 @@ export async function discoverDocuments(input) {
|
|
|
342
352
|
await addDocument(real, 'workspace-config', declaredBy, root);
|
|
343
353
|
}
|
|
344
354
|
else if (resolvedObservation.kind === 'directory') {
|
|
345
|
-
await scanDirectory(real, 3, 'workspace-config', declaredBy, root, null);
|
|
355
|
+
await scanDirectory(real, Math.max(3, options.scanDepth), 'workspace-config', declaredBy, root, null);
|
|
346
356
|
}
|
|
347
357
|
}
|
|
348
358
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Diagnostic } from '../schemas/diagnostics.js';
|
|
2
2
|
import { type WorkspaceConfig } from '../schemas/workspace.js';
|
|
3
3
|
import type { MachineConfig } from '../schemas/machine.js';
|
|
4
|
+
import { type GitObservationScope } from '../infra/git.js';
|
|
4
5
|
import type { DiscoveredRepository, NormalizedDiscoveryOptions, UnresolvedRepository } from './types.js';
|
|
5
6
|
export interface RepositoryDiscoveryInput {
|
|
6
7
|
readonly root: string;
|
|
@@ -8,6 +9,12 @@ export interface RepositoryDiscoveryInput {
|
|
|
8
9
|
readonly machine: MachineConfig | null;
|
|
9
10
|
readonly configPath: string;
|
|
10
11
|
readonly options: NormalizedDiscoveryOptions;
|
|
12
|
+
/**
|
|
13
|
+
* One operation's Git probe scope. Discovery and a later identity probe of the
|
|
14
|
+
* same checkout must share it, otherwise identical repository probes are
|
|
15
|
+
* spawned twice. Callers that omit it get a scope scoped to this discovery.
|
|
16
|
+
*/
|
|
17
|
+
readonly observations?: GitObservationScope;
|
|
11
18
|
}
|
|
12
19
|
export interface RepositoryDiscoveryOutput {
|
|
13
20
|
readonly repositories: readonly DiscoveredRepository[];
|
|
@@ -4,9 +4,12 @@ import { createDiagnostic, pointer } from '../schemas/diagnostics.js';
|
|
|
4
4
|
import { diagnosticCodes } from '../schemas/errors.js';
|
|
5
5
|
import { externalRepositoryId, isExternalRepositoryPath, isPathInside, resolvePortableRelativePath, samePath, toWorkspaceRelativePath, } from '../schemas/paths.js';
|
|
6
6
|
import { normalizedExcludes, } from '../schemas/workspace.js';
|
|
7
|
-
import {
|
|
7
|
+
import { createGitObservationScope, } from '../infra/git.js';
|
|
8
8
|
import { observePath, resolveRealpath } from '../infra/fs.js';
|
|
9
9
|
import { isExcludedPath, isHiddenSegment } from './ignore.js';
|
|
10
|
+
function probeScope(input) {
|
|
11
|
+
return input.observations ?? createGitObservationScope();
|
|
12
|
+
}
|
|
10
13
|
function failureDiagnostic(failure, source, location) {
|
|
11
14
|
return createDiagnostic({
|
|
12
15
|
code: failure.code,
|
|
@@ -185,7 +188,7 @@ async function resolveConfiguredRepository(input, repositoryIndex) {
|
|
|
185
188
|
}));
|
|
186
189
|
return { repository: null, unresolved: unresolved(), diagnostics };
|
|
187
190
|
}
|
|
188
|
-
const inspected = await
|
|
191
|
+
const inspected = await probeScope(input).repository(candidateRoot, {
|
|
189
192
|
timeoutMs: options.gitTimeoutMs,
|
|
190
193
|
});
|
|
191
194
|
if (!inspected.ok) {
|
|
@@ -231,6 +234,12 @@ function scanRepository(input, git) {
|
|
|
231
234
|
*/
|
|
232
235
|
export async function discoverRepositories(input) {
|
|
233
236
|
const { config, configPath, options, root } = input;
|
|
237
|
+
// One scope per discovery: explicit declarations, the root probe and any scan
|
|
238
|
+
// share the same immutable repository observations.
|
|
239
|
+
const decorated = {
|
|
240
|
+
...input,
|
|
241
|
+
observations: input.observations ?? createGitObservationScope(),
|
|
242
|
+
};
|
|
234
243
|
const diagnostics = [];
|
|
235
244
|
const repositories = [];
|
|
236
245
|
const unresolved = [];
|
|
@@ -260,7 +269,7 @@ export async function discoverRepositories(input) {
|
|
|
260
269
|
};
|
|
261
270
|
if (config !== null) {
|
|
262
271
|
for (const index of config.repositories.keys()) {
|
|
263
|
-
const resolved = await resolveConfiguredRepository(
|
|
272
|
+
const resolved = await resolveConfiguredRepository(decorated, index);
|
|
264
273
|
diagnostics.push(...resolved.diagnostics);
|
|
265
274
|
if (resolved.repository !== null)
|
|
266
275
|
addRepository(resolved.repository);
|
|
@@ -271,7 +280,7 @@ export async function discoverRepositories(input) {
|
|
|
271
280
|
const rootGitEntry = await observePath(join(root, '.git'));
|
|
272
281
|
if (rootGitEntry.kind === 'directory' || rootGitEntry.kind === 'file') {
|
|
273
282
|
stopsAtRepositories = true;
|
|
274
|
-
const inspected = await
|
|
283
|
+
const inspected = await probeScope(decorated).repository(root, {
|
|
275
284
|
timeoutMs: options.gitTimeoutMs,
|
|
276
285
|
});
|
|
277
286
|
if (inspected.ok) {
|
|
@@ -324,7 +333,7 @@ export async function discoverRepositories(input) {
|
|
|
324
333
|
}
|
|
325
334
|
const gitEntry = await observePath(join(directory, '.git'));
|
|
326
335
|
if (gitEntry.kind === 'directory' || gitEntry.kind === 'file') {
|
|
327
|
-
const inspected = await
|
|
336
|
+
const inspected = await probeScope(decorated).repository(directory, {
|
|
328
337
|
timeoutMs: options.gitTimeoutMs,
|
|
329
338
|
});
|
|
330
339
|
if (inspected.ok) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@phyzess/pappra",
|
|
3
|
-
"version": "0.1.0-beta.
|
|
4
|
-
"description": "Portable
|
|
3
|
+
"version": "0.1.0-beta.18",
|
|
4
|
+
"description": "Portable coding-agent workspaces with knowledge, continuity, code navigation and optional collaboration.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -19,33 +19,13 @@
|
|
|
19
19
|
"types": "./dist/index.d.ts",
|
|
20
20
|
"import": "./dist/index.js"
|
|
21
21
|
},
|
|
22
|
-
"./
|
|
23
|
-
"types": "./dist/
|
|
24
|
-
"import": "./dist/
|
|
25
|
-
},
|
|
26
|
-
"./collab/admission": {
|
|
27
|
-
"types": "./dist/collab/admission.d.ts",
|
|
28
|
-
"import": "./dist/collab/admission.js"
|
|
29
|
-
},
|
|
30
|
-
"./hosts": {
|
|
31
|
-
"types": "./dist/hosts/index.d.ts",
|
|
32
|
-
"import": "./dist/hosts/index.js"
|
|
33
|
-
},
|
|
34
|
-
"./doctor": {
|
|
35
|
-
"types": "./dist/app/doctor.d.ts",
|
|
36
|
-
"import": "./dist/app/doctor.js"
|
|
37
|
-
},
|
|
38
|
-
"./init": {
|
|
39
|
-
"types": "./dist/app/init.d.ts",
|
|
40
|
-
"import": "./dist/app/init.js"
|
|
41
|
-
},
|
|
42
|
-
"./collaboration": {
|
|
43
|
-
"types": "./dist/app/collaboration.d.ts",
|
|
44
|
-
"import": "./dist/app/collaboration.js"
|
|
22
|
+
"./workspace": {
|
|
23
|
+
"types": "./dist/workspace/index.d.ts",
|
|
24
|
+
"import": "./dist/workspace/index.js"
|
|
45
25
|
},
|
|
46
|
-
"./
|
|
47
|
-
"types": "./dist/
|
|
48
|
-
"import": "./dist/
|
|
26
|
+
"./knowledge": {
|
|
27
|
+
"types": "./dist/knowledge/index.d.ts",
|
|
28
|
+
"import": "./dist/knowledge/index.js"
|
|
49
29
|
},
|
|
50
30
|
"./continuity": {
|
|
51
31
|
"types": "./dist/continuity/index.d.ts",
|
|
@@ -55,17 +35,37 @@
|
|
|
55
35
|
"types": "./dist/code/index.d.ts",
|
|
56
36
|
"import": "./dist/code/index.js"
|
|
57
37
|
},
|
|
58
|
-
"./knowledge": {
|
|
59
|
-
"types": "./dist/knowledge/index.d.ts",
|
|
60
|
-
"import": "./dist/knowledge/index.js"
|
|
61
|
-
},
|
|
62
38
|
"./schemas": {
|
|
63
39
|
"types": "./dist/schemas/index.d.ts",
|
|
64
40
|
"import": "./dist/schemas/index.js"
|
|
65
41
|
},
|
|
66
|
-
"./
|
|
67
|
-
"types": "./dist/
|
|
68
|
-
"import": "./dist/
|
|
42
|
+
"./install": {
|
|
43
|
+
"types": "./dist/install/index.d.ts",
|
|
44
|
+
"import": "./dist/install/index.js"
|
|
45
|
+
},
|
|
46
|
+
"./hosts": {
|
|
47
|
+
"types": "./dist/hosts/index.d.ts",
|
|
48
|
+
"import": "./dist/hosts/index.js"
|
|
49
|
+
},
|
|
50
|
+
"./init": {
|
|
51
|
+
"types": "./dist/init.d.ts",
|
|
52
|
+
"import": "./dist/init.js"
|
|
53
|
+
},
|
|
54
|
+
"./doctor": {
|
|
55
|
+
"types": "./dist/doctor.d.ts",
|
|
56
|
+
"import": "./dist/doctor.js"
|
|
57
|
+
},
|
|
58
|
+
"./collab": {
|
|
59
|
+
"types": "./dist/collab/index.d.ts",
|
|
60
|
+
"import": "./dist/collab/index.js"
|
|
61
|
+
},
|
|
62
|
+
"./experimental": {
|
|
63
|
+
"types": "./dist/experimental/index.d.ts",
|
|
64
|
+
"import": "./dist/experimental/index.js"
|
|
65
|
+
},
|
|
66
|
+
"./experimental/pi": {
|
|
67
|
+
"types": "./dist/experimental/pi.d.ts",
|
|
68
|
+
"import": "./dist/experimental/pi.js"
|
|
69
69
|
},
|
|
70
70
|
"./package.json": "./package.json"
|
|
71
71
|
},
|
package/skills/pappra/SKILL.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pappra
|
|
3
|
-
description: Use Pappra workspace knowledge, checkpoint/resume,
|
|
3
|
+
description: Use Pappra workspace knowledge, checkpoint/resume, selected-repository code intelligence, and task-scoped cross-harness collaboration from any supported coding agent. Use when a task needs durable handoff context, workspace documents, bounded code navigation, or a visible/direct multi-agent collaboration workflow.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Pappra
|
|
@@ -20,15 +20,28 @@ index, or new writer.
|
|
|
20
20
|
the workspace selected by the current root. Never infer a workspace from an
|
|
21
21
|
unrelated session. `pappra docs scan --apply` registers discovered documents;
|
|
22
22
|
`pappra runtime install --apply` keeps a durable copy of this package.
|
|
23
|
-
5. For
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
23
|
+
5. For task-scoped collaboration, read `references/environment.md` first to
|
|
24
|
+
choose direct versus visible Herdr operation, bootstrap or reuse the
|
|
25
|
+
receiving instance, and bind its routing identity. Then read
|
|
26
|
+
`references/collaboration.md` and build the shared strict
|
|
27
|
+
`pappra/collaboration-goal/1` from explicit choices. The installed CLI accepts
|
|
28
|
+
`pappra collab prepare --goal <file> --domain-root <dir>`; it has no preview
|
|
29
|
+
mode, so it mutates task state, claims resources and registers the initial
|
|
30
|
+
ASSIGN once authorized. MCP `collab_prepare` accepts `{ domainRoot, goal }`
|
|
31
|
+
and rejects the retired flat objective form. Neither prepares a capability
|
|
32
|
+
card; derive and preflight actual runtime evidence separately, and notify the
|
|
33
|
+
already-registered ASSIGN rather than sending a duplicate. Visible peers are
|
|
34
|
+
the default collaboration channel; the owned Pi `pi-rpc` run remains a
|
|
35
|
+
separate explicit option, and fixtures are explicit only. Never turn prose
|
|
36
|
+
into identity, approval, or capability claims.
|
|
29
37
|
|
|
30
38
|
## One-request collaboration
|
|
31
39
|
|
|
40
|
+
Visible collaboration uses `references/environment.md` plus the persisted
|
|
41
|
+
message/notify loop in `references/collaboration.md`. The owned `collab run`
|
|
42
|
+
flow described here is the separate Pi RPC option, not a substitute for a
|
|
43
|
+
visible participant.
|
|
44
|
+
|
|
32
45
|
`pappra collab prepare --goal <file> --domain-root <dir>` requires an explicit
|
|
33
46
|
shared domain. It validates the canonical domain/tasks/task/private namespace
|
|
34
47
|
before writing any task metadata and again around each write, so a task-root or
|
|
@@ -61,6 +74,14 @@ No approval is auto-answered, no cancel is inferred from an acknowledgement, and
|
|
|
61
74
|
arbitrary PID is adopted. Do not launch a model or real user session without
|
|
62
75
|
the task's explicit authorization.
|
|
63
76
|
|
|
77
|
+
## Recovery and parallel work
|
|
78
|
+
|
|
79
|
+
Use `pappra collab work-run --request <abs-request.json>` for a read-only plan and add `--apply` only when the existing assignments, current capability cards, coordinator authority, resource claims and visible participant binding are ready. Work-run notifies only registered participants; it does not create sessions, merge, accept reports, or replay ambiguous delivery.
|
|
80
|
+
|
|
81
|
+
Use `pappra collab recovery-run --request <abs-request.json>` to inspect one guarded recovery action; add `--apply` only with exact current session/cwd/harness/pane and a digest-pinned task-local binding. Recovery is a bounded single wake, not generic outage recovery: there is no reconnect trigger, hidden worker, approval automation, or replay after an unknown effect.
|
|
82
|
+
|
|
83
|
+
For an explicitly selected Pi package, `pappra host bundle --host pi --out <new-private-dir> --recovery-config <abs-private-config.json>` exports the recovery extension and its private sibling config. Add `--transition-extension` to export the separate `/collab-transition` command extension. Exports do not install, trust, enable, load, launch, or transfer anything; review and install packages explicitly. Native quiescence and interactive Pi session takeover remain unsupported, and task retirement is not native session archive.
|
|
84
|
+
|
|
64
85
|
## Boundaries
|
|
65
86
|
|
|
66
87
|
- Hooks are local and bounded. They do not read transcripts, run commands,
|