- Replaced `with { type: "file" }` worker imports with `isCompiledBinary()` hybrid: literal string for `--compile` static analysis, `new URL(import.meta.url)` for dev portability.
- Added worker entrypoints as explicit `--compile` args in `build-binary.ts` so Bun emits them into bunfs.
- Added `smokeTestSyncWorker` and `omp --smoke-test` to catch silent worker-load failures in compiled binaries (fixes#1011, #1027).
- Added `isCompiledBinary()` utility to `@oh-my-pi/pi-utils` detecting bunfs path markers.
- Switched template CSS/JS inlining replacements to callback form in generation scripts to avoid `$` replacement expansion semantics.
- Updated HTML export generation to use callback-based replacements for theme variables and session data injection to prevent accidental `$` substitution parsing.
- Added regression tests for the inlined script ensuring literal `$'` regex tokens remain intact, no closing HTML tags are injected, and the script parses via `new Function`.
new URL(...).pathname returns a POSIX-style /D:/... path on Windows, which
is not a valid filesystem path. import.meta.dir gives the correct native path
on all platforms.
Standalone Bun binaries on WSL (and any host where the user moves the
binary away from the build-host's checkout) failed to load
pi_natives.<platform>-<arch>*.node. The loader's isCompiledBinary
detection relied on two signals that are both false in shipped binaries:
process.env.PI_COMPILED (bun --define PI_COMPILED=true substitutes the
bare identifier, not property accesses on process.env) and
__filename.includes("$bunfs") (Bun retains the build-host absolute path
in __filename for required CJS modules — only import.meta.url is
rewritten). Detection therefore returned false, embedded-addon
extraction was skipped, and the only candidates probed were the
build-host nativeDir and execDir.
Make embedded-addon presence the authoritative compiled-mode signal
(it is null in the post-build --reset stub, populated when embed:native
ran for the standalone build), eagerly require the manifest, and
extract candidate-path computation into a pure helper covered by a
host-platform-agnostic unit test. Also fix the build-time --define so
process.env.PI_COMPILED is genuinely set at runtime as a defensive
fallback.
Fixes#823
- Extracted prompt rendering and formatting utilities from coding-agent to centralized pi-utils package with new API surface (prompt.render, prompt.format, prompt.registerHelper).
- Migrated parseFrontmatter utility from coding-agent to pi-utils package; updated 8 files to import from @oh-my-pi/pi-utils.
- Removed 170-line prompt-format.ts module and consolidated 192 lines of Handlebars helper registrations into pi-utils prompt module.
- Updated 60+ files across coding-agent and typescript-edit-benchmark to use new prompt.render() and prompt.format() API from pi-utils.
- Simplified prompt-templates.ts by delegating core functionality to pi-utils while retaining custom helper registrations (jtdToTypeScript, jsonStringify, etc.).
- Added gh-renderer.ts module with GitHub Actions workflow visualization for terminal output.
- Enhanced gh_pr_view tool to fetch and display inline review comments alongside pull request reviews.
- Improved gh_run_watch tool output with structured job state tracking and failed log formatting.
- Fixed gh_run_watch to resolve explicit branch watches against GitHub API branch head instead of local HEAD.
- Fixed gh_* tool outputs to spill full large results to artifacts instead of pre-truncating.
- Standardized trailing newlines across 100+ prompt template files for POSIX compliance.
- Extracted prompt formatting logic into reusable `formatPromptContent()` utility function with configurable render phases.
- Removed 166 lines of duplicate formatting code from scripts and config modules by centralizing regex patterns and helper functions.
- Updated prompt template rendering to use unified `formatPromptContent()` instead of inline `optimizePromptLayout()` implementation.
- Added comprehensive test coverage for prompt formatting with pre-render and post-render mode validation.
- Standardized prompt format, removing XML-like tags.
- Emphasized RFC 2119 keywords using bolding across all prompts.
- Rewrote the core system prompt with enhanced structure and directives.
- Introduced OAuthManualInputManager and routed callback-server logins to await pasted redirect URLs with a visible tip.
- Extended /login slash command to submit redirect URLs, block overlapping logins, and covered manual callbacks in tests.
- Propagated onManualCodeInput through OAuth provider login helpers with a default authorization prompt.
- Resolved docs index generation paths using path.resolve relative to the script directory.
- Corrected XML tag indent stripping to only apply to top-level closing tags, preventing incorrect whitespace removal from nested tags.
- Implemented depth-aware tag tracking using a stack to distinguish top-level from nested XML elements.
- Updated formatting rule documentation to clarify that indent stripping applies only to top-level closing tags.
Static imports from '../../../../docs/' resolve correctly in the monorepo
but break when the package is installed from npm -- the docs/ directory
at the repo root is not included in the published tarball.
Switch the generator to read each file at build time and emit the content
as inlined string literals, eliminating all runtime file resolution.
- Added docs:// internal URL protocol handler for accessing embedded markdown documentation files with path traversal validation.
- Added support for executable tool files (.ts, .js, .sh, .bash, .py) in custom tools discovery from .omp/tools/ and .claude/tools/ directories.
- Added generate-docs-index build script to automatically scan and embed markdown documentation files at build time.
- Updated system prompt to document docs:// protocol usage and identify agent as operating within Oh My Pi harness.
- Plan mode provides structured workflow where agents propose plans for user approval before execution.
- Added plan:// internal URL protocol for accessing plan files and injecting plan-mode context into subagent prompts.
- Added plan mode toggle shortcut and paused status indicator in status line.
- Fixed plan reference injection to properly pass workflow state to plan-mode system prompts.
- Improved autocomplete fuzzy matching to support subsequence matching for skill suggestions.
- Removed Prettier configuration files (.prettierignore and .prettierrc) and migrated formatting to Biome.
- Updated Biome configuration from version 2.3.11 to 2.3.12 and changed arrowParentheses rule from 'always' to 'asNeeded'.
- Pinned @biomejs/biome dependency to exact version 2.3.12 in package.json and bun.lock.
- Applied consistent arrow function formatting across 489 files by removing unnecessary parentheses around single parameters.
- Removed blank lines after comment blocks and reorganized imports for consistency across the codebase.
- Removed WASM generation script; use Bun `wasm?raw` loader for imports.
- Added bunfig.toml with loaders for `.md`, `.py`, and `.wasm?raw` text imports.
- Added types/assets/index.d.ts for global TypeScript module declarations.
- Unified TypeScript configuration with tsgo-based checking across monorepo.
- Removed build and WASM steps from install and publish pipelines.
- Added tsconfig.publish.json files to all packages with optimized publish-time configuration.
- Updated all package.json scripts with prepublishOnly hooks for correct type checking during publish.
- Added @oh-my-pi/omp-stats path mappings to root tsconfig.json for consistent imports.
- Added WASM generation script for photon module and integrated into install:dev script.
- Fixed file descriptor leak in OutputSink when write fails
- Fixed isError flag not propagating to UI for grouped tool calls
- Fixed Python streaming updates during cell execution (missing onChunk)
- Fixed ls icon detection broken by age suffix in entry names
- Added Tool Output Infrastructure section to DEVELOPMENT.md
- Added format-prompts script for standardizing prompt file formatting across the codebase.
- Updated system prompt tags from `<required>`/`<antipatterns>` to `<important>`/`<avoid>` for clarity.
- Enhanced prompt formatting by removing blank lines after colons and around blocks for consistency.
- Standardized whitespace handling across all prompt files to improve readability.
- Reformatted code indentation and spacing across multiple TypeScript files.
- Standardized export statements to single-line format in various modules.
- Fixed async/await precedence and corrected indentation in benchmark files.
- Added benchmark report files for GPT-5.1-codex-mini model performance.
- Updated keyboard shortcuts: Ctrl+P/Shift+Ctrl+P now cycle role models instead of models.
- Changed Ctrl+T to toggle todo list expansion instead of thinking block.
- Added support for openai-codex-responses, google-vertex, cursor providers.
- Updated settings structure to use modelRoles object and removed deprecated options.
- Removed WASM base64 generation script and simplified postinstall process.
- Updated SDK documentation to reflect async auth/model discovery and new auth storage path.
- Added Windows ARM64 binary support and architecture detection in installers.
- Updated WASM loading to use streaming with base64 fallback for binary compatibility.
- Moved TTSR settings to dedicated tab and expanded abbreviation to Time Traveling Stream Rules.
- Added comprehensive install testing infrastructure with Docker validation.
- Updated package name from @oh-my-pi/omp-coding-agent to @oh-my-pi/pi-coding-agent.
- Renamed CLI binary and package from 'pi' to 'omp' across all platforms and installers.
- Changed environment variable prefix from PI_* to OMP_* with automatic migration support.
- Changed configuration directory from ~/.pi/ to ~/.omp/ with multi-path fallback discovery.
- Added getConfigDirPaths(), findConfigFile(), and readConfigFile() functions for config resolution across .omp, .pi, and .claude directories.