Spaces:
Runtime error
Runtime error
jackyliang42
commited on
Commit
·
a2fa930
1
Parent(s):
8538649
minor updates
Browse files- README.md +1 -0
- app.py +2 -2
- prompts/tabletop_ui.py +0 -5
README.md
CHANGED
@@ -52,3 +52,4 @@ Note object names may need to be changed depending the sampled object names.
|
|
52 |
* Currently, the low-level pick place primitive does not do collision checking, so if there are many objects on the table, placing actions may incur collisions.
|
53 |
* Prompt saturation - if too many instructions (10+) are executed in a row, then the LLM may start to ignore examples in the early parts of the prompt.
|
54 |
* Ambiguous instructions - if a given instruction doesn't lead to the desired actions, try rephrasing it to remove ambiguities (e.g. place the block on the closest bowl -> place the block on its closest bowl)
|
|
|
|
52 |
* Currently, the low-level pick place primitive does not do collision checking, so if there are many objects on the table, placing actions may incur collisions.
|
53 |
* Prompt saturation - if too many instructions (10+) are executed in a row, then the LLM may start to ignore examples in the early parts of the prompt.
|
54 |
* Ambiguous instructions - if a given instruction doesn't lead to the desired actions, try rephrasing it to remove ambiguities (e.g. place the block on the closest bowl -> place the block on its closest bowl)
|
55 |
+
* Maximum token length - you may hit the maximum token length if running multiple commands in sequence. Please reset the simulation when this happens.
|
app.py
CHANGED
@@ -127,7 +127,7 @@ if __name__ == '__main__':
|
|
127 |
with gr.Row():
|
128 |
with gr.Column():
|
129 |
with gr.Row():
|
130 |
-
inp_api_key = gr.Textbox(label='OpenAI API Key', lines=1)
|
131 |
inp_model_name = gr.Dropdown(label='Model Name', choices=['code-davinci-002', 'text-davinci-002'], value='code-davinci-002')
|
132 |
with gr.Row():
|
133 |
inp_n_blocks = gr.Slider(label='Number of Blocks', minimum=0, maximum=4, value=3, step=1)
|
@@ -142,7 +142,7 @@ if __name__ == '__main__':
|
|
142 |
with gr.Column():
|
143 |
|
144 |
inp_instruction = gr.Textbox(label='Instruction', lines=1)
|
145 |
-
btn_run = gr.Button("Run
|
146 |
info_run = gr.Markdown(label='Generated Code')
|
147 |
with gr.Column():
|
148 |
video_run = gr.Video(label='Video of Last Instruction')
|
|
|
127 |
with gr.Row():
|
128 |
with gr.Column():
|
129 |
with gr.Row():
|
130 |
+
inp_api_key = gr.Textbox(label='OpenAI API Key (this is not stored anywhere)', lines=1)
|
131 |
inp_model_name = gr.Dropdown(label='Model Name', choices=['code-davinci-002', 'text-davinci-002'], value='code-davinci-002')
|
132 |
with gr.Row():
|
133 |
inp_n_blocks = gr.Slider(label='Number of Blocks', minimum=0, maximum=4, value=3, step=1)
|
|
|
142 |
with gr.Column():
|
143 |
|
144 |
inp_instruction = gr.Textbox(label='Instruction', lines=1)
|
145 |
+
btn_run = gr.Button("Run (this may take 20+ seconds)")
|
146 |
info_run = gr.Markdown(label='Generated Code')
|
147 |
with gr.Column():
|
148 |
video_run = gr.Video(label='Video of Last Instruction')
|
prompts/tabletop_ui.py
CHANGED
@@ -48,11 +48,6 @@ right_side = parse_position('the right side')
|
|
48 |
put_first_on_second('gray block', right_side)
|
49 |
order_bottom_to_top = ['gray block', 'green block', 'yellow block']
|
50 |
stack_objects_in_order(object_names=order_bottom_to_top)
|
51 |
-
objects = ['yellow block', 'green block', 'yellow bowl', 'blue block', 'blue bowl', 'green bowl']
|
52 |
-
# hide the blue bowl.
|
53 |
-
bowl_name = np.random.choice(['yellow bowl', 'green bowl'])
|
54 |
-
say(f'Sounds good! Hiding the blue bowl under the {bowl_name}')
|
55 |
-
put_first_on_second(bowl_name, 'blue bowl')
|
56 |
objects = ['pink block', 'green block', 'pink bowl', 'blue block', 'blue bowl', 'green bowl']
|
57 |
# stack everything with the green block on top.
|
58 |
say('Ok! Stacking everything with the green block on the top')
|
|
|
48 |
put_first_on_second('gray block', right_side)
|
49 |
order_bottom_to_top = ['gray block', 'green block', 'yellow block']
|
50 |
stack_objects_in_order(object_names=order_bottom_to_top)
|
|
|
|
|
|
|
|
|
|
|
51 |
objects = ['pink block', 'green block', 'pink bowl', 'blue block', 'blue bowl', 'green bowl']
|
52 |
# stack everything with the green block on top.
|
53 |
say('Ok! Stacking everything with the green block on the top')
|