docs: documentation for v0.1.0 [skip ci]

This commit is contained in:
Stevan Freeborn
2024-08-18 20:02:24 +00:00
parent 838e7ba859
commit a4a3379dc4
20 changed files with 1745 additions and 169 deletions
+84 -31
View File
@@ -153,6 +153,39 @@ Class Tool <a class="header-action link-secondary" title="View source" href="ht
</h2>
<a id="AnthropicClient_Models_Tool_CacheControl_" data-uid="AnthropicClient.Models.Tool.CacheControl*"></a>
<h3 id="AnthropicClient_Models_Tool_CacheControl" data-uid="AnthropicClient.Models.Tool.CacheControl">
CacheControl
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L61"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Gets or sets the cache control to be used for the tool.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">[JsonPropertyName(&quot;cache_control&quot;)]
public CacheControl? CacheControl { get; set; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd></dd>
</dl>
<a id="AnthropicClient_Models_Tool_Description_" data-uid="AnthropicClient.Models.Tool.Description*"></a>
<h3 id="AnthropicClient_Models_Tool_Description" data-uid="AnthropicClient.Models.Tool.Description">
@@ -189,7 +222,7 @@ Class Tool <a class="header-action link-secondary" title="View source" href="ht
<h3 id="AnthropicClient_Models_Tool_DisplayName" data-uid="AnthropicClient.Models.Tool.DisplayName">
DisplayName
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L61"><i class="bi bi-code-slash"></i></a>
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L67"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Gets the display name of the tool.</p>
@@ -322,9 +355,9 @@ public JsonObject InputSchema { get; }</code></pre>
<a id="AnthropicClient_Models_Tool_CreateFromClass_" data-uid="AnthropicClient.Models.Tool.CreateFromClass*"></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromClass__1" data-uid="AnthropicClient.Models.Tool.CreateFromClass``1">
CreateFromClass&lt;T&gt;()
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L102"><i class="bi bi-code-slash"></i></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromClass__1_AnthropicClient_Models_CacheControl_" data-uid="AnthropicClient.Models.Tool.CreateFromClass``1(AnthropicClient.Models.CacheControl)">
CreateFromClass&lt;T&gt;(CacheControl?)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L109"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Creates a tool from a type that implements <a class="xref" href="AnthropicClient.Models.ITool.html">ITool</a>.</p>
@@ -332,9 +365,14 @@ public JsonObject InputSchema { get; }</code></pre>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Tool CreateFromClass&lt;T&gt;() where T : ITool, new()</code></pre>
<pre><code class="lang-csharp hljs">public static Tool CreateFromClass&lt;T&gt;(CacheControl? cacheControl = null) where T : ITool, new()</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>cacheControl</code> <a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd></dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
@@ -355,7 +393,7 @@ public JsonObject InputSchema { get; }</code></pre>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromClass__1_remarks">Remarks</h4>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromClass__1_AnthropicClient_Models_CacheControl__remarks">Remarks</h4>
<div class="markdown level1 remarks"><p>The implementation of <a class="xref" href="AnthropicClient.Models.ITool.html">ITool</a> must have a parameterless constructor.</p>
</div>
@@ -373,9 +411,9 @@ public JsonObject InputSchema { get; }</code></pre>
<a id="AnthropicClient_Models_Tool_CreateFromFunction_" data-uid="AnthropicClient.Models.Tool.CreateFromFunction*"></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromFunction__1_System_String_System_String_System_Func___0__" data-uid="AnthropicClient.Models.Tool.CreateFromFunction``1(System.String,System.String,System.Func{``0})">
CreateFromFunction&lt;TResult&gt;(string, string, Func&lt;TResult&gt;)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L177"><i class="bi bi-code-slash"></i></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromFunction__1_System_String_System_String_System_Func___0__AnthropicClient_Models_CacheControl_" data-uid="AnthropicClient.Models.Tool.CreateFromFunction``1(System.String,System.String,System.Func{``0},AnthropicClient.Models.CacheControl)">
CreateFromFunction&lt;TResult&gt;(string, string, Func&lt;TResult&gt;, CacheControl?)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L199"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Creates a tool from a function.</p>
@@ -383,7 +421,7 @@ public JsonObject InputSchema { get; }</code></pre>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Tool CreateFromFunction&lt;TResult&gt;(string name, string description, Func&lt;TResult&gt; func)</code></pre>
<pre><code class="lang-csharp hljs">public static Tool CreateFromFunction&lt;TResult&gt;(string name, string description, Func&lt;TResult&gt; func, CacheControl? cacheControl = null)</code></pre>
</div>
<h4 class="section">Parameters</h4>
@@ -396,6 +434,9 @@ public JsonObject InputSchema { get; }</code></pre>
</dd>
<dt><code>func</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.func-1">Func</a>&lt;TResult&gt;</dt>
<dd><p>The function.</p>
</dd>
<dt><code>cacheControl</code> <a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd><p>The cache control to be used for the tool.</p>
</dd>
</dl>
@@ -418,7 +459,7 @@ public JsonObject InputSchema { get; }</code></pre>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromFunction__1_System_String_System_String_System_Func___0___remarks">Remarks</h4>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromFunction__1_System_String_System_String_System_Func___0__AnthropicClient_Models_CacheControl__remarks">Remarks</h4>
<div class="markdown level1 remarks"><p>The name of the tool will be sanitized to conform to the Anthropic tool naming rules.</p>
</div>
@@ -433,9 +474,9 @@ public JsonObject InputSchema { get; }</code></pre>
<a id="AnthropicClient_Models_Tool_CreateFromFunction_" data-uid="AnthropicClient.Models.Tool.CreateFromFunction*"></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromFunction__2_System_String_System_String_System_Func___0___1__" data-uid="AnthropicClient.Models.Tool.CreateFromFunction``2(System.String,System.String,System.Func{``0,``1})">
CreateFromFunction&lt;T1, TResult&gt;(string, string, Func&lt;T1, TResult&gt;)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L195"><i class="bi bi-code-slash"></i></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromFunction__2_System_String_System_String_System_Func___0___1__AnthropicClient_Models_CacheControl_" data-uid="AnthropicClient.Models.Tool.CreateFromFunction``2(System.String,System.String,System.Func{``0,``1},AnthropicClient.Models.CacheControl)">
CreateFromFunction&lt;T1, TResult&gt;(string, string, Func&lt;T1, TResult&gt;, CacheControl?)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L223"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Creates a tool from a function.</p>
@@ -443,7 +484,7 @@ public JsonObject InputSchema { get; }</code></pre>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Tool CreateFromFunction&lt;T1, TResult&gt;(string name, string description, Func&lt;T1, TResult&gt; func)</code></pre>
<pre><code class="lang-csharp hljs">public static Tool CreateFromFunction&lt;T1, TResult&gt;(string name, string description, Func&lt;T1, TResult&gt; func, CacheControl? cacheControl = null)</code></pre>
</div>
<h4 class="section">Parameters</h4>
@@ -456,6 +497,9 @@ public JsonObject InputSchema { get; }</code></pre>
</dd>
<dt><code>func</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.func-2">Func</a>&lt;T1, TResult&gt;</dt>
<dd><p>The function.</p>
</dd>
<dt><code>cacheControl</code> <a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd><p>The cache control to be used for the tool.</p>
</dd>
</dl>
@@ -481,7 +525,7 @@ public JsonObject InputSchema { get; }</code></pre>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromFunction__2_System_String_System_String_System_Func___0___1___remarks">Remarks</h4>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromFunction__2_System_String_System_String_System_Func___0___1__AnthropicClient_Models_CacheControl__remarks">Remarks</h4>
<div class="markdown level1 remarks"><p>The name of the tool will be sanitized to conform to the Anthropic tool naming rules.</p>
</div>
@@ -496,9 +540,9 @@ public JsonObject InputSchema { get; }</code></pre>
<a id="AnthropicClient_Models_Tool_CreateFromFunction_" data-uid="AnthropicClient.Models.Tool.CreateFromFunction*"></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromFunction__3_System_String_System_String_System_Func___0___1___2__" data-uid="AnthropicClient.Models.Tool.CreateFromFunction``3(System.String,System.String,System.Func{``0,``1,``2})">
CreateFromFunction&lt;T1, T2, TResult&gt;(string, string, Func&lt;T1, T2, TResult&gt;)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L214"><i class="bi bi-code-slash"></i></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromFunction__3_System_String_System_String_System_Func___0___1___2__AnthropicClient_Models_CacheControl_" data-uid="AnthropicClient.Models.Tool.CreateFromFunction``3(System.String,System.String,System.Func{``0,``1,``2},AnthropicClient.Models.CacheControl)">
CreateFromFunction&lt;T1, T2, TResult&gt;(string, string, Func&lt;T1, T2, TResult&gt;, CacheControl?)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L248"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Creates a tool from a function.</p>
@@ -506,7 +550,7 @@ public JsonObject InputSchema { get; }</code></pre>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Tool CreateFromFunction&lt;T1, T2, TResult&gt;(string name, string description, Func&lt;T1, T2, TResult&gt; func)</code></pre>
<pre><code class="lang-csharp hljs">public static Tool CreateFromFunction&lt;T1, T2, TResult&gt;(string name, string description, Func&lt;T1, T2, TResult&gt; func, CacheControl? cacheControl = null)</code></pre>
</div>
<h4 class="section">Parameters</h4>
@@ -519,6 +563,9 @@ public JsonObject InputSchema { get; }</code></pre>
</dd>
<dt><code>func</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.func-3">Func</a>&lt;T1, T2, TResult&gt;</dt>
<dd><p>The function.</p>
</dd>
<dt><code>cacheControl</code> <a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd><p>The cache control to be used for the tool.</p>
</dd>
</dl>
@@ -547,7 +594,7 @@ public JsonObject InputSchema { get; }</code></pre>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromFunction__3_System_String_System_String_System_Func___0___1___2___remarks">Remarks</h4>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromFunction__3_System_String_System_String_System_Func___0___1___2__AnthropicClient_Models_CacheControl__remarks">Remarks</h4>
<div class="markdown level1 remarks"><p>The name of the tool will be sanitized to conform to the Anthropic tool naming rules.</p>
</div>
@@ -562,9 +609,9 @@ public JsonObject InputSchema { get; }</code></pre>
<a id="AnthropicClient_Models_Tool_CreateFromInstanceMethod_" data-uid="AnthropicClient.Models.Tool.CreateFromInstanceMethod*"></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromInstanceMethod_System_String_System_String_System_Object_System_String_" data-uid="AnthropicClient.Models.Tool.CreateFromInstanceMethod(System.String,System.String,System.Object,System.String)">
CreateFromInstanceMethod(string, string, object, string)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L152"><i class="bi bi-code-slash"></i></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromInstanceMethod_System_String_System_String_System_Object_System_String_AnthropicClient_Models_CacheControl_" data-uid="AnthropicClient.Models.Tool.CreateFromInstanceMethod(System.String,System.String,System.Object,System.String,AnthropicClient.Models.CacheControl)">
CreateFromInstanceMethod(string, string, object, string, CacheControl?)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L167"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Creates a tool from an instance method.</p>
@@ -572,7 +619,7 @@ public JsonObject InputSchema { get; }</code></pre>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Tool CreateFromInstanceMethod(string name, string description, object instance, string methodName)</code></pre>
<pre><code class="lang-csharp hljs">public static Tool CreateFromInstanceMethod(string name, string description, object instance, string methodName, CacheControl? cacheControl = null)</code></pre>
</div>
<h4 class="section">Parameters</h4>
@@ -588,6 +635,9 @@ public JsonObject InputSchema { get; }</code></pre>
</dd>
<dt><code>methodName</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd><p>The name of the method.</p>
</dd>
<dt><code>cacheControl</code> <a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd><p>The cache control to be used for the tool.</p>
</dd>
</dl>
@@ -604,7 +654,7 @@ public JsonObject InputSchema { get; }</code></pre>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromInstanceMethod_System_String_System_String_System_Object_System_String__remarks">Remarks</h4>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromInstanceMethod_System_String_System_String_System_Object_System_String_AnthropicClient_Models_CacheControl__remarks">Remarks</h4>
<div class="markdown level1 remarks"><p>The name of the tool will be sanitized to conform to the Anthropic tool naming rules.</p>
</div>
@@ -625,9 +675,9 @@ public JsonObject InputSchema { get; }</code></pre>
<a id="AnthropicClient_Models_Tool_CreateFromStaticMethod_" data-uid="AnthropicClient.Models.Tool.CreateFromStaticMethod*"></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromStaticMethod_System_String_System_String_System_Type_System_String_" data-uid="AnthropicClient.Models.Tool.CreateFromStaticMethod(System.String,System.String,System.Type,System.String)">
CreateFromStaticMethod(string, string, Type, string)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L125"><i class="bi bi-code-slash"></i></a>
<h3 id="AnthropicClient_Models_Tool_CreateFromStaticMethod_System_String_System_String_System_Type_System_String_AnthropicClient_Models_CacheControl_" data-uid="AnthropicClient.Models.Tool.CreateFromStaticMethod(System.String,System.String,System.Type,System.String,AnthropicClient.Models.CacheControl)">
CreateFromStaticMethod(string, string, Type, string, CacheControl?)
<a class="header-action link-secondary" title="View source" href="https://github.com/StevanFreeborn/anthropic-client/blob/main/src/AnthropicClient/Models/Tool.cs/#L133"><i class="bi bi-code-slash"></i></a>
</h3>
<div class="markdown level1 summary"><p>Creates a tool from a static method.</p>
@@ -635,7 +685,7 @@ public JsonObject InputSchema { get; }</code></pre>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Tool CreateFromStaticMethod(string name, string description, Type type, string methodName)</code></pre>
<pre><code class="lang-csharp hljs">public static Tool CreateFromStaticMethod(string name, string description, Type type, string methodName, CacheControl? cacheControl = null)</code></pre>
</div>
<h4 class="section">Parameters</h4>
@@ -651,6 +701,9 @@ public JsonObject InputSchema { get; }</code></pre>
</dd>
<dt><code>methodName</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd><p>The name of the method.</p>
</dd>
<dt><code>cacheControl</code> <a class="xref" href="AnthropicClient.Models.CacheControl.html">CacheControl</a></dt>
<dd><p>The cache control to be used for the tool.</p>
</dd>
</dl>
@@ -667,7 +720,7 @@ public JsonObject InputSchema { get; }</code></pre>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromStaticMethod_System_String_System_String_System_Type_System_String__remarks">Remarks</h4>
<h4 class="section" id="AnthropicClient_Models_Tool_CreateFromStaticMethod_System_String_System_String_System_Type_System_String_AnthropicClient_Models_CacheControl__remarks">Remarks</h4>
<div class="markdown level1 remarks"><p>The name of the tool will be sanitized to conform to the Anthropic tool naming rules.</p>
</div>