The best way to control Claude Code, Codex and more from any computer or phone

main
ts 43 lines 1.33 KB
Raw
1 import type * as qapps from "@distilled.cloud/aws/qapps";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { QApp } from "./QApp.ts";
5
6 /**
7 * Request for {@link PredictQApp} — `instanceId` is injected from the bound Q App.
8 */
9 export interface PredictQAppRequest extends Omit<qapps.PredictQAppInput, "instanceId"> {}
10
11 /**
12 * Runtime binding for `qapps:PredictQApp`.
13 *
14 * Generates a Q App definition from a natural-language problem statement or a Q Business conversation. Provide the implementation with
15 * `Effect.provide(AWS.QApps.PredictQAppHttp)`.
16 * ### Generation
17 * **Example:** Generate an App Definition from a Prompt
18 * ```typescript
19 * // init — bind the operation to the Q App
20 * const predictQApp = yield* AWS.QApps.PredictQApp(app);
21 *
22 * // runtime
23 * const predicted = yield* predictQApp({
24 * options: {
25 * problemStatement: "Summarize meeting notes into action items",
26 * },
27 * });
28 * console.log(predicted.app.title);
29 * ```
30 *
31 * @binding
32 */
33 export interface PredictQApp extends Binding.Service<
34 PredictQApp,
35 "AWS.QApps.PredictQApp",
36 (
37 app: QApp,
38 ) => Effect.Effect<
39 (request?: PredictQAppRequest) => Effect.Effect<qapps.PredictQAppOutput, qapps.PredictQAppError>
40 >
41 > {}
42
43 export const PredictQApp = Binding.Service<PredictQApp>("AWS.QApps.PredictQApp");