This commit introduces several improvements and new features to the AI Assistant:
- **Refactored code:** Improved code structure and readability.
- **Added clipboard functionality:** Implemented a `/copy` command to copy code blocks to the clipboard.
- **Improved command parsing:** Added a `/copy` command to copy code blocks to the clipboard.
- **Enhanced error handling:** Added error handling for clipboard operations.
- **Improved documentation:** Updated documentation to reflect changes.
This commit introduces a significant refactor of the AI assistant's codebase, transitioning from a procedural approach to an object-oriented design. This change improves modularity, maintainability, and extensibility.
Key changes include:
- Introduction of classes: AIAssistant, CommandLineParser, InputHandler, and CommandParser.
- Encapsulation of core functionality within the AIAssistant class.
- Improved input handling with separation of interactive and piped input.
- Implementation of command parsing for actions like saving, clearing, and exiting.
- Refactored history management for persistent conversation storage.