qlogicagent 2.18.12 → 2.19.2

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 (95) hide show
  1. package/README.md +382 -382
  2. package/dist/agent-contract.js +1 -0
  3. package/dist/cli.js +1 -1
  4. package/dist/default-project-knowledge/INSTRUCTIONS.md +7 -7
  5. package/dist/default-project-knowledge/rules/project-workflow.md +6 -6
  6. package/dist/host-contract.js +1 -1
  7. package/dist/host-session-collection-contract.js +1 -0
  8. package/dist/index.js +478 -505
  9. package/dist/pet-host.js +8 -8
  10. package/dist/project-memory-host.js +23 -23
  11. package/dist/protocol.js +1 -1
  12. package/dist/skills/builtin/desktop-screenshot/SKILL.md +62 -62
  13. package/dist/skills/builtin/office-doc-reading/SKILL.md +19 -19
  14. package/dist/types/cli/acp-commands.d.ts +1 -1
  15. package/dist/types/cli/acp-extended-handlers.d.ts +8 -8
  16. package/dist/types/cli/acp-extended-host-adapter.d.ts +0 -11
  17. package/dist/types/cli/acp-session-host.d.ts +2 -0
  18. package/dist/types/cli/core-tool-coordinator.d.ts +0 -9
  19. package/dist/types/cli/default-project-bootstrap.d.ts +2 -32
  20. package/dist/types/cli/handlers/session-handler.d.ts +0 -43
  21. package/dist/types/cli/handlers/solo-handler.d.ts +3 -14
  22. package/dist/types/cli/multi-agent-handler-host.d.ts +3 -16
  23. package/dist/types/cli/product-coordinator.d.ts +3 -14
  24. package/dist/types/cli/rpc-registry.d.ts +0 -2
  25. package/dist/types/cli/stdio-rpc-handler-hosts.d.ts +4 -1
  26. package/dist/types/cli/stdio-server.d.ts +1 -2
  27. package/dist/types/host-contract/index.d.ts +112 -19
  28. package/dist/types/host-session-collection-contract.d.ts +61 -0
  29. package/dist/types/orchestration/agent-instance.d.ts +11 -14
  30. package/dist/types/orchestration/agent-roster.d.ts +8 -4
  31. package/dist/types/orchestration/delegate-bridge.d.ts +8 -0
  32. package/dist/types/orchestration/goal-mode-adapters.d.ts +3 -3
  33. package/dist/types/orchestration/product-persistence.d.ts +0 -4
  34. package/dist/types/orchestration/product-planner.d.ts +4 -6
  35. package/dist/types/orchestration/solo-evaluator.d.ts +2 -5
  36. package/dist/types/orchestration/testing/delegate-test-bridge.d.ts +2 -1
  37. package/dist/types/orchestration/testing/host-agent-provider-directory-fixture.d.ts +7 -0
  38. package/dist/types/orchestration/workflow/qla-executor-host.d.ts +1 -1
  39. package/dist/types/protocol/agent-contract.d.ts +50 -0
  40. package/dist/types/protocol/methods.d.ts +20 -38
  41. package/dist/types/protocol/notifications.d.ts +1 -1
  42. package/dist/types/protocol/wire/acp-agent-management.d.ts +2 -190
  43. package/dist/types/protocol/wire/acp-protocol.d.ts +3 -4
  44. package/dist/types/protocol/wire/agent-events.d.ts +1 -32
  45. package/dist/types/protocol/wire/agent-methods.d.ts +1 -243
  46. package/dist/types/protocol/wire/gateway-rpc.d.ts +343 -15
  47. package/dist/types/protocol/wire/index.d.ts +3 -3
  48. package/dist/types/protocol/wire/notification-payloads.d.ts +103 -126
  49. package/dist/types/runtime/infra/host-agent-provider-directory.d.ts +17 -0
  50. package/dist/types/runtime/infra/project-authority-facade.d.ts +1 -1
  51. package/dist/types/runtime/infra/project-data-paths.d.ts +2 -1
  52. package/dist/types/runtime/infra/project-host-authority.d.ts +3 -2
  53. package/dist/types/runtime/infra/project-store.d.ts +4 -39
  54. package/dist/types/runtime/session/session-catalog.d.ts +0 -12
  55. package/dist/types/runtime/session/session-persistence.d.ts +1 -1
  56. package/dist/types/runtime/session/session-resource-key.d.ts +1 -1
  57. package/dist/types/runtime/session/session-types.d.ts +0 -23
  58. package/dist/types/transport/acp-server.d.ts +2 -10
  59. package/dist/vendor/hatch-pet/LICENSE.txt +201 -201
  60. package/dist/vendor/hatch-pet/NOTICE.md +25 -25
  61. package/dist/vendor/hatch-pet/references/animation-rows.md +29 -29
  62. package/dist/vendor/hatch-pet/references/codex-pet-contract.md +35 -35
  63. package/dist/vendor/hatch-pet/references/qa-rubric.md +66 -66
  64. package/dist/vendor/hatch-pet/scripts/compose_atlas.py +169 -169
  65. package/dist/vendor/hatch-pet/scripts/derive_running_left_from_running_right.py +150 -150
  66. package/dist/vendor/hatch-pet/scripts/extract_strip_frames.py +408 -408
  67. package/dist/vendor/hatch-pet/scripts/inspect_frames.py +256 -256
  68. package/dist/vendor/hatch-pet/scripts/make_contact_sheet.py +96 -96
  69. package/dist/vendor/hatch-pet/scripts/prepare_pet_run.py +834 -834
  70. package/dist/vendor/hatch-pet/scripts/render_animation_previews.py +78 -78
  71. package/dist/vendor/hatch-pet/scripts/validate_atlas.py +157 -157
  72. package/dist/workflow-host.js +10 -10
  73. package/package.json +16 -1
  74. package/dist/types/cli/agent-config-coordinator.d.ts +0 -27
  75. package/dist/types/cli/agent-config-runtime.d.ts +0 -11
  76. package/dist/types/cli/agent-status-notifier.d.ts +0 -11
  77. package/dist/types/cli/handlers/agents-handler.d.ts +0 -121
  78. package/dist/types/cli/handlers/project-handler.d.ts +0 -36
  79. package/dist/types/cli/project-command-service.d.ts +0 -28
  80. package/dist/types/orchestration/delegation-coordinator.d.ts +0 -100
  81. package/dist/types/runtime/infra/acp-detector.d.ts +0 -271
  82. package/dist/types/runtime/infra/agent-config-store.d.ts +0 -30
  83. package/dist/types/runtime/infra/agent-install-runner.d.ts +0 -80
  84. package/dist/types/runtime/infra/external-agent-approvals.d.ts +0 -59
  85. package/dist/types/runtime/infra/migrate-device-scope.d.ts +0 -49
  86. package/dist/types/runtime/infra/project-data-gc.d.ts +0 -15
  87. package/dist/types/runtime/session/native/claude-session-source.d.ts +0 -23
  88. package/dist/types/runtime/session/native/codex-index.d.ts +0 -21
  89. package/dist/types/runtime/session/native/codex-session-source.d.ts +0 -31
  90. package/dist/types/runtime/session/native/cwd-normalize.d.ts +0 -53
  91. package/dist/types/runtime/session/native/ephemeral-rollout-sweep.d.ts +0 -13
  92. package/dist/types/runtime/session/native/native-cwd-agents.d.ts +0 -17
  93. package/dist/types/runtime/session/native/native-session-source.d.ts +0 -89
  94. package/dist/types/runtime/session/native/native-title.d.ts +0 -1
  95. package/dist/types/runtime/session/native/register-builtin-sources.d.ts +0 -1
@@ -1,13 +0,0 @@
1
- /**
2
- * Sweep both native stores. Best-effort: never throws (all I/O is guarded); returns how many rollouts were
3
- * reclaimed. `home`/`codexHome`/`ttlMs`/`now` are injectable for tests.
4
- */
5
- export declare function sweepEphemeralWorktreeRollouts(opts?: {
6
- home?: string;
7
- codexHome?: string;
8
- ttlMs?: number;
9
- now?: number;
10
- }): Promise<{
11
- claudeDeleted: number;
12
- codexDeleted: number;
13
- }>;
@@ -1,17 +0,0 @@
1
- /**
2
- * Single source of truth for WHICH third-party ACP backend ids have local, cwd-discoverable
3
- * native session history ("native-cwd" adapters registered in register-builtin-sources.ts).
4
- *
5
- * Consumed by both:
6
- * - acp-detector.ts (assembleBackendDescriptor) — descriptor's capabilities.sessionHistory
7
- * - session-handler.ts (resolveAgentSessionHistory) — session.list routing
8
- *
9
- * so the two can never drift on which ids are native-adapted (the DRY debt Cut 1 intentionally
10
- * left behind — see Cut 3 Task 3.0). To add or remove a native-cwd agent: change this set AND
11
- * register/unregister the matching NativeSessionSource adapter in register-builtin-sources.ts.
12
- *
13
- * Zero imports by design — this file must stay a dependency-free leaf so both acp-detector.ts and
14
- * session-handler.ts (which itself imports ACP_BACKENDS from acp-detector.ts) can import it without
15
- * risking an import cycle.
16
- */
17
- export declare const NATIVE_CWD_BACKEND_IDS: ReadonlySet<string>;
@@ -1,89 +0,0 @@
1
- /**
2
- * Native session source registry.
3
- *
4
- * A "native" session source lets a third-party ACP agent (codex/claude) expose ITS OWN
5
- * CWD-scoped session history — recorded by the agent's own CLI, not by qlogicagent — through
6
- * the same session.list / session.get surface as our own sessions.
7
- *
8
- * Cut 1 shipped only the registry contract with a loose shape; no adapter registered itself, so
9
- * {@link getNativeSessionSource} always returned undefined and callers (session-handler's
10
- * resolveSessionSource) fell back to an empty list for native-cwd agents. Cut 2 refines the
11
- * contract below and adds the claude adapter (see claude-session-source.ts) that calls
12
- * {@link registerNativeSessionSource}.
13
- */
14
- /** Opaque locator for a single native session's transcript, round-tripped by the frontend without
15
- * interpretation (session.list returns it, session.loadNativeTranscript consumes it). */
16
- export interface NativeSessionRef {
17
- agentId: string;
18
- kind: "codex" | "claude";
19
- /** Absolute path to the on-disk transcript file (adapter-specific format). */
20
- file: string;
21
- }
22
- /** One native session list entry — the `source: "native"` variant of session.list's
23
- * SessionListEntry (see session-types.ts SessionListEntry for the "own" counterpart). */
24
- export interface NativeSessionEntry {
25
- sessionId: string;
26
- source: "native";
27
- agentId: string;
28
- title?: string;
29
- lastActiveAt: string;
30
- messageCount: number;
31
- cwd: string;
32
- nativeRef: NativeSessionRef;
33
- /** Stamped by handleSessionList from the requested project so the frontend's per-project grouping
34
- * (project-tree filters by projectId) shows native entries under it. The source discovers by cwd
35
- * and cannot know the project, so it leaves this unset. */
36
- projectId?: string;
37
- }
38
- /**
39
- * Minimal transcript-line shape for native session.loadTranscript. This intentionally does NOT
40
- * import the frontend's `InboundMessagePayload` (ui-next/src/types/gateway.ts) — that type lives
41
- * in a separate package/repo from this engine and carries many fields irrelevant to a bare
42
- * transcript line (sessionKey, blocks, attachments, mediaUrl, chatId, ...). Instead this is the
43
- * minimal subset every native adapter can populate, documented field-for-field against the
44
- * frontend contract so a caller can widen a TranscriptMessage into an InboundMessagePayload by
45
- * filling in the rest as optional/absent:
46
- * - messageId -> InboundMessagePayload.messageId (required)
47
- * - content -> InboundMessagePayload.content (required)
48
- * - timestamp -> InboundMessagePayload.timestamp (required)
49
- * - source -> InboundMessagePayload.source (required, narrowed here to "user"|"assistant"
50
- * since that's all a transcript line can be)
51
- * - platform -> InboundMessagePayload.platform (required there; optional here since every
52
- * current adapter always sets it to "desktop" — kept optional so future adapters
53
- * aren't forced to fabricate a value)
54
- */
55
- export interface TranscriptMessage {
56
- messageId: string;
57
- content: string;
58
- timestamp: string;
59
- source: "user" | "assistant";
60
- platform?: string;
61
- }
62
- export interface NativeSessionSource {
63
- readonly agentId: string;
64
- readonly kind: "codex" | "claude";
65
- /** `cwd` is the RAW (un-normalized) project cwd — callers (session-handler's
66
- * resolveSessionSource, via handleSessionList) pass the REQUESTED project's workspaceDir
67
- * (params.projectId's, when present) straight through, falling back to getActiveProjectRoot()
68
- * only when no projectId was given. Each adapter is responsible for whatever
69
- * normalization/encoding its own on-disk storage requires (e.g. claude's
70
- * claudeProjectDirName preserves original casing). */
71
- list(cwd: string, opts?: {
72
- limit?: number;
73
- }): Promise<NativeSessionEntry[]>;
74
- /** Cheap existence check: is `sessionId` an existing native session under `cwd` for this agent?
75
- * Used on a COLD spawn to decide whether to resume it (ACP session/load) instead of creating a
76
- * fresh session — so a native conversation regains its authoritative history after pool eviction/
77
- * restart, not only on the one-shot "继续". Optional so test fakes need not implement it. */
78
- has?(sessionId: string, cwd: string): Promise<boolean>;
79
- loadTranscript(ref: NativeSessionRef): Promise<TranscriptMessage[]>;
80
- }
81
- /** Register a native session source for an agentId. Last registration for a given id wins. */
82
- export declare function registerNativeSessionSource(source: NativeSessionSource): void;
83
- /** Look up a registered native session source by agentId. Undefined when none is registered for
84
- * that id (no adapter registered itself yet, or the agentId has no native adapter at all). */
85
- export declare function getNativeSessionSource(agentId?: string): NativeSessionSource | undefined;
86
- /** Remove a registered native session source by agentId. Symmetric with {@link registerNativeSessionSource};
87
- * exists primarily so tests can deregister a fake adapter afterward without leaking it into other
88
- * test cases that share this module-level registry. No-op if nothing is registered for that id. */
89
- export declare function unregisterNativeSessionSource(agentId: string): void;
@@ -1 +0,0 @@
1
- export declare function cleanNativeTitle(message: string, maxLen?: number): string | undefined;
@@ -1 +0,0 @@
1
- export declare function registerBuiltinNativeSources(): void;