Documentation
¶
Overview ¶
Copyright © 2025 KubeRocketAI Team
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright © 2025 KubeRocketAI Team ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- Constants
- func GetAgentsPath(frameworkDir string) string
- func GetDataPath(frameworkDir string) string
- func GetKrciPath(projectDir string) string
- func GetTasksPath(frameworkDir string) string
- func GetTemplatesPath(frameworkDir string) string
- type Agent
- type ClaudeIntegration
- type CursorIntegration
- type DataFile
- type Discovery
- func (d *Discovery) GetAgent(ctx context.Context, shortName string) (*Agent, error)
- func (d *Discovery) GetAgents(ctx context.Context) ([]Agent, error)
- func (d *Discovery) GetAgentsByNames(ctx context.Context, names []string) ([]Agent, error)
- func (d *Discovery) ReadFile(filePath string) ([]byte, error)
- type EmbeddedFileSystem
- type FileSystem
- type IDEIntegration
- type Installer
- func (i *Installer) GetAgentsPath() string
- func (i *Installer) GetClaudeCommandsPath() string
- func (i *Installer) GetCursorRulesPath() string
- func (i *Installer) GetDataPath() string
- func (i *Installer) GetFrameworkPath() string
- func (i *Installer) GetTasksPath() string
- func (i *Installer) GetTemplatesPath() string
- func (i *Installer) GetVSCodeChatmodesPath() string
- func (i *Installer) GetWindsurfRulesPath() string
- func (i *Installer) Install() error
- func (i *Installer) InstallClaudeIntegration() error
- func (i *Installer) InstallCursorIntegration() error
- func (i *Installer) InstallSelective(agentNames []string) error
- func (i *Installer) InstallVSCodeIntegration() error
- func (i *Installer) InstallWindsurfIntegration() error
- func (i *Installer) IsInstalled() bool
- func (i *Installer) ValidateInstallation() error
- type IstallerDiscovery
- type OSFileSystem
- type Task
- type TaskDependencies
- type Template
- type VSCodeIntegration
- type WindsurfIntegration
Constants ¶
const ( // Main framework directory structure KrciAIDir = ".krci-ai" BundleDir = "bundle" DataDir = "data" TasksDir = "tasks" TemplatesDir = "templates" EmbeddedPrefix = "assets/framework/core" // GitHub tools configuration GitHubToolsList = "" /* 163-byte string literal not displayed */ DefaultAgentIcon = "🤖" // File permissions DirectoryPermissions = 0755 // Read, write, execute for owner; read, execute for group and others FilePermissions = 0644 // Read, write for owner; read for group and others )
Variables ¶
This section is empty.
Functions ¶
func GetAgentsPath ¶ added in v0.38.0
func GetDataPath ¶ added in v0.38.0
func GetKrciPath ¶ added in v0.38.0
func GetTasksPath ¶ added in v0.38.0
func GetTemplatesPath ¶ added in v0.38.0
Types ¶
type Agent ¶
type Agent struct {
Name string
Description string
Role string
Goal string
Icon string
Tasks []Task
FilePath string
ShortName string
}
Agent represents basic information about an agent
func MakeAgent ¶ added in v0.38.0
func MakeAgent(path string, representation *processor.AgentYamlRepresentation, tasks []Task) Agent
func (*Agent) GetAllDataFilesPaths ¶ added in v0.38.0
func (*Agent) GetAllTasksPaths ¶ added in v0.38.0
func (*Agent) GetAllTemplatesPaths ¶ added in v0.38.0
type ClaudeIntegration ¶
type ClaudeIntegration struct {
// contains filtered or unexported fields
}
ClaudeIntegration implements IDEIntegration for Claude Code
func (*ClaudeIntegration) GenerateContent ¶
func (c *ClaudeIntegration) GenerateContent(agentName, role string, yamlContent []byte) string
func (*ClaudeIntegration) GetDirectoryPath ¶
func (c *ClaudeIntegration) GetDirectoryPath() string
func (*ClaudeIntegration) GetFileExtension ¶
func (c *ClaudeIntegration) GetFileExtension() string
type CursorIntegration ¶
type CursorIntegration struct {
// contains filtered or unexported fields
}
CursorIntegration implements IDEIntegration for Cursor IDE
func (*CursorIntegration) GenerateContent ¶
func (c *CursorIntegration) GenerateContent(agentName, role string, yamlContent []byte) string
func (*CursorIntegration) GetDirectoryPath ¶
func (c *CursorIntegration) GetDirectoryPath() string
func (*CursorIntegration) GetFileExtension ¶
func (c *CursorIntegration) GetFileExtension() string
type Discovery ¶
type Discovery struct {
// contains filtered or unexported fields
}
Discovery handles discovery and parsing of framework assets from any source
func NewDiscovery ¶
NewDiscovery creates a new asset discovery service for filesystem assets
func NewEmbeddedDiscovery ¶ added in v0.38.0
NewEmbeddedDiscovery creates a new asset discovery service for embedded assets
func (*Discovery) GetAgent ¶ added in v0.38.0
GetAgent returns an agent by short name. TODO: Method can be optimized by reading only one agent instead of all agents.
func (*Discovery) GetAgentsByNames ¶ added in v0.38.0
type EmbeddedFileSystem ¶ added in v0.38.0
type EmbeddedFileSystem struct {
// contains filtered or unexported fields
}
EmbeddedFileSystem implements FileSystem for embedded filesystems
func (EmbeddedFileSystem) ReadFile ¶ added in v0.38.0
func (efs EmbeddedFileSystem) ReadFile(name string) ([]byte, error)
func (EmbeddedFileSystem) WalkDir ¶ added in v0.38.0
func (efs EmbeddedFileSystem) WalkDir(root string, fn fs.WalkDirFunc) error
type FileSystem ¶ added in v0.38.0
type FileSystem interface {
WalkDir(root string, fn fs.WalkDirFunc) error
ReadFile(name string) ([]byte, error)
}
FileSystem interface abstracts file system operations for both OS and embedded filesystems
type IDEIntegration ¶
type IDEIntegration interface {
GetDirectoryPath() string
GetFileExtension() string
GenerateContent(agentName, role string, yamlContent []byte) string
}
IDEIntegration defines the interface for IDE-specific integrations
type Installer ¶
type Installer struct {
// contains filtered or unexported fields
}
Installer handles installation of framework assets
func NewInstaller ¶
func NewInstaller(projectDir string, embeddedAssets embed.FS, discovery IstallerDiscovery) *Installer
NewInstaller creates a new asset installer
func (*Installer) GetAgentsPath ¶
func (*Installer) GetClaudeCommandsPath ¶
GetClaudeCommandsPath returns the path to the Claude commands directory
func (*Installer) GetCursorRulesPath ¶
GetCursorRulesPath returns the path to the Cursor rules directory
func (*Installer) GetDataPath ¶
func (*Installer) GetFrameworkPath ¶ added in v0.38.0
func (*Installer) GetTasksPath ¶
func (*Installer) GetTemplatesPath ¶
func (*Installer) GetVSCodeChatmodesPath ¶
GetVSCodeChatmodesPath returns the path to the VS Code chatmodes directory
func (*Installer) GetWindsurfRulesPath ¶
GetWindsurfRulesPath returns the path to the Windsurf rules directory
func (*Installer) InstallClaudeIntegration ¶
InstallClaudeIntegration creates .claude/commands directory and generates .md files for agents
func (*Installer) InstallCursorIntegration ¶
InstallCursorIntegration creates .cursor/rules directory and generates .mdc files for agents
func (*Installer) InstallSelective ¶ added in v0.28.0
InstallSelective installs only specified agents and their dependencies using existing bundle logic
func (*Installer) InstallVSCodeIntegration ¶
InstallVSCodeIntegration creates .github/chatmodes directory and generates .chatmode.md files for agents
func (*Installer) InstallWindsurfIntegration ¶
InstallWindsurfIntegration creates .windsurf/rules directory and generates .md files for agents
func (*Installer) IsInstalled ¶
IsInstalled checks if the framework is properly installed in the target directory
func (*Installer) ValidateInstallation ¶
ValidateInstallation performs basic validation of the installation
type IstallerDiscovery ¶ added in v0.38.0
type OSFileSystem ¶ added in v0.38.0
type OSFileSystem struct{}
OSFileSystem implements FileSystem for the operating system filesystem
func (OSFileSystem) ReadFile ¶ added in v0.38.0
func (OSFileSystem) ReadFile(name string) ([]byte, error)
func (OSFileSystem) WalkDir ¶ added in v0.38.0
func (OSFileSystem) WalkDir(root string, fn fs.WalkDirFunc) error
type Task ¶ added in v0.38.0
type Task struct {
Path string
Name string
Dependencies TaskDependencies
}
type TaskDependencies ¶ added in v0.38.0
func MakeTaskDependency ¶ added in v0.38.0
func MakeTaskDependency(basePath string, dependency processor.TaskDependenciesYamlRepresentation) TaskDependencies
type VSCodeIntegration ¶
type VSCodeIntegration struct {
// contains filtered or unexported fields
}
VSCodeIntegration implements IDEIntegration for VS Code
func (*VSCodeIntegration) GenerateContent ¶
func (v *VSCodeIntegration) GenerateContent(agentName, role string, yamlContent []byte) string
func (*VSCodeIntegration) GetDirectoryPath ¶
func (v *VSCodeIntegration) GetDirectoryPath() string
func (*VSCodeIntegration) GetFileExtension ¶
func (v *VSCodeIntegration) GetFileExtension() string
type WindsurfIntegration ¶
type WindsurfIntegration struct {
// contains filtered or unexported fields
}
WindsurfIntegration implements IDEIntegration for Windsurf IDE
func (*WindsurfIntegration) GenerateContent ¶
func (w *WindsurfIntegration) GenerateContent(agentName, role string, yamlContent []byte) string
func (*WindsurfIntegration) GetDirectoryPath ¶
func (w *WindsurfIntegration) GetDirectoryPath() string
func (*WindsurfIntegration) GetFileExtension ¶
func (w *WindsurfIntegration) GetFileExtension() string