Class: LittleGhost::Tools::Filesystem::ListFiles
- Inherits:
-
LittleGhost::Tool
- Object
- LittleGhost::Tool
- LittleGhost::Tools::Filesystem::ListFiles
- Defined in:
- lib/little_ghost/tools/filesystem.rb
Overview
Lists one directory through the configured sandbox.
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from LittleGhost::Tool
Instance Method Summary collapse
-
#call(input) ⇒ Object
Returns the listing for input, or the workspace root when
pathis omitted.
Methods inherited from LittleGhost::Tool
#agent, #close, define, description, #description, exclusive, #exclusive?, #execute, #initialize, input_schema, #input_schema, #model, #run, #runtime, #sandbox, specification, #specification, tool_name, #tool_name, #workspace
Methods included from Support::ClassAttributes
Constructor Details
This class inherits a constructor from LittleGhost::Tool
Instance Method Details
#call(input) ⇒ Object
Returns the listing for input, or the workspace root
when path is omitted.
42 43 44 |
# File 'lib/little_ghost/tools/filesystem.rb', line 42 def call(input) sandbox.list(input.fetch("path", "."), context:) end |