Copy architecture docs, ADRs, storage domain specs, research, reviews, and 56 storage architecture tasks from the alkhub_ts monorepo. Adapt for standalone @alkdev/hub repo structure (src/ not packages/hub/). Sanitize all sensitive information: - Replace private IPs (10.0.0.1) with localhost defaults - Remove internal server hostnames (dev1, ns528096) - Replace /workspace/ private paths with npm package references - Remove hardcoded credentials from examples - Rewrite infrastructure.md without private network details Add Deno project scaffolding: deno.json (pinned deps), .gitignore, AGENTS.md, entry point. Migrate existing code stubs (crypto, config types, logger) with updated import paths.
3.5 KiB
id, name, status, depends_on, scope, risk, impact, level
| id | name | status | depends_on | scope | risk | impact | level |
|---|---|---|---|---|---|---|---|
| update-call-graph-and-operations-docs | Update call-graph.md and operations.md for @alkdev/operations API | completed | moderate | medium | component | implementation |
Description
These two architecture docs describe the call protocol and operations system, both of which are now implemented in @alkdev/operations. They need significant updates to reflect the actual API surface.
call-graph.md changes
-
PendingRequestMap section — Replace the schematic implementation with actual
@alkdev/operationsAPI:new PendingRequestMap({ eventTarget })constructor with optional EventTargetcall(operationId, input, { deadline, identity })returnsPromise<ResponseEnvelope>subscribe(operationId, input, { idleTimeout, identity })returnsAsyncIterable<ResponseEnvelope>respond(requestId, output)requiresisResponseEnvelope(output)emitError(requestId, code, message, details?),complete(requestId),abort(requestId)- Built-in deadline and idle timeout support
-
CallHandler section — Reference
buildCallHandlerfrom@alkdev/operations -
buildEnv section — Remove
callMapparameter. New API:buildEnv({ registry, context })— setstrusted: trueon nested context- No
callMapparameter —PendingRequestMaphandles call routing - Returns env functions that return
Promise<ResponseEnvelope>
-
Dependencies section — Replace direct
graphologydeps.graphologyis now a transitive dep through@alkdev/taskgraph. For call graph storage, the hub can still usegraphologydirectly or use@alkdev/taskgraph'sTaskGraphclass. -
CallEventSchema — Cross-reference that the TypeBox schemas are in
@alkdev/operationsand may differ slightly from what's documented. Add note to verify against package source. -
Transport mapping table — Update WebSocket row:
@alkdev/pubsub/event-target-websocket-serverfor hub,@alkdev/pubsub/event-target-websocket-clientfor spoke
operations.md changes
- Remove "In-repo location:
packages/core/operations/" — now@alkdev/operationsnpm package - Update component descriptions to reference
@alkdev/operationsexports - Add
ResponseEnvelopeconcept (universal result wrapper:local/http/mcp) - Add
CallError/InfrastructureErrorCodeconcept - Add
subscribe()helper for subscription operations - Add
ScannerFSinterface (Deno/Node agnostic) - Update Schema Adapters section to use
SchemaAdapterpattern from@alkdev/operations/from-typemap - Remove "SSE Subscription Handler Fix" from open issues — fixed in
@alkdev/operations/from-openapi - Update Call Protocol Integration section to reference
@alkdev/operationsAPI - Update
buildEnvto removecallMapparameter
Acceptance Criteria
- call-graph.md PendingRequestMap section shows actual
@alkdev/operationsAPI - call-graph.md buildEnv section has no
callMapparameter - call-graph.md dependencies reference
@alkdev/taskgraphtransitively - call-graph.md transport table references
@alkdev/pubsubevent targets - operations.md references
@alkdev/operationspackage throughout - operations.md open issues no longer include fixed items
- operations.md documents ResponseEnvelope and CallError
- No references to
packages/core/operations/remain in either doc
References
- docs/reviews/core-library-extraction-sync-2026-05-18.md (Section 2.4, 2.5)