Documentation
¶
Index ¶
- type Agent
- func (a *Agent) CleanupAfterPRClosed(ctx context.Context, pr *github.PullRequest) error
- func (a *Agent) ContinuePRFromReviewComment(ctx context.Context, event *github.PullRequestReviewCommentEvent, args string) error
- func (a *Agent) ContinuePRFromReviewCommentWithAI(ctx context.Context, event *github.PullRequestReviewCommentEvent, ...) error
- func (a *Agent) ContinuePRWithArgs(ctx context.Context, event *github.IssueCommentEvent, args string) error
- func (a *Agent) ContinuePRWithArgsAndAI(ctx context.Context, event *github.IssueCommentEvent, aiModel, args string) error
- func (a *Agent) FixPR(ctx context.Context, pr *github.PullRequest) error
- func (a *Agent) FixPRFromReviewComment(ctx context.Context, event *github.PullRequestReviewCommentEvent, args string) error
- func (a *Agent) FixPRFromReviewCommentWithAI(ctx context.Context, event *github.PullRequestReviewCommentEvent, ...) error
- func (a *Agent) FixPRWithArgs(ctx context.Context, event *github.IssueCommentEvent, args string) error
- func (a *Agent) FixPRWithArgsAndAI(ctx context.Context, event *github.IssueCommentEvent, aiModel, args string) error
- func (a *Agent) ProcessIssueComment(ctx context.Context, event *github.IssueCommentEvent) error
- func (a *Agent) ProcessIssueCommentWithAI(ctx context.Context, event *github.IssueCommentEvent, aiModel, args string) error
- func (a *Agent) ProcessPRFromReviewWithTriggerUser(ctx context.Context, event *github.PullRequestReviewEvent, command string, ...) error
- func (a *Agent) ProcessPRFromReviewWithTriggerUserAndAI(ctx context.Context, event *github.PullRequestReviewEvent, command string, ...) error
- func (a *Agent) ReviewPR(ctx context.Context, pr *github.PullRequest) error
- func (a *Agent) StartCleanupRoutine()
- type EnhancedAgent
- func (a *EnhancedAgent) GetMCPManager() mcp.MCPManager
- func (a *EnhancedAgent) GetModeManager() *modes.Manager
- func (a *EnhancedAgent) ProcessGitHubWebhookEvent(ctx context.Context, eventType string, deliveryID string, payload []byte) error
- func (a *EnhancedAgent) Shutdown(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Agent ¶
type Agent struct {
// contains filtered or unexported fields
}
func (*Agent) CleanupAfterPRClosed ¶
CleanupAfterPRClosed PR 关闭后清理工作区、映射、执行的code session和删除CodeAgent创建的分支
func (*Agent) ContinuePRFromReviewComment ¶
func (a *Agent) ContinuePRFromReviewComment(ctx context.Context, event *github.PullRequestReviewCommentEvent, args string) error
ContinuePRFromReviewComment continues processing tasks from PR code line comments
func (*Agent) ContinuePRFromReviewCommentWithAI ¶
func (a *Agent) ContinuePRFromReviewCommentWithAI(ctx context.Context, event *github.PullRequestReviewCommentEvent, aiModel, args string) error
ContinuePRFromReviewCommentWithAI continues processing tasks from PR code line comments, supporting AI models
func (*Agent) ContinuePRWithArgs ¶
func (a *Agent) ContinuePRWithArgs(ctx context.Context, event *github.IssueCommentEvent, args string) error
ContinuePRWithArgs continues processing tasks in PR, supporting command parameters
func (*Agent) ContinuePRWithArgsAndAI ¶
func (a *Agent) ContinuePRWithArgsAndAI(ctx context.Context, event *github.IssueCommentEvent, aiModel, args string) error
ContinuePRWithArgsAndAI continues processing tasks in PR, supporting command parameters and AI models
func (*Agent) FixPRFromReviewComment ¶
func (a *Agent) FixPRFromReviewComment(ctx context.Context, event *github.PullRequestReviewCommentEvent, args string) error
FixPRFromReviewComment 从 PR 代码行评论修复问题
func (*Agent) FixPRFromReviewCommentWithAI ¶
func (a *Agent) FixPRFromReviewCommentWithAI(ctx context.Context, event *github.PullRequestReviewCommentEvent, aiModel, args string) error
FixPRFromReviewCommentWithAI 从 PR 代码行评论修复问题,支持AI模型
func (*Agent) FixPRWithArgs ¶
func (a *Agent) FixPRWithArgs(ctx context.Context, event *github.IssueCommentEvent, args string) error
FixPRWithArgs fixes issues in PR, supporting command parameters
func (*Agent) FixPRWithArgsAndAI ¶
func (a *Agent) FixPRWithArgsAndAI(ctx context.Context, event *github.IssueCommentEvent, aiModel, args string) error
FixPRWithArgsAndAI fixes issues in PR, supporting command parameters and AI models
func (*Agent) ProcessIssueComment ¶
ProcessIssueComment processes Issue comment events, including complete repository information
func (*Agent) ProcessIssueCommentWithAI ¶
func (a *Agent) ProcessIssueCommentWithAI(ctx context.Context, event *github.IssueCommentEvent, aiModel, args string) error
ProcessIssueCommentWithAI processes Issue comment events with support for specifying AI models
func (*Agent) ProcessPRFromReviewWithTriggerUser ¶
func (a *Agent) ProcessPRFromReviewWithTriggerUser(ctx context.Context, event *github.PullRequestReviewEvent, command string, args string, triggerUser string) error
ProcessPRFromReviewWithTriggerUser 从 PR review 批量处理多个 review comments 并在反馈中@用户
func (*Agent) ProcessPRFromReviewWithTriggerUserAndAI ¶
func (a *Agent) ProcessPRFromReviewWithTriggerUserAndAI(ctx context.Context, event *github.PullRequestReviewEvent, command string, aiModel, args string, triggerUser string) error
ProcessPRFromReviewWithTriggerUserAndAI 从 PR review 批量处理多个 review comments 并在反馈中@用户,支持AI模型
func (*Agent) StartCleanupRoutine ¶
func (a *Agent) StartCleanupRoutine()
StartCleanupRoutine starts the periodic cleanup routine
type EnhancedAgent ¶
type EnhancedAgent struct {
// contains filtered or unexported fields
}
EnhancedAgent 增强版Agent,集成了新的组件架构
func NewEnhancedAgent ¶
func NewEnhancedAgent(cfg *config.Config, workspaceManager *workspace.Manager) (*EnhancedAgent, error)
NewEnhancedAgent 创建增强版Agent
func (*EnhancedAgent) GetMCPManager ¶
func (a *EnhancedAgent) GetMCPManager() mcp.MCPManager
GetMCPManager 获取MCP管理器(用于外部扩展)
func (*EnhancedAgent) GetModeManager ¶
func (a *EnhancedAgent) GetModeManager() *modes.Manager
GetModeManager 获取模式管理器(用于外部扩展)
func (*EnhancedAgent) ProcessGitHubWebhookEvent ¶
func (a *EnhancedAgent) ProcessGitHubWebhookEvent(ctx context.Context, eventType string, deliveryID string, payload []byte) error
ProcessGitHubWebhookEvent 处理来自Webhook的GitHub事件(推荐方法)