docs: add keyword-only args note to mcp-forge-conventions skill
This commit is contained in:
parent
678e052315
commit
3cead45934
1 changed files with 13 additions and 0 deletions
|
|
@ -18,6 +18,19 @@ mcp-forge injects tools using their **bare function name**, not the namespaced n
|
|||
|
||||
The pattern: strip any server prefix (e.g. `searxng_`, `rag-mcp_`) and use only the function name.
|
||||
|
||||
## Calling injected tools — keyword-only arguments
|
||||
|
||||
Injected tool functions are **keyword-only wrappers**. Always pass arguments by name:
|
||||
|
||||
```python
|
||||
# correct
|
||||
results = search(query="foo", language="en")
|
||||
page = fetch(url="https://example.com", max_chars=2000)
|
||||
|
||||
# wrong — positional args raise TypeError
|
||||
results = search("foo")
|
||||
```
|
||||
|
||||
## Injection syntax
|
||||
|
||||
Pass a JSON array of bare tool names to `mcp_tools`:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue