IAiSdkDocs

References
public interface IAiSdkDocs
Lookup service that surfaces Grasshopper2 SDK information to the model during code generation. Implementations are expected to be fast and in-process -- the model calls these tools multiple times per generation and tool latency directly extends the user's wait time.

Methods

GetExample

#
string GetExample(string topic)
Return a worked example for a named topic, or null if no example exists for that topic. Used for idiomatic patterns where the answer is "how do I do X in Grasshopper2?" rather than "what does symbol Y look like?".
topic (string)

LookupSymbol

#
AiDocHit[] LookupSymbol(string query, int max)
Return the top max matches for the query, ranked by relevance. Used for "does this symbol exist? what's its signature?" questions. An empty array means no match -- the model should treat that as a signal that it should not use the symbol it was about to.
query (string)
max (int)