Commit 48dadc8

mo khan <mo@mokhan.ca>
2026-01-29 04:08:57
feat: add interview tool and default prompts for different modes
1 parent bbbfa9b
Changed files (2)
lib/elelem/builtins/interview.rb
@@ -0,0 +1,14 @@
+# frozen_string_literal: true
+
+Elelem::Plugins.register(:interview) do |agent|
+  agent.toolbox.add("interview",
+    description: "Ask the user a question and wait for their response",
+    params: {
+      question: { type: "string", description: "The question to ask the user" },
+    },
+    required: ["question"]
+  ) do |args|
+    agent.terminal.say(agent.terminal.markdown(args["question"]))
+    { answer: agent.terminal.ask("> ") }
+  end
+end
lib/elelem/builtins/permissions.json
@@ -1,6 +1,7 @@
 {
-  "read": "allow",
-  "write": "ask",
   "edit": "ask",
-  "execute": "ask"
+  "execute": "ask",
+  "interview": "allow",
+  "read": "allow",
+  "write": "ask"
 }