Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
acharneski committed Dec 17, 2024
1 parent 0cd2e42 commit 9baf55b
Show file tree
Hide file tree
Showing 102 changed files with 907 additions and 921 deletions.
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ plugins {
}


group = "com.github.simiacryptus"
group = "com.simiacryptus"
version = properties("pluginVersion")

repositories {
Expand Down
2 changes: 1 addition & 1 deletion docs/coding_standards.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ to ensure consistency, readability, and maintainability of the codebase.
- **Classes and Interfaces**: Use PascalCase and be descriptive. Example: `StaticAppSettingsConfigurable`.
- **Functions and Variables**: Use camelCase and be descriptive. Example: `buildComponent`.
- **Constants**: Use UPPER_SNAKE_CASE. Example: `API_PROVIDER`.
- **Packages**: Use lowercase and avoid underscores. Example: `com.github.simiacryptus.aicoder.util`.
- **Packages**: Use lowercase and avoid underscores. Example: `com.simiacryptus.aicoder.util`.

## Formatting

Expand Down
18 changes: 9 additions & 9 deletions docs/feature_roadmap.md
Original file line number Diff line number Diff line change
Expand Up @@ -1325,7 +1325,7 @@ This roadmap is a living document and will be updated periodically to reflect pr

# kotlin\com\github\simiacryptus\aicoder\ApplicationEvents.kt

Creating a feature development roadmap for the `ApplicationEvents` class within the `com.github.simiacryptus.aicoder` package involves outlining the future enhancements, improvements, and additions planned for this component. The roadmap will be structured into short-term, mid-term, and long-term goals, considering the current functionalities such as application activation handling, initialization of services like `OutputInterceptor`, `ClientManager`, and various `ApplicationServices`.
Creating a feature development roadmap for the `ApplicationEvents` class within the `com.simiacryptus.aicoder` package involves outlining the future enhancements, improvements, and additions planned for this component. The roadmap will be structured into short-term, mid-term, and long-term goals, considering the current functionalities such as application activation handling, initialization of services like `OutputInterceptor`, `ClientManager`, and various `ApplicationServices`.


#### Short-Term Goals (0-3 Months)
Expand Down Expand Up @@ -1524,7 +1524,7 @@ This roadmap provides a structured approach to developing new features for the `

# kotlin\com\github\simiacryptus\aicoder\config\SimpleEnvelope.kt

Creating a feature development roadmap for the `SimpleEnvelope` class within the `com.github.simiacryptus.aicoder.config` package involves outlining a series of enhancements and new functionalities that can be added to make the class more robust, versatile, and useful in various applications. Here's a proposed roadmap:
Creating a feature development roadmap for the `SimpleEnvelope` class within the `com.simiacryptus.aicoder.config` package involves outlining a series of enhancements and new functionalities that can be added to make the class more robust, versatile, and useful in various applications. Here's a proposed roadmap:


#### Phase 1: Basic Enhancements
Expand Down Expand Up @@ -1617,7 +1617,7 @@ This roadmap is subject to change based on user feedback, technological advancem

# kotlin\com\github\simiacryptus\aicoder\config\Name.kt

Creating a feature development roadmap for the `Name` annotation within the `com.github.simiacryptus.aicoder.config` package involves outlining a series of planned enhancements and functionalities that will be added over time. This roadmap will guide the development process, ensuring that the annotation becomes more versatile and useful in various coding scenarios. Here's a proposed roadmap:
Creating a feature development roadmap for the `Name` annotation within the `com.simiacryptus.aicoder.config` package involves outlining a series of planned enhancements and functionalities that will be added over time. This roadmap will guide the development process, ensuring that the annotation becomes more versatile and useful in various coding scenarios. Here's a proposed roadmap:


#### Phase 1: Initial Release
Expand Down Expand Up @@ -2293,7 +2293,7 @@ Creating a feature development roadmap is an iterative process that requires fle

# kotlin\com\github\simiacryptus\aicoder\util\LineComment.kt

The `LineComment` class and its nested `Factory` class, as part of the `com.github.simiacryptus.aicoder.util` package, provide a structured way to handle line comments within text blocks, particularly useful in the context of code generation or analysis. The development roadmap for enhancing these classes and their functionalities can be structured into several phases, focusing on improving usability, flexibility, and integration capabilities.
The `LineComment` class and its nested `Factory` class, as part of the `com.simiacryptus.aicoder.util` package, provide a structured way to handle line comments within text blocks, particularly useful in the context of code generation or analysis. The development roadmap for enhancing these classes and their functionalities can be structured into several phases, focusing on improving usability, flexibility, and integration capabilities.


#### Phase 1: Core Functionality Enhancements
Expand Down Expand Up @@ -4374,7 +4374,7 @@ This roadmap is subject to change based on user feedback and technological advan

# resources\sources\kt\com\github\simiacryptus\aicoder\ApplicationEvents.kt

Creating a feature development roadmap for the `ApplicationEvents` class within the `com.github.simiacryptus.aicoder` package involves outlining the future enhancements, improvements, and additions planned for this component. The roadmap will guide the development process, ensuring that the class evolves to meet the needs of its users effectively. Here's a proposed roadmap:
Creating a feature development roadmap for the `ApplicationEvents` class within the `com.simiacryptus.aicoder` package involves outlining the future enhancements, improvements, and additions planned for this component. The roadmap will guide the development process, ensuring that the class evolves to meet the needs of its users effectively. Here's a proposed roadmap:


#### Phase 1: Initial Setup and Integration
Expand Down Expand Up @@ -4912,7 +4912,7 @@ This roadmap is a starting point and may evolve based on user needs, technologic

# resources\sources\kt\com\github\simiacryptus\aicoder\config\Name.kt

Creating a feature development roadmap for the `Name` annotation within the `com.github.simiacryptus.aicoder.config` package involves outlining a series of planned enhancements and functionalities that will be added over time. This roadmap will guide the development process, ensuring that the annotation becomes more versatile and useful for its intended purpose. Here's a proposed roadmap:
Creating a feature development roadmap for the `Name` annotation within the `com.simiacryptus.aicoder.config` package involves outlining a series of planned enhancements and functionalities that will be added over time. This roadmap will guide the development process, ensuring that the annotation becomes more versatile and useful for its intended purpose. Here's a proposed roadmap:


#### Phase 1: Initial Release
Expand Down Expand Up @@ -4968,7 +4968,7 @@ This roadmap is a living document and should be revisited regularly to adjust th

# resources\sources\kt\com\github\simiacryptus\aicoder\config\SimpleEnvelope.kt

Creating a feature development roadmap for the `SimpleEnvelope` class within the `com.github.simiacryptus.aicoder.config` package involves outlining a series of enhancements and new functionalities that can be added to make the class more robust, versatile, and useful in various applications. Here's a proposed roadmap:
Creating a feature development roadmap for the `SimpleEnvelope` class within the `com.simiacryptus.aicoder.config` package involves outlining a series of enhancements and new functionalities that can be added to make the class more robust, versatile, and useful in various applications. Here's a proposed roadmap:


#### Phase 1: Basic Enhancements
Expand Down Expand Up @@ -5124,7 +5124,7 @@ This roadmap is a living document and should be revisited and revised based on u

# resources\sources\kt\com\github\simiacryptus\aicoder\ui\EditorMenu.kt

Developing a feature for a software project, especially one that integrates with complex platforms like IntelliJ IDEA (as suggested by the provided code snippet), requires careful planning and execution. Below is a structured roadmap to guide the development of a new feature for the `com.github.simiacryptus.aicoder.ui` package, focusing on enhancing the editor menu with additional actions based on user settings.
Developing a feature for a software project, especially one that integrates with complex platforms like IntelliJ IDEA (as suggested by the provided code snippet), requires careful planning and execution. Below is a structured roadmap to guide the development of a new feature for the `com.simiacryptus.aicoder.ui` package, focusing on enhancing the editor menu with additional actions based on user settings.


#### Phase 1: Requirements Gathering and Analysis
Expand Down Expand Up @@ -5609,7 +5609,7 @@ This roadmap is iterative and cyclical; the insights gained from the evaluation

# resources\sources\kt\com\github\simiacryptus\aicoder\util\ComputerLanguage.kt

Developing a feature roadmap for the `ComputerLanguage` enum and its associated classes within the `com.github.simiacryptus.aicoder.util` package involves planning enhancements, optimizations, and new capabilities that can be added to improve its functionality, usability, and integration capabilities. Here's a proposed development roadmap:
Developing a feature roadmap for the `ComputerLanguage` enum and its associated classes within the `com.simiacryptus.aicoder.util` package involves planning enhancements, optimizations, and new capabilities that can be added to improve its functionality, usability, and integration capabilities. Here's a proposed development roadmap:


#### Phase 1: Core Enhancements
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ The action is implemented as a simple override of `actionPerformed()` that calls


### Dependencies
- Requires `com.github.simiacryptus.aicoder.util.BrowseUtil` for browser handling
- Requires `com.simiacryptus.aicoder.util.BrowseUtil` for browser handling
- Uses Java's `URI` class for URL representation


Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
package com.github.simiacryptus.aicoder.actions
package aicoder.actions

import com.github.simiacryptus.aicoder.util.IdeaChatClient
import com.github.simiacryptus.aicoder.util.IdeaOpenAIClient
import com.github.simiacryptus.aicoder.util.UITools
/**
* Base action class providing common functionality for AI Coder actions.
* Handles API client initialization and common UI operations.
*/
import com.intellij.openapi.actionSystem.AnAction
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.application.ApplicationManager
import com.simiacryptus.aicoder.util.IdeaChatClient
import com.simiacryptus.aicoder.util.IdeaOpenAIClient
import com.simiacryptus.aicoder.util.UITools
import com.simiacryptus.jopenai.ChatClient
/**
* Base action class providing common functionality for AI Coder actions.
* Handles API client initialization and common UI operations.
*/
import org.slf4j.LoggerFactory
import javax.swing.Icon

Expand Down Expand Up @@ -73,4 +73,4 @@ abstract class BaseAction(
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions

import com.simiacryptus.jopenai.ChatClient
import com.simiacryptus.jopenai.models.ApiModel
Expand All @@ -8,7 +8,6 @@ import com.simiacryptus.skyenet.core.platform.Session
import com.simiacryptus.skyenet.core.platform.model.StorageInterface
import com.simiacryptus.skyenet.webui.application.ApplicationServer
import com.simiacryptus.skyenet.webui.chat.ChatSocketManager
import com.simiacryptus.skyenet.webui.session.SessionTask

class EnhancedChatSocketManager(
session: Session,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
package com.github.simiacryptus.aicoder.actions
package aicoder.actions

import com.github.simiacryptus.aicoder.config.AppSettingsState
import com.github.simiacryptus.aicoder.util.UITools
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.application.ApplicationManager
import com.intellij.openapi.fileEditor.FileEditorManager
import com.intellij.openapi.progress.ProgressIndicator
import com.intellij.openapi.project.Project
import com.intellij.openapi.vfs.LocalFileSystem
import com.intellij.openapi.vfs.VirtualFile
import com.simiacryptus.aicoder.config.AppSettingsState
import com.simiacryptus.aicoder.util.UITools
import org.slf4j.LoggerFactory
import java.io.File
import java.nio.file.Path
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions

import com.intellij.openapi.project.Project
import com.intellij.openapi.ui.DialogWrapper
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
package com.github.simiacryptus.aicoder.actions
package aicoder.actions

import com.github.simiacryptus.aicoder.util.ComputerLanguage
import com.github.simiacryptus.aicoder.util.LanguageUtils
import com.github.simiacryptus.aicoder.util.UITools
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.actionSystem.CommonDataKeys
import com.intellij.openapi.command.WriteCommandAction
Expand All @@ -16,6 +13,9 @@ import com.intellij.psi.PsiElement
import com.intellij.psi.PsiFile
import com.intellij.psi.PsiManager
import com.intellij.psi.PsiRecursiveElementVisitor
import com.simiacryptus.aicoder.util.ComputerLanguage
import com.simiacryptus.aicoder.util.LanguageUtils
import com.simiacryptus.aicoder.util.UITools

abstract class SelectionAction<T : Any>(
private val requiresSelection: Boolean = true
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions

import com.simiacryptus.skyenet.core.platform.ApplicationServices
import com.simiacryptus.skyenet.core.platform.Session
Expand All @@ -8,7 +8,6 @@ import com.simiacryptus.skyenet.webui.application.AppInfoData
import com.simiacryptus.skyenet.webui.application.ApplicationServer
import com.simiacryptus.skyenet.webui.chat.ChatServer
import com.simiacryptus.skyenet.webui.session.SocketManager
import java.net.URL

class SessionProxyServer : ApplicationServer(
applicationName = "AI Coding Assistant",
Expand All @@ -28,7 +27,8 @@ class SessionProxyServer : ApplicationServer(
}.toMap()

override fun newSession(user: User?, session: Session) =
chats[session]?.newSession(user, session) ?: agents[session] ?: throw IllegalStateException("No agent found for session $session")
chats[session]?.newSession(user, session) ?: agents[session]
?: throw IllegalStateException("No agent found for session $session")

companion object {
private val log = org.slf4j.LoggerFactory.getLogger(SessionProxyServer::class.java)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,21 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions.agent
/**
* Action that provides automated fixing of command execution issues through AI assistance
*/

import com.github.simiacryptus.aicoder.AppServer
import com.github.simiacryptus.aicoder.actions.BaseAction
import com.github.simiacryptus.aicoder.config.AppSettingsState
import com.github.simiacryptus.aicoder.util.BrowseUtil.browse
import com.github.simiacryptus.aicoder.util.UITools
import aicoder.actions.BaseAction
import aicoder.actions.SessionProxyServer
import com.intellij.openapi.actionSystem.ActionUpdateThread
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.actionSystem.PlatformDataKeys
import com.intellij.openapi.project.Project
import com.intellij.openapi.ui.ComboBox
import com.intellij.openapi.ui.DialogWrapper
import com.intellij.openapi.vfs.VirtualFile
import com.simiacryptus.aicoder.AppServer
import com.simiacryptus.aicoder.config.AppSettingsState
import com.simiacryptus.aicoder.util.BrowseUtil.browse
import com.simiacryptus.aicoder.util.UITools
import com.simiacryptus.jopenai.models.chatModel
import com.simiacryptus.skyenet.apps.general.CmdPatchApp
import com.simiacryptus.skyenet.apps.general.PatchApp
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions.agent

import com.github.simiacryptus.aicoder.AppServer
import com.github.simiacryptus.aicoder.actions.BaseAction
import com.github.simiacryptus.aicoder.config.Name
import com.github.simiacryptus.aicoder.util.BrowseUtil.browse
import com.github.simiacryptus.aicoder.util.UITools
import aicoder.actions.BaseAction
import aicoder.actions.SessionProxyServer
import aicoder.actions.generate.items
import com.intellij.openapi.actionSystem.ActionUpdateThread
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.project.Project
import com.intellij.openapi.ui.DialogWrapper
import com.intellij.ui.CheckBoxList
import com.intellij.ui.components.JBScrollPane
import com.intellij.ui.components.JBTextArea
import com.simiacryptus.aicoder.AppServer
import com.simiacryptus.aicoder.config.Name
import com.simiacryptus.aicoder.util.BrowseUtil.browse
import com.simiacryptus.aicoder.util.UITools
import com.simiacryptus.diff.FileValidationUtils.Companion.isLLMIncludableFile
import com.simiacryptus.skyenet.core.platform.Session
import com.simiacryptus.skyenet.webui.application.AppInfoData
Expand Down Expand Up @@ -121,7 +123,7 @@ class DocumentedMassPatchAction : BaseAction() {
return Settings(dialog.userSettings, project)
}

class ConfigDialog(project: Project?, private val settingsUI: SettingsUI, title: String)
class ConfigDialog(project: Project?, private val settingsUI: SettingsUI, title: String)
: DialogWrapper(project) {
val userSettings = UserSettings()

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions.agent

import com.github.simiacryptus.aicoder.config.AppSettingsState
import com.simiacryptus.aicoder.config.AppSettingsState
import com.simiacryptus.diff.addApplyFileDiffLinks
import com.simiacryptus.jopenai.API
import com.simiacryptus.jopenai.ChatClient
Expand All @@ -22,10 +22,10 @@ import java.util.concurrent.Semaphore
import java.util.concurrent.atomic.AtomicReference

class DocumentedMassPatchServer(
val config: DocumentedMassPatchAction.Settings,
val api: ChatClient,
val autoApply: Boolean
/**
val config: DocumentedMassPatchAction.Settings,
val api: ChatClient,
val autoApply: Boolean
/**
* Server for handling documented mass code patches
* @param config Settings containing project and file configurations
* @param api ChatClient for AI interactions
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
package com.github.simiacryptus.aicoder.actions.generic
package aicoder.actions.agent

import com.github.simiacryptus.aicoder.AppServer
import com.github.simiacryptus.aicoder.actions.BaseAction
import com.github.simiacryptus.aicoder.actions.generic.MassPatchAction.Settings
import com.github.simiacryptus.aicoder.config.AppSettingsState
import com.github.simiacryptus.aicoder.config.Name
import com.github.simiacryptus.aicoder.util.BrowseUtil.browse
import com.github.simiacryptus.aicoder.util.UITools
import aicoder.actions.BaseAction
import aicoder.actions.SessionProxyServer
import aicoder.actions.agent.MassPatchAction.Settings
import aicoder.actions.generate.items
import com.intellij.openapi.actionSystem.ActionUpdateThread
import com.intellij.openapi.actionSystem.AnActionEvent
import com.intellij.openapi.project.Project
import com.intellij.openapi.ui.DialogWrapper
import com.intellij.ui.CheckBoxList
import com.intellij.ui.components.JBScrollPane
import com.intellij.ui.components.JBTextArea
import com.simiacryptus.aicoder.AppServer
import com.simiacryptus.aicoder.config.AppSettingsState
import com.simiacryptus.aicoder.config.Name
import com.simiacryptus.aicoder.util.BrowseUtil.browse
import com.simiacryptus.aicoder.util.UITools
import com.simiacryptus.diff.FileValidationUtils.Companion.isLLMIncludableFile
import com.simiacryptus.diff.addApplyFileDiffLinks
import com.simiacryptus.jopenai.API
Expand Down
Loading

0 comments on commit 9baf55b

Please sign in to comment.