Class: XAeonAgents::Agents::FeedbackAnalystAgent

Inherits:
ComposableAgents::Cline::Agent
  • Object
show all
Includes:
XAeonAgents::AgentDefaults
Defined in:
lib/x_aeon_agents/agents/feedback_analyst_agent.rb

Overview

Agent responsible for extracting requirements from PR comments directed at X-Aeon Agents

Instance Method Summary collapse

Methods included from XAeonAgents::AgentDefaults

#new_agent, prepended, singleton_session_id

Constructor Details

#initialize(**agent_params) ⇒ FeedbackAnalystAgent

Constructor

Parameters:

  • agent_params (Hash{Symbol => Object})

    Extra agent parameters



41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# File 'lib/x_aeon_agents/agents/feedback_analyst_agent.rb', line 41

def initialize(**agent_params)
  super(
    name: 'FeedbackAnalyst',
    role: 'You are a feedback analyst agent, analyzing feedback from a Pull Request and devising new requirements to address this feedback.',
    objective: 'Extract requirements from Pull Request comments',
    constraints: <<~EO_CONSTRAINTS,
      - You are in read-only mode.
      - Do NOT modify or write any file.
      - Focus only on agent-directed comments (/agent) for requirement extraction.
      - Output clear, actionable requirements or "No requirements" if none exist.
    EO_CONSTRAINTS
    skills: %w[
      applying-ruby-conventions
      applying-test-conventions
      enforcing-project-rules
    ],
    **agent_params
  )
end

Instance Method Details

#input_artifacts_contractsHash{Symbol => Object}

Define input artifacts contracts

Returns:

  • (Hash{Symbol => Object})

    Set of input artifacts description, per artifact name



10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/x_aeon_agents/agents/feedback_analyst_agent.rb', line 10

def input_artifacts_contracts
  super.merge(
    pr_description: 'The Pull Request description (context)',
    pr_files_diffs: 'The files modifications that were done in this Pull Request (context)',
    conversations: {
      description: 'All Pull Request conversations and comments to be considered (context)',
      type: :json
    },
    open_comments_to_agents: {
      description: 'The exact list of agent-directed comments that need to be addressed',
      type: :json
    }
  )
end

#output_artifacts_contractsHash{Symbol => Object}

Define output artifacts contracts

Returns:

  • (Hash{Symbol => Object})

    Set of output artifacts description, per artifact name



28
29
30
31
32
33
34
35
36
# File 'lib/x_aeon_agents/agents/feedback_analyst_agent.rb', line 28

def output_artifacts_contracts
  super.merge(
    requirements: {
      description: 'The requirements that will implement what is needed by the agent-directed comments ' \
        '(reply "No requirements" if there is no implementation needed)',
      type: :markdown
    }
  )
end