Skip to content

Conversation

brandonkachen
Copy link
Collaborator

No description provided.

@brandonkachen brandonkachen force-pushed the brandon/tui branch 4 times, most recently from 5a347f3 to 870113d Compare October 14, 2025 00:14
brandonkachen and others added 24 commits October 14, 2025 10:48
Implement stateful XML parser to remove <codebuff_tool_call> tags from handleStreamChunk output while preserving text before/after tool calls and handling tags split across chunk boundaries.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
…line editing in the CLI chat. Improves user experience with proper newline handling, cursor navigation, and line wrapping.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff Co-Authored-By: Codebuff
<[email protected]>
…y renderer and update dependencies

This replaces the old markdown renderer (marked/marked-terminal) with a remark/unified-based pipeline. It updates CLI dependencies (remark-parse/unified) and adjusts dev workflow to Bun-based watch mode.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
…e unused clamp helper. Standardize deletion/navigation shortcuts across macOS/Windows to improve reliability and consistency.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
…pport; align build process to ensure reliable color rendering in macOS terminals.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
Updates OpenTUI submodule to include:
- RGB to 8-bit ANSI color conversion for terminals without RGB support
- Fixed macOS Terminal color rendering (RGB -> 256-color fallback)
- Improved build process with automatic binary copying
- Documentation for troubleshooting color issues

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
Adds support for running the CLI chat app with a prompt argument that auto-executes and displays debug logs.

Changes:
- cli/src/index.tsx: Parse -p argument and pass initialPrompt to App
- cli/src/chat.tsx: Auto-submit prompt on mount, wait for completion, display debug log, then exit
- cli/src/chat.tsx: Log subagent chunks via handleEvent callback
- cli/src/chat.tsx: Track subagent lifecycle with activeSubagentsRef
- cli/src/chat.tsx: Conditionally log chunks in handleStreamChunk when subagents are active
- sdk/src/run.ts: Simplify onSubagentResponseChunk to only call callbacks (remove file logging)
- sdk/src/run-state.ts: Remove unused subagents field from RunState type
- sdk/README.md: Remove documentation about codebuff-events.log

Usage: bun run cli/src/index.tsx -p "your prompt here"

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
Updates OpenTUI submodule to include fix for cross-runtime compatibility by replacing Bun.stripANSI with custom implementation.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
- Detect Zed IDE via ZED_TERM environment variable
- Implement ZedScrollAccel with 0.15x base multiplier and velocity-based boost
- Refactor useScrollManagement to useChatScrollbox hook
- Add smooth animated scrolling with easeOutCubic easing
- Consolidate Zed detection and scroll configuration in hook
- Scroll acceleration: 0.15x base, up to 1.9x for sustained fast scrolling

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
brandonkachen and others added 8 commits October 14, 2025 10:48
This adds hierarchical agent nesting support so spawned agents appear
inside their parent agent blocks in the UI, making agent relationships
clearer.

🤖 Generated with Codebuff Co-Authored-By: Codebuff
<[email protected]>
Prevents tool calls from attempting to nest under agent blocks that
don't exist yet. Adds recursive search to confirm agent block presence
before nesting, falling back to top-level placement when needed.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
brandonkachen and others added 2 commits October 14, 2025 14:22
Conditionally add agentId to tool call metadata only when the agent has a parent. This prevents the base agent from unnecessarily including its ID in tool calls while maintaining proper tracking for spawned subagents.

Also simplified CLI agent block logic by removing unused helper and using existing recursive update function.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
Removed obsolete TODO list documentation that described non-existent features.
Added Zustand store, message virtualization, and performance optimizations.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
Remove git submodule dependency on packages/opentui and replace with a
cross-platform TypeScript postinstall script that creates symlinks to
OpenTUI packages. This improves monorepo management and eliminates
submodule complexity.

Changes: - Remove .gitmodules and packages/opentui submodule - Add
scripts/setup-cli-symlinks.ts for automated symlink creation - Update
postinstall script in package.json - Add preserveSymlinks: false to
cli/tsconfig.json - Document new setup approach in cli/knowledge.md

🤖 Generated with Codebuff Co-Authored-By: Codebuff
<[email protected]>
brandonkachen and others added 13 commits October 14, 2025 17:16
- Added @types/react-reconciler@^0.32.0 as devDependency - Fixes
TypeScript errors in OpenTUI host-config.ts - Also fixed typo in
node_modules/@opentui/react (react-re reconciler -> react-reconciler)
…gation

Enables correct UI nesting of spawned agents by propagating parentAgentId through the event system. Backend now adds parentAgentId to nested agent events, and CLI uses this to nest spawned agents under their parents instead of showing them at top level.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
filtering

Prevents <codebuff_tool_call> blocks from appearing in the UI by
buffering and processing text chunks to detect and skip tool call
boundaries. Adds intelligent buffer management that outputs safe text
while keeping a 50-char buffer to avoid partial tags. Ensures all
legitimate text content is displayed by flushing remaining buffer at
stream end.

🤖 Generated with Codebuff Co-Authored-By: Codebuff
<[email protected]>
Thoughtfully merged changes in backend/src/run-programmatic-step.ts:
- From origin/main: HandleStepsLogChunkFn, handleStepsLogChunk, sendSubagentChunk, fromHandleSteps param
- From brandon/tui: parentAgentId wrapping logic for nested agent events
- Combined both sets of changes for full functionality

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
- Add immer middleware to reduce boilerplate in setters
- Use useShallow for efficient multi-value selection in chat.tsx
- Remove unused chatStore non-hook wrapper export
- Move slashSelectedIndex and agentSelectedIndex to store

Benefits:
- Cleaner setter syntax with direct state mutations
- Single useChatStore call with useShallow instead of multiple calls
- Reduced boilerplate while maintaining type safety

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff Co-Authored-By: Codebuff
<[email protected]>
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <[email protected]>
🤖 Generated with Codebuff Co-Authored-By: Codebuff
<[email protected]>
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