Skip to content

🧰 Tools Reference

Janito uses these tools automatically based on your prompt and context. This table is for transparency and to help you understand what the agent can do.

🛠️ Tool 📝 Description 🗝️ Key Arguments 🔁 Returns 🗒️ Notes
create_file Create a new file with content. Fails if file exists. path (str): file path
content (str): file content
backup (bool, optional)
Success or error message Will NOT overwrite existing files unless backup is specified.
replace_file Overwrite or create a file with new content. path (str): file path
content (str): file content
backup (bool, optional)
Success message Creates file if it does not exist.
fetch_url Fetch and extract text from a web page. url (str): web page URL
search_strings (list of str, optional)
Extracted text or warning Useful for research or referencing online resources.
run_bash_command Run a bash command and capture output. command (str): bash command
timeout (int, optional)
require_confirmation (bool, opt.)
File paths and line counts for output Requires bash (e.g., WSL or Git Bash on Windows). Use with caution.
find_files Search for files matching a pattern. directories (list)
pattern (str)
recursive (bool, optional)
List of matching file paths Respects .gitignore.
get_file_outline Get outline of a file's structure (classes, functions, etc.). file_path (str) Outline summary Useful for code navigation and analysis.
get_lines Read lines or full content from a file. file_path (str)
from_line (int, optional)
to_line (int, optional)
File content Specify line range or omit for full file.
move_file Move a file to a new location. src_path (str)
dest_path (str)
overwrite (bool, optional)
backup (bool, optional)
Success or error message Can create backup before moving.
remove_file Remove a file. file_path (str)
backup (bool, optional)
Success or error message Can create backup before removing.
remove_directory Remove a directory (optionally recursively). directory (str)
recursive (bool, optional)
backup (bool, optional)
Success or error message Use recursive for non-empty dirs.
replace_text_in_file Replace exact text in a file. file_path (str)
search_text (str)
replacement_text (str)
replace_all (bool, opt.)
Success or warning message Can replace all or first occurrence.
py_compile_file Validate a Python file by compiling it. file_path (str) Compilation status message Checks for syntax errors.
run_python_command Execute Python code in a subprocess and capture output. code (str)
timeout (int, optional)
Output or file paths for output Useful for automation and testing.
search_files Search for a text pattern in files. directories (list)
pattern (str)
recursive (bool, optional)
Matching lines from files Respects .gitignore.
ask_user Request clarification or input from the user interactively. question (str) User response as a string Used when agent needs explicit user input.

For more details, see the codebase or tool docstrings.