Skip to content

Commit

Permalink
Small improvements to FDC init and JSON Schema. (#7674)
Browse files Browse the repository at this point in the history
  • Loading branch information
mbleigh committed Sep 18, 2024
1 parent c222f52 commit 18d302a
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 16 deletions.
55 changes: 43 additions & 12 deletions schema/connector-yaml.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,16 @@
"description": "Path to the directory where generated files should be written to."
}
}
},
"llmTools": {
"additionalProperties": true,
"type": "object",
"properties": {
"outputFile": {
"type": "string",
"description": "Path where the JSON LLM tool definitions file should be generated."
}
}
}
},
"properties": {
Expand All @@ -55,25 +65,46 @@
"additionalProperties": false,
"properties": {
"javascriptSdk": {
"type": "array",
"items": {
"$ref": "#/definitions/javascriptSdk"
},
"oneOf": [
{ "$ref": "#/definitions/javascriptSdk" },
{
"type": "array",
"items": {
"$ref": "#/definitions/javascriptSdk"
}
}
],
"description": "Configuration for a generated Javascript SDK"
},
"kotlinSdk": {
"type": "array",
"items": {
"$ref": "#/definitions/kotlinSdk"
},
"oneOf": [
{ "$ref": "#/definitions/kotlinSdk" },
{
"type": "array",
"items": {
"$ref": "#/definitions/kotlinSdk"
}
}
],
"description": "Configuration for a generated Kotlin SDK"
},
"swiftSdk": {
"type": "array",
"items": {
"$ref": "#/definitions/swiftSdk"
},
"oneOf": [
{ "$ref": "#/definitions/swiftSdk" },
{
"type": "array",
"items": {
"$ref": "#/definitions/swiftSdk"
}
}
],
"description": "Configuration for a generated Swift SDK"
},
"llmTools": {
"oneOf": [
{ "$ref": "#/definitions/llmTools" },
{ "type": "array", "items": { "$ref": "#/definitions/llmTools" } }
]
}
}
}
Expand Down
7 changes: 3 additions & 4 deletions src/init/features/dataconnect/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,7 @@ async function askQuestions(setup: Setup, config: Config): Promise<RequiredInfo>
(info.isNewInstance || info.isNewDatabase) &&
isBillingEnabled &&
(await confirm({
message:
"Would you like to provision your CloudSQL instance and database now? This will take a few minutes.",
message: `Would you like to provision your Cloud SQL instance and database now?${info.isNewInstance ? " This will take several minutes." : ""}.`,
default: true,
}))
);
Expand Down Expand Up @@ -295,7 +294,7 @@ async function promptForService(
info.serviceId = await promptOnce({
message: "What ID would you like to use for this service?",
type: "input",
default: "my-service",
default: "app",
});
}
return info;
Expand Down Expand Up @@ -330,7 +329,7 @@ async function promptForCloudSQLInstance(setup: Setup, info: RequiredInfo): Prom
info.cloudSqlInstanceId = await promptOnce({
message: `What ID would you like to use for your new CloudSQL instance?`,
type: "input",
default: `fdc-sql`,
default: `${info.serviceId || "app"}-fdc`,
});
}
if (info.locationId === "") {
Expand Down

0 comments on commit 18d302a

Please sign in to comment.