Hello_World Tool (example)¶
hello_world
¶
Hello_World
¶
Bases: BaseTool
Minimal example tool that exposes greetings in several languages.
Serves as an example scaffold for real tools.
Source code in src/MCPStack/tools/hello_world/hello_world.py
actions()
¶
actions function.
Source code in src/MCPStack/tools/hello_world/hello_world.py
from_dict(params)
classmethod
¶
from_dict function.
Source code in src/MCPStack/tools/hello_world/hello_world.py
say_hello_world_in_chinese()
¶
Return 'Hello world' in chinese.
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
The translated greeting. |
say_hello_world_in_french()
¶
Return 'Hello world' in french.
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
The translated greeting. |
say_hello_world_in_german()
¶
Return 'Hello world' in german.
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
The translated greeting. |
say_hello_world_in_italian()
¶
Return 'Hello world' in italian.
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
The translated greeting. |
cli
¶
Hello_WorldCLI
¶
Bases: BaseToolCLI
Hello_WorldCLI class.
Source code in src/MCPStack/tools/hello_world/cli.py
configure(prefix=None, languages=None, output=None, verbose=False)
classmethod
¶
configure function.
Source code in src/MCPStack/tools/hello_world/cli.py
get_app()
classmethod
¶
get_app function.
Source code in src/MCPStack/tools/hello_world/cli.py
init(prefix='👋')
classmethod
¶
init function.
Source code in src/MCPStack/tools/hello_world/cli.py
status(verbose=False)
classmethod
¶
status function.