docs: add keyword-only args note to mcp-forge-conventions skill

This commit is contained in:
Hans Aschauer 2026-04-21 19:45:44 +02:00
parent 678e052315
commit 3cead45934

View file

@ -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`: