@quantcdn/pulumi-quant 0.1.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/aiGovernance.ts +183 -0
- package/aiSkill.ts +197 -0
- package/aiVectorCollection.ts +119 -0
- package/aiVectorDocument.ts +180 -0
- package/crawler.ts +9 -0
- package/crawlerSchedule.ts +6 -6
- package/index.ts +28 -0
- package/package.json +2 -2
- package/project.ts +18 -0
- package/ruleContentFilter.ts +42 -0
- package/ruleCustomResponse.ts +42 -0
- package/ruleFunction.ts +42 -0
- package/ruleProxy.ts +42 -0
- package/ruleRedirect.ts +42 -0
- package/tsconfig.json +4 -0
- package/types/input.ts +46 -0
- package/types/output.ts +46 -0
package/aiGovernance.ts
ADDED
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
2
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
3
|
+
|
|
4
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
5
|
+
import * as inputs from "./types/input";
|
|
6
|
+
import * as outputs from "./types/output";
|
|
7
|
+
import * as utilities from "./utilities";
|
|
8
|
+
|
|
9
|
+
export class AiGovernance extends pulumi.CustomResource {
|
|
10
|
+
/**
|
|
11
|
+
* Get an existing AiGovernance resource's state with the given name, ID, and optional extra
|
|
12
|
+
* properties used to qualify the lookup.
|
|
13
|
+
*
|
|
14
|
+
* @param name The _unique_ name of the resulting resource.
|
|
15
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
16
|
+
* @param state Any extra arguments used during the lookup.
|
|
17
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
18
|
+
*/
|
|
19
|
+
public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AiGovernanceState, opts?: pulumi.CustomResourceOptions): AiGovernance {
|
|
20
|
+
return new AiGovernance(name, <any>state, { ...opts, id: id });
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
public static readonly __pulumiType = 'quant:index:AiGovernance';
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Returns true if the given object is an instance of AiGovernance. This is designed to work even
|
|
28
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
29
|
+
*/
|
|
30
|
+
public static isInstance(obj: any): obj is AiGovernance {
|
|
31
|
+
if (obj === undefined || obj === null) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return obj['__pulumiType'] === AiGovernance.__pulumiType;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Whether AI features are enabled for the organization
|
|
39
|
+
*/
|
|
40
|
+
declare public readonly aiEnabled: pulumi.Output<boolean>;
|
|
41
|
+
/**
|
|
42
|
+
* List of mandatory content filter policy identifiers
|
|
43
|
+
*/
|
|
44
|
+
declare public readonly mandatoryFilterPolicies: pulumi.Output<string[] | undefined>;
|
|
45
|
+
/**
|
|
46
|
+
* Mandatory guardrail preset to enforce on all AI requests
|
|
47
|
+
*/
|
|
48
|
+
declare public readonly mandatoryGuardrailPreset: pulumi.Output<string | undefined>;
|
|
49
|
+
/**
|
|
50
|
+
* List of model identifiers for the allowlist or blocklist policy
|
|
51
|
+
*/
|
|
52
|
+
declare public readonly modelLists: pulumi.Output<string[] | undefined>;
|
|
53
|
+
/**
|
|
54
|
+
* Model access policy: `unrestricted`, `allowlist`, or `blocklist`
|
|
55
|
+
*/
|
|
56
|
+
declare public readonly modelPolicy: pulumi.Output<string>;
|
|
57
|
+
/**
|
|
58
|
+
* Organization machine name (defaults to provider organization)
|
|
59
|
+
*/
|
|
60
|
+
declare public readonly organization: pulumi.Output<string>;
|
|
61
|
+
/**
|
|
62
|
+
* Spend limit configuration for AI usage
|
|
63
|
+
*/
|
|
64
|
+
declare public readonly spendLimits: pulumi.Output<outputs.AiGovernanceSpendLimits | undefined>;
|
|
65
|
+
/**
|
|
66
|
+
* Configuration version for optimistic concurrency control
|
|
67
|
+
*/
|
|
68
|
+
declare public /*out*/ readonly version: pulumi.Output<number>;
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* Create a AiGovernance resource with the given unique name, arguments, and options.
|
|
72
|
+
*
|
|
73
|
+
* @param name The _unique_ name of the resource.
|
|
74
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
75
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
76
|
+
*/
|
|
77
|
+
constructor(name: string, args: AiGovernanceArgs, opts?: pulumi.CustomResourceOptions)
|
|
78
|
+
constructor(name: string, argsOrState?: AiGovernanceArgs | AiGovernanceState, opts?: pulumi.CustomResourceOptions) {
|
|
79
|
+
let resourceInputs: pulumi.Inputs = {};
|
|
80
|
+
opts = opts || {};
|
|
81
|
+
if (opts.id) {
|
|
82
|
+
const state = argsOrState as AiGovernanceState | undefined;
|
|
83
|
+
resourceInputs["aiEnabled"] = state?.aiEnabled;
|
|
84
|
+
resourceInputs["mandatoryFilterPolicies"] = state?.mandatoryFilterPolicies;
|
|
85
|
+
resourceInputs["mandatoryGuardrailPreset"] = state?.mandatoryGuardrailPreset;
|
|
86
|
+
resourceInputs["modelLists"] = state?.modelLists;
|
|
87
|
+
resourceInputs["modelPolicy"] = state?.modelPolicy;
|
|
88
|
+
resourceInputs["organization"] = state?.organization;
|
|
89
|
+
resourceInputs["spendLimits"] = state?.spendLimits;
|
|
90
|
+
resourceInputs["version"] = state?.version;
|
|
91
|
+
} else {
|
|
92
|
+
const args = argsOrState as AiGovernanceArgs | undefined;
|
|
93
|
+
if (args?.aiEnabled === undefined && !opts.urn) {
|
|
94
|
+
throw new Error("Missing required property 'aiEnabled'");
|
|
95
|
+
}
|
|
96
|
+
if (args?.modelPolicy === undefined && !opts.urn) {
|
|
97
|
+
throw new Error("Missing required property 'modelPolicy'");
|
|
98
|
+
}
|
|
99
|
+
resourceInputs["aiEnabled"] = args?.aiEnabled;
|
|
100
|
+
resourceInputs["mandatoryFilterPolicies"] = args?.mandatoryFilterPolicies;
|
|
101
|
+
resourceInputs["mandatoryGuardrailPreset"] = args?.mandatoryGuardrailPreset;
|
|
102
|
+
resourceInputs["modelLists"] = args?.modelLists;
|
|
103
|
+
resourceInputs["modelPolicy"] = args?.modelPolicy;
|
|
104
|
+
resourceInputs["organization"] = args?.organization;
|
|
105
|
+
resourceInputs["spendLimits"] = args?.spendLimits;
|
|
106
|
+
resourceInputs["version"] = undefined /*out*/;
|
|
107
|
+
}
|
|
108
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
109
|
+
super(AiGovernance.__pulumiType, name, resourceInputs, opts);
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Input properties used for looking up and filtering AiGovernance resources.
|
|
115
|
+
*/
|
|
116
|
+
export interface AiGovernanceState {
|
|
117
|
+
/**
|
|
118
|
+
* Whether AI features are enabled for the organization
|
|
119
|
+
*/
|
|
120
|
+
aiEnabled?: pulumi.Input<boolean>;
|
|
121
|
+
/**
|
|
122
|
+
* List of mandatory content filter policy identifiers
|
|
123
|
+
*/
|
|
124
|
+
mandatoryFilterPolicies?: pulumi.Input<pulumi.Input<string>[]>;
|
|
125
|
+
/**
|
|
126
|
+
* Mandatory guardrail preset to enforce on all AI requests
|
|
127
|
+
*/
|
|
128
|
+
mandatoryGuardrailPreset?: pulumi.Input<string>;
|
|
129
|
+
/**
|
|
130
|
+
* List of model identifiers for the allowlist or blocklist policy
|
|
131
|
+
*/
|
|
132
|
+
modelLists?: pulumi.Input<pulumi.Input<string>[]>;
|
|
133
|
+
/**
|
|
134
|
+
* Model access policy: `unrestricted`, `allowlist`, or `blocklist`
|
|
135
|
+
*/
|
|
136
|
+
modelPolicy?: pulumi.Input<string>;
|
|
137
|
+
/**
|
|
138
|
+
* Organization machine name (defaults to provider organization)
|
|
139
|
+
*/
|
|
140
|
+
organization?: pulumi.Input<string>;
|
|
141
|
+
/**
|
|
142
|
+
* Spend limit configuration for AI usage
|
|
143
|
+
*/
|
|
144
|
+
spendLimits?: pulumi.Input<inputs.AiGovernanceSpendLimits>;
|
|
145
|
+
/**
|
|
146
|
+
* Configuration version for optimistic concurrency control
|
|
147
|
+
*/
|
|
148
|
+
version?: pulumi.Input<number>;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* The set of arguments for constructing a AiGovernance resource.
|
|
153
|
+
*/
|
|
154
|
+
export interface AiGovernanceArgs {
|
|
155
|
+
/**
|
|
156
|
+
* Whether AI features are enabled for the organization
|
|
157
|
+
*/
|
|
158
|
+
aiEnabled: pulumi.Input<boolean>;
|
|
159
|
+
/**
|
|
160
|
+
* List of mandatory content filter policy identifiers
|
|
161
|
+
*/
|
|
162
|
+
mandatoryFilterPolicies?: pulumi.Input<pulumi.Input<string>[]>;
|
|
163
|
+
/**
|
|
164
|
+
* Mandatory guardrail preset to enforce on all AI requests
|
|
165
|
+
*/
|
|
166
|
+
mandatoryGuardrailPreset?: pulumi.Input<string>;
|
|
167
|
+
/**
|
|
168
|
+
* List of model identifiers for the allowlist or blocklist policy
|
|
169
|
+
*/
|
|
170
|
+
modelLists?: pulumi.Input<pulumi.Input<string>[]>;
|
|
171
|
+
/**
|
|
172
|
+
* Model access policy: `unrestricted`, `allowlist`, or `blocklist`
|
|
173
|
+
*/
|
|
174
|
+
modelPolicy: pulumi.Input<string>;
|
|
175
|
+
/**
|
|
176
|
+
* Organization machine name (defaults to provider organization)
|
|
177
|
+
*/
|
|
178
|
+
organization?: pulumi.Input<string>;
|
|
179
|
+
/**
|
|
180
|
+
* Spend limit configuration for AI usage
|
|
181
|
+
*/
|
|
182
|
+
spendLimits?: pulumi.Input<inputs.AiGovernanceSpendLimits>;
|
|
183
|
+
}
|
package/aiSkill.ts
ADDED
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
2
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
3
|
+
|
|
4
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
5
|
+
import * as inputs from "./types/input";
|
|
6
|
+
import * as outputs from "./types/output";
|
|
7
|
+
import * as utilities from "./utilities";
|
|
8
|
+
|
|
9
|
+
export class AiSkill extends pulumi.CustomResource {
|
|
10
|
+
/**
|
|
11
|
+
* Get an existing AiSkill resource's state with the given name, ID, and optional extra
|
|
12
|
+
* properties used to qualify the lookup.
|
|
13
|
+
*
|
|
14
|
+
* @param name The _unique_ name of the resulting resource.
|
|
15
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
16
|
+
* @param state Any extra arguments used during the lookup.
|
|
17
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
18
|
+
*/
|
|
19
|
+
public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AiSkillState, opts?: pulumi.CustomResourceOptions): AiSkill {
|
|
20
|
+
return new AiSkill(name, <any>state, { ...opts, id: id });
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
public static readonly __pulumiType = 'quant:index:AiSkill';
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Returns true if the given object is an instance of AiSkill. This is designed to work even
|
|
28
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
29
|
+
*/
|
|
30
|
+
public static isInstance(obj: any): obj is AiSkill {
|
|
31
|
+
if (obj === undefined || obj === null) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return obj['__pulumiType'] === AiSkill.__pulumiType;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Inline skill content. Conflicts with `source`.
|
|
39
|
+
*/
|
|
40
|
+
declare public readonly content: pulumi.Output<string | undefined>;
|
|
41
|
+
/**
|
|
42
|
+
* Skill description
|
|
43
|
+
*/
|
|
44
|
+
declare public readonly description: pulumi.Output<string | undefined>;
|
|
45
|
+
/**
|
|
46
|
+
* Timestamp when the skill was installed
|
|
47
|
+
*/
|
|
48
|
+
declare public /*out*/ readonly installedAt: pulumi.Output<string>;
|
|
49
|
+
/**
|
|
50
|
+
* Skill name
|
|
51
|
+
*/
|
|
52
|
+
declare public readonly name: pulumi.Output<string>;
|
|
53
|
+
/**
|
|
54
|
+
* Skill namespace
|
|
55
|
+
*/
|
|
56
|
+
declare public /*out*/ readonly namespace: pulumi.Output<string>;
|
|
57
|
+
/**
|
|
58
|
+
* Organization machine name (defaults to provider organization)
|
|
59
|
+
*/
|
|
60
|
+
declare public readonly organization: pulumi.Output<string>;
|
|
61
|
+
/**
|
|
62
|
+
* External source for importing a skill. Conflicts with `content`.
|
|
63
|
+
*/
|
|
64
|
+
declare public readonly source: pulumi.Output<outputs.AiSkillSource | undefined>;
|
|
65
|
+
/**
|
|
66
|
+
* Tags for categorizing the skill
|
|
67
|
+
*/
|
|
68
|
+
declare public readonly tags: pulumi.Output<string[] | undefined>;
|
|
69
|
+
/**
|
|
70
|
+
* Condition that triggers the skill
|
|
71
|
+
*/
|
|
72
|
+
declare public readonly triggerCondition: pulumi.Output<string | undefined>;
|
|
73
|
+
/**
|
|
74
|
+
* Timestamp when the skill was last updated
|
|
75
|
+
*/
|
|
76
|
+
declare public /*out*/ readonly updatedAt: pulumi.Output<string>;
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Create a AiSkill resource with the given unique name, arguments, and options.
|
|
80
|
+
*
|
|
81
|
+
* @param name The _unique_ name of the resource.
|
|
82
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
83
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
84
|
+
*/
|
|
85
|
+
constructor(name: string, args?: AiSkillArgs, opts?: pulumi.CustomResourceOptions)
|
|
86
|
+
constructor(name: string, argsOrState?: AiSkillArgs | AiSkillState, opts?: pulumi.CustomResourceOptions) {
|
|
87
|
+
let resourceInputs: pulumi.Inputs = {};
|
|
88
|
+
opts = opts || {};
|
|
89
|
+
if (opts.id) {
|
|
90
|
+
const state = argsOrState as AiSkillState | undefined;
|
|
91
|
+
resourceInputs["content"] = state?.content;
|
|
92
|
+
resourceInputs["description"] = state?.description;
|
|
93
|
+
resourceInputs["installedAt"] = state?.installedAt;
|
|
94
|
+
resourceInputs["name"] = state?.name;
|
|
95
|
+
resourceInputs["namespace"] = state?.namespace;
|
|
96
|
+
resourceInputs["organization"] = state?.organization;
|
|
97
|
+
resourceInputs["source"] = state?.source;
|
|
98
|
+
resourceInputs["tags"] = state?.tags;
|
|
99
|
+
resourceInputs["triggerCondition"] = state?.triggerCondition;
|
|
100
|
+
resourceInputs["updatedAt"] = state?.updatedAt;
|
|
101
|
+
} else {
|
|
102
|
+
const args = argsOrState as AiSkillArgs | undefined;
|
|
103
|
+
resourceInputs["content"] = args?.content;
|
|
104
|
+
resourceInputs["description"] = args?.description;
|
|
105
|
+
resourceInputs["name"] = args?.name;
|
|
106
|
+
resourceInputs["organization"] = args?.organization;
|
|
107
|
+
resourceInputs["source"] = args?.source;
|
|
108
|
+
resourceInputs["tags"] = args?.tags;
|
|
109
|
+
resourceInputs["triggerCondition"] = args?.triggerCondition;
|
|
110
|
+
resourceInputs["installedAt"] = undefined /*out*/;
|
|
111
|
+
resourceInputs["namespace"] = undefined /*out*/;
|
|
112
|
+
resourceInputs["updatedAt"] = undefined /*out*/;
|
|
113
|
+
}
|
|
114
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
115
|
+
super(AiSkill.__pulumiType, name, resourceInputs, opts);
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Input properties used for looking up and filtering AiSkill resources.
|
|
121
|
+
*/
|
|
122
|
+
export interface AiSkillState {
|
|
123
|
+
/**
|
|
124
|
+
* Inline skill content. Conflicts with `source`.
|
|
125
|
+
*/
|
|
126
|
+
content?: pulumi.Input<string>;
|
|
127
|
+
/**
|
|
128
|
+
* Skill description
|
|
129
|
+
*/
|
|
130
|
+
description?: pulumi.Input<string>;
|
|
131
|
+
/**
|
|
132
|
+
* Timestamp when the skill was installed
|
|
133
|
+
*/
|
|
134
|
+
installedAt?: pulumi.Input<string>;
|
|
135
|
+
/**
|
|
136
|
+
* Skill name
|
|
137
|
+
*/
|
|
138
|
+
name?: pulumi.Input<string>;
|
|
139
|
+
/**
|
|
140
|
+
* Skill namespace
|
|
141
|
+
*/
|
|
142
|
+
namespace?: pulumi.Input<string>;
|
|
143
|
+
/**
|
|
144
|
+
* Organization machine name (defaults to provider organization)
|
|
145
|
+
*/
|
|
146
|
+
organization?: pulumi.Input<string>;
|
|
147
|
+
/**
|
|
148
|
+
* External source for importing a skill. Conflicts with `content`.
|
|
149
|
+
*/
|
|
150
|
+
source?: pulumi.Input<inputs.AiSkillSource>;
|
|
151
|
+
/**
|
|
152
|
+
* Tags for categorizing the skill
|
|
153
|
+
*/
|
|
154
|
+
tags?: pulumi.Input<pulumi.Input<string>[]>;
|
|
155
|
+
/**
|
|
156
|
+
* Condition that triggers the skill
|
|
157
|
+
*/
|
|
158
|
+
triggerCondition?: pulumi.Input<string>;
|
|
159
|
+
/**
|
|
160
|
+
* Timestamp when the skill was last updated
|
|
161
|
+
*/
|
|
162
|
+
updatedAt?: pulumi.Input<string>;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* The set of arguments for constructing a AiSkill resource.
|
|
167
|
+
*/
|
|
168
|
+
export interface AiSkillArgs {
|
|
169
|
+
/**
|
|
170
|
+
* Inline skill content. Conflicts with `source`.
|
|
171
|
+
*/
|
|
172
|
+
content?: pulumi.Input<string>;
|
|
173
|
+
/**
|
|
174
|
+
* Skill description
|
|
175
|
+
*/
|
|
176
|
+
description?: pulumi.Input<string>;
|
|
177
|
+
/**
|
|
178
|
+
* Skill name
|
|
179
|
+
*/
|
|
180
|
+
name?: pulumi.Input<string>;
|
|
181
|
+
/**
|
|
182
|
+
* Organization machine name (defaults to provider organization)
|
|
183
|
+
*/
|
|
184
|
+
organization?: pulumi.Input<string>;
|
|
185
|
+
/**
|
|
186
|
+
* External source for importing a skill. Conflicts with `content`.
|
|
187
|
+
*/
|
|
188
|
+
source?: pulumi.Input<inputs.AiSkillSource>;
|
|
189
|
+
/**
|
|
190
|
+
* Tags for categorizing the skill
|
|
191
|
+
*/
|
|
192
|
+
tags?: pulumi.Input<pulumi.Input<string>[]>;
|
|
193
|
+
/**
|
|
194
|
+
* Condition that triggers the skill
|
|
195
|
+
*/
|
|
196
|
+
triggerCondition?: pulumi.Input<string>;
|
|
197
|
+
}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
2
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
3
|
+
|
|
4
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
5
|
+
import * as utilities from "./utilities";
|
|
6
|
+
|
|
7
|
+
export class AiVectorCollection extends pulumi.CustomResource {
|
|
8
|
+
/**
|
|
9
|
+
* Get an existing AiVectorCollection resource's state with the given name, ID, and optional extra
|
|
10
|
+
* properties used to qualify the lookup.
|
|
11
|
+
*
|
|
12
|
+
* @param name The _unique_ name of the resulting resource.
|
|
13
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
14
|
+
* @param state Any extra arguments used during the lookup.
|
|
15
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
16
|
+
*/
|
|
17
|
+
public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AiVectorCollectionState, opts?: pulumi.CustomResourceOptions): AiVectorCollection {
|
|
18
|
+
return new AiVectorCollection(name, <any>state, { ...opts, id: id });
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/** @internal */
|
|
22
|
+
public static readonly __pulumiType = 'quant:index:AiVectorCollection';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Returns true if the given object is an instance of AiVectorCollection. This is designed to work even
|
|
26
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
27
|
+
*/
|
|
28
|
+
public static isInstance(obj: any): obj is AiVectorCollection {
|
|
29
|
+
if (obj === undefined || obj === null) {
|
|
30
|
+
return false;
|
|
31
|
+
}
|
|
32
|
+
return obj['__pulumiType'] === AiVectorCollection.__pulumiType;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Timestamp when the collection was created
|
|
37
|
+
*/
|
|
38
|
+
declare public /*out*/ readonly createdAt: pulumi.Output<string>;
|
|
39
|
+
/**
|
|
40
|
+
* Collection description
|
|
41
|
+
*/
|
|
42
|
+
declare public readonly description: pulumi.Output<string | undefined>;
|
|
43
|
+
/**
|
|
44
|
+
* Collection name (immutable after creation)
|
|
45
|
+
*/
|
|
46
|
+
declare public readonly name: pulumi.Output<string>;
|
|
47
|
+
/**
|
|
48
|
+
* Organization machine name (defaults to provider organization)
|
|
49
|
+
*/
|
|
50
|
+
declare public readonly organization: pulumi.Output<string>;
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Create a AiVectorCollection resource with the given unique name, arguments, and options.
|
|
54
|
+
*
|
|
55
|
+
* @param name The _unique_ name of the resource.
|
|
56
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
57
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
58
|
+
*/
|
|
59
|
+
constructor(name: string, args?: AiVectorCollectionArgs, opts?: pulumi.CustomResourceOptions)
|
|
60
|
+
constructor(name: string, argsOrState?: AiVectorCollectionArgs | AiVectorCollectionState, opts?: pulumi.CustomResourceOptions) {
|
|
61
|
+
let resourceInputs: pulumi.Inputs = {};
|
|
62
|
+
opts = opts || {};
|
|
63
|
+
if (opts.id) {
|
|
64
|
+
const state = argsOrState as AiVectorCollectionState | undefined;
|
|
65
|
+
resourceInputs["createdAt"] = state?.createdAt;
|
|
66
|
+
resourceInputs["description"] = state?.description;
|
|
67
|
+
resourceInputs["name"] = state?.name;
|
|
68
|
+
resourceInputs["organization"] = state?.organization;
|
|
69
|
+
} else {
|
|
70
|
+
const args = argsOrState as AiVectorCollectionArgs | undefined;
|
|
71
|
+
resourceInputs["description"] = args?.description;
|
|
72
|
+
resourceInputs["name"] = args?.name;
|
|
73
|
+
resourceInputs["organization"] = args?.organization;
|
|
74
|
+
resourceInputs["createdAt"] = undefined /*out*/;
|
|
75
|
+
}
|
|
76
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
77
|
+
super(AiVectorCollection.__pulumiType, name, resourceInputs, opts);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Input properties used for looking up and filtering AiVectorCollection resources.
|
|
83
|
+
*/
|
|
84
|
+
export interface AiVectorCollectionState {
|
|
85
|
+
/**
|
|
86
|
+
* Timestamp when the collection was created
|
|
87
|
+
*/
|
|
88
|
+
createdAt?: pulumi.Input<string>;
|
|
89
|
+
/**
|
|
90
|
+
* Collection description
|
|
91
|
+
*/
|
|
92
|
+
description?: pulumi.Input<string>;
|
|
93
|
+
/**
|
|
94
|
+
* Collection name (immutable after creation)
|
|
95
|
+
*/
|
|
96
|
+
name?: pulumi.Input<string>;
|
|
97
|
+
/**
|
|
98
|
+
* Organization machine name (defaults to provider organization)
|
|
99
|
+
*/
|
|
100
|
+
organization?: pulumi.Input<string>;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* The set of arguments for constructing a AiVectorCollection resource.
|
|
105
|
+
*/
|
|
106
|
+
export interface AiVectorCollectionArgs {
|
|
107
|
+
/**
|
|
108
|
+
* Collection description
|
|
109
|
+
*/
|
|
110
|
+
description?: pulumi.Input<string>;
|
|
111
|
+
/**
|
|
112
|
+
* Collection name (immutable after creation)
|
|
113
|
+
*/
|
|
114
|
+
name?: pulumi.Input<string>;
|
|
115
|
+
/**
|
|
116
|
+
* Organization machine name (defaults to provider organization)
|
|
117
|
+
*/
|
|
118
|
+
organization?: pulumi.Input<string>;
|
|
119
|
+
}
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
2
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
3
|
+
|
|
4
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
5
|
+
import * as utilities from "./utilities";
|
|
6
|
+
|
|
7
|
+
export class AiVectorDocument extends pulumi.CustomResource {
|
|
8
|
+
/**
|
|
9
|
+
* Get an existing AiVectorDocument resource's state with the given name, ID, and optional extra
|
|
10
|
+
* properties used to qualify the lookup.
|
|
11
|
+
*
|
|
12
|
+
* @param name The _unique_ name of the resulting resource.
|
|
13
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
14
|
+
* @param state Any extra arguments used during the lookup.
|
|
15
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
16
|
+
*/
|
|
17
|
+
public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AiVectorDocumentState, opts?: pulumi.CustomResourceOptions): AiVectorDocument {
|
|
18
|
+
return new AiVectorDocument(name, <any>state, { ...opts, id: id });
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/** @internal */
|
|
22
|
+
public static readonly __pulumiType = 'quant:index:AiVectorDocument';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Returns true if the given object is an instance of AiVectorDocument. This is designed to work even
|
|
26
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
27
|
+
*/
|
|
28
|
+
public static isInstance(obj: any): obj is AiVectorDocument {
|
|
29
|
+
if (obj === undefined || obj === null) {
|
|
30
|
+
return false;
|
|
31
|
+
}
|
|
32
|
+
return obj['__pulumiType'] === AiVectorDocument.__pulumiType;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Vector collection UUID
|
|
37
|
+
*/
|
|
38
|
+
declare public readonly collectionId: pulumi.Output<string>;
|
|
39
|
+
/**
|
|
40
|
+
* Document text content
|
|
41
|
+
*/
|
|
42
|
+
declare public readonly content: pulumi.Output<string>;
|
|
43
|
+
/**
|
|
44
|
+
* SHA256 hash of content for drift detection
|
|
45
|
+
*/
|
|
46
|
+
declare public /*out*/ readonly contentSha256: pulumi.Output<string>;
|
|
47
|
+
/**
|
|
48
|
+
* Auto-assigned document UUID
|
|
49
|
+
*/
|
|
50
|
+
declare public /*out*/ readonly documentId: pulumi.Output<string>;
|
|
51
|
+
/**
|
|
52
|
+
* Stable document key (max 512 characters)
|
|
53
|
+
*/
|
|
54
|
+
declare public readonly key: pulumi.Output<string>;
|
|
55
|
+
/**
|
|
56
|
+
* Key-value metadata attached to the document
|
|
57
|
+
*/
|
|
58
|
+
declare public readonly metadata: pulumi.Output<{[key: string]: string} | undefined>;
|
|
59
|
+
/**
|
|
60
|
+
* Organization machine name (defaults to provider organization)
|
|
61
|
+
*/
|
|
62
|
+
declare public readonly organization: pulumi.Output<string>;
|
|
63
|
+
/**
|
|
64
|
+
* List of searchable field names
|
|
65
|
+
*/
|
|
66
|
+
declare public readonly searchableFields: pulumi.Output<string[] | undefined>;
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Create a AiVectorDocument resource with the given unique name, arguments, and options.
|
|
70
|
+
*
|
|
71
|
+
* @param name The _unique_ name of the resource.
|
|
72
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
73
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
74
|
+
*/
|
|
75
|
+
constructor(name: string, args: AiVectorDocumentArgs, opts?: pulumi.CustomResourceOptions)
|
|
76
|
+
constructor(name: string, argsOrState?: AiVectorDocumentArgs | AiVectorDocumentState, opts?: pulumi.CustomResourceOptions) {
|
|
77
|
+
let resourceInputs: pulumi.Inputs = {};
|
|
78
|
+
opts = opts || {};
|
|
79
|
+
if (opts.id) {
|
|
80
|
+
const state = argsOrState as AiVectorDocumentState | undefined;
|
|
81
|
+
resourceInputs["collectionId"] = state?.collectionId;
|
|
82
|
+
resourceInputs["content"] = state?.content;
|
|
83
|
+
resourceInputs["contentSha256"] = state?.contentSha256;
|
|
84
|
+
resourceInputs["documentId"] = state?.documentId;
|
|
85
|
+
resourceInputs["key"] = state?.key;
|
|
86
|
+
resourceInputs["metadata"] = state?.metadata;
|
|
87
|
+
resourceInputs["organization"] = state?.organization;
|
|
88
|
+
resourceInputs["searchableFields"] = state?.searchableFields;
|
|
89
|
+
} else {
|
|
90
|
+
const args = argsOrState as AiVectorDocumentArgs | undefined;
|
|
91
|
+
if (args?.collectionId === undefined && !opts.urn) {
|
|
92
|
+
throw new Error("Missing required property 'collectionId'");
|
|
93
|
+
}
|
|
94
|
+
if (args?.content === undefined && !opts.urn) {
|
|
95
|
+
throw new Error("Missing required property 'content'");
|
|
96
|
+
}
|
|
97
|
+
if (args?.key === undefined && !opts.urn) {
|
|
98
|
+
throw new Error("Missing required property 'key'");
|
|
99
|
+
}
|
|
100
|
+
resourceInputs["collectionId"] = args?.collectionId;
|
|
101
|
+
resourceInputs["content"] = args?.content;
|
|
102
|
+
resourceInputs["key"] = args?.key;
|
|
103
|
+
resourceInputs["metadata"] = args?.metadata;
|
|
104
|
+
resourceInputs["organization"] = args?.organization;
|
|
105
|
+
resourceInputs["searchableFields"] = args?.searchableFields;
|
|
106
|
+
resourceInputs["contentSha256"] = undefined /*out*/;
|
|
107
|
+
resourceInputs["documentId"] = undefined /*out*/;
|
|
108
|
+
}
|
|
109
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
110
|
+
super(AiVectorDocument.__pulumiType, name, resourceInputs, opts);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* Input properties used for looking up and filtering AiVectorDocument resources.
|
|
116
|
+
*/
|
|
117
|
+
export interface AiVectorDocumentState {
|
|
118
|
+
/**
|
|
119
|
+
* Vector collection UUID
|
|
120
|
+
*/
|
|
121
|
+
collectionId?: pulumi.Input<string>;
|
|
122
|
+
/**
|
|
123
|
+
* Document text content
|
|
124
|
+
*/
|
|
125
|
+
content?: pulumi.Input<string>;
|
|
126
|
+
/**
|
|
127
|
+
* SHA256 hash of content for drift detection
|
|
128
|
+
*/
|
|
129
|
+
contentSha256?: pulumi.Input<string>;
|
|
130
|
+
/**
|
|
131
|
+
* Auto-assigned document UUID
|
|
132
|
+
*/
|
|
133
|
+
documentId?: pulumi.Input<string>;
|
|
134
|
+
/**
|
|
135
|
+
* Stable document key (max 512 characters)
|
|
136
|
+
*/
|
|
137
|
+
key?: pulumi.Input<string>;
|
|
138
|
+
/**
|
|
139
|
+
* Key-value metadata attached to the document
|
|
140
|
+
*/
|
|
141
|
+
metadata?: pulumi.Input<{[key: string]: pulumi.Input<string>}>;
|
|
142
|
+
/**
|
|
143
|
+
* Organization machine name (defaults to provider organization)
|
|
144
|
+
*/
|
|
145
|
+
organization?: pulumi.Input<string>;
|
|
146
|
+
/**
|
|
147
|
+
* List of searchable field names
|
|
148
|
+
*/
|
|
149
|
+
searchableFields?: pulumi.Input<pulumi.Input<string>[]>;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* The set of arguments for constructing a AiVectorDocument resource.
|
|
154
|
+
*/
|
|
155
|
+
export interface AiVectorDocumentArgs {
|
|
156
|
+
/**
|
|
157
|
+
* Vector collection UUID
|
|
158
|
+
*/
|
|
159
|
+
collectionId: pulumi.Input<string>;
|
|
160
|
+
/**
|
|
161
|
+
* Document text content
|
|
162
|
+
*/
|
|
163
|
+
content: pulumi.Input<string>;
|
|
164
|
+
/**
|
|
165
|
+
* Stable document key (max 512 characters)
|
|
166
|
+
*/
|
|
167
|
+
key: pulumi.Input<string>;
|
|
168
|
+
/**
|
|
169
|
+
* Key-value metadata attached to the document
|
|
170
|
+
*/
|
|
171
|
+
metadata?: pulumi.Input<{[key: string]: pulumi.Input<string>}>;
|
|
172
|
+
/**
|
|
173
|
+
* Organization machine name (defaults to provider organization)
|
|
174
|
+
*/
|
|
175
|
+
organization?: pulumi.Input<string>;
|
|
176
|
+
/**
|
|
177
|
+
* List of searchable field names
|
|
178
|
+
*/
|
|
179
|
+
searchableFields?: pulumi.Input<pulumi.Input<string>[]>;
|
|
180
|
+
}
|