Spaces:
Build error
Build error
dai
commited on
Commit
·
7a64d10
1
Parent(s):
0a431d7
change README
Browse files
README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
---
|
2 |
title: Code As Policies
|
3 |
-
emoji:
|
4 |
colorFrom: purple
|
5 |
colorTo: indigo
|
6 |
sdk: gradio
|
@@ -13,22 +13,19 @@ duplicated_from: jackyliang42/code-as-policies
|
|
13 |
|
14 |
# Code as Policies Tabletop Manipulation Interactive Demo
|
15 |
|
16 |
-
This demo is from the paper:
|
17 |
|
18 |
[Code as Policies: Language Model Programs for Embodied Control](https://code-as-policies.github.io/)
|
19 |
|
20 |
-
Below is an interactive demo for the simulated tabletop manipulation domain, seen in the paper section IV.D
|
21 |
-
|
22 |
## Preparations
|
23 |
1. Obtain an [OpenAI API Key](https://openai.com/blog/openai-api/)
|
24 |
-
2.
|
25 |
-
|
26 |
-
Once you have Codex access you can use code-davinci-002. Using the GPT-3 model (text-dainvci-002) is also ok, but performance won't be as good (there will be more code logic errors).
|
27 |
|
28 |
## Usage
|
29 |
-
1.
|
30 |
-
2. Click Setup/Reset Simulation
|
31 |
-
3. Based on the new randomly sampled object names, input an instruction
|
|
|
32 |
|
33 |
You can run instructions in sequence and refer back to previous instructions (e.g. do the same with other blocks, move the same block to the other bowl, etc). To reset, click Setup/Reset Env, and this will clear the current instruction history.
|
34 |
|
@@ -53,6 +50,7 @@ Note object names may need to be changed depending the sampled object names.
|
|
53 |
* 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.
|
54 |
* The pick place primitive is also unable to pick up bowls.
|
55 |
* 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.
|
56 |
-
* 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)
|
57 |
* Maximum token length - you may hit the maximum token length if running multiple commands in sequence. Please reset the simulation when this happens.
|
58 |
-
|
|
|
|
|
|
1 |
---
|
2 |
title: Code As Policies
|
3 |
+
emoji: 🗣🦾
|
4 |
colorFrom: purple
|
5 |
colorTo: indigo
|
6 |
sdk: gradio
|
|
|
13 |
|
14 |
# Code as Policies Tabletop Manipulation Interactive Demo
|
15 |
|
16 |
+
This demo is based on the [original demo](https://huggingface.co/spaces/jackyliang42/code-as-policies) from the paper:
|
17 |
|
18 |
[Code as Policies: Language Model Programs for Embodied Control](https://code-as-policies.github.io/)
|
19 |
|
|
|
|
|
20 |
## Preparations
|
21 |
1. Obtain an [OpenAI API Key](https://openai.com/blog/openai-api/)
|
22 |
+
2. Enter your API key in the form below. We use the supplied key to use OpenAI APIs (which can incur a cost) solely for your demo interactions. It is not retained after you session.
|
|
|
|
|
23 |
|
24 |
## Usage
|
25 |
+
1. You can change the LM model to use, and how many blocks and bowls to be spawned in the environment.
|
26 |
+
2. Click `Setup/Reset Simulation`. Too many objects can cause the setup to hang.
|
27 |
+
3. Based on the new randomly sampled object names, input an instruction or ask a question and click `Run`.
|
28 |
+
4. You can conveniently affix your instructions with buttons.
|
29 |
|
30 |
You can run instructions in sequence and refer back to previous instructions (e.g. do the same with other blocks, move the same block to the other bowl, etc). To reset, click Setup/Reset Env, and this will clear the current instruction history.
|
31 |
|
|
|
50 |
* 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.
|
51 |
* The pick place primitive is also unable to pick up bowls.
|
52 |
* 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.
|
|
|
53 |
* Maximum token length - you may hit the maximum token length if running multiple commands in sequence. Please reset the simulation when this happens.
|
54 |
+
|
55 |
+
### Author
|
56 |
+
Falcon Dai
|