Skip to content

Rebuild as standalone web-mux package - #37

Open
mavam wants to merge 6 commits into
mainfrom
topic/web-mux
Open

Rebuild as standalone web-mux package#37
mavam wants to merge 6 commits into
mainfrom
topic/web-mux

Conversation

@mavam

@mavam mavam commented Aug 2, 2026

Copy link
Copy Markdown
Owner

🔍 Problem

The package is coupled to pi and exposes provider management, UI, and background features instead of a reusable web-access surface. Its configuration, output, and custom-provider contracts are not suitable for a standalone CLI and library.

🛠️ Solution

  • Rebrand the package as web-mux@0.1.0 with a typed library, schema-driven web CLI, and thin pi entry point.
  • Add strict XDG configuration, explicit provider selection, ordered partial batches, foreground research, secret-safe raw output, and lazy loading for all 16 providers.
  • Build the CLI with Commander, detailed contextual help and examples, and TTY-aware Picocolors styling with ✔︎ and ✘︎ status marks while keeping JSON and raw output ANSI-free.
  • Replace custom wrappers with a versioned JSON subprocess protocol and document the manual migration path.
  • Add Node.js 22, 24, and 26 CI plus packed-package smoke coverage.

💬 Review

Focus on the public API and configuration contracts, dynamic option-flag generation, and the provider/runtime boundary. The change intentionally includes no compatibility or automatic migration path.

The mavam/web-mux repository links and versioned unpkg schema URL become live only after these post-merge release steps:

  • Rename mavam/pi-web-providers to mavam/web-mux.
  • Publish web-mux@0.1.0 and verify the CLI, library, pi entry point, and unpkg schema.
  • Deprecate pi-web-providers with a link to the migration guide.

mavam added 6 commits August 2, 2026 17:10
Expose a typed client through a standalone library, the web CLI,
and a thin pi extension. Add strict XDG configuration, lazy provider
loading, normalized batch output, and a versioned custom-provider
contract.

Retain all 16 provider integrations and cover the package with CLI,
pi, provider, and packed-install tests.

Assisted-by: GPT-5 (Codex)
Document the standalone package and manual migration in the
unreleased changelog. Link the entry to PR #37.

Assisted-by: GPT-5 (Codex)
Validate provider IDs before schema loading and keep unknown loads out
of the cache. Derive runtime version metadata from package.json,
preserve contents ordering across rewritten URLs, and warn pi sessions
that bind no tools.

Remove the unreachable pi-era implementation and its orphaned tests,
move the active suite under test/, and cover the reviewed edge cases
and packed metadata.

Assisted-by: GPT-5 (Codex)
Build commands and provider-specific options through Commander while preserving two-pass schema discovery and existing exit and output contracts. Add TTY-aware Picocolors styling for help, provider status, progress, and human-readable results with heavy success and failure marks.

Honor --no-color, NO_COLOR, and FORCE_COLOR, and keep JSON and raw output free of ANSI sequences.

Assisted-by: GPT-5 (Codex)
Use icon-only capability cells and explain their meaning once in a compact legend. Account for variation selectors when measuring visible width so the colored table remains aligned.

Assisted-by: GPT-5 (Codex)
Describe capability semantics, provider selection, batching, streams, and configuration behavior directly in Commander help. Add workflow examples at the root and focused examples for every capability, provider inspection, and configuration action.

Keep provider-aware help alongside the exact schema-derived flags so agents can discover both the right command and its backend-specific options.

Assisted-by: GPT-5 (Codex)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant