Function render
-
Parameters
- value: Rendered
Any result a memory operation returns.
Optionalprefix: stringWhat the tools a model was offered start with, as given to Session.tools. Leave it out to keep the service's text as written.
Returns string
The result as text.
- value: Rendered
Render an operation's result as text a model can read.
Every result carries Instructions — the service's own guidance on what to do with what came back — and that is included, because a model that never sees it is left to guess.
These results are interfaces, which have no run-time identity, so the dispatch here is on the field only one of them carries.
outcomeis tested beforeoperationIdbecause a revert carries both.The service's guidance names tools. Given a prefix, it is rewritten to name them as the prefix spells them; without one it is left as written. What a memory says is never rewritten.