@vectorchat/mcp-server
Version:
VectorChat MCP Server - Encrypted AI-to-AI communication with hardware security (YubiKey/TPM). 45+ MCP tools for Windsurf, Claude, and AI assistants. Model-based identity with EMDM encryption. Dynamic AI playbook system, communication zones, message relay
304 lines (243 loc) • 9.73 kB
Markdown
# VectorChat Console Functionality Documentation
## Overview
The VectorChat console provides a real-time command interface for interacting with the daemon's MCP server, offering comprehensive system monitoring, debugging, and administration capabilities.
## Features
### Real-time Connection Status
- **Live Daemon Status**: Shows MCP server connection state
- **Health Monitoring**: Continuous health checks and status updates
- **Connection Recovery**: Automatic reconnection on network issues
### MCP Tool Browser
- **Tool Discovery**: Lists all 42+ available MCP tools
- **Tool Descriptions**: Detailed information about each tool's capabilities
- **Tool Categories**: Organized by functional groups (core, messaging, files, terminal, network, management)
### Command Interface
- **Direct Command Execution**: Execute MCP tools directly from console
- **Parameter Validation**: Real-time validation of command parameters
- **Response Display**: Formatted display of command results
- **Error Handling**: Comprehensive error reporting and recovery
### Real-time Output Streaming
- **Live Updates**: Real-time daemon output and system events
- **Message Filtering**: Filter by log level or source
- **Timestamp Display**: Precise timing for debugging
- **Auto-scroll**: Automatic scrolling to latest messages
## Usage
### Accessing the Console
1. **Toolbar Icon**: Click the terminal/console icon in the main toolbar
2. **Admin Panel**: Access through the admin/settings panel
3. **Keyboard Shortcut**: Ctrl+Shift+C (configurable)
### Basic Commands
#### System Status
```bash
status # Get daemon status
health # Health check
whoami # Get client identity
```
#### Tool Discovery
```bash
tools list # List all available tools
tools describe <name> # Get tool description
tools search <term> # Search tools by keyword
```
#### File Operations
```bash
files list # List files in current directory
files read <path> # Read file contents
files write <path> <content> # Write file
files delete <path> # Delete file (with confirmation)
```
#### Network Operations
```bash
network status # Network connectivity check
network peers # List IPFS peers
network discover # Discover VectorChat peers
```
#### AI Operations
```bash
ai status # AI model status
ai log <message> # Log AI event
ai conversation <message> # Start AI conversation
```
#### System Management
```bash
system restart # Restart daemon
system config # Show configuration
system update # Check for updates
```
## Console Interface
### Layout
```
┌─────────────────────────────────────────────────────────────┐
│ VectorChat Console [Connected] │
├─────────────────────────────────────────────────────────────┤
│ 🛠️ Tools | 📝 Commands | 🔌 Status | ⚙️ Settings │
├─────────────────────────────────────────────────────────────┤
│ > status │
│ │
│ [INFO] Daemon status: running │
│ [INFO] Model: Qwen3-1.7B (loaded) │
│ [INFO] GPU: RTX 3070 (8GB VRAM) │
│ [INFO] IPFS: Connected (QmXxXxXxXxXxXxXxXxXxXxXxXxXx) │
│ │
│ > tools list │
│ │
│ Available Tools: │
│ • status (core) - Get daemon status │
│ • generate_text (core) - Generate AI text │
│ • ai_log_entry (core) - Log AI events │
│ • relay_message_chain (core) - Message relay chains │
│ • communication_zones (core) - Zone management │
│ │
│ [42 tools available] │
├─────────────────────────────────────────────────────────────┤
│ > │
└─────────────────────────────────────────────────────────────┘
```
### Command Input
- **Single Line**: Simple commands
- **Multi-line**: Complex commands with parameters
- **Auto-completion**: Tool name and parameter suggestions
- **History**: Command history with arrow key navigation
### Response Display
- **Formatted Output**: JSON responses formatted for readability
- **Error Highlighting**: Clear error indication and details
- **Success Indicators**: Visual confirmation of successful operations
- **Timestamps**: Precise timing for all operations
## Integration
### MCP Server Integration
- **Direct Connection**: Connects to daemon's MCP server (port 8766)
- **Tool Execution**: Executes MCP tools through JSON-RPC interface
- **Real-time Updates**: Receives real-time updates from daemon
- **Session Management**: Maintains connection state and authentication
### WebSocket Integration
- **Live Updates**: Real-time status updates via WebSocket
- **Event Streaming**: System events and notifications
- **Connection Monitoring**: Automatic reconnection on failures
- **Message Routing**: Proper message routing between components
## Security
### Access Control
- **Authentication**: Session-based authentication
- **Authorization**: Role-based access to console features
- **Audit Logging**: All console actions logged for security
- **Secure Communication**: Encrypted communication with daemon
### Command Validation
- **Parameter Validation**: Input validation for all commands
- **Security Checks**: Security validation for sensitive operations
- **Error Handling**: Safe error handling to prevent information leakage
- **Rate Limiting**: Protection against command spam
## Troubleshooting
### Connection Issues
```bash
# Check daemon status
> status
# Check network connectivity
> network status
# Restart daemon if needed
> system restart
```
### Command Errors
```bash
# Get detailed error information
> tools describe <tool_name>
# Check tool parameters
> tools validate <tool_name> <parameters>
```
### Performance Issues
```bash
# Check system resources
> system resources
# Monitor memory usage
> system memory
# Check AI model status
> ai status
```
## Advanced Features
### Custom Tool Development
```bash
# Create custom tool
> tools create <name> <description>
# Test custom tool
> tools test <name>
# Register custom tool
> tools register <name>
```
### Script Execution
```bash
# Execute multi-line scripts
> script start
> files list
> ai log "Script executed"
> script end
```
### Session Management
```bash
# List active sessions
> sessions list
# Switch session
> sessions switch <id>
# Create new session
> sessions create <name>
```
## Configuration
### Console Settings
```json
{
"console": {
"auto_scroll": true,
"max_history": 1000,
"theme": "auto",
"font_size": 12,
"show_timestamps": true,
"log_level": "INFO"
}
}
```
### Keyboard Shortcuts
- **Ctrl+Enter**: Execute command
- **Ctrl+L**: Clear console
- **Ctrl+U**: Clear command line
- **Ctrl+R**: Search command history
- **Tab**: Auto-complete
- **Up/Down**: Navigate history
## Best Practices
### Efficient Usage
1. **Use Tab Completion**: Speed up command entry
2. **Group Related Commands**: Execute related operations together
3. **Monitor System Health**: Regular status checks
4. **Use Descriptive Commands**: Clear, self-documenting commands
### Security
1. **Validate Commands**: Always verify command parameters
2. **Monitor Access**: Regular audit log review
3. **Secure Environment**: Use in trusted environments only
4. **Regular Updates**: Keep system updated for security
### Performance
1. **Monitor Resource Usage**: Regular resource checks
2. **Optimize Commands**: Use efficient command patterns
3. **Batch Operations**: Group related operations
4. **Clean Up**: Regular cleanup of temporary files
## Support
### Getting Help
```bash
# Get help for specific command
> help <command>
# List all available commands
> help
# Get system documentation
> docs
```
### Reporting Issues
```bash
# Report console issue
> issue report <description>
# Get support information
> support info
```
---
## Summary
The VectorChat console provides a comprehensive command interface for system administration, debugging, and real-time monitoring. With 42+ MCP tools, real-time status updates, and sophisticated command processing, it serves as the primary interface for advanced users and system administrators.
**Key Features:**
- ✅ Real-time daemon connection and health monitoring
- ✅ Complete MCP tool browser with 42+ tools
- ✅ Advanced command interface with validation
- ✅ Live output streaming with filtering
- ✅ Secure authentication and audit logging
- ✅ Integration with all system components