Scriptwriting for film, television, and interactive entertainment, including script development.
Operation description
You can input basic script requirements to generate a script synopsis and brief shot descriptions. This feature helps editors quickly create a script framework.
Try it now
You can run this API directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After a successful run, OpenAPI Explorer can automatically generate SDK code examples.
Try it
Authorization information
The following table describes the authorization information of the API. You can use the Action element in RAM permission policy statements to grant RAM users or RAM roles the permission to call this API. Details are as follows:
- Operation: the specific permission point.
- Access level: the access level of each operation. Valid values: Write, Read, or List.
-
Resource type: the resource types that support authorization in the operation. Details are as follows:
- For required resource types, an asterisk (*) is prefixed.
- For operations that do not support resource-level authorization, All Resources is used.
- Condition key: the condition keys defined by the cloud service itself.
- Dependent action: other permissions required to successfully perform the operation. The caller must also have the permissions of the dependent actions for the operation to succeed.
| Operation | Access level | Resource type | Condition key | Dependent action |
|---|---|---|---|---|
| quanmiaolightapp:RunScriptPlanning | none | *All Resources * |
| None |
Request syntax
Request parameters
| Name | Type | Required | Description | Example value |
|---|---|---|---|---|
| workspaceId | string | Yes | Unique identifier of an Alibaba Cloud Model Studio workspace. For more information, see workspace ID. | llm-e9zzbkg0aj2mlXX |
| scriptName | string | No | Script name entered in natural language. | Urban War God |
| scriptTypeKeyword | string | No | Script type keyword: users can provide a qualitative description of the script type, such as alternate history, sci-fi, romance, or fantasy. | Modern, Urban, Romance, Fantasy |
| scriptSummary | string | Yes | Script synopsis: a brief story description that the user provides for the script. | In a quiet little town, every household receives a mysterious, unmarked package on the same day. |
| scriptShotCount | integer | No | Number of script shots: users can define the number of shot descriptions to generate within a single script. Value range: 1 to 10. | 3 |
| dialogueInScene | boolean | No | Whether specific shot dialogues are needed. Default value: false. | |
| plotConflict | boolean | No | Readability: users can choose whether to add plot conflicts and twist elements to the planning content. If selected, they are automatically generated in the plot. | |
| additionalNote | string | No | Additional notes: users can make open-ended adjustments by entering natural language descriptions in the text box, such as adding descriptions of tense and thrilling moments, to fine-tune the output. | Make the story as melodramatic as possible |
Response parameters
| Name | Type | Description | Example value |
|---|---|---|---|
| object | Schema of Response | ||
| end | boolean | Whether the output is complete. true indicates completion. | |
| header | object | Streaming output header, containing general return information. | |
| errorCode | string | Abnormal error code. | 403 |
| errorMessage | string | Abnormal error message. | Pop sign mismatch, please check. |
| event | string | Event type. | result-generated |
| eventInfo | string | Event description. | Model generation event |
| requestId | string | Request ID. | 0EB27AE3-CA53-5FAE-83C6-EE66CA4DF5DF |
| sessionId | string | Session ID. | 3cd10828-0e42-471c-8f1a-931cde20b035 |
| taskId | string | Generation task ID. | d3be9981-ca2d-4e17-bf31-1c0a628e9f99 |
| traceId | string | Trace ID. | 2150451a17191950923411783e2927 |
| payload | object | Payload of the returned result, in JSON structure. | |
| output | object | Output content object. | |
| text | string | Output content. | This is test output |
| usage | object | LLM token usage information. | |
| inputTokens | long | Number of input tokens. | 100 |
| outputTokens | long | Number of output tokens. | 100 |
| totalTokens | long | Total number of tokens. | 200 |
Examples
Success response
JSON format
Error codes
| HTTP status code | Error code | Error message | Description |
|---|---|---|---|
| 403 | NoPermission | You are not authorized to perform this action , Please check the assignment of the workspaceId. | Check the assignment of the workspaceId. |