- Replaced deprecated `await` tool wiring with `poll` in tool exports and built-in tool registry.
- Updated bash and task prompts plus start-result messaging to direct users to the `poll` tool.
- Added effective timeout metadata to Bash tool results and rendered output to show that effective timeout.
- Implemented bounded auto-background wait logic that backgrounds jobs when the timeout window is exhausted.
- Added bash.autoBackground.enabled and bash.autoBackground.thresholdMs settings with defaults for background job behavior.
- Added auto-backgrounding support for long foreground bash commands with managed job state and timeout threshold.
- Updated bash prompts, job-protocol messages, and tool activation checks to use async and auto-background support.
- Added background bash completion integration with AsyncJobManager and end-to-end tests for short/long auto-background scenarios.
- Added bounds clamping to prologue and epilogue byte calculations to prevent out-of-range boundary violations.
- Extended chunk boundaries for indent-based languages when epilogue exceeds calculated range with trailing newline.
- Added comprehensive test coverage for Python chunk editing operations including body/head replacement and indentation preservation.
- Extracted working directory formatting logic into reusable utility function and applied tab sanitization to bash command previews.
- 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.).
- Extracted OAuth identifier logic into public functions extractOAuthCredentialIdentifiers and extractOAuthTokenIdentifiers.
- Replaced single credentialIdentity string with multi-identifier resolveCredentialIdentifiers returning string[] for flexible matching.
- Changed credential deduplication from email-based to accountId-based matching in replaceAuthCredentialsForProvider.
- Updated auth-storage tests to verify accountId-prioritized deduplication behavior across soft-disable and hard-delete scenarios.
- Added documentation comments in coding-agent modules explaining partial JSON preservation for streaming tool previews.
- Documented streaming tool preview requirements and render paths in AGENTS.md.
- Added `env` parameter to bash tool for safe environment variable passing without shell re-parsing.
- Added support for rendering partial environment variable assignments in command preview during streaming.
- Updated bash tool prompt to recommend `env` parameter for multiline, quote-heavy, and untrusted values.
- Refactored tool execution component to conditionally merge partial JSON arguments during streaming.
- Added helper functions for environment variable normalization, escaping, and formatting.
- Added auto-inclusion of ast_grep and ast_edit tools when their text-based counterparts are enabled.
- Made AST tool recommendations conditional in bash tool prompt based on session availability.
- Replaced timeout-based cancellation with AbortSignal-based cancellation in ask tool.
- Added auto-correction of escaped tab indentation in edits via PI_HASHLINE_AUTOCORRECT_ESCAPED_TABS environment variable.
- Added warning detection for suspicious Unicode escape placeholder in edit content.
- Added `tools.maxTimeout` setting to enforce global timeout ceiling across all tool calls.
- Centralized per-tool timeout constants and clamping logic into `tool-timeouts.ts` module.
- Extracted `clampTimeout()` function to standardize timeout enforcement across bash, python, browser, ssh, and fetch tools.
The non-interactive environment variables (pager, editor, and prompt
suppression) were only applied in the PTY (interactive) bash path.
The non-PTY executeBash path had no such defaults, so commands could
block on pagers or credential prompts.
- Extract NO_PAGER_ENV from bash-interactive.ts into shared
non-interactive-env.ts module (renamed to NON_INTERACTIVE_ENV)
- Apply it in executeBash (non-PTY) with user overrides taking
precedence
- Fix ordering in interactive PTY path so user env overrides
the defaults (was reversed)
- Add test verifying defaults are applied alongside user env
- Consolidated @oh-my-pi/pi-utils subpath imports into single package root import across 100+ files.
- Moved tryParseJson utility from local web scrapers module to @oh-my-pi/pi-utils package for centralized JSON parsing.
- Renamed loadSkillsFromDir to scanSkillsFromDir and refactored skill discovery to use fs.promises.readdir instead of glob-based approach.
- Replaced custom parseJSON with tryParseJson across discovery modules for consistent error handling.
- Removed emitCustomToolSessionEvent method and cleanupSshResources function, consolidating shutdown logic into dispose method.
- Updated glob pattern construction to use GlobBuilder with literal_separator(true) for improved path handling.
- Standardized XML tag naming from snake_case to kebab-case across 50+ prompt files for consistency.
- Replaced imperative language with RFC 2119 keywords (MUST/SHOULD/MAY/MUST NOT) throughout system and tool prompts for clarity.
- Removed artifactsDir parameter from Python executor and simplified environment variable handling to use PI_SESSION_FILE only.
- Renamed read_path.md to read-path.md and updated memory guidance with hierarchy rules and conflict resolution workflow.
- Added noEscape option to bash URL expansion and extracted cwd parameter from leading cd commands for improved path handling.
- Exported NO_PAGER_ENV constant from bash-interactive module for centralized environment variable management.
- Added per-command `pty` parameter to bash tool for fine-grained PTY mode control.
- Removed global `bash.virtualTerminal` setting in favor of per-command PTY parameter.
- Fixed potential deadlock in shell session cleanup by replacing blocking lock with non-blocking try_lock.
- Updated async session key generation to include jobId for improved session isolation.
- Added poll_jobs tool for blocking until background jobs complete without manual polling loops.
- Added task.maxConcurrency setting to limit concurrent subagent task execution with semaphore-based control.
- Enhanced task progress tracking to report per-task status with individual timing and token metrics.
- Improved parallel task execution to schedule multiple background jobs independently for true concurrent execution.
- Updated bash and task tool documentation to recommend poll_jobs instead of polling read jobs:// in loops.
- Added async background job execution for bash and task tools with configurable concurrency limits and automatic result delivery.
- Added cancel_job tool and /jobs slash command to manage and inspect running background jobs with status display.
- Added jobs:// internal protocol handler for querying job status and retrieving job execution details.
- Added async.enabled and async.maxJobs settings to control background job execution behavior.
- Enhanced status line to display count of running background jobs with visual indicator.
- Implemented AsyncJobManager with exponential backoff retry delivery, job lifecycle tracking, and automatic eviction.
Fixes#56.
- Moved artifact management from ToolSession to SessionManager for centralized lifecycle control and caching.
- Replaced getArtifactManager() with allocateOutputArtifact() async method in ToolSession interface for simplified artifact allocation.
- Updated bash, fetch, python, and ssh tools to call session.allocateOutputArtifact() directly with optional chaining fallback.
- Fixed Lobsters scraper to handle user fields as strings instead of nested objects in API responses.
- Extracted credential storage to shared @oh-my-pi/pi-ai package with AuthCredentialStore and AuthStorage classes.
- Consolidated UI formatting logic from ToolUIKit class into standalone utility functions across render-utils and output-meta modules.
- Moved utility functions (parseCommandArgs, substituteArgs, expandPath, normalizeUnicode) to dedicated modules for improved code reuse.
- Extracted JTD type definitions and type guards to jtd-utils module for shared use across schema conversion tools.
- Updated Claude model pricing and added cache read costs in models.json for accurate billing calculations.
- Refactored agent-storage to delegate credential management to AuthCredentialStore instead of direct SQLite operations.
- Consolidated truncation and output utilities from tools/truncate.ts and tools/output-utils.ts into session/streaming-output.ts with improved UTF-8 boundary handling.
- Renamed formatSize() to formatBytes() across codebase for consistency and clarity in byte-level formatting.
- Refactored OutputSink to use windowed byte truncation instead of full-buffer encoding, improving memory efficiency on large outputs.
- Migrated from Buffer to Uint8Array in web scrapers for better cross-platform compatibility and native browser support.
- Added getArtifactManager() lazy-initialization method to ToolSession for deferred artifact manager instantiation.
- Simplified API surface with wildcard exports from tools and session modules, reducing import complexity.
- Fixed persistent shell session state not being reset after command abort or hard timeout.
- Fixed hard timeout handling to properly interrupt long-running commands exceeding grace period.
- Introduced hard timeout mechanism with Promise.race() to enforce absolute timeout limit and prevent command hangs.
- Replaced shell command execution with explicit timeout and SIGKILL signal handling in shell-snapshot.
- Simplified bash command normalization to use only explicit head/tail parameters from tool input.
- Exported getAntigravityUserAgent() function for centralized User-Agent header construction.
- Replaced all direct `process.cwd()` calls with `getProjectDir()` utility function across 40+ files to centralize project directory resolution logic.
- Added `getProjectDir()` and `setProjectDir()` functions to `@oh-my-pi/pi-utils/dirs` module to provide abstracted project directory management.
- Made `SessionManager.list()` method asynchronous to support asynchronous session discovery operations.
- Updated default working directory resolution throughout codebase to use `getProjectDir()` instead of `process.cwd()` for improved project directory detection.
- Added PTY (pseudo-terminal) backed interactive command execution with streaming output support via PtySession class in pi-natives.
- Added PtyStartOptions and PtyRunResult types to configure and report PTY session execution status.
- Added write(), resize(), and kill() methods to PtySession for interactive control of running commands.
- Added interactive bash execution via PTY with real-time terminal rendering and input forwarding in bash-interactive tool.
- Added --no-pty CLI flag and PI_NO_PTY environment variable to disable PTY-based interactive bash execution.
- Added bash.virtualTerminal setting to control PTY-backed interactive execution behavior.
- Changed hashline display format separator from pipe to two spaces for improved readability.
- Removed `lines` and `hashes` parameters from read tool in favor of automatic file display mode resolution.
- Added `resolveFileDisplayMode` utility to centralize file display mode configuration logic.
- Integrated file display mode settings into grep and read tools for consistent output formatting.
- Consolidated tool parameter types to use schema-derived types via Typebox `Static` utility.
- Updated parseLineRef to handle both legacy pipe-separator and new two-space hashline formats.
- Added abort event listener registration in bash executor to properly handle abort signals and clean up resources in finally block.
- Improved bash tool error handling to distinguish between user-initiated aborts via AbortSignal and other cancellations, throwing ToolAbortError for aborted requests.
- Wrapped bash executor command execution in try-finally block to ensure abort event listeners are properly removed after execution completes.
- Migrated console.error() calls to structured logger.warn() and logger.error() throughout codebase.
- Updated os.tmpdir() import style in browser tool from destructured to namespace import.
- Fixed tab character display in error messages and bash tool output by applying replaceTabs() sanitization.
- Added TUI rendering sanitization documentation to AGENTS.md with guidelines for sanitizing text in tool renderers.
- Applied replaceTabs() function to error text in patch shared module to ensure proper tab-to-space conversion.
- Applied replaceTabs() function to bash tool output lines in both expanded and collapsed display modes.
- Implemented caching for tool output block rendering to avoid redundant computations on re-renders.
- Enhanced read tool grouping to prevent coalescing across narrative boundaries (text/thinking blocks between tool calls).
- Improved string preview formatting to detect multi-line strings and display line counts with ellipsis indicators.
- Refactored tool execution component to use reactive render state tracking for better state management.
- Enhanced error handling in tool renderers with logging for failures.
- Fixed truncation indicator to use ellipsis character instead of verbose suffix.
- Converted class properties to TypeScript parameter properties across 51 files to reduce boilerplate code.
- Removed explicit field declarations and manual assignments in constructors by using TypeScript's parameter property syntax with access modifiers.
- Applied consistent pattern of declaring private readonly and public readonly properties directly in constructor parameters.
- Added exclusive concurrency mode enforcement to file-modifying tools (edit, write, bash, python, ssh, todo-write) by introducing a new public `concurrency` property set to "exclusive" on each tool class.
- Updated CHANGELOG.md to document the enforcement of exclusive concurrency mode for file-modifying tools.
- Cleaned up imports in tool-execution.ts by removing unused Theme type import and reordering imports for better organization.
- Consolidated directory listing functionality from dedicated `ls` tool into the `read` tool.
- Removed the `ls` tool and all related exports, types, and configurations from the public API.
- Updated `read` tool to return formatted directory listings with modification times instead of redirecting to `ls` tool.
- Removed `bashInterceptor.simpleLs` setting and related interception logic from bash tool.
- Removed `ls.enabled` setting and related tool registration logic.
- Removed test cases for the `ls` tool and updated tool type definitions to remove `LsToolResultEvent`.
- Changed TextInput type parameter to string in truncateToWidth(), visibleWidth(), sliceWithWidth(), and extractSegments() functions in native bindings.
- Removed TextInput type export from public API of pi-natives package.
- Removed format.ellipsis symbol from theme configuration, replacing all theme-based ellipsis references with hardcoded Unicode ellipsis character (...).
- Removed ellipsis property from SymbolTheme interface in pi-tui package.
- Removed truncateToWidth, sliceWithWidth, and extractSegments wrapper functions from pi-tui public API, now re-exporting directly from pi-natives.
- Added early return optimizations in truncateToWidth() and sliceWithWidth() native functions to skip native calls when possible.
- Replaced SettingsManager class with new Settings singleton providing synchronous get/set API and background persistence.
- Introduced settings-schema.ts as single source of truth for all configuration definitions with 100+ settings organized into logical groups.
- Migrated from method-based settings access (getTheme(), setTheme()) to path-based access using dot notation (settings.get('theme'), settings.set('theme', value)).
- Removed 2035-line settings-manager.ts file and replaced with modular settings.ts (693 lines) and settings-schema.ts (836 lines) for improved maintainability.
- Unified settings schema into single source of truth eliminating duplicate definitions across settings-defs.ts and settings-manager.ts.
- Added head and tail parameters to bash tool for native output limiting without piping.
- Implemented automatic normalization of bash commands to extract and strip head/tail pipes and stderr redirects.
- Created bash-normalize utility module with normalizeBashCommand and applyHeadTail functions for command processing.
- Updated bash tool documentation to recommend using head/tail parameters instead of piping through shell commands.
- Added comprehensive test coverage for bash command normalization and head/tail filtering functionality.
- Renamed `head_limit` to `limit` in grep and find tools for consistency.
- Added `context` as optional alias for the `c` parameter in grep.
- Made hidden files inclusion configurable in find with `hidden` parameter.
- Integrated .gitignore and .ignore file support in find tool.
- Updated plan mode documentation for self-contained plan files.
- 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.
- Converted readdirSync, readFileSync, and statSync to async readdir, readFile, stat across skills and agent discovery.
- Made scanDirectoryForSkills async and refactored custom directory scanning to use Promise.all for concurrent processing.
- Updated agent discovery to use fs/promises for async file reading and refactored helper patterns.
- Added AgentParsingError exception class for better error handling during agent parsing.
- Added filesystem error type guards (isEnoent, isEacces, isPerm, etc.) to pi-utils for safe error checking.
- Added color manipulation utilities to pi-utils for accessibility features.
- Added color-blind mode setting to settings manager.
- Migrated plugins, settings, and config modules from sync to async file operations.
- Updated error handling to use new pi-utils type guards for type-safe checking.
- 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 indentation and line breaks in nested code blocks (lsp/render.ts, patch/shared.ts).
- Collapsed overlong function arguments and ternary expressions to standard line length.
- Reorganized import statements for consistency (ask.ts).
- Improved readability of conditional expressions (output-block.ts, web/search/render.ts, python.ts).