Skip to content

Commit 48c7ed7

Browse files
committed
update doc
1 parent 78f6275 commit 48c7ed7

File tree

2 files changed

+39
-1
lines changed

2 files changed

+39
-1
lines changed

integration/mcp/src/main/kotlin/com/javaaidev/easyllmtools/integration/mcp/McpToolHelper.java

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,31 @@
1313
import java.util.Map;
1414
import reactor.core.publisher.Mono;
1515

16+
/**
17+
* Helper class for integration with MCP
18+
*/
1619
public class McpToolHelper {
1720

1821
private final ToolInvoker toolInvoker = new ToolInvoker();
1922

23+
/**
24+
* Convert a tool to MCP sync tool
25+
*
26+
* @param tool Tool
27+
* @return MCP sync tool
28+
*/
2029
public McpServerFeatures.SyncToolSpecification toSyncTool(Tool tool) {
2130
return new SyncToolSpecification(
2231
fromTool(tool), (exchange, args) -> callTool(tool, args)
2332
);
2433
}
2534

35+
/**
36+
* Convert a tool to MCP async tool
37+
*
38+
* @param tool Tool
39+
* @return MCP async tool
40+
*/
2641
public McpServerFeatures.AsyncToolSpecification toAsyncTool(Tool tool) {
2742
return new AsyncToolSpecification(
2843
fromTool(tool),

pom.xml

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
<execution>
187187
<phase>package</phase>
188188
<goals>
189-
<goal>javadocJar</goal>
189+
<goal>dokka</goal>
190190
</goals>
191191
</execution>
192192
</executions>
@@ -199,6 +199,25 @@
199199
</pluginsConfiguration>
200200
</configuration>
201201
</plugin>
202+
<plugin>
203+
<groupId>org.apache.maven.plugins</groupId>
204+
<artifactId>maven-jar-plugin</artifactId>
205+
<version>3.3.0</version>
206+
<executions>
207+
<execution>
208+
<id>dokka-jar</id>
209+
<phase>package</phase>
210+
<goals>
211+
<goal>jar</goal>
212+
</goals>
213+
<configuration>
214+
<classifier>javadoc</classifier>
215+
<classesDirectory>${project.build.directory}/dokka</classesDirectory>
216+
<skipIfEmpty>true</skipIfEmpty>
217+
</configuration>
218+
</execution>
219+
</executions>
220+
</plugin>
202221
<plugin>
203222
<groupId>org.apache.maven.plugins</groupId>
204223
<artifactId>maven-gpg-plugin</artifactId>
@@ -246,6 +265,10 @@
246265
<groupId>org.jetbrains.dokka</groupId>
247266
<artifactId>dokka-maven-plugin</artifactId>
248267
</plugin>
268+
<plugin>
269+
<groupId>org.apache.maven.plugins</groupId>
270+
<artifactId>maven-jar-plugin</artifactId>
271+
</plugin>
249272
<plugin>
250273
<groupId>org.apache.maven.plugins</groupId>
251274
<artifactId>maven-gpg-plugin</artifactId>

0 commit comments

Comments
 (0)