docs(api): fix backwards send_result claim — send() is canonical

product-guidelines.md claimed send_result() was canonical and send()
was removed. The reverse is true: send() is the live public API
returning Result[str, ErrorInfo]; send_result exists only as a local
var in _send_gemini_cli. Corrected the section and added a
reconciliation note. Also fixed guide_ai_client.md send() signature
to show -> Result[str] instead of -> str.
This commit is contained in:
ed
2026-07-02 18:55:20 -04:00
parent f463edf93d
commit 3ff759ad66
2 changed files with 19 additions and 8 deletions
+2 -2
View File
@@ -106,10 +106,10 @@ def send(
stream_callback: Optional[Callable] = None,
patch_callback: Optional[Callable] = None,
rag_engine: Optional[Any] = None,
) -> str:
) -> Result[str]:
```
Returns the model's response as a string. All provider calls go through here.
Returns the model's response as a `Result[str, ErrorInfo]` (the data-oriented error type from `src/result_types.py`). Check `result.ok` for success; on failure, `result.errors` holds `ErrorInfo` instances with classified `ErrorKind`. All provider calls go through here.
**Parameters:**
- `md_content` — the system prompt + context (markdown)