Skip to content

mcpx program — full-investigation prompt: design completion & build-out for the MCP gateway #13264

Open

Description

@dezren39

Commission (Drew, 2026-11-23): "make one of these for mcpx" — a full-programme investigation master prompt for mcpx, mirroring the ID programme prompt (#13240) and the Atlas programme prompt (#13241). The full prompt is the first comment on this issue; it also lands in the repo as a dated design record under doc/ by starter PR.

Scope in one paragraph: mcpx is the fleet's single MCP gateway — a Go daemon + CLI in pkgs/mcpx/ that owns every MCP server process and serves every harness, with a 252-setting typed config registry, an effect-probe ratchet with an 8-setting exemption tail, transports over local socket/systemd, ssh, and tsnet, a live book at the repo Pages root, and live integrations (Atlas as a remote server; ID's capability-first MCP bridge; fleet integration at design stage). The prompt drives its executors to establish purpose, current + planned capabilities, and short/long-term roadmap; review and improve all existing designs and create new designs for the obvious next steps toward a fully featured MCP platform (not an MVP) — server onboarding and lifecycle (the supervisor design), per-client policy and capability ceilings tied to Atlas's sensitivity tiers and ID's capability discipline, remote/hosted servers as versioned deployments, config-system completion (the exemption tail to zero), observability, library/embedding use of mcpx's parts, and the mcpx↔fleet↔Atlas↔ID integration surface.

Deliverables: the mcpx book extended (starting from a mechanical book-vs-binary coverage audit), a dependency + blocker map, a prioritized issue map of all mcpx issues with blockers marked, landed designs, and merged implementation PRs wherever unblocked. Many parallel agents. The prompt states explicitly that it is a starting point, not a final stopping point — expand, review, repeat.

Standing constraints carried in the prompt: flag-held items (#8472's plugin.disabledTools + plugin.instructions remainders, #8473's protoTasks.cancelGrace) are investigated and designed around, never implemented without Drew's item-specific word; Drew's decisions (#8809 server logins, #8810's answers, #1943's CNAME, #12900 thread 2) are surfaced with substance, never silently decided.

This issue stays open as the programme's tracking home.

{
  "direct_parent": null,
  "links": [],
  "lineage": {
    "design": null,
    "roadmap_item": null,
    "priority": null
  },
  "pm_meta": 1,
  "provenance": {
    "queue_id": null,
    "scheduled_start": null,
    "picked_up_at": null,
    "work_started_at": null,
    "created_at": "2026-11-23T12:39:28Z",
    "session_id": null,
    "lane": null,
    "host": "htch-runtime",
    "worktree": null,
    "model": null,
    "lane_start_issues": [],
    "workspace_ref": null,
    "auth_subject": "archer",
    "stamped_by": "fleet 0.1.0 (native)"
  }
}

Activity

  1. developing-today commented on Nov 23, 2026

    @developing-today
    Contributor
  2. dezren39 commented on Nov 23, 2026

    @dezren39
    MemberAuthor

    MCPX Program — Full Investigation, Next-Steps Design & Build-Out Prompt

    You are the coordinator of a program-scale investigation and build-out of mcpx — Drew's
    MCP aggregation and proxy daemon in developing-today/code (pkgs/mcpx/), the single gateway
    through which every agent on the fleet reaches every MCP server. Dig into the full system:
    what it aggregates, how the daemon lives and dies, how its 252 settings behave, who consumes it
    (harnesses, fleet, Atlas, ID), and what it should become. This prompt is a starting point, not
    a conclusive or final stopping point
    . Work the design end to end, begin implementation
    wherever you are unblocked, and when a pass finishes, review what remains, expand the plan, and
    repeat — until nothing more can be done with the access and authority you have. Use subtasks and
    orchestration heavily: launch many parallel agents (analyze, research, design, document,
    implement) and keep them pointed at the frontier. A phase finishing is a signal to start the
    next one, not to stop and ask.


    1. What mcpx is (ground truth — verify, don't re-derive)

    mcpx is a Go daemon + CLI (version 0.1.0) that owns every MCP server process on a machine and
    exposes them to agents through one surface, so no harness ever loads every tool schema into
    context. The agent loop is mcpx ls → mcpx search → mcpx types <namespace> →
    mcpx run / mcpx exec (TypeScript scripts on deno/bun/node with namespaces preloaded).
    One canonical source in pkgs/mcpx/ (the dedup shipped; #8822
    is its tracking home). Programme homes: epic #8993
    (one canonical MCP gateway and server parity), maintenance epic
    #12459, and the super tracker
    #1900 (every theme, in one order, with
    the disagreements between them).

    2. Drew's directions (the next-steps agenda — design all of it, build what's unblocked)

    A. Server onboarding and lifecycle

    Make adding a server a designed, boring path end to end: declaration shapes (stdio
    command, remote URL, adapter-wrapped CLI #11147/adapters.allowBare + cwd, OpenAPI-derived
    api servers, plugins, registry finds), credential resolution (in-memory mcpx secrets,
    env, per-server env), health/probe semantics, restart and reload without disturbing
    unchanged servers, and removal with session cleanup. Finish the supervisor design
    (#1384 → #9963): one lifecycle design that unifies takeover, cold-restart resume
    (#1414 phase 3), and supervised stdio — a daemon upgrade should become a plain restart
    of a front end whose children never notice. Cover multi-daemon machines (mcpx daemons)
    and the systemd/socket-activation posture.

    B. Per-client policy and capability ceilings

    mcpx is where every client's reach is actually decided, but today policy is scattered
    (rate limits and elicitation in proto.*, write policy, autonomy levels). Design one
    per-client policy model
    : client identity (harness, seat, session), a capability
    ceiling per client (which namespaces, which tools, read/write posture, rate and budget),
    and enforcement inside the daemon so every transport inherits it. Tie the ladder to the
    fleet's existing disciplines instead of inventing a third one: Atlas's sensitivity
    ceilings
    (shareable < personal < local-only < secret-bearing, enforced server-side per
    client identity) and ID's capability discipline (attenuable, revocable, audited —
    the PolicySession shape). Open questions to design, not assume: how a ceiling is
    declared (settings, config, per-server manifest), how elicitation binds user identity
    (#7843, #1957), annotation trust, and what the audit record of a refused call looks like.
    #12900 thread 2 (is Atlas headed for multi-client use?) is Drew's decision — design the
    ceiling model so it survives either answer; don't pre-build multi-tenancy.

    C. Remote and hosted servers as versioned deployments

    The Atlas server is the template: a hosted MCP server shipped as a versioned Cloudflare
    deployment and wired into mcpx by URL. Generalize it: how a remote server is declared,
    versioned, health-checked, and rolled back from the mcpx side; OAuth authorization for
    remote servers and for mcpx's own /mcp (#1950, 61 conformance rows); session resume
    across deploys; what mcpx registry should promise about a hosted server's provenance.
    Close the release-channel gap on mcpx itself (#9900 → #1881): the install channels the
    docs promise must be channels that exist.

    D. Config-system completion — burn the exemption tail to zero

    The ratchet only moves one way; finish it. For each of the 8 exempt settings, design
    the probe (or, where a setting is a pure allocation hint like http.streamBufferInit,
    the contract decision that reclassifies it honestly — an exemption with a permanent
    reason is a design smell, not a resting place): a harness-controlled tailnet for the
    two daemon.tsnet.* settings and daemon.tsnetUpTimeout's bring-up budget; a
    timing-observable inline-start harness for daemon.inlineStartPoll; a small
    embed-exporting wasm fixture model in-tree for embeddings.wasmPath (which also
    unblocks real testing of the Wasm embedder). The three flag-held settings
    (plugin.instructions, plugin.disabledTools, protoTasks.cancelGrace) get their
    probe designs prepared and recorded — implementation waits for Drew's word, exactly
    like the 11 sibling plugin.* probes that landed 2026-11-23 under #8472. In parallel:
    the remaining burn-downs (#8465 CLI running group, #8469, #8471) and the test-venue
    blockers (#2686, #10330) that decide how much of this CI can see.

    E. Daemon lifecycle, transports, and reach

    Beyond §A's supervisor: tsnet as a first-class reach (a daemon on the tailnet,
    reachable from any seat — the stdio-proxy/ssh pattern generalized), inline-start
    semantics, stream buffering as a designed contract (#4375: one bounded response-read
    contract for all outbound calls — the http.streamBufferInit/Max pair is one
    instance), dashboard and observability of the daemon itself, and the upgrade path's
    failure shapes. Every bound in the daemon should be a setting with a probe (§D) —
    no magic numbers with a comment.

    F. Observability and the event record

    mcpx already keeps events, logs, stats, and feedback (mcpx feedback, the event
    store, logstore). Design the coherent observability story: one event record for
    every tool call (client, ceiling decision, latency, bytes, refusal reason), stats
    that answer "which servers/tools does the fleet actually use", feedback wired to
    something that consumes it, and the dashboard as the live view of the same record —
    not three partial systems. This is also the audit substrate §B's policy model needs.

    G. Library and embedding use

    mcpx's parts should be usable without the daemon: the public Go API (pkg/client
    today), the C ABI / WASM / mcpx-as-its-own-upstream programme (#1877), the
    harness-free plugin core with per-harness adapters (#1861), and embedding the
    catalog/settings/policy packages as libraries in fleet and ID. Define the versioned
    library surface (what is public, what is internal, what stability is promised),
    with embedding examples taken from real call sites.

    H. The integration surface: mcpx ↔ fleet ↔ Atlas ↔ ID

    I. The model layer and the AI surface

    Settle where the model comes from (#1891, #1925 — blocked): the provider layer mcpx
    owns, model profiles, the prompt command's contract, the OpenAI-compatible
    proxy, and life after MCP Sampling's deprecation. Include administration by intent
    (#1931: finish the operation surface, then route a sentence to a declared operation),
    the request repair ladder (#1927), and lifecycle hooks on exec (#1929) — these are
    one AI-surface design, currently four issues.

    J. Book extension, issue map, and the living record

    1. Extend the mcpx book (it exists — do not rebuild it): first run the missing
      mechanical coverage audit — every CLI command and flag, every one of the 252
      settings (with default + provenance + probe/exemption status), every transport,
      every public library entry point, mapped to a chapter or a named gap; then write
      the missing chapters (the §A–§I designs join as book chapters in pkgs/mcpx/docs/,
      per mcpx's own convention), fix reverse gaps (chapters describing surfaces the
      code no longer has — the ASSESSMENT corrections-header pattern), and keep the
      zero-warning build + docs-twins gates green. The book's deployment chapter must
      absorb the new reality: its deploy now carries the fleet, atlas, and id books
      under subpaths (fix(ci): stage fleet docs into writable Pages directory #13225's staging fix is part of this workstream's surface).
      Extend the docs-sync contract the way fleet's DOC-01 works: a surface change
      (command, flag, setting, transport) updates its chapter in the same change.
    2. An issue-by-issue map of ALL mcpx issues — every open app/mcpx and
      epic/mcpx-platform issue (and the mcpx-adjacent atlas memory slice 3: MCP query surface over the unified Atlas index (mcpx namespace) (#8567) #8625/epic: mcpx — one canonical MCP gateway and server parity #8993/mcpx: the backlog build-out — every theme, in one order, with the disagreements between them (super tracker) #1900 families),
      prioritized in best working order, with all blockers marked both on the issues
      themselves and in the priority list
      (book chapter + tracking issue kept
      current). Blockers are worked, not just listed.
    3. Designs + PRs — every workstream produces landed designs (mcpx product
      designs in the book tree; programme records in the repo doc/ archive) and,
      wherever unblocked, merged implementation PRs.

    3. How to work (fleet rules — binding)

    4. The iteration rule

    This prompt is the starting point. When every workstream has reported, do not
    conclude: re-survey (issues, settings registry, book coverage, consumers, the live
    daemon's server set), reconcile what the passes learned, expand the design set and
    the issue map, and run the next pass. The program ends only when a full pass finds
    nothing more that can be designed, documented, or implemented with the authority
    available — and even then, the book, the issue map, the exemption ratchet at zero,
    and the docs-sync contract remain as the living record the next pass starts from.

  3. added a commit that references this issue on Nov 23, 2026
  4. dezren39 commented on Nov 23, 2026

    @dezren39
    MemberAuthor

    Pages deploy structure: recommendation from the mcpx book audit

    Asked as part of the bookwright pass over the mcpx book (PR #13413): should each book have its own GitHub Pages deploy, or should mcpx stay merged in the single deploy — and should mcpx stay at the site root? This comment records the analysis and the recommendation. Nothing was restructured: the deploy shape is the owner's call; the book PR only documented the current arrangement (new chapter: Deploying this book).

    Recommendation

    Keep the single deploy. Keep mcpx at the root. Fleet, Atlas and ID stay under /fleet/, /atlas/, /id/.

    Why per-book deploys are not really on the table

    • GitHub Pages gives a repository one site, and a deployment replaces the whole site. There is no per-book deployment inside this repo to be had: a second workflow publishing its own output alone would erase the other three books on its first run. The current workflow's deploy job says as much in its comments.
    • The actual alternatives are worse than the problem: move books to separate repositories (splits the one-flake build, the shared mdBook/docs-twins tooling pattern, and cross-book links), or move hosting off Pages (new infrastructure, new failure modes, zero reader benefit).
    • The single deploy already does the right things: one workflow (mcpx-docs.yml) builds all four books with a per-book siteUrl, stages them into one tree, and publishes through a separate job (the split that fixed the metadata-propagation failure in mcpx docs workflow: Deploy to GitHub Pages fails - artifact not found #10956); deploys are serialised and never cancelled (mcpx docs: build the site in CI and deploy to GitHub Pages #1941).

    Why mcpx stays at the root

    • The root address — https://developing-today.github.io/code/ — is the mcpx book's published address. It is baked into the book's own siteUrl, it is the address the pending custom-domain decision (mcpx docs: a custom subdomain for the site (DNS, CNAME, HTTPS) #1943) is about, and it is what existing links point at.
    • Pages offers no server-side redirects. Moving mcpx to /mcpx/ for symmetry with the other three would break every existing link to the root, or require a maintained tree of meta-refresh stubs — a permanent tax for an aesthetic gain.
    • Symmetry is the only thing a move buys, and it can be bought later: if a fifth book or a books index ever needs the root, the staging step makes it a one-line siteUrl change plus the stub question. That decision belongs with mcpx docs: a custom subdomain for the site (DNS, CNAME, HTTPS) #1943's CNAME call, since both change the site's public addresses at once.

    What the audit changed around this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions