MCPcopy Create free account
hub / github.com/llm-workflow-engine/llm-workflow-engine / get_examples

Method get_examples

lwe/plugins/examples.py:45–55  ·  view source on GitHub ↗
(self, example_type)

Source from the content-addressed store, hash-verified

43 return commands
44
45 def get_examples(self, example_type):
46 example_type_dir = f"{self.examples_root}/{example_type}"
47 examples = []
48 for root, dirs, files in os.walk(example_type_dir):
49 # Exclude directories that start with an underscore
50 dirs[:] = [d for d in dirs if not d.startswith("_")]
51 for file in files:
52 file_path = os.path.join(root, file)
53 if os.path.isfile(file_path):
54 examples.append(os.path.relpath(file_path, example_type_dir))
55 return examples
56
57 def install_example_file(self, example_type, example_file):
58 """Helper method to install a single example file."""

Callers 2

install_examplesMethod · 0.95
command_examplesMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected