Skip to content

Commit af9f513

Browse files
tgberkeleyTom Gotsman
andauthored
breaking up a complex prompt (#1382)
Co-authored-by: Tom Gotsman <[email protected]>
1 parent 16c89e7 commit af9f513

File tree

2 files changed

+48
-8
lines changed

2 files changed

+48
-8
lines changed
Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,44 @@
11
# Breaking up complex prompts
22

3+
## Incremental Prompting
4+
5+
Asking for incremental, smaller changes leads to better results, rather than asking for everything all in a single huge prompt. It's better to take it step-by-step rather than give the AI complex tasks all at once.
36

4-
Still to come!
7+
### Example 1
8+
Too Complex:
9+
10+
`Create a data visualization dashboard that includes user authentication, data integration, multiple charts, real-time updates, and export options.`
11+
12+
Better Approach:
13+
14+
Prompt 1: `Design a simple dashboard layout.`
15+
16+
Prompt 2: `Now let's add a bar chart for visualizing sales data.`
17+
18+
Prompt 3: `Now add user authentication.`
19+
20+
Prompt 4: `Now integrate data from an external API.`
21+
22+
Prompt 5: `Now add real-time updates for the chart.`
23+
24+
Prompt 6: `Now add export options for the dashboard data.`
25+
26+
### Example 2
27+
Too Complex:
28+
29+
`Create an app that takes in data, processes it, generates reports, sends notifications, and allows users to filter results by various criteria.`
30+
31+
Better Approach:
32+
33+
Prompt 1: `Create an app that takes in data`
34+
35+
Prompt 2: `Now add logic to process the data.`
36+
37+
Prompt 3: `Now add a feature to generate reports.`
38+
39+
Prompt 4: `Now add a feature to send notifications.`
40+
41+
Prompt 5: `Now add a feature to filter results by various criteria.`
42+
43+
44+

pcweb/components/docpage/sidebar/sidebar_items/ai.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ def get_sidebar_items_ai_builder_overview():
2727
ai_builder.features.deploy_app,
2828
],
2929
),
30-
# create_item(
31-
# "Prompting Guide",
32-
# children=[
33-
# ai_builder.prompting.fixing_errors,
34-
# ai_builder.prompting.breaking_up_complex_prompts,
35-
# ],
36-
# ),
30+
create_item(
31+
"Prompting Guide",
32+
children=[
33+
#ai_builder.prompting.fixing_errors,
34+
ai_builder.prompting.breaking_up_complex_prompts,
35+
],
36+
),
3737
create_item(
3838
"Integrations",
3939
children=[

0 commit comments

Comments
 (0)