Class: AgentHarness::Providers::Kilocode
- Inherits:
-
Base
- Object
- Base
- AgentHarness::Providers::Kilocode
show all
- Defined in:
- lib/agent_harness/providers/kilocode.rb
Overview
Kilocode CLI provider
Provides integration with the Kilocode CLI tool.
Constant Summary
collapse
- PACKAGE_NAME =
"@kilocode/cli"
- DEFAULT_VERSION =
"7.1.3"
- SUPPORTED_VERSION_REQUIREMENT =
"= #{DEFAULT_VERSION}"
Constants inherited
from Base
Base::COMMON_ERROR_PATTERNS, Base::DEFAULT_SMOKE_TEST_CONTRACT
Instance Attribute Summary
Attributes inherited from Base
#config, #executor, #logger
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Base
#configure, #initialize, #sandboxed_environment?, #send_message
Methods included from Adapter
#auth_type, #build_mcp_flags, #configuration_schema, #dangerous_mode_flags, #fetch_mcp_servers, #health_status, included, metadata_package_name, normalize_metadata_installation, normalize_metadata_source_type, normalize_metadata_version_requirement, #parse_rate_limit_reset, #send_message, #session_flags, #smoke_test, #smoke_test_contract, #supported_mcp_transports, #supports_dangerous_mode?, #supports_mcp?, #supports_sessions?, #validate_config, #validate_mcp_servers!
Class Method Details
.binary_name ⇒ Object
18
19
20
|
# File 'lib/agent_harness/providers/kilocode.rb', line 18
def binary_name
"kilo"
end
|
.discover_models ⇒ Object
38
39
40
41
|
# File 'lib/agent_harness/providers/kilocode.rb', line 38
def discover_models
return [] unless available?
[]
end
|
.firewall_requirements ⇒ Object
27
28
29
30
31
32
|
# File 'lib/agent_harness/providers/kilocode.rb', line 27
def firewall_requirements
{
domains: [],
ip_ranges: []
}
end
|
.install_command(version: DEFAULT_VERSION) ⇒ Object
59
60
61
|
# File 'lib/agent_harness/providers/kilocode.rb', line 59
def install_command(version: DEFAULT_VERSION)
installation_contract(version: version)[:install_command]
end
|
.installation_contract(version: DEFAULT_VERSION) ⇒ Object
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
# File 'lib/agent_harness/providers/kilocode.rb', line 43
def installation_contract(version: DEFAULT_VERSION)
validate_install_version!(version)
package_spec = "#{PACKAGE_NAME}@#{version}"
{
source: {
type: :npm,
package: PACKAGE_NAME
},
install_command: ["npm", "install", "-g", "--ignore-scripts", package_spec],
binary_name: binary_name,
default_version: DEFAULT_VERSION,
supported_version_requirement: SUPPORTED_VERSION_REQUIREMENT
}
end
|
.instruction_file_paths ⇒ Object
34
35
36
|
# File 'lib/agent_harness/providers/kilocode.rb', line 34
def instruction_file_paths
[]
end
|
.provider_name ⇒ Object
14
15
16
|
# File 'lib/agent_harness/providers/kilocode.rb', line 14
def provider_name
:kilocode
end
|
.smoke_test_contract ⇒ Object
Instance Method Details
#capabilities ⇒ Object
87
88
89
90
91
92
93
94
95
96
97
|
# File 'lib/agent_harness/providers/kilocode.rb', line 87
def capabilities
{
streaming: false,
file_upload: false,
vision: false,
tool_use: false,
json_mode: false,
mcp: false,
dangerous_mode: false
}
end
|
#display_name ⇒ Object
83
84
85
|
# File 'lib/agent_harness/providers/kilocode.rb', line 83
def display_name
"Kilocode CLI"
end
|
#error_patterns ⇒ Object
99
100
101
|
# File 'lib/agent_harness/providers/kilocode.rb', line 99
def error_patterns
COMMON_ERROR_PATTERNS
end
|
#execution_semantics ⇒ Object
103
104
105
106
107
108
109
110
111
112
113
114
|
# File 'lib/agent_harness/providers/kilocode.rb', line 103
def execution_semantics
{
prompt_delivery: :arg,
output_format: :text,
sandbox_aware: false,
uses_subcommand: true,
non_interactive_flag: nil,
legitimate_exit_codes: [0],
stderr_is_diagnostic: true,
parses_rate_limit_reset: false
}
end
|
#name ⇒ Object
79
80
81
|
# File 'lib/agent_harness/providers/kilocode.rb', line 79
def name
"kilocode"
end
|