Class Runs
java.lang.Object
com.alibaba.dashscope.legacy_2x.threads.runs.Runs
Deprecated.
The Assistants API (com.alibaba.dashscope.legacy_2x.threads.runs) is deprecated and
will be removed in a future release. Please migrate to the Responses API. See
https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.
-
Constructor Summary
ConstructorsConstructorDescriptionRuns()Deprecated.Runs(String baseUrl, ConnectionOptions connectionOptions) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.The Assistants API is deprecated and will be removed in a future release.io.reactivex.Flowable<AssistantStreamMessage>createStream(String threadId, RunParam param) Deprecated.The Assistants API is deprecated and will be removed in a future release.voidcreateStream(String threadId, RunParam param, AssistantEventHandler handler) Deprecated.The Assistants API is deprecated and will be removed in a future release.io.reactivex.Flowable<AssistantStreamMessage>Deprecated.The Assistants API is deprecated and will be removed in a future release.voidcreateStreamThreadAndRun(ThreadAndRunParam param, AssistantEventHandler handler) Deprecated.The Assistants API is deprecated and will be removed in a future release.Deprecated.The Assistants API is deprecated and will be removed in a future release.list(String threadId, GeneralListParam listParam) Deprecated.The Assistants API is deprecated and will be removed in a future release.listSteps(String threadId, String runId, GeneralListParam listParam) Deprecated.The Assistants API is deprecated and will be removed in a future release.Deprecated.The Assistants API is deprecated and will be removed in a future release.Deprecated.The Assistants API is deprecated and will be removed in a future release.Deprecated.The Assistants API is deprecated and will be removed in a future release.retrieveStep(String threadId, String runId, String stepId) Deprecated.The Assistants API is deprecated and will be removed in a future release.retrieveStep(String threadId, String runId, String stepId, String apiKey) Deprecated.The Assistants API is deprecated and will be removed in a future release.retrieveStep(String threadId, String runId, String stepId, String apiKey, Map<String, String> headers) Deprecated.The Assistants API is deprecated and will be removed in a future release.io.reactivex.Flowable<AssistantStreamMessage>submitStreamToolOutputs(String threadId, String runId, SubmitToolOutputsParam param) Deprecated.The Assistants API is deprecated and will be removed in a future release.voidsubmitStreamToolOutputs(String threadId, String runId, SubmitToolOutputsParam param, AssistantEventHandler handler) Deprecated.The Assistants API is deprecated and will be removed in a future release.submitToolOutputs(String threadId, String runId, SubmitToolOutputsParam param) Deprecated.The Assistants API is deprecated and will be removed in a future release.update(String threadId, String runId, UpdateMetadataParam param) Deprecated.The Assistants API is deprecated and will be removed in a future release.
-
Constructor Details
-
Runs
public Runs()Deprecated. -
Runs
Deprecated.
-
-
Method Details
-
create
@Deprecated public Run create(String threadId, RunParam param) throws ApiException, NoApiKeyException, InputRequiredException, InvalidateParameter Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Create a thread run.- Parameters:
threadId- The thread id.param- The `RunParam`- Returns:
- The `Run` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInputRequiredException- The threadId must input.InvalidateParameter- The input parameter is invalid.
-
createStream
@Deprecated public io.reactivex.Flowable<AssistantStreamMessage> createStream(String threadId, RunParam param) throws ApiException, NoApiKeyException, InputRequiredException, InvalidateParameter Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Create stream run, return Flowable of StreamMessage.- Parameters:
threadId- The run thread idparam- The run parameters.- Returns:
- The StreamMessage flowable.
- Throws:
ApiException- The request failed.NoApiKeyException- No api key found.InputRequiredException- The threadId is null or empty.InvalidateParameter- The stream in param is false.
-
createStream
@Deprecated public void createStream(String threadId, RunParam param, AssistantEventHandler handler) throws ApiException, NoApiKeyException, InputRequiredException, InvalidateParameter Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Create stream run, with event handler.- Parameters:
threadId- The run thread idparam- The run parameters.handler- The assistant event handler.- Throws:
ApiException- The request failed.NoApiKeyException- No api key found.InputRequiredException- The threadId is null or empty.InvalidateParameter- The stream in param is false.
-
createThreadAndRun
@Deprecated public Run createThreadAndRun(ThreadAndRunParam param) throws ApiException, NoApiKeyException, InvalidateParameter Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Create thread and run.- Parameters:
param- The `ThreadAndRunParam` object.- Returns:
- The `Run` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInvalidateParameter- The input parameter is invalid.
-
createStreamThreadAndRun
@Deprecated public io.reactivex.Flowable<AssistantStreamMessage> createStreamThreadAndRun(ThreadAndRunParam param) throws ApiException, NoApiKeyException, InvalidateParameter Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Create stream output and run.- Parameters:
param- The `ThreadAndRunParam` object with stream=true.- Returns:
- Flowable of AssistantStreamMessage you can iterator the result.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInvalidateParameter- The input parameter is invalid.
-
createStreamThreadAndRun
@Deprecated public void createStreamThreadAndRun(ThreadAndRunParam param, AssistantEventHandler handler) throws ApiException, NoApiKeyException, InvalidateParameter Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Create stream output and run.- Parameters:
param- The `ThreadAndRunParam` object with stream=true.handler- The stream event handler callback.- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInvalidateParameter- The input parameter is invalid.
-
update
@Deprecated public Run update(String threadId, String runId, UpdateMetadataParam param) throws ApiException, NoApiKeyException, InputRequiredException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Update the run.- Parameters:
threadId- The thread id.runId- The run id.param- The parameter.- Returns:
- The updated `Run` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInputRequiredException- The thread id and run id are required.
-
list
@Deprecated public ListResult<Run> list(String threadId, GeneralListParam listParam) throws ApiException, NoApiKeyException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.List the run of thread id.- Parameters:
threadId- the thread id.listParam- The list parameter.- Returns:
- The list of `Run`.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api key
-
listSteps
@Deprecated public ListResult<RunStep> listSteps(String threadId, String runId, GeneralListParam listParam) throws ApiException, NoApiKeyException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.List the run step of the run id.- Parameters:
threadId- The thread idrunId- The run id.listParam- The list parameter.- Returns:
- The list of 'RunStep'
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api key
-
retrieve
@Deprecated public Run retrieve(String threadId, String runId) throws ApiException, NoApiKeyException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Retrieve the run.- Parameters:
threadId- The thread id.runId- The run id.- Returns:
- The `Run` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api key
-
retrieve
@Deprecated public Run retrieve(String threadId, String runId, String apiKey) throws ApiException, NoApiKeyException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Retrieve the run.- Parameters:
threadId- The thread id.runId- The run id.apiKey- The request api key.- Returns:
- The `Run` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api key
-
retrieve
@Deprecated public Run retrieve(String threadId, String runId, String apiKey, Map<String, String> headers) throws ApiException, NoApiKeyExceptionDeprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.- Throws:
ApiExceptionNoApiKeyException
-
retrieveStep
@Deprecated public RunStep retrieveStep(String threadId, String runId, String stepId) throws ApiException, NoApiKeyException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Retrieve the run step.- Parameters:
threadId- The thread id.runId- The run id.stepId- the run step id.- Returns:
- The `RunStep` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api key
-
retrieveStep
@Deprecated public RunStep retrieveStep(String threadId, String runId, String stepId, String apiKey) throws ApiException, NoApiKeyException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Retrieve the run step.- Parameters:
threadId- The thread id.runId- The run id.stepId- the run step id.apiKey- The request api key.- Returns:
- The `RunStep` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api key
-
retrieveStep
@Deprecated public RunStep retrieveStep(String threadId, String runId, String stepId, String apiKey, Map<String, String> headers) throws ApiException, NoApiKeyExceptionDeprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.- Throws:
ApiExceptionNoApiKeyException
-
submitToolOutputs
@Deprecated public Run submitToolOutputs(String threadId, String runId, SubmitToolOutputsParam param) throws ApiException, NoApiKeyException, InputRequiredException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Submit tool outputs.- Parameters:
threadId- The thread id.runId- The run id.param- The output parameters.- Returns:
- The `Run` object.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInputRequiredException- The thread id and run id must input.
-
submitStreamToolOutputs
@Deprecated public io.reactivex.Flowable<AssistantStreamMessage> submitStreamToolOutputs(String threadId, String runId, SubmitToolOutputsParam param) throws ApiException, NoApiKeyException, InputRequiredException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Submit tool outputs, and return stream result.- Parameters:
threadId- The thread id.runId- The run id.param- The output parameters.- Returns:
- The stream assistant stream messages.
- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInputRequiredException- The thread id and run id must input.
-
submitStreamToolOutputs
@Deprecated public void submitStreamToolOutputs(String threadId, String runId, SubmitToolOutputsParam param, AssistantEventHandler handler) throws ApiException, NoApiKeyException, InputRequiredException Deprecated.The Assistants API is deprecated and will be removed in a future release. Please migrate to the Responses API. See https://help.aliyun.com/zh/model-studio/synchronous-call-api-reference for migration details.Submit tool outputs, and return stream result.- Parameters:
threadId- The thread id.runId- The run id.param- The output parameters.handler- The stream event handler callback.- Throws:
ApiException- The request exception, if network connection issue etc.NoApiKeyException- Can not find a valid api keyInputRequiredException- The thread id and run id must input.
-