@nowcrew/daemon 0.6.88-beta.7 → 0.6.88-beta.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/README.md +14 -10
  2. package/dist/agent-memory/policy.js +3 -1
  3. package/dist/execution-protocol.js +1 -1
  4. package/dist/execution-runner.js +3 -2
  5. package/dist/local-executor.js +30 -9
  6. package/dist/native-thread-context.js +59 -0
  7. package/dist/prompt.js +15 -15
  8. package/dist/runner.js +14 -15
  9. package/dist/runtimes/claude-session-start-hook.js +24 -0
  10. package/dist/runtimes/claude-thread-runner.js +266 -0
  11. package/dist/runtimes/claude.js +23 -4
  12. package/dist/runtimes/codex-app-server-runner.js +43 -4
  13. package/dist/runtimes/kimi-acp-runner.js +6 -2
  14. package/dist/runtimes/opencode-runner.js +7 -1
  15. package/dist/serve.js +7 -8
  16. package/dist/session.js +4 -0
  17. package/dist/supervised-runtime.js +11 -16
  18. package/dist/thread-input-delivery.js +217 -0
  19. package/package.json +2 -2
  20. package/dist/project-skills/capability.js +0 -109
  21. package/dist/project-skills/controller-convergence.js +0 -57
  22. package/dist/project-skills/projection-set-switch.js +0 -419
  23. package/dist/project-skills/projection-state-domain.js +0 -170
  24. package/dist/project-skills/projection-state-store.js +0 -842
  25. package/dist/project-skills/projection-state-transaction.js +0 -322
  26. package/dist/project-skills/projection-state.js +0 -3
  27. package/dist/project-skills/runtime-root-bootstrap.js +0 -47
  28. package/dist/project-skills/runtime-root-domain.js +0 -268
  29. package/dist/project-skills/runtime-root-gc.js +0 -293
  30. package/dist/project-skills/runtime-root-lease-artifact.js +0 -46
  31. package/dist/project-skills/runtime-root-leases.js +0 -487
  32. package/dist/project-skills/runtime-root-source-identity.js +0 -60
  33. package/dist/project-skills/runtime-root-startup.js +0 -49
  34. package/dist/project-skills/runtime-root-state-artifact-domain.js +0 -143
  35. package/dist/project-skills/runtime-root-state-index.js +0 -356
  36. package/dist/project-skills/runtime-root-store.js +0 -722
  37. package/dist/project-skills/serve-capability.js +0 -28
  38. package/dist/project-skills/serve-startup.js +0 -37
@@ -1,28 +0,0 @@
1
- import { WebSocket } from "ws";
2
- import { daemonCapabilityBindings, } from "../machine-info.js";
3
- import { prepareProjectSkillConnectionCapabilities, } from "./capability.js";
4
- export function createProjectSkillConnectionCapabilityProvider(input) {
5
- return async () => daemonCapabilityBindings(input.platform, await prepareProjectSkillConnectionCapabilities(input));
6
- }
7
- export function createProjectSkillMachineHelloPublisher(input) {
8
- let latest = null;
9
- let latestSocket = null;
10
- const republish = () => {
11
- if (latest === null || latestSocket?.readyState !== WebSocket.OPEN)
12
- return;
13
- const hello = input.effective(latest, input.status());
14
- try {
15
- latestSocket.send(JSON.stringify(hello));
16
- input.onSent(hello);
17
- }
18
- catch { /* 非 OPEN,忽略 */ }
19
- };
20
- return Object.freeze({
21
- publish: (hello, socket) => {
22
- latest = hello;
23
- latestSocket = socket;
24
- republish();
25
- },
26
- republish,
27
- });
28
- }
@@ -1,37 +0,0 @@
1
- import { createExecutionJournal } from "../execution-journal.js";
2
- import { reconcileExecutionJournal } from "../execution-recovery.js";
3
- import { dslog, flushSlog } from "../slog.js";
4
- export async function initializeProjectSkillProtectedExecutionJournal(input) {
5
- return input.startup.initializeAfterLeaseProtection(input.config.agentsRoot, async (snapshot) => {
6
- input.protectedExecutionIds.clear();
7
- for (const executionId of snapshot)
8
- input.protectedExecutionIds.add(executionId);
9
- const journal = input.injectedJournal ?? createExecutionJournal(input.config.agentsRoot, {
10
- protectedExecutionIds: () => input.protectedExecutionIds,
11
- onOperationTiming: (event) => {
12
- if (event.operation !== "mark_runtime_ready"
13
- && event.queueWaitMs < 250
14
- && event.operationMs < 250)
15
- return;
16
- dslog("execution.journal_operation", "execution journal 操作完成", {
17
- level: event.outcome === "succeeded" ? "INFO" : "ERROR",
18
- execution_id: event.executionId,
19
- operation: event.operation,
20
- outcome: event.outcome,
21
- queue_wait_ms: event.queueWaitMs,
22
- operation_ms: event.operationMs,
23
- total_ms: event.queueWaitMs + event.operationMs,
24
- });
25
- },
26
- });
27
- await reconcileExecutionJournal(journal, {
28
- agentsRoot: input.config.agentsRoot,
29
- serverUrl: input.config.serverUrl,
30
- ...(input.profileName === undefined ? {} : { profileName: input.profileName }),
31
- log: dslog,
32
- flush: flushSlog,
33
- writeStderr: (line) => process.stderr.write(line),
34
- });
35
- return journal;
36
- });
37
- }