You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: _versions/main/guides/assistant.adoc
+22-2Lines changed: 22 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -174,7 +174,17 @@ You can invoke the assistant from backend code using xref:dev-ui.adoc#communicat
174
174
175
175
==== JsonRPC against the Runtime classpath
176
176
177
-
To use the assistant in a xref:dev-ui.adoc#jsonrpc-against-the-runtime-classpath[`JsonRpcService`] on the runtime classpath, inject the `Assistant` like this:
177
+
To use the assistant in a xref:dev-ui.adoc#jsonrpc-against-the-runtime-classpath[`JsonRpcService`] on the runtime classpath, you need to make sure the `Assistant` interface is available:
178
+
179
+
[source,xml]
180
+
----
181
+
<dependency>
182
+
<groupId>io.quarkus</groupId>
183
+
<artifactId>quarkus-assistant-dev</artifactId>
184
+
</dependency>
185
+
----
186
+
187
+
Then you can inject the `Assistant` like this:
178
188
179
189
[source,java]
180
190
----
@@ -201,7 +211,17 @@ You can now use this assistant in any JsonRPC method, example:
201
211
202
212
==== JsonRPC against the Deployment classpath
203
213
204
-
In xref:dev-ui.adoc#jsonrpc-against-the-deployment-classpath[deployment-time] code, use the `BuildTimeActionBuildItem` and register assistant actions via `.addAssistantAction(...)`:
214
+
In xref:dev-ui.adoc#jsonrpc-against-the-deployment-classpath[deployment-time] code, you need to add the assistant-deployment-spi:
0 commit comments