Commit Graph

30 Commits

Author SHA1 Message Date
can1357 51ec9bd05d feat(coding-agent): enabled docs:// protocol and custom tool discovery from .omp/tools/
- 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.
2026-02-19 22:19:00 +01:00
can1357 64c374a910 feat(coding-agent/discovery): added OpenCode discovery provider with config loading and MCP/skills/commands support
- Added OpenCode discovery provider that loads configuration from ~/.config/opencode/ and .opencode/ directories.
- Added support for loading MCP servers from opencode.json mcp key with stdio and HTTP transport types.
- Added support for loading skills from ~/.config/opencode/skills/ and .opencode/skills/ directories.
- Added support for loading slash commands from ~/.config/opencode/commands/ and .opencode/commands/ directories with frontmatter parsing.
- Added support for loading extension modules (plugins) from ~/.config/opencode/plugins/ and .opencode/plugins/ directories.
- Added support for loading context files (AGENTS.md) and settings from OpenCode configuration.
2026-02-17 09:36:23 +01:00
can1357 10a71b5c0c build: upgraded @biomejs/biome from 2.3.15 to 2.4.0
- Upgraded @biomejs/biome from 2.3.15 to 2.4.0.
2026-02-16 05:02:26 +01:00
can1357 a155d98f9f feat(coding-agent): auto-switch dark/light theme via SIGWINCH
Replace single `theme` setting with `theme.dark` and `theme.light`.
Auto-detection is always on — COLORFGBG determines which slot to use.
On SIGWINCH, re-check COLORFGBG and switch themes if background changed.
Old `theme` setting auto-migrated using luminance detection.

Fixes #65
2026-02-15 10:20:11 +01:00
can1357 c7c0a1e7b7 build: bumped @biomejs/biome from 2.3.14 to 2.3.15
- Bumped @biomejs/biome from 2.3.14 to 2.3.15.
2026-02-12 15:26:24 +01:00
can1357 1bebc8c6fd chore: expanded Biome configuration to include TypeScript files in package root directories
- Expanded Biome configuration to include TypeScript files in package root directories with new glob pattern `packages/*/*.ts`.
2026-02-11 08:12:09 +01:00
can1357 1845e96d13 feat(ai): migrated models export from TypeScript to JSON format and updated dependencies
- Migrated models export from TypeScript module to JSON format, changing the public API from importing MODELS from './models.generated' to importing from './models.json' with JSON import assertion.
- Updated @anthropic-ai/sdk dependency from ^0.72.1 to ^0.74.0.
- Simplified model generation script by replacing 49 lines of TypeScript code generation with direct JSON serialization.
- Updated @types/bun devDependency from ^1.3.8 to ^1.3.9 across all packages.
- Removed models.generated.ts exclusion from biome.json linting configuration.
2026-02-10 22:01:35 +01:00
can1357 315cd35958 feat(coding-agent/mcp): added TUI rendering for MCP tool calls and results with JSON tree display
- Added renderCall and renderResult methods to MCPTool and DeferredMCPTool classes for TUI rendering of tool calls and results.
- Created new mcp/render.ts module providing JSON tree rendering functionality with configurable depth and line limits for terminal display.
- Updated renderResult signature in custom tool and extension types to accept optional args parameter for accessing original tool arguments during result rendering.
- Fixed method binding in extension and hook tool wrappers by applying .bind(tool) to renderCall and renderResult methods to preserve correct 'this' context.
- Added filter to skip .git directories in fuzzy_find_sync function to improve search performance.
2026-02-03 21:59:54 +01:00
can1357 978b93ba62 refactor: migrated native tools to WASM-based implementation
- Consolidated grep, find, and image processing into a new `@oh-my-pi/pi-natives` WASM package.
- Eliminated subprocess overhead and simplified JS tool implementations.
- Updated CI to include Rust workspace, linting, formatting, and WASM build steps.
- Documented `Promise.withResolvers()` and `using` declarations for wasm-bindgen.
2026-01-29 09:29:21 +01:00
can1357 5f46437f70 feat(stats/client): added model statistics table and TTFT/throughput metrics to stats dashboard
- Added ModelStatsTable component to display model statistics with columns for model, provider, requests, cost, tokens, throughput, and error rate.
- Added 'models' tab to stats dashboard for viewing aggregated model performance metrics.
- Added TTFT (Time to First Token) metric display in request details and overview statistics.
- Added Tokens/s (throughput) metric calculation and display in request list and model statistics.
- Improved code formatting and accessibility by adding semantic HTML attributes (type='button', role, aria-modal) and reformatting style objects for readability.
- Refactored loadData function to use useCallback hook for better performance optimization.
2026-01-28 13:35:46 +01:00
can1357 a91330bae0 feat(ai): added Kimi Code provider integration with OAuth and token management
- Added Kimi Code provider integration with OAuth device authorization flow and token management.
- Added four new Kimi Code models (kimi-for-coding, kimi-k2, kimi-k2-turbo-preview, kimi-k2.5) with reasoning support and 262K context window.
- Added kimiUsageProvider for fetching and caching Kimi Code API usage quota information.
- Added kimi-code login command to CLI for OAuth authentication with Kimi Code.
- Updated openai-completions provider to support Kimi-specific headers and cached token formats.
- Updated MiniMax-M2 model pricing: input 1.2->0.6, output 1.2->3, cacheRead 0.6->0.1.
2026-01-28 13:22:19 +01:00
can1357 779ca4872b style(deps): migrated from Prettier to Biome and updated formatting rules
- 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.
2026-01-24 04:20:19 +01:00
can1357 53541b110b feat(coding-agent/core): added depth-controlled search and path utilities
- Added maxdepth and mindepth parameters to find function for depth-controlled file search.
- Added counter function to count occurrences and sort by frequency.
- Added basenames function to extract base names from paths.
- Fixed biome.json configuration to remove invalid double negation pattern.
2026-01-19 03:20:22 +01:00
can1357 03cfbd81d4 feat(coding-agent): added vendored photon WASM for image processing
- Replaced external photon-node dependency with vendored WebAssembly implementation.
- Added local photon library with 200+ image processing functions and WASM bindings.
- Updated image conversion and resize utilities to use local photon implementation.
- Added error handling for unknown OAuth providers in AI package.
2026-01-19 00:02:12 +01:00
can1357 242f319cfc feat(cursor): added Cursor AI provider with OAuth, HTTP/2 streaming, and tool execution bridge
- Added Cursor AI provider with HTTP/2 streaming support using Connect protocol and protobuf binary serialization.
- Added OAuth authentication flow for Cursor including browser-based login, token refresh, and expiry detection.
- Added 14 Cursor model definitions including Claude 4.5, GPT 5.x, Gemini 3, and Grok variants.
- Added execution bridge for Cursor tool calls supporting read, ls, grep, write, delete, shell, diagnostics, and MCP operations.
- Added cursorExecHandlers and cursorOnToolResult options to Agent for local tool execution with cursor-based streaming.
- Added emitExternalEvent method to Agent class for external event injection into agent state.
2026-01-11 07:42:41 +01:00
can1357 753be5d87f feat: introduced Worker-based subagent execution with BUILTIN_TOOLS registry
- Added ToolSession interface and Bun Worker-based subagent execution replacing subprocess spawning.
- Added BUILTIN_TOOLS registry and createTools factory function replacing individual tool exports.
- Added toolNames parameter for filtering which built-in tools to include in agent sessions.
- Removed deprecated tool exports (codingTools, readOnlyTools, createCodingTools, createReadOnlyTools).
- Removed subagent custom tool example and question custom tool example.
2026-01-07 03:03:34 +01:00
can1357 15fbe228b3 feat(monorepo): merged codex providers and extensions 2026-01-05 15:37:44 +01:00
can1357 a8fa0db830 chore: bump version to 2.3.1337 2026-01-03 14:53:38 +01:00
can1357 1cee37cf92 build: migrated from Node.js to Bun for native TypeScript support
- Migrated from Node.js to Bun runtime to leverage native TypeScript execution and faster startup times.
- Replaced npm with bun package manager and updated lockfile format.
- Converted Node.js APIs (child_process, fs, readline) to Bun equivalents across all packages.
- Updated shebang lines from node/tsx to bun for CLI entry points.
- Removed TypeScript build step by using source files directly as package entry points.
- Updated CI workflows to use Bun instead of Node.js for installation and testing.
2026-01-02 13:46:05 +01:00
Mario Zechner e7ad9738fc WIP: Remove global state from pi-ai OAuth/API key handling
- Remove setApiKey, resolveApiKey, and global apiKeys Map from stream.ts
- Rename getApiKey to getApiKeyFromEnv (only checks env vars)
- Remove OAuth storage layer (storage.ts deleted)
- OAuth login/refresh functions now return credentials instead of saving
- getOAuthApiKey/refreshOAuthToken now take credentials as params
- Add test/oauth.ts helper for ai package tests
- Simplify root npm run check (single biome + tsgo pass)
- Remove redundant check scripts from most packages
- Add web-ui and coding-agent examples to biome/tsgo includes

coding-agent still has compile errors - needs refactoring for new API
2025-12-25 01:01:03 +01:00
Mario Zechner f0c5be541f Enable more biome lints and fix things 2025-12-21 22:56:20 +01:00
Mario Zechner 964565c69a Release v0.22.1 2025-12-15 21:53:27 +01:00
Mario Zechner 6117127b02 mom: Single accumulated message per run, exclude data dir from biome 2025-11-26 01:21:45 +01:00
Mario Zechner 93a60b7969 Downgrade Biome to 2.3.5 to fix false positive noUnusedPrivateClassMembers warnings 2025-11-20 22:32:45 +01:00
Mario Zechner c7d00e6ba4 Updated README.md 2025-11-20 21:17:32 +01:00
Mario Zechner 00d8286523 Handle FinishReason.NO_IMAGE and fix optional chaining
- Add NO_IMAGE to error finish reasons in Google provider
- Fix non-null assertion after optional chaining in Anthropic provider
- Migrate biome config to 2.3.5
- Ignore Tailwind CSS file from biome checks
- Bump all packages to version 0.6.0
2025-11-12 10:58:03 +01:00
Mario Zechner 99983af597 Fix lints. 2025-10-03 23:21:59 +02:00
Mario Zechner 433b42ac91 Fix Biome config, don't submit empty assistant messages to completions endpoint. 2025-09-09 21:47:40 +02:00
Mario Zechner 66cefb236e Massive refactor of API
- Switch to function based API
- Anthropic SDK style async generator
- Fully typed with escape hatches for custom models
2025-09-02 23:59:36 +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