Skip to content

AI Chat: major revamping#18

Merged
miltonlaufer merged 3 commits intomainfrom
feature/AI-chat-updates
Dec 20, 2025
Merged

AI Chat: major revamping#18
miltonlaufer merged 3 commits intomainfrom
feature/AI-chat-updates

Conversation

@miltonlaufer
Copy link
Owner

@miltonlaufer miltonlaufer commented Dec 18, 2025

Describe your changes

  • Multiple providers and models
  • Tool calling for better editing
  • Result loop with AI to enhance results
  • Response schema validation
  • Chat history
  • AI Operations history
  • Error queue fed into the AI
  • Autolayout (needed because of the mess of AI added nodes)

Type of change

  • ✨ New feature (non-breaking change which adds functionality)
  • 🐛 Bug fix (non-breaking change which fixes an issue)
  • 🛠️ Re-factoring or improvement
  • 🚩 Add or update tests

Known issues

  • Results are still not ideal (but clearly better than before)

…ding

- Multiple providers and models
- Tool calling for better editing
- Result loop with AI to enhance results
- Response schema validation
- Chat history
- AI Operations history
- Error queue fed into the AI
- Autolayout (needed because of the mess of AI added nodes)
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR represents a major refactoring of the AI chat system, transforming it from a basic OpenAI-only implementation into a comprehensive multi-provider AI assistant with advanced features.

Key improvements:

  • Multi-provider support (OpenAI, Anthropic, Google, DeepSeek, xAI, OpenRouter, Ollama) with dynamic model fetching
  • Tool calling architecture for structured AI-graph interactions with automatic validation and error recovery
  • Persistent chat history with IndexedDB storage and conversation management
  • Error queue system that feeds runtime errors back to the AI for self-correction
  • Auto-layout functionality using Dagre for graph organization

Reviewed changes

Copilot reviewed 31 out of 32 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
src/utils/jsonRepair.ts JSON repair utilities for fallback mode when tool calling isn't supported
src/utils/autoLayout.ts Graph auto-layout using Dagre algorithm
src/config/ Multi-provider configuration system with model metadata
src/services/LangChainService.ts Refactored to support tool calling, multiple providers, and error recovery loops
src/services/LLMProviderService.ts Unified provider abstraction layer
src/services/ModelFetcherService.ts Dynamic model fetching from provider APIs
src/services/AudioGraphToolService.ts Zod-validated tools for AI graph manipulation
src/services/ChatPersistenceService.ts IndexedDB-based conversation persistence
src/stores/ChatStore.ts MST store for conversation management
src/stores/AudioGraphStore.ts Added error queue for AI feedback
src/stores/NodeAdapter.ts Integrated error reporting to queue
src/components/AIChat/ Modularized chat UI with sidebar, actions panel, and improved UX
src/components/NodePalette.tsx Added collapsible categories for better organization
src/components/GraphCanvas.tsx Integrated auto-layout panel
package.json Updated LangChain dependencies and added new providers

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@miltonlaufer miltonlaufer marked this pull request as ready for review December 20, 2025 16:48
@miltonlaufer miltonlaufer merged commit 270da54 into main Dec 20, 2025
4 checks passed
@miltonlaufer miltonlaufer deleted the feature/AI-chat-updates branch December 20, 2025 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants