MCPcopy Index your code
hub / github.com/geekcomputers/Python / handle_user_text

Function handle_user_text

JARVIS/actions.py:143–153  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

141
142
143def handle_user_text(text):
144 cleaned = normalize_text(text)
145 if cleaned.startswith("remember that "):
146 return remember_note(text.split("remember that", 1)[1].strip())
147 action = rule_based_action(text) or classify_action(text)
148 if action.strip().lower() == "blocked" and not is_dangerous_request(text):
149 action = "chat"
150 answer = run_action(action)
151 if answer:
152 return answer
153 return ask_model(text)

Callers 1

handle_commandFunction · 0.85

Calls 7

normalize_textFunction · 0.85
remember_noteFunction · 0.85
rule_based_actionFunction · 0.85
classify_actionFunction · 0.85
is_dangerous_requestFunction · 0.85
run_actionFunction · 0.85
ask_modelFunction · 0.85

Tested by

no test coverage detected