Commit graph

616 commits

Author SHA1 Message Date
Mike Sawka
ae3e9f05b7
new job manager / framework for creating persistent remove sessions (#2779)
lots of stuff here.

introduces a streaming framework for the RPC system with flow control.
new authentication primitives for the RPC system. this is used to create
a persistent "job manager" process (via wsh) that can survive
disconnects. and then a jobcontroller in the main server that can
create, reconnect, and manage these new persistent jobs.

code is currently not actively hooked up to anything minus some new
debugging wsh commands, and a switch in the term block that lets me test
viewing the output.

after PRing this change the next steps are more testing and then
integrating this functionality into the product.
2026-01-21 16:54:18 -08:00
Mike Sawka
31a8714454
rpc streaming primitives (#2759)
built some streaming primitives with windowing for rpc streams. not
hooked up to anything yet (or the WshRpc)
2026-01-08 16:14:56 -08:00
Mike Sawka
c5068238f9
add nowsh reason to help debug failure (#2755) 2026-01-06 14:38:45 -08:00
Mike Sawka
79705074fa
only create activity events every 2 hours (#2752) 2026-01-05 16:24:51 -08:00
Mike Sawka
e3c9984e68
removed pinned tabs feature (#2737) 2026-01-02 21:12:03 -08:00
Mike Sawka
adc823fd3b
rip out osc 23198 and osc 9283 handlers (#2736) 2026-01-02 11:51:37 -08:00
Mike Sawka
2b243627c3
very large refactor of wshrouter (#2732)
the PR spiraled and ended up being much larger than anticipated.

it is a refactor of wshrouter to have it track "links" as opposed to
just routes. this lets us simplify a lot of things when it comes to
multi-level routing.

* now the router can handle unauthenticated links directly, instead of a
weird limbo in wshproxy
* no more wshmultiproxy
* no more "authtoken" weirdness
* more straightforward handling in connserver (when using router option)

also adds more debugging, more logging, some windows fixes, other wsl
fixes
2026-01-01 17:44:00 -08:00
Mike Sawka
cfbb39a7e9
some RPC client/server cleanup (#2709)
* announce and unannounce should propagate
* route the sendmessage command
* add timeouts for sending to OutputCh (appropriately)
* add ctx for SendCancel function
2025-12-22 15:04:20 -08:00
Mike Sawka
27ac131b85
Implement AI "stop" -- in the client, open ai responses/chat, and gemini backends (#2704) 2025-12-19 16:59:31 -08:00
Mike Sawka
3c3c665ac2
fix tool approval lifecycle to match SSE connection, not keep-alives (#2693)
tie the tool approvals to the lifecycle of the SSE connection, NOT FE
keepalive packets. this prevents timeouts when the FE hasn't rendered
the tools (or FE tool rendering lifecycle issues). also allows immediate
timeouts on refresh.

other small fixes: convert to use wshclient in wshcmd-*.go files,
cleanup in SSE code
2025-12-18 16:43:59 -08:00
Mike Sawka
cd7a940209
Docs and v0.13.1 release notes (#2687) 2025-12-16 09:30:28 -08:00
Mike Sawka
667de56198
updates to allow wave ai panel to function without telemetry with BYOK/local models (#2685)
* lots of changes to how aimodes are shown on frontend
* backend now requires aimode to be sent with request
* diagnostic ping
2025-12-16 09:06:56 -08:00
Andy_Allan
f622c658b0
feat: implement SSH agent for Windows with tests (#2644)
#2643 

## Implementation
1. Add platform-aware identity-agent dialing: on Window, default to `//./pipe/openssh-ssh-agent`.
2. Keep Unix agent dialing via Unix sockets; unify agent resolution
across platforms.
3. Add cross-platform unit tests covering dialer selection and failure
paths.
2025-12-15 11:05:11 -08:00
Mike Sawka
fbb0c4d052
windows, have a new "local" conn option for Git Bash if installed (#2666) 2025-12-12 14:05:48 -08:00
Mike Sawka
a5599e9105
QoL and Layout Fixes for Windows (#2661)
* remove title bar on windows windows
* re-integrate native controls into our tab bar
* remove menu completely (weird "Alt" activation)
* actually fix Ctrl-V in terminal
* clamp zoom levels better (0.4 - 2.6)
* simplify macos / windows drag regions (keep responsive to zoom)
* fix settings schemas for windows
2025-12-11 17:50:02 -08:00
Mike Sawka
96b397f5a6
default tool type to "function" (sometimes APIs omit this from deltas) (#2662) 2025-12-10 18:46:14 -08:00
Mike Sawka
c9c6192fc9
minor v0.13 fixes (#2649) 2025-12-08 21:58:54 -08:00
Mike Sawka
ea68aec9f4
v0.13 Release Notes, Docs Updates, Onboarding Updates (#2642) 2025-12-08 16:29:19 -08:00
Mike Sawka
f6bd5930ad
AI model compatibility, other misc fixes for release (#2641) 2025-12-05 16:23:54 -08:00
Mike Sawka
0c60f2c8a7
set Ctrl+V as a paste accelerator by default on windows (#2640) 2025-12-05 16:00:14 -08:00
Mike Sawka
0d60950915
default bracketed paste mode ON, add context menu (#2639)
We were too conservative by defaulting ignorebrackedpastemode in
xterm.js to true. it should have been set to false. this solves issues
with pasting multi-line strings into zsh, claude code, etc.

add a new context menu option to more easily disable if you're in a
weird ssh session or a REPL that doesn't support bracketedpaste.
2025-12-05 14:41:17 -08:00
Copilot
4449895424
Add Google Gemini backend for AI chat (#2602)
- [x] Add new API type constant for Google Gemini in uctypes.go
- [x] Create gemini directory under pkg/aiusechat/
- [x] Implement gemini-backend.go with streaming chat support
- [x] Implement gemini-convertmessage.go for message conversion
- [x] Implement gemini-types.go for Google-specific types
- [x] Add gemini backend to usechat-backend.go
- [x] Support tool calling with structured arguments
- [x] Support image upload (base64 inline data)
- [x] Support PDF upload (base64 inline data)
- [x] Support file upload (text files, directory listings)
- [x] Build verification passed
- [x] Add documentation for Gemini backend usage
- [x] Security scan passed (CodeQL found 0 issues)
- [x] Code review passed with no comments
- [x] Revert tsunami demo go.mod/go.sum files (per feedback - twice)
- [x] Add `--gemini` flag to main-testai.go for testing
- [x] Fix schema validation for tool calling (clean unsupported fields)
- [x] Preserve non-map property values in schema cleaning

## Summary

Successfully implemented a complete Google Gemini backend for WaveTerm's
AI chat system. The implementation:

- **Follows existing patterns**: Matches the structure of OpenAI and
Anthropic backends
- **Fully featured**: Supports all required capabilities including tool
calling, images, PDFs, and files
- **Properly tested**: Builds successfully with no errors or warnings
- **Secure**: Passed CodeQL security scanning with 0 issues
- **Well documented**: Includes comprehensive package documentation with
usage examples
- **Minimal changes**: Only affects backend code under pkg/aiusechat
(tsunami demo files reverted twice)
- **Testable**: Added `--gemini` flag to main-testai.go for easy testing
with SSE output
- **Schema compatible**: Cleans JSON schemas to remove fields
unsupported by Gemini API while preserving valid structure

## Testing

To test the Gemini backend using main-testai.go:
```bash
export GOOGLE_APIKEY="your-api-key"
cd cmd/testai
go run main-testai.go --gemini 'What is 2+2?'
go run main-testai.go --gemini --model gemini-1.5-pro 'Explain quantum computing'
go run main-testai.go --gemini --tools 'Help me configure GitHub Actions monitoring'
```


Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: sawka <2722291+sawka@users.noreply.github.com>
2025-12-05 12:43:42 -08:00
Mike Sawka
2f92e23ece
more config updates (secrets, waveai, ai:provider) (#2631) 2025-12-05 10:10:43 -08:00
Mike Sawka
c32eb6690b
fixup macos zsh_history (merge wave history back to => ~/.zsh_history) (#2625) 2025-12-02 15:50:23 -08:00
Mike Sawka
d1ebcc9d07
new waveconfig widget, consolidate config/help in widget sidebar (#2604) 2025-11-28 11:56:59 -08:00
Mike Sawka
73e56193e7
implement openai chat completions api -- enables local model support (#2600) 2025-11-26 11:43:19 -08:00
Mike Sawka
7b99b80474
more misc builder improvements (#2592) 2025-11-24 13:37:24 -08:00
Mike Sawka
f621e61953
v0.12.4 release notes (#2590)
also stop sending OLD telemetry events (new tevents still sent)
2025-11-21 16:03:15 -08:00
Mike Sawka
cc51509fe7
add new setting term:macoptionismeta (#2589) 2025-11-21 10:54:58 -08:00
Mike Sawka
e0ca73ad53
builder secrets, builder config/data tab hooked up (#2581)
builder secrets, builder config/data tab hooked up, and tsunami cors
config env var
2025-11-21 10:36:51 -08:00
Mike Sawka
4f6aa38363
fix issue when tab does not exist in workspace (#2580)
this fixes a rare case where a workspace tries to load a tab that
doesn't exist. this allows the UI to load even despite that condition.
in addition it fixes the "delete tab" path so, even if the tab doesn't
exist, it will get cleaned up correctly out of the workspace.
2025-11-20 17:01:29 -08:00
Mike Sawka
8b246d749c
fix osc7 encoding for zsh (bad regex substitutions) (#2578) 2025-11-20 12:42:17 -08:00
Mike Sawka
6420ae9095
various AI updates (#2574)
* roundtrip image filenames correctly
* fix scrolling issue where the thumbs-up/thumbs-down buttons were cut
off
* update ai-sdk / ai-sdk react to current versions
* fix a focus issue when moving to AI panel using ctrl:shift:arrowleft
2025-11-19 13:01:29 -08:00
Mike Sawka
cd6389d1ec
Create Interface for Backend AI Providers (#2572)
Created an interface in aiusechat for the backend providers. Use that
interface throughout the usechat code. Isolate the backend
implementations to only the new file usechat-backend.go.
2025-11-19 11:38:56 -08:00
Mike Sawka
ce978c1205
More Builder Improvements + Tsunami AppInit (#2571)
* Kebab Menu + Switch App Functionality
* Updated Secrets Tab (still more to do, but closer)
* Better Error Handling (Switch to Secrets Tab)
* Add AppInit functionality to Tsunami (fixes initialization issues and
races with embedded assets, and error handling)
* Tsunami - ListStaticFiles
* Tsunami - More Robust Manifest generation (even when there are extra
stdout messages)
2025-11-19 09:41:11 -08:00
Mike Sawka
44a068833f
builder files tab (#2569) 2025-11-18 10:46:30 -08:00
Mike Sawka
7324f5babd
bump tsunami version to v0.12.3 (#2568) 2025-11-17 16:25:43 -08:00
Mike Sawka
3b97084471
fix tsunami scaffold in build (#2564) 2025-11-14 16:35:37 -08:00
Mike Sawka
6c4744bffd
dont grow events unbounded when persisting (#2560) 2025-11-14 11:04:45 -08:00
Mike Sawka
9b4f696d65
show apps icon in the widgets bar which shows a tsunami app launcher (#2554) 2025-11-14 09:34:14 -08:00
Mike Sawka
347eef289d
more builder updates (#2553)
* load manifest metadata into the FE
* builder only edits draft/ apps (convert local => draft)
* gofmt app.go after saving (AI tools and manual user save)
* dont open duplicate builder windows
* remix app context menu in waveapp
* add icon/iconcolor in appmeta and implement in the wave block frame
2025-11-13 22:47:46 -08:00
Mike Sawka
d6578b7929
update to gpt-5.1 (#2552) 2025-11-13 21:10:28 -08:00
Mike Sawka
7ac2f25b04
big improvements to waveapp builder (#2550)
* build manifest
* working on secrets injection (secretstore + secret-bindings.json)
* tool progress indicators
* build output and errors injected as the result of the edit calls so AI
gets instant feedback on edits
* change edits to not be atomic (allows AI to make better progress)
* updated binary location for waveapps
* publish button
* new partial json parser (for sending incremental tool progress
indication)
* updated tsunami view to use new embedded scaffold + config vars
* lots of work on cleaning up the output so it is more useful to users +
AI agents
* fix builder init flow
2025-11-13 17:54:17 -08:00
Mike Sawka
4da6a39303
New AI Thinking Control (#2543)
Create an AI Thinking Dropdown in Wave AI.
Quick, Balanced, or Deep which map to gpt-5-mini, gpt-5 (low thinking),
or gpt-5 (medium thinking). Also default down to Quick when no premium
requests.
2025-11-11 19:46:10 -08:00
Mike Sawka
0da0a6421e
when the AI edits a file it now triggers a rebuild and the AI gets the tool output (#2546) 2025-11-11 18:08:56 -08:00
Mike Sawka
eb3ba64121
cleaned up build output w/ "debug" lines and filtering (#2545) 2025-11-11 11:53:57 -08:00
Mike Sawka
3a08c5518d
add a 'check go version' command to RPC (#2542) 2025-11-10 22:46:56 -08:00
Mike Sawka
34062ad226
capture go build / go mod tidy output to outputcapture (#2540) 2025-11-10 19:55:46 -08:00
Copilot
f12ae1ee78
Add RenameLocalApp function to waveappstore (#2536)
## Plan: Add RenameLocalApp function to waveappstore

- [x] Analyze existing code patterns in waveappstore.go
- [x] Implement RenameLocalApp(appName string, newAppName string) error
function
  - Validate newAppName using existing validation
- Check if local/[appname] exists and rename to local/[newAppName] if it
does
- Check if draft/[appname] exists and rename to draft/[newAppName] if it
does
  - Handle errors appropriately including rollback on partial failure
- [x] Add documentation comments
- [x] Run security checks (CodeQL - no issues found)

## Summary

Successfully implemented `RenameLocalApp(appName string, newAppName
string) error` function that:
- Renames local apps in both `local/` and `draft/` namespaces
- Validates app names and checks for conflicts
- Implements proper error handling with rollback on partial failure
- Passes all security checks with zero vulnerabilities



Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: sawka <2722291+sawka@users.noreply.github.com>
2025-11-10 16:46:52 -08:00
Mike Sawka
8c50f7b0b3
revert file telemetry (#2538) 2025-11-10 16:34:35 -08:00