Commit Graph

45 Commits

Author SHA1 Message Date
can1357 1f7c4f6f90 refactor(stream-parsing): restructured stream utilities to use Web standard APIs and generic SSE parsing
- Refactored SSE stream parsing to use generic `readSseJson` utility instead of domain-specific handlers across multiple packages.
- Migrated from Node.js Buffer API to Web standard APIs (Uint8Array, TextDecoder, DataView) for cross-platform compatibility.
- Simplified stream transformation pipeline by consolidating multiple stream operations into unified `createTextLineSplitter` utility.
- Refactored `ptree.ts` to remove complex stream pumping infrastructure and simplify stderr handling with direct async iteration.
- Rewrote stream utilities to operate at binary level with byte-level parsing for improved efficiency and reduced string allocations.
- Updated TypeScript configuration to include DOM.AsyncIterable type definitions for async iterable DOM API support.
2026-02-05 10:59:47 +01:00
can1357 acc799cd2e chore(ci): improved release process and expanded Rust toolchain support
- Updated release process to create new commits with descriptive messages instead of amending previous commits.
- Changed release push strategy from force push to regular push for better git history integrity.
- Extended check:rs script to verify minimal dependency versions and Windows MSVC target compilation.
- Added x86_64-pc-windows-msvc target to Rust toolchain configuration for cross-compilation support.
2026-02-05 08:28:56 +01:00
can1357 37c74bb19d perf: migrated timing measurements to Bun.nanoseconds() for higher precision
- Migrated timing measurements from `performance.now()` to `Bun.nanoseconds()` for higher precision benchmarking across all benchmark and timing-sensitive code.
- Updated elapsed time calculations to convert nanoseconds to milliseconds using division by 1e6 to maintain consistent time units.
- Increased benchmark precision from 4 to 6 decimal places for per-operation timing measurements.
- Refactored grep benchmark to use averaged timing values instead of storing individual iteration times, reducing memory overhead.
2026-02-05 06:19:49 +01:00
can1357 89e6479661 refactor: migrated environment variable access from process.env to Bun.env across 71 files
- Migrated all environment variable access from Node.js `process.env` to Bun runtime `Bun.env` API across the entire codebase.
- Updated 71 files including source code, tests, documentation, and configuration to use Bun's native environment variable API.
- Added comprehensive environment variables documentation in `packages/coding-agent/docs/environment-variables.md` covering 100+ environment variables organized by category.
- Updated CHANGELOG entries to reflect migration from `process.env` to `Bun.env` and environment variable prefix changes (PI_* vs OMP_*).
- Maintained identical behavior and logic across all changes - only the environment variable access method was updated.
2026-02-05 04:51:18 +01:00
can1357 ec801665bc refactor(env): migrated environment variables from OMP_ to PI_ prefix and centralized access via getEnv()
- Migrated environment variable access from direct process.env to centralized getEnv() utility function across all packages.
- Renamed environment variable prefix from OMP_ to PI_ throughout codebase (e.g., OMP_CODING_AGENT_DIR -> PI_CODING_AGENT_DIR).
- Removed automatic environment variable migration from PI_ to OMP_ prefixes via migrate-env.ts module.
- Removed env setting from configuration schema and applyEnvironmentVariables() method from settings.
- Updated CI/CD build configuration to use PI_COMPILED flag instead of OMP_COMPILED.
- Changed venvPath property in PythonRuntime from nullable (string | null) to optional (string | undefined).
2026-02-05 02:55:01 +01:00
can1357 f41705ce3a feat(coding-agent): improved Python startup performance with prelude caching and shared gateway mode
- Added Python prelude caching to improve startup performance by caching helper functions and module discovery results.
- Added OMP_DEBUG_STARTUP environment variable for detailed startup stage tracing across initialization pipeline.
- Changed Python kernel initialization to require shared gateway mode, removing support for local kernel gateway startup.
- Improved error handling in shared gateway acquisition with automatic retries on 5xx status codes.
- Added repro-stuck.ts script for reproducing and debugging rare CLI hang issues with Chrome DevTools integration.
- Added trace-loader.ts preload script for tracing module resolution during startup diagnostics.
2026-02-04 05:02:28 +01:00
can1357 ad37a58b5f feat(scripts): added job-level status checking in CI watcher with auto log tailing for failures
- Added job-level status checking in CI watcher to fail fast on first job failure with detailed error reporting.
- Added automatic log tailing for failed CI jobs showing last 20 lines of output.
2026-02-01 20:34:12 +01:00
can1357 1e52c837c8 feat(natives): added native addon distribution and platform validation to CLI update mechanism
- Added native addon distribution and installation support to the CLI update mechanism, enabling platform-specific native modules to be downloaded and installed alongside the main binary.
- Added platform validation in native addon loader to verify supported platforms (linux-x64, linux-arm64, darwin-x64, darwin-arm64, win32-x64) with helpful error messages for unsupported configurations.
- Enhanced native addon loading error messages to provide platform-specific troubleshooting guidance for both npm/bun installations and local development environments.
- Updated installation scripts (install.sh, install.ps1) to download and install native addon files alongside the main binary during CLI installation.
2026-02-01 05:17:06 +01:00
can1357 2c85f43709 refactor(utils): renamed packages/pi-utils to packages/utils
- Renamed package directory from packages/pi-utils to packages/utils.
- Updated all path aliases and references in tsconfig.base.json to reflect new package location.
- Updated workspace references in bun.lock and package.json to point to new packages/utils directory.
- Updated documentation and build scripts to reference the renamed utils package.
2026-01-29 11:03:27 +01:00
can1357 32bc2b8d02 fix: fixed LSP server display, file streaming, and slash command autocomplete; reorganized npm scripts
- Fixed LSP servers showing as 'unknown' in status display when server warmup fails by using index-based lookup to correctly extract server name and file types.
- Fixed Read tool loading entire file into memory when offset/limit was specified by implementing streaming line-by-line processing that only collects requested range.
- Fixed slash command autocomplete applying stale completions when typing quickly by adding staleness check before applying completion on Enter/Return.
- Reorganized npm scripts to follow consistent naming pattern with separate TypeScript and Rust variants for check, lint, fmt, and fix operations.
- Updated release script to properly handle Rust workspace version updates in Cargo.toml files and regenerate lockfiles.
2026-01-29 10:57:20 +01:00
can1357 ec463fe7c7 chore(scripts): updated Bun engine requirement to 1.3.7 and added version validation
- Updated minimum Bun engine requirement from 1.2.0 to 1.3.7 across root and coding-agent packages.
- Added Bun version validation to install.ps1 with Get-BunVersion, Test-BunVersion, and Assert-BunVersion functions to enforce minimum version requirement.
- Added Bun version validation to install.sh with version_ge and require_bun_version functions to enforce minimum version requirement.
2026-01-28 04:10:00 +01:00
can1357 d9a3291641 feat(deps): replaced external JSON/JSONL and text utilities with Bun built-in APIs
- Replaced external JSON/JSONL parsing libraries with Bun's built-in JSON5 and JSONL APIs across all packages.
- Removed dependencies: json5, ndjson, get-east-asian-width, json-stringify-safe, split2, through2, and @types/ndjson.
- Replaced custom text width and ANSI wrapping implementations with Bun.stringWidth() and Bun.wrapAnsi() APIs.
- Updated Bun type definitions from ^1.2.17 to ^1.2.18 and bun-types from ^1.3.5 to ^1.3.7.
- Refactored JSONL parsing throughout codebase to use Bun.JSONL.parse() and Bun.JSONL.parseChunk() with improved buffer management and error handling.
- Updated test assertions to use Bun.stringWidth() for dynamic width calculations instead of hardcoded values.
2026-01-27 19:18:58 +01:00
can1357 f901befd19 refactor(model-discovery): converted model discovery to synchronous file operations
- Changed loadCustomModels from async to sync using fs.readFileSync for immediate resolution.
- Updated discoverModels to return synchronously, removing await from main.ts, pipeline.ts, and commit index.ts.
- Migrated sdk.ts to use node:fs instead of node:fs/promises for synchronous operations.
- Refactored scanDirectoryForSkills to use recursive traversal instead of batch Promise.all.
- Added tarball Dockerfile for testing npm publish/install flow with verdaccio registry.
2026-01-24 04:00:12 +01:00
can1357 fc3dd7e569 fix(tui): fixed race conditions and null reference errors
- Fixed autocomplete race condition in editor by tracking request ID to discard stale results.
- Added guard clause in plugin-settings to prevent null reference when settings list is undefined.
- Added branch change callbacks in footer to update state after git head resolution.
- Added timing instrumentation to Python kernel startup and gateway acquisition.
- Improved error logging in settings manager for config file access failures.
- Fixed model discovery to re-check file existence after JSON to YAML migration and improved file access error handling.
2026-01-24 03:23:02 +01:00
can1357 e22d123009 refactor(fs): migrated remaining sync file operations to async
- 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.
2026-01-24 03:18:03 +01:00
can1357 fcbfab765b refactor: consolidated module import paths
- Removed custom TypeScript path aliases and the associated transformation script.
- Replaced aliased imports with direct `@oh-my-pi` package imports for improved clarity.
- Simplified internal module references by removing explicit `/index` suffixes.
2026-01-23 21:01:13 +01:00
can1357 7b5af2dd9f refactor(build): migrated imports to path aliases with per-package tsconfig support
- converted relative imports to path aliases ($c/*, $ai/*, $tui/*, etc.) across all packages
- added per-package tsconfig.json with complete path mappings for runtime resolution
- set importModuleSpecifier to non-relative for IDE auto-import preferences
- updated dev script to run from monorepo root for consistent path resolution
2026-01-23 11:56:32 +01:00
can1357 b9c9330ea1 feat: enhanced usage providers to extract account identifiers from headers
- Enhanced usage providers to extract account identifiers from response headers.
- Fixed GitHub Copilot usage provider token handling and account identifier resolution.
- Added usage report deduplication and provider sorting features.
- Added isolated task execution with git worktree management.
2026-01-21 23:52:03 +01:00
can1357 5ae70ed2dd feat: enhanced patch applicator with fallback variants and fuzzy matching
- Enhanced patch applicator with fallback variant generation and improved fuzzy matching.
- Added support for ellipsis placeholders, top-of-file anchors, and comment-prefix normalization.
- Renamed operation and moveTo parameters to op and rename across patch tool interfaces.
- Added batch processing system to benchmark runner for parallel task execution.
- Added comprehensive benchmark reports for Claude Haiku and GPT-5.1-codex-mini models.
2026-01-19 16:16:55 +01:00
can1357 7a081e1c7c feat: added React mutation testing package and coding-agent improvements
- Added new @oh-my-pi/react-edit-benchmark package for React source code mutation testing.
- Added --no-title flag to disable automatic session title generation in coding-agent.
- Changed default behavior of read tool to omit line numbers by default.
- Added environment variable support for edit tool configuration and fuzzy matching.
- Updated test files to use import.meta.dir for ES module compatibility.
- Added Prettier configuration and CI improvements for private package handling.
2026-01-19 16:16:55 +01:00
can1357 50e3d73b65 feat(coding-agent): added allowFuzzy option to control patch matching behavior
- Added allowFuzzy option to control fuzzy matching behavior in patch operations.
- Added validation for line numbers to ensure they are >= 1 in patch headers and hints.
- Enhanced fuzzy matching algorithms to respect the allowFuzzy setting for precise control.
- Fixed patch application to prefer actual diff over cached preview when displaying results.
2026-01-19 16:16:55 +01:00
Can Bölük acb70f3545 fix: simplify binary installation in install.ps1
- Removed architecture suffix handling for binary installation.
2026-01-19 15:16:35 +01:00
can1357 34f2fc0854 chore: bump version to 6.0.0 2026-01-19 01:38:04 +01:00
can1357 5a601bb0c0 feat: added Windows ARM64 support and streaming WASM loading with base64 fallback
- 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.
2026-01-19 01:23:27 +01:00
can1357 7469166ad1 chore: cleaned historical changelog entries and added validation to release script
- Removed historical version entries from multiple package CHANGELOG files.
- Added changelog validation functions to release script.
- Prevented creation of empty version entries in changelog generation.
2026-01-18 21:50:00 +01:00
can1357 ac151519c1 feat: port upstream changes from pi-mono (72047c05..55769e75)
AI provider fixes:
- Fixed Claude tool prefix matching and Gemini 3 unsigned tool handling
- Added Bedrock thinking budget guardrails and tool id sanitization
- Added tool argument coercion and Codex response retry logic

TUI improvements:
- Improved Kitty key handling and editor behavior (scrolling, padding, kill ring)

Coding agent changes:
- Added extension input interception, compaction helpers, and UI updates
- Added session forking prompt for cross-project sessions
- Added APPEND_SYSTEM discovery, piped stdin print mode, and key hint exports

Docs:
- Updated pi-mono sync point
2026-01-18 17:52:58 +01:00
can1357 91e2d478fb chore: bump version to 3.33.0 2026-01-08 14:13:08 +01:00
can1357 5ec30e19f4 feat(scripts): added --ref flag for installing specific git refs
- Added --ref flag to install specific tags, branches, or commits from source or binary releases.
- Enabled source installation from git refs by cloning and checking out the specified reference.
- Added git availability check for source installations with --ref flag.
- Updated README with usage examples for --ref flag on both shell and PowerShell installers.
2026-01-06 22:01:24 +00:00
can1357 f26493824e feat(coding-agent): added 65 themes to expand user customization options
- Added 65 new built-in color themes including dark, light, and material variants.
- Added theme sync script to generate theme index from JSON files.
- Expanded default theme collection from approximately 30 to 96 themes.
2026-01-05 05:16:07 +01:00
can1357 4cc8270ad5 chore: bump version to 3.15.0 2026-01-05 04:52:31 +01:00
can1357 24170d4be2 feat: added watch subcommand to release script 2026-01-04 16:25:50 +01:00
can1357 5a9346ac0c refactor: use Bun shell API in release script 2026-01-04 16:21:36 +01:00
can1357 068a2965a9 refactor: simplified release script glob usage 2026-01-04 16:20:17 +01:00
can1357 994dc34f40 fix: release script now waits for all CI workflow runs 2026-01-04 16:18:35 +01:00
can1357 77bca78dd3 chore: migrated release script to TypeScript 2026-01-04 16:16:29 +01:00
can1357 790a5370bb feat: renamed binary from pi to omp with config migration support
- 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.
2026-01-03 15:54:45 +01:00
can1357 d969b0d565 feat(scripts): added --source and --binary flags for install method control
- Added --source and --binary flags to control installation method in install scripts.
- Enabled automatic bun detection with fallback to prebuilt binary for default installation.
- Added bun-based installation option that installs bun automatically if needed.
- Documented new installer options in README with usage examples.
2026-01-03 14:37:17 +01:00
can1357 a42061d9ee feat(coding-agent): added self-update command with bundled templates
- Added `pi update` command for checking and installing CLI updates from GitHub releases or bun.
- Added cross-platform installer scripts (shell and PowerShell) with automatic PATH configuration.
- Changed HTML export to use compile-time bundled templates via Bun macros.
- Changed `exportToHtml` and `exportFromFile` functions to async operations.
2026-01-03 14:17:28 +01:00
can1357 2be354322d chore: renamed package scope to @oh-my-pi for consistent branding
- Renamed npm package scope from @mariozechner to @oh-my-pi across all packages for consistent branding.
- Removed packages/pods directory and all related pod management functionality.
- Updated import paths and module declarations throughout codebase to reflect new package names.
- Reformatted code with consistent trailing comma removal and ternary operator alignment.
2026-01-02 18:08:23 +01:00
Mario Zechner ee8dd7f182 Add release script
Usage: npm run release:patch|minor|major

Automates:
- Check for uncommitted changes
- Bump version
- Update CHANGELOGs: [Unreleased] -> [version] - date
- Commit and tag
- Publish to npm
- Add new [Unreleased] sections
- Push
2025-12-30 22:42:21 +01:00
Mario Zechner bc670bc63c Fix lockstep versioning and improve documentation
- Sync all packages to version 0.7.7
- Rewrite sync-versions.js to handle ALL inter-package dependencies automatically
- Fix web-ui dependency on pi-ai (was 0.6.0, now 0.7.7)
- Move agent fix changelog entry to coding-agent CHANGELOG
- Remove redundant agent CHANGELOG.md
- Improve README.md with clearer lockstep versioning docs
- Add /changelog command to display full changelog in TUI (newest last)
- Fix changelog description (not a scrollable viewer, just displays in chat)
- Update CHANGELOG for 0.7.7 release
2025-11-13 23:37:43 +01:00
Mario Zechner 8be2613417 Fix version sync script to update all internal dependencies 2025-11-12 14:41:40 +01:00
Mario Zechner 2a7ccf0fcb Updates to prompts 2025-10-17 22:44:03 +02:00
Mario Zechner 66f092c0c6 Proxy package 2025-10-05 19:02:15 +02:00
Mario Zechner a74c5da112 Initial monorepo setup with npm workspaces and dual TypeScript configuration
- Set up npm workspaces for three packages: pi-tui, pi-agent, and pi (pods)
- Implemented dual TypeScript configuration:
  - Root tsconfig.json with path mappings for development and type checking
  - Package-specific tsconfig.build.json for clean production builds
- Configured lockstep versioning with sync script for inter-package dependencies
- Added comprehensive documentation for development and publishing workflows
- All packages at version 0.5.0 ready for npm publishing
2025-08-09 17:18:38 +02:00