ruby-claw 0.1.2 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +94 -0
- data/README.md +214 -10
- data/exe/claw +42 -1
- data/lib/claw/auto_forge.rb +66 -0
- data/lib/claw/benchmark/benchmark.rb +79 -0
- data/lib/claw/benchmark/diff.rb +69 -0
- data/lib/claw/benchmark/report.rb +87 -0
- data/lib/claw/benchmark/runner.rb +91 -0
- data/lib/claw/benchmark/scorer.rb +69 -0
- data/lib/claw/benchmark/task.rb +63 -0
- data/lib/claw/benchmark/tasks/claw_remember.rb +20 -0
- data/lib/claw/benchmark/tasks/claw_session.rb +18 -0
- data/lib/claw/benchmark/tasks/evolution_trace.rb +18 -0
- data/lib/claw/benchmark/tasks/mana_call_func.rb +21 -0
- data/lib/claw/benchmark/tasks/mana_eval.rb +18 -0
- data/lib/claw/benchmark/tasks/mana_knowledge.rb +19 -0
- data/lib/claw/benchmark/tasks/mana_var_readwrite.rb +18 -0
- data/lib/claw/benchmark/tasks/runtime_fork.rb +18 -0
- data/lib/claw/benchmark/tasks/runtime_snapshot.rb +18 -0
- data/lib/claw/benchmark/trigger.rb +68 -0
- data/lib/claw/chat.rb +119 -6
- data/lib/claw/child_runtime.rb +196 -0
- data/lib/claw/cli.rb +177 -0
- data/lib/claw/commands.rb +131 -0
- data/lib/claw/config.rb +5 -1
- data/lib/claw/console/event_logger.rb +69 -0
- data/lib/claw/console/public/app.js +264 -0
- data/lib/claw/console/public/style.css +330 -0
- data/lib/claw/console/server.rb +253 -0
- data/lib/claw/console/sse.rb +28 -0
- data/lib/claw/console/views/experiments.erb +8 -0
- data/lib/claw/console/views/index.erb +27 -0
- data/lib/claw/console/views/layout.erb +29 -0
- data/lib/claw/console/views/memory.erb +13 -0
- data/lib/claw/console/views/monitor.erb +15 -0
- data/lib/claw/console/views/prompt.erb +15 -0
- data/lib/claw/console/views/snapshots.erb +12 -0
- data/lib/claw/console/views/tools.erb +13 -0
- data/lib/claw/console/views/traces.erb +9 -0
- data/lib/claw/console.rb +5 -0
- data/lib/claw/evolution.rb +227 -0
- data/lib/claw/forge.rb +144 -0
- data/lib/claw/hub.rb +67 -0
- data/lib/claw/init.rb +199 -0
- data/lib/claw/knowledge.rb +36 -2
- data/lib/claw/memory_store.rb +2 -2
- data/lib/claw/plan_mode.rb +110 -0
- data/lib/claw/resource.rb +35 -0
- data/lib/claw/resources/binding_resource.rb +128 -0
- data/lib/claw/resources/context_resource.rb +73 -0
- data/lib/claw/resources/filesystem_resource.rb +107 -0
- data/lib/claw/resources/memory_resource.rb +74 -0
- data/lib/claw/resources/worktree_resource.rb +133 -0
- data/lib/claw/roles.rb +56 -0
- data/lib/claw/runtime.rb +189 -0
- data/lib/claw/serializer.rb +10 -7
- data/lib/claw/tool.rb +99 -0
- data/lib/claw/tool_index.rb +84 -0
- data/lib/claw/tool_registry.rb +100 -0
- data/lib/claw/trace.rb +86 -0
- data/lib/claw/tui/agent_executor.rb +92 -0
- data/lib/claw/tui/chat_panel.rb +81 -0
- data/lib/claw/tui/command_bar.rb +22 -0
- data/lib/claw/tui/file_card.rb +88 -0
- data/lib/claw/tui/folding.rb +80 -0
- data/lib/claw/tui/input_handler.rb +73 -0
- data/lib/claw/tui/layout.rb +34 -0
- data/lib/claw/tui/messages.rb +31 -0
- data/lib/claw/tui/model.rb +411 -0
- data/lib/claw/tui/object_explorer.rb +136 -0
- data/lib/claw/tui/status_bar.rb +30 -0
- data/lib/claw/tui/status_panel.rb +133 -0
- data/lib/claw/tui/styles.rb +58 -0
- data/lib/claw/tui/tui.rb +54 -0
- data/lib/claw/version.rb +1 -1
- data/lib/claw.rb +99 -1
- metadata +223 -7
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Claw
|
|
4
|
+
module TUI
|
|
5
|
+
# Right panel: Binding, Snapshots, Memory, Tokens, Status sections.
|
|
6
|
+
module StatusPanel
|
|
7
|
+
def self.render(model, width, height)
|
|
8
|
+
sections = []
|
|
9
|
+
|
|
10
|
+
sections << render_binding(model, width - 4)
|
|
11
|
+
sections << render_snapshots(model, width - 4)
|
|
12
|
+
sections << render_memory(model, width - 4)
|
|
13
|
+
sections << render_tokens(model, width - 4)
|
|
14
|
+
sections << render_status(model, width - 4)
|
|
15
|
+
|
|
16
|
+
content = sections.join("\n")
|
|
17
|
+
Styles::PANEL_BORDER.width(width).height(height).render(content)
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
def self.render_binding(model, width)
|
|
21
|
+
header = Styles::SECTION_HEADER.render("Binding")
|
|
22
|
+
return "#{header}\n (no runtime)" unless model.runtime
|
|
23
|
+
|
|
24
|
+
binding_res = model.runtime.resources["binding"]
|
|
25
|
+
return "#{header}\n (not tracked)" unless binding_res
|
|
26
|
+
|
|
27
|
+
lines = [header]
|
|
28
|
+
binding_res.tracked.each do |name, blob|
|
|
29
|
+
val = begin
|
|
30
|
+
v = MarshalMd.load(blob)
|
|
31
|
+
"#{v.class} (#{summary_value(v)})"
|
|
32
|
+
rescue
|
|
33
|
+
"?"
|
|
34
|
+
end
|
|
35
|
+
line = " #{name}: #{val}"
|
|
36
|
+
lines << truncate(line, width)
|
|
37
|
+
end
|
|
38
|
+
lines << " (empty)" if binding_res.tracked.empty?
|
|
39
|
+
lines.join("\n")
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
def self.render_snapshots(model, width)
|
|
43
|
+
header = Styles::SECTION_HEADER.render("Snapshots")
|
|
44
|
+
return "#{header}\n (none)" unless model.runtime
|
|
45
|
+
|
|
46
|
+
snaps = model.runtime.snapshots.last(5)
|
|
47
|
+
lines = [header]
|
|
48
|
+
snaps.reverse_each do |s|
|
|
49
|
+
lines << " [#{s.id}] #{s.label || '(unlabeled)'}"
|
|
50
|
+
end
|
|
51
|
+
lines << " (none)" if snaps.empty?
|
|
52
|
+
lines.join("\n")
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
def self.render_memory(model, width)
|
|
56
|
+
header = Styles::SECTION_HEADER.render("Memory")
|
|
57
|
+
memory = Claw.memory
|
|
58
|
+
unless memory
|
|
59
|
+
return "#{header}\n (disabled)"
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
count = memory.long_term.size
|
|
63
|
+
lines = [header, " #{count} facts"]
|
|
64
|
+
memory.long_term.last(3).each do |m|
|
|
65
|
+
lines << " · #{truncate(m[:content].to_s, width - 4)}"
|
|
66
|
+
end
|
|
67
|
+
lines.join("\n")
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
def self.render_tokens(model, width)
|
|
71
|
+
header = Styles::SECTION_HEADER.render("Tokens")
|
|
72
|
+
ctx = Mana::Context.current
|
|
73
|
+
used = ctx.token_count
|
|
74
|
+
limit = Mana.config.context_window
|
|
75
|
+
pct = limit > 0 ? (used.to_f / limit * 100).round(1) : 0
|
|
76
|
+
|
|
77
|
+
bar_width = [width - 12, 10].max
|
|
78
|
+
filled = (bar_width * pct / 100.0).round
|
|
79
|
+
bar = "▓" * filled + "░" * (bar_width - filled)
|
|
80
|
+
|
|
81
|
+
lines = [header]
|
|
82
|
+
lines << " session: #{format_tokens(used)}/#{format_tokens(limit)}"
|
|
83
|
+
lines << " #{bar} #{pct}%"
|
|
84
|
+
lines.join("\n")
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
def self.render_status(model, width)
|
|
88
|
+
header = Styles::SECTION_HEADER.render("Status")
|
|
89
|
+
return "#{header}\n (no runtime)" unless model.runtime
|
|
90
|
+
|
|
91
|
+
state = model.runtime.state
|
|
92
|
+
icon = case state
|
|
93
|
+
when :idle then "●"
|
|
94
|
+
when :thinking then "◉"
|
|
95
|
+
when :executing_tool then "⚡"
|
|
96
|
+
when :failed then "✗"
|
|
97
|
+
else "?"
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
lines = [header, " #{icon} #{state}"]
|
|
101
|
+
if model.runtime.current_step
|
|
102
|
+
step = model.runtime.current_step
|
|
103
|
+
lines << " #{step.tool_name}(#{step.target})"
|
|
104
|
+
end
|
|
105
|
+
lines.join("\n")
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
# --- Helpers ---
|
|
109
|
+
|
|
110
|
+
def self.summary_value(v)
|
|
111
|
+
case v
|
|
112
|
+
when Array then v.size.to_s
|
|
113
|
+
when Hash then "#{v.size} keys"
|
|
114
|
+
when String then v.length > 20 ? "#{v.length} chars" : v.inspect
|
|
115
|
+
else v.inspect[0, 20]
|
|
116
|
+
end
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
def self.format_tokens(n)
|
|
120
|
+
return "#{n}" if n < 1000
|
|
121
|
+
"#{(n / 1000.0).round(1)}k"
|
|
122
|
+
end
|
|
123
|
+
|
|
124
|
+
def self.truncate(str, max)
|
|
125
|
+
str.length > max ? "#{str[0, max - 3]}..." : str
|
|
126
|
+
end
|
|
127
|
+
|
|
128
|
+
private_class_method :render_binding, :render_snapshots, :render_memory,
|
|
129
|
+
:render_tokens, :render_status,
|
|
130
|
+
:summary_value, :format_tokens, :truncate
|
|
131
|
+
end
|
|
132
|
+
end
|
|
133
|
+
end
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "lipgloss"
|
|
4
|
+
|
|
5
|
+
module Claw
|
|
6
|
+
module TUI
|
|
7
|
+
# Centralized color and style definitions for the TUI.
|
|
8
|
+
module Styles
|
|
9
|
+
# Colors
|
|
10
|
+
CYAN = "#00BFFF"
|
|
11
|
+
YELLOW = "#FFD700"
|
|
12
|
+
GREEN = "#32CD32"
|
|
13
|
+
RED = "#FF4444"
|
|
14
|
+
MAGENTA = "#FF69B4"
|
|
15
|
+
DIM_GRAY = "#666666"
|
|
16
|
+
BORDER = "#444444"
|
|
17
|
+
BG_DARK = "#1A1A2E"
|
|
18
|
+
|
|
19
|
+
# Status bar (top)
|
|
20
|
+
STATUS_BAR = Lipgloss::Style.new
|
|
21
|
+
.foreground(CYAN)
|
|
22
|
+
.background("#1A1A2E")
|
|
23
|
+
.bold(true)
|
|
24
|
+
.padding(0, 1)
|
|
25
|
+
|
|
26
|
+
# Chat panel styles
|
|
27
|
+
USER_STYLE = Lipgloss::Style.new.foreground(CYAN).bold(true)
|
|
28
|
+
AGENT_STYLE = Lipgloss::Style.new.foreground(YELLOW)
|
|
29
|
+
TOOL_STYLE = Lipgloss::Style.new.foreground(DIM_GRAY).faint(true)
|
|
30
|
+
RESULT_STYLE = Lipgloss::Style.new.foreground(GREEN).faint(true)
|
|
31
|
+
ERROR_STYLE = Lipgloss::Style.new.foreground(RED)
|
|
32
|
+
RUBY_STYLE = Lipgloss::Style.new.foreground(MAGENTA)
|
|
33
|
+
|
|
34
|
+
# Panel borders
|
|
35
|
+
PANEL_BORDER = Lipgloss::Style.new
|
|
36
|
+
.border(:rounded)
|
|
37
|
+
.border_foreground(BORDER)
|
|
38
|
+
.padding(0, 1)
|
|
39
|
+
|
|
40
|
+
# Right panel section headers
|
|
41
|
+
SECTION_HEADER = Lipgloss::Style.new
|
|
42
|
+
.foreground(CYAN)
|
|
43
|
+
.bold(true)
|
|
44
|
+
|
|
45
|
+
# Command bar (bottom)
|
|
46
|
+
COMMAND_BAR = Lipgloss::Style.new
|
|
47
|
+
.foreground(DIM_GRAY)
|
|
48
|
+
.padding(0, 1)
|
|
49
|
+
|
|
50
|
+
# Spinner style
|
|
51
|
+
SPINNER_STYLE = Lipgloss::Style.new.foreground(YELLOW)
|
|
52
|
+
|
|
53
|
+
# Progress bar colors
|
|
54
|
+
PROGRESS_FULL = GREEN
|
|
55
|
+
PROGRESS_EMPTY = DIM_GRAY
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
end
|
data/lib/claw/tui/tui.rb
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "bubbletea"
|
|
4
|
+
require "lipgloss"
|
|
5
|
+
require "bubbles"
|
|
6
|
+
|
|
7
|
+
require_relative "styles"
|
|
8
|
+
require_relative "messages"
|
|
9
|
+
require_relative "status_bar"
|
|
10
|
+
require_relative "chat_panel"
|
|
11
|
+
require_relative "status_panel"
|
|
12
|
+
require_relative "command_bar"
|
|
13
|
+
require_relative "layout"
|
|
14
|
+
require_relative "agent_executor"
|
|
15
|
+
require_relative "input_handler"
|
|
16
|
+
require_relative "object_explorer"
|
|
17
|
+
require_relative "file_card"
|
|
18
|
+
require_relative "folding"
|
|
19
|
+
require_relative "model"
|
|
20
|
+
|
|
21
|
+
module Claw
|
|
22
|
+
module TUI
|
|
23
|
+
# Start the TUI application.
|
|
24
|
+
#
|
|
25
|
+
# @param caller_binding [Binding] the caller's binding for variable access
|
|
26
|
+
def self.start(caller_binding)
|
|
27
|
+
# Load session state
|
|
28
|
+
load_session(caller_binding)
|
|
29
|
+
|
|
30
|
+
model = Model.new(caller_binding)
|
|
31
|
+
Bubbletea.run(model, alt_screen: true)
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
# --- Session loading (extracted from Chat) ---
|
|
35
|
+
|
|
36
|
+
def self.load_session(caller_binding)
|
|
37
|
+
# Load compiled mana def methods
|
|
38
|
+
cache_dir = Mana::Compiler.cache_dir
|
|
39
|
+
if Dir.exist?(cache_dir)
|
|
40
|
+
Dir.glob(File.join(cache_dir, "*.rb")).each do |path|
|
|
41
|
+
caller_binding.eval(File.read(path), path, 1) rescue nil
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# Restore runtime state
|
|
46
|
+
return unless Claw.config.persist_session
|
|
47
|
+
dir = File.join(Dir.pwd, ".ruby-claw")
|
|
48
|
+
return unless File.exist?(File.join(dir, "values.json")) || File.exist?(File.join(dir, "definitions.rb"))
|
|
49
|
+
Claw::Serializer.restore(caller_binding, dir) rescue nil
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
private_class_method :load_session
|
|
53
|
+
end
|
|
54
|
+
end
|
data/lib/claw/version.rb
CHANGED
data/lib/claw.rb
CHANGED
|
@@ -1,13 +1,37 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
require "mana"
|
|
4
|
+
require "marshal-md"
|
|
4
5
|
require_relative "claw/version"
|
|
5
6
|
require_relative "claw/config"
|
|
6
7
|
require_relative "claw/memory_store"
|
|
7
8
|
require_relative "claw/memory"
|
|
8
9
|
require_relative "claw/knowledge"
|
|
10
|
+
require_relative "claw/resource"
|
|
11
|
+
require_relative "claw/runtime"
|
|
12
|
+
require_relative "claw/resources/context_resource"
|
|
13
|
+
require_relative "claw/resources/memory_resource"
|
|
14
|
+
require_relative "claw/resources/filesystem_resource"
|
|
15
|
+
require_relative "claw/resources/binding_resource"
|
|
16
|
+
require_relative "claw/resources/worktree_resource"
|
|
9
17
|
require_relative "claw/serializer"
|
|
18
|
+
require_relative "claw/trace"
|
|
19
|
+
require_relative "claw/init"
|
|
20
|
+
require_relative "claw/evolution"
|
|
21
|
+
require_relative "claw/child_runtime"
|
|
22
|
+
require_relative "claw/tool"
|
|
23
|
+
require_relative "claw/tool_index"
|
|
24
|
+
require_relative "claw/tool_registry"
|
|
25
|
+
require_relative "claw/forge"
|
|
26
|
+
require_relative "claw/auto_forge"
|
|
27
|
+
require_relative "claw/hub"
|
|
28
|
+
require_relative "claw/commands"
|
|
29
|
+
require_relative "claw/plan_mode"
|
|
30
|
+
require_relative "claw/roles"
|
|
31
|
+
require_relative "claw/console"
|
|
32
|
+
require_relative "claw/cli"
|
|
10
33
|
require_relative "claw/chat"
|
|
34
|
+
require_relative "claw/tui/tui"
|
|
11
35
|
|
|
12
36
|
module Claw
|
|
13
37
|
class << self
|
|
@@ -32,8 +56,19 @@ module Claw
|
|
|
32
56
|
Memory.incognito(&block)
|
|
33
57
|
end
|
|
34
58
|
|
|
59
|
+
def tool_registry
|
|
60
|
+
@tool_registry
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
def init_tool_registry(tools_dir: nil, hub: nil)
|
|
64
|
+
tools_dir ||= File.join(Dir.pwd, ".ruby-claw", "tools")
|
|
65
|
+
@tool_registry = ToolRegistry.new(tools_dir: tools_dir, hub: hub)
|
|
66
|
+
end
|
|
67
|
+
|
|
35
68
|
def reset!
|
|
36
69
|
@config = Config.new
|
|
70
|
+
@tool_registry = nil
|
|
71
|
+
Claw::Tool.tool_classes.clear
|
|
37
72
|
Thread.current[:claw_memory] = nil
|
|
38
73
|
Thread.current[:mana_context] = nil
|
|
39
74
|
end
|
|
@@ -69,9 +104,72 @@ Mana.register_prompt_section do
|
|
|
69
104
|
lines = ["Long-term memories (persistent background context):"]
|
|
70
105
|
memory.long_term.each { |m| lines << "- #{m[:content]}" }
|
|
71
106
|
lines << ""
|
|
72
|
-
lines << "You have a `remember` tool to store
|
|
107
|
+
lines << "You have a `remember` tool to store facts in long-term memory."
|
|
108
|
+
lines << "After completing a task, proactively use `remember` to store:"
|
|
109
|
+
lines << "- User preferences you observed (coding style, language, formatting)"
|
|
110
|
+
lines << "- Project characteristics (tech stack, architecture, key files)"
|
|
111
|
+
lines << "- Effective strategies that worked well"
|
|
112
|
+
lines << "- Corrections the user made (to avoid repeating mistakes)"
|
|
113
|
+
lines << "Do not wait to be asked — remember useful context proactively."
|
|
73
114
|
lines.join("\n")
|
|
74
115
|
end
|
|
75
116
|
|
|
117
|
+
# Register prompt section to inject active role into system prompt.
|
|
118
|
+
Mana.register_prompt_section do
|
|
119
|
+
role = Claw::Roles.current
|
|
120
|
+
next nil unless role
|
|
121
|
+
|
|
122
|
+
"Active role: #{role[:name]}\n#{role[:content]}"
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
# Register search_tools — agent uses this to discover available project/hub tools.
|
|
126
|
+
Mana.register_tool(
|
|
127
|
+
{
|
|
128
|
+
name: "search_tools",
|
|
129
|
+
description: "Search for available tools by keyword. Returns matching tools that can be loaded with load_tool.",
|
|
130
|
+
input_schema: {
|
|
131
|
+
type: "object",
|
|
132
|
+
properties: { query: { type: "string", description: "What capability you need" } },
|
|
133
|
+
required: ["query"]
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
) do |input|
|
|
137
|
+
registry = Claw.tool_registry
|
|
138
|
+
unless registry
|
|
139
|
+
next "Tool registry not initialized. Run `claw init` first."
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
results = registry.search(input["query"])
|
|
143
|
+
if results.empty?
|
|
144
|
+
"No tools found matching '#{input['query']}'"
|
|
145
|
+
else
|
|
146
|
+
lines = results.map do |r|
|
|
147
|
+
status = r[:loaded] ? " [loaded]" : ""
|
|
148
|
+
"- #{r[:name]}: #{r[:description]} (#{r[:source]}#{status})"
|
|
149
|
+
end
|
|
150
|
+
"Found #{results.size} tool(s):\n#{lines.join("\n")}"
|
|
151
|
+
end
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# Register load_tool — agent uses this to dynamically load a discovered tool.
|
|
155
|
+
Mana.register_tool(
|
|
156
|
+
{
|
|
157
|
+
name: "load_tool",
|
|
158
|
+
description: "Load a tool to make it available for use in the current session. Use search_tools first to find available tools.",
|
|
159
|
+
input_schema: {
|
|
160
|
+
type: "object",
|
|
161
|
+
properties: { tool_name: { type: "string", description: "Name of the tool to load" } },
|
|
162
|
+
required: ["tool_name"]
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
) do |input|
|
|
166
|
+
registry = Claw.tool_registry
|
|
167
|
+
unless registry
|
|
168
|
+
next "Tool registry not initialized. Run `claw init` first."
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
registry.load(input["tool_name"])
|
|
172
|
+
end
|
|
173
|
+
|
|
76
174
|
# Register Claw's enhanced knowledge provider.
|
|
77
175
|
Mana.config.knowledge_provider = Claw::Knowledge
|
metadata
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ruby-claw
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Carl Li
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: exe
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
12
11
|
dependencies:
|
|
13
12
|
- !ruby/object:Gem::Dependency
|
|
14
13
|
name: ruby-mana
|
|
@@ -24,6 +23,20 @@ dependencies:
|
|
|
24
23
|
- - ">="
|
|
25
24
|
- !ruby/object:Gem::Version
|
|
26
25
|
version: 0.5.11
|
|
26
|
+
- !ruby/object:Gem::Dependency
|
|
27
|
+
name: marshal-md
|
|
28
|
+
requirement: !ruby/object:Gem::Requirement
|
|
29
|
+
requirements:
|
|
30
|
+
- - ">="
|
|
31
|
+
- !ruby/object:Gem::Version
|
|
32
|
+
version: 0.1.0
|
|
33
|
+
type: :runtime
|
|
34
|
+
prerelease: false
|
|
35
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
36
|
+
requirements:
|
|
37
|
+
- - ">="
|
|
38
|
+
- !ruby/object:Gem::Version
|
|
39
|
+
version: 0.1.0
|
|
27
40
|
- !ruby/object:Gem::Dependency
|
|
28
41
|
name: binding_of_caller
|
|
29
42
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -52,9 +65,148 @@ dependencies:
|
|
|
52
65
|
- - ">="
|
|
53
66
|
- !ruby/object:Gem::Version
|
|
54
67
|
version: '0.5'
|
|
68
|
+
- !ruby/object:Gem::Dependency
|
|
69
|
+
name: bubbletea
|
|
70
|
+
requirement: !ruby/object:Gem::Requirement
|
|
71
|
+
requirements:
|
|
72
|
+
- - ">="
|
|
73
|
+
- !ruby/object:Gem::Version
|
|
74
|
+
version: 0.1.0
|
|
75
|
+
type: :runtime
|
|
76
|
+
prerelease: false
|
|
77
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
78
|
+
requirements:
|
|
79
|
+
- - ">="
|
|
80
|
+
- !ruby/object:Gem::Version
|
|
81
|
+
version: 0.1.0
|
|
82
|
+
- !ruby/object:Gem::Dependency
|
|
83
|
+
name: lipgloss
|
|
84
|
+
requirement: !ruby/object:Gem::Requirement
|
|
85
|
+
requirements:
|
|
86
|
+
- - ">="
|
|
87
|
+
- !ruby/object:Gem::Version
|
|
88
|
+
version: 0.2.0
|
|
89
|
+
type: :runtime
|
|
90
|
+
prerelease: false
|
|
91
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
92
|
+
requirements:
|
|
93
|
+
- - ">="
|
|
94
|
+
- !ruby/object:Gem::Version
|
|
95
|
+
version: 0.2.0
|
|
96
|
+
- !ruby/object:Gem::Dependency
|
|
97
|
+
name: bubbles
|
|
98
|
+
requirement: !ruby/object:Gem::Requirement
|
|
99
|
+
requirements:
|
|
100
|
+
- - ">="
|
|
101
|
+
- !ruby/object:Gem::Version
|
|
102
|
+
version: 0.1.0
|
|
103
|
+
type: :runtime
|
|
104
|
+
prerelease: false
|
|
105
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
106
|
+
requirements:
|
|
107
|
+
- - ">="
|
|
108
|
+
- !ruby/object:Gem::Version
|
|
109
|
+
version: 0.1.0
|
|
110
|
+
- !ruby/object:Gem::Dependency
|
|
111
|
+
name: glamour
|
|
112
|
+
requirement: !ruby/object:Gem::Requirement
|
|
113
|
+
requirements:
|
|
114
|
+
- - ">="
|
|
115
|
+
- !ruby/object:Gem::Version
|
|
116
|
+
version: 0.2.0
|
|
117
|
+
type: :runtime
|
|
118
|
+
prerelease: false
|
|
119
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
120
|
+
requirements:
|
|
121
|
+
- - ">="
|
|
122
|
+
- !ruby/object:Gem::Version
|
|
123
|
+
version: 0.2.0
|
|
124
|
+
- !ruby/object:Gem::Dependency
|
|
125
|
+
name: ntcharts
|
|
126
|
+
requirement: !ruby/object:Gem::Requirement
|
|
127
|
+
requirements:
|
|
128
|
+
- - ">="
|
|
129
|
+
- !ruby/object:Gem::Version
|
|
130
|
+
version: 0.1.0
|
|
131
|
+
type: :runtime
|
|
132
|
+
prerelease: false
|
|
133
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
134
|
+
requirements:
|
|
135
|
+
- - ">="
|
|
136
|
+
- !ruby/object:Gem::Version
|
|
137
|
+
version: 0.1.0
|
|
138
|
+
- !ruby/object:Gem::Dependency
|
|
139
|
+
name: bubblezone
|
|
140
|
+
requirement: !ruby/object:Gem::Requirement
|
|
141
|
+
requirements:
|
|
142
|
+
- - ">="
|
|
143
|
+
- !ruby/object:Gem::Version
|
|
144
|
+
version: 0.1.0
|
|
145
|
+
type: :runtime
|
|
146
|
+
prerelease: false
|
|
147
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
148
|
+
requirements:
|
|
149
|
+
- - ">="
|
|
150
|
+
- !ruby/object:Gem::Version
|
|
151
|
+
version: 0.1.0
|
|
152
|
+
- !ruby/object:Gem::Dependency
|
|
153
|
+
name: huh
|
|
154
|
+
requirement: !ruby/object:Gem::Requirement
|
|
155
|
+
requirements:
|
|
156
|
+
- - ">="
|
|
157
|
+
- !ruby/object:Gem::Version
|
|
158
|
+
version: '1.0'
|
|
159
|
+
type: :runtime
|
|
160
|
+
prerelease: false
|
|
161
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
162
|
+
requirements:
|
|
163
|
+
- - ">="
|
|
164
|
+
- !ruby/object:Gem::Version
|
|
165
|
+
version: '1.0'
|
|
166
|
+
- !ruby/object:Gem::Dependency
|
|
167
|
+
name: harmonica
|
|
168
|
+
requirement: !ruby/object:Gem::Requirement
|
|
169
|
+
requirements:
|
|
170
|
+
- - ">="
|
|
171
|
+
- !ruby/object:Gem::Version
|
|
172
|
+
version: 0.1.0
|
|
173
|
+
type: :runtime
|
|
174
|
+
prerelease: false
|
|
175
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
176
|
+
requirements:
|
|
177
|
+
- - ">="
|
|
178
|
+
- !ruby/object:Gem::Version
|
|
179
|
+
version: 0.1.0
|
|
180
|
+
- !ruby/object:Gem::Dependency
|
|
181
|
+
name: sinatra
|
|
182
|
+
requirement: !ruby/object:Gem::Requirement
|
|
183
|
+
requirements:
|
|
184
|
+
- - ">="
|
|
185
|
+
- !ruby/object:Gem::Version
|
|
186
|
+
version: '4.0'
|
|
187
|
+
type: :runtime
|
|
188
|
+
prerelease: false
|
|
189
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
190
|
+
requirements:
|
|
191
|
+
- - ">="
|
|
192
|
+
- !ruby/object:Gem::Version
|
|
193
|
+
version: '4.0'
|
|
194
|
+
- !ruby/object:Gem::Dependency
|
|
195
|
+
name: rackup
|
|
196
|
+
requirement: !ruby/object:Gem::Requirement
|
|
197
|
+
requirements:
|
|
198
|
+
- - ">="
|
|
199
|
+
- !ruby/object:Gem::Version
|
|
200
|
+
version: '2.0'
|
|
201
|
+
type: :runtime
|
|
202
|
+
prerelease: false
|
|
203
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
204
|
+
requirements:
|
|
205
|
+
- - ">="
|
|
206
|
+
- !ruby/object:Gem::Version
|
|
207
|
+
version: '2.0'
|
|
55
208
|
description: Claw is an Agent framework built on ruby-mana. Adds interactive chat,
|
|
56
209
|
persistent memory with compaction, knowledge base, and runtime state persistence.
|
|
57
|
-
email:
|
|
58
210
|
executables:
|
|
59
211
|
- claw
|
|
60
212
|
extensions: []
|
|
@@ -65,18 +217,83 @@ files:
|
|
|
65
217
|
- README.md
|
|
66
218
|
- exe/claw
|
|
67
219
|
- lib/claw.rb
|
|
220
|
+
- lib/claw/auto_forge.rb
|
|
221
|
+
- lib/claw/benchmark/benchmark.rb
|
|
222
|
+
- lib/claw/benchmark/diff.rb
|
|
223
|
+
- lib/claw/benchmark/report.rb
|
|
224
|
+
- lib/claw/benchmark/runner.rb
|
|
225
|
+
- lib/claw/benchmark/scorer.rb
|
|
226
|
+
- lib/claw/benchmark/task.rb
|
|
227
|
+
- lib/claw/benchmark/tasks/claw_remember.rb
|
|
228
|
+
- lib/claw/benchmark/tasks/claw_session.rb
|
|
229
|
+
- lib/claw/benchmark/tasks/evolution_trace.rb
|
|
230
|
+
- lib/claw/benchmark/tasks/mana_call_func.rb
|
|
231
|
+
- lib/claw/benchmark/tasks/mana_eval.rb
|
|
232
|
+
- lib/claw/benchmark/tasks/mana_knowledge.rb
|
|
233
|
+
- lib/claw/benchmark/tasks/mana_var_readwrite.rb
|
|
234
|
+
- lib/claw/benchmark/tasks/runtime_fork.rb
|
|
235
|
+
- lib/claw/benchmark/tasks/runtime_snapshot.rb
|
|
236
|
+
- lib/claw/benchmark/trigger.rb
|
|
68
237
|
- lib/claw/chat.rb
|
|
238
|
+
- lib/claw/child_runtime.rb
|
|
239
|
+
- lib/claw/cli.rb
|
|
240
|
+
- lib/claw/commands.rb
|
|
69
241
|
- lib/claw/config.rb
|
|
242
|
+
- lib/claw/console.rb
|
|
243
|
+
- lib/claw/console/event_logger.rb
|
|
244
|
+
- lib/claw/console/public/app.js
|
|
245
|
+
- lib/claw/console/public/style.css
|
|
246
|
+
- lib/claw/console/server.rb
|
|
247
|
+
- lib/claw/console/sse.rb
|
|
248
|
+
- lib/claw/console/views/experiments.erb
|
|
249
|
+
- lib/claw/console/views/index.erb
|
|
250
|
+
- lib/claw/console/views/layout.erb
|
|
251
|
+
- lib/claw/console/views/memory.erb
|
|
252
|
+
- lib/claw/console/views/monitor.erb
|
|
253
|
+
- lib/claw/console/views/prompt.erb
|
|
254
|
+
- lib/claw/console/views/snapshots.erb
|
|
255
|
+
- lib/claw/console/views/tools.erb
|
|
256
|
+
- lib/claw/console/views/traces.erb
|
|
257
|
+
- lib/claw/evolution.rb
|
|
258
|
+
- lib/claw/forge.rb
|
|
259
|
+
- lib/claw/hub.rb
|
|
260
|
+
- lib/claw/init.rb
|
|
70
261
|
- lib/claw/knowledge.rb
|
|
71
262
|
- lib/claw/memory.rb
|
|
72
263
|
- lib/claw/memory_store.rb
|
|
264
|
+
- lib/claw/plan_mode.rb
|
|
265
|
+
- lib/claw/resource.rb
|
|
266
|
+
- lib/claw/resources/binding_resource.rb
|
|
267
|
+
- lib/claw/resources/context_resource.rb
|
|
268
|
+
- lib/claw/resources/filesystem_resource.rb
|
|
269
|
+
- lib/claw/resources/memory_resource.rb
|
|
270
|
+
- lib/claw/resources/worktree_resource.rb
|
|
271
|
+
- lib/claw/roles.rb
|
|
272
|
+
- lib/claw/runtime.rb
|
|
73
273
|
- lib/claw/serializer.rb
|
|
274
|
+
- lib/claw/tool.rb
|
|
275
|
+
- lib/claw/tool_index.rb
|
|
276
|
+
- lib/claw/tool_registry.rb
|
|
277
|
+
- lib/claw/trace.rb
|
|
278
|
+
- lib/claw/tui/agent_executor.rb
|
|
279
|
+
- lib/claw/tui/chat_panel.rb
|
|
280
|
+
- lib/claw/tui/command_bar.rb
|
|
281
|
+
- lib/claw/tui/file_card.rb
|
|
282
|
+
- lib/claw/tui/folding.rb
|
|
283
|
+
- lib/claw/tui/input_handler.rb
|
|
284
|
+
- lib/claw/tui/layout.rb
|
|
285
|
+
- lib/claw/tui/messages.rb
|
|
286
|
+
- lib/claw/tui/model.rb
|
|
287
|
+
- lib/claw/tui/object_explorer.rb
|
|
288
|
+
- lib/claw/tui/status_bar.rb
|
|
289
|
+
- lib/claw/tui/status_panel.rb
|
|
290
|
+
- lib/claw/tui/styles.rb
|
|
291
|
+
- lib/claw/tui/tui.rb
|
|
74
292
|
- lib/claw/version.rb
|
|
75
293
|
homepage: https://github.com/twokidsCarl/ruby-claw
|
|
76
294
|
licenses:
|
|
77
295
|
- MIT
|
|
78
296
|
metadata: {}
|
|
79
|
-
post_install_message:
|
|
80
297
|
rdoc_options: []
|
|
81
298
|
require_paths:
|
|
82
299
|
- lib
|
|
@@ -91,8 +308,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
91
308
|
- !ruby/object:Gem::Version
|
|
92
309
|
version: '0'
|
|
93
310
|
requirements: []
|
|
94
|
-
rubygems_version: 3.
|
|
95
|
-
signing_key:
|
|
311
|
+
rubygems_version: 3.6.9
|
|
96
312
|
specification_version: 4
|
|
97
313
|
summary: AI Agent framework for Ruby — chat, memory, persistence
|
|
98
314
|
test_files: []
|