mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-12 02:37:45 +08:00
feat: Enhance JSON streaming parsing and UI updates
- Added a function to parse JSON streaming content in core-memory.js, extracting readable text from messages. - Updated memory detail view to utilize the new parsing function for content and summary. - Introduced an enableReview option in rules-manager.js, allowing users to toggle review functionality in rule creation. - Simplified skill creation modal in skills-manager.js by removing generation type selection UI. - Improved CLI executor to handle tool calls for file writing, ensuring proper output parsing. - Adjusted CLI command tests to set timeout to 0 for immediate execution. - Updated file watcher to implement a true debounce mechanism and added a pending queue status for UI updates. - Enhanced watcher manager to handle queue changes and provide JSON output for better integration with TypeScript backend. - Established TypeScript naming conventions documentation to standardize code style across the project.
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import time
|
||||
from dataclasses import dataclass, field
|
||||
from enum import Enum
|
||||
from pathlib import Path
|
||||
@@ -28,7 +29,7 @@ class FileEvent:
|
||||
@dataclass
|
||||
class WatcherConfig:
|
||||
"""Configuration for file watcher."""
|
||||
debounce_ms: int = 1000
|
||||
debounce_ms: int = 60000 # Default 60 seconds for debounce
|
||||
ignored_patterns: Set[str] = field(default_factory=lambda: {
|
||||
# Version control
|
||||
".git", ".svn", ".hg",
|
||||
@@ -50,13 +51,26 @@ class WatcherConfig:
|
||||
languages: Optional[List[str]] = None # None = all supported
|
||||
|
||||
|
||||
@dataclass
|
||||
class PendingQueueStatus:
|
||||
"""Status of pending file changes queue."""
|
||||
file_count: int = 0
|
||||
files: List[str] = field(default_factory=list) # Limited to 20 files
|
||||
countdown_seconds: int = 0
|
||||
last_event_time: Optional[float] = None
|
||||
|
||||
|
||||
@dataclass
|
||||
class IndexResult:
|
||||
"""Result of processing file changes."""
|
||||
files_indexed: int = 0
|
||||
files_removed: int = 0
|
||||
symbols_added: int = 0
|
||||
symbols_removed: int = 0
|
||||
files_success: List[str] = field(default_factory=list)
|
||||
files_failed: List[str] = field(default_factory=list)
|
||||
errors: List[str] = field(default_factory=list)
|
||||
timestamp: float = field(default_factory=time.time)
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
Reference in New Issue
Block a user