Skip to content

Commit 8347be9

Browse files
author
Pedro Rodrigues
committed
improve onboarding prompt
1 parent 3a3b42e commit 8347be9

File tree

2 files changed

+7
-53
lines changed

2 files changed

+7
-53
lines changed

src/api/prompts/prompts.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def onboarding_helios_user() -> list:
2121
"Let's create a starter workspace if I don't have one yet. Then, populate the database with sample data.",
2222
),
2323
AssistantMessage(
24-
"Step 3: Load sample data into your new database. Try running this SQL in your virtual workspace:"
24+
"Step 3: First, let's create a table to store our sample customer data:"
2525
),
2626
AssistantMessage(
2727
"""\
@@ -31,13 +31,15 @@ def onboarding_helios_user() -> list:
3131
email VARCHAR(100),
3232
country VARCHAR(50),
3333
PRIMARY KEY (id)
34-
);
35-
34+
);"""
35+
),
36+
AssistantMessage("Great! Now let's add some sample data to our table:"),
37+
AssistantMessage(
38+
"""\
3639
INSERT INTO sample_customers VALUES
3740
(1, 'John Doe', 'john@example.com', 'USA'),
3841
(2, 'Jane Smith', 'jane@example.com', 'Canada'),
39-
(3, 'Alice Johnson', 'alice@example.com', 'UK');
40-
"""
42+
(3, 'Alice Johnson', 'alice@example.com', 'UK');"""
4143
),
4244
AssistantMessage("Step 4: Try your first query!"),
4345
UserMessage("Let's run a simple select query to see our data."),

src/api/tools/tools.py

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -2141,54 +2141,6 @@ class TerminationConfirmation(BaseModel):
21412141
f"Proceeding with termination of virtual workspace: {validated_workspace_id}"
21422142
)
21432143

2144-
class TerminationConfirmation(BaseModel):
2145-
"""Schema for collecting organization selection."""
2146-
2147-
confirm: bool = Field(
2148-
description="Do you really want to terminate this virtual workspace?",
2149-
default=False,
2150-
)
2151-
2152-
result = await ctx.elicit(
2153-
message=f"⚠️ **WARNING**: You are about to terminate the virtual workspace '{workspace_name}'.\n\n"
2154-
"This action is permanent and cannot be undone. All data in the workspace will be lost.\n\n"
2155-
"Do you want to proceed with the termination?",
2156-
schema=TerminationConfirmation,
2157-
)
2158-
2159-
# Skip confirmation if elicitation is not supported
2160-
if error == ElicitationError.NOT_SUPPORTED:
2161-
await ctx.info(
2162-
"Proceeding with termination without confirmation since interactive confirmation is not supported."
2163-
)
2164-
else:
2165-
# Only check confirmation if elicitation was supported
2166-
if not (
2167-
elicit_result.status == "success"
2168-
and elicit_result.data
2169-
and elicit_result.data.confirm
2170-
):
2171-
return {
2172-
"status": "cancelled",
2173-
"message": "Workspace termination was cancelled by the user",
2174-
"workspace_id": validated_workspace_id,
2175-
"workspace_name": workspace_name,
2176-
}
2177-
2178-
# Track analytics event
2179-
settings.analytics_manager.track_event(
2180-
user_id,
2181-
"tool_calling",
2182-
{
2183-
"name": "terminate_virtual_workspace",
2184-
"workspace_id": validated_workspace_id,
2185-
},
2186-
)
2187-
2188-
await ctx.info(
2189-
f"Proceeding with termination of virtual workspace: {validated_workspace_id}"
2190-
)
2191-
21922144
# Terminate the virtual workspace
21932145
build_request(
21942146
"DELETE", f"sharedtier/virtualWorkspaces/{validated_workspace_id}"

0 commit comments

Comments
 (0)