Introducing Insert and Edits Capabilities

A recommendation for edits: highlight text that the AI editted.

1 Like

I am trying some code completions (insertions) for python code. You may check the attached image which pinpoints the problem.

When asking for an insertions sometimes the model replies with a possible solution given the context, but then continues to return tokens for additional problems by also providing comments that describe the additional problems. In the specific example we ask an insertion in order to get a reply if user can login depending on his username/password, but then we get additional function for “register the user if the username is not taken”.
I can somehow overcome this problem by providing specific stop strings but this is highly dependend to the context.

Is this a prefered behavior of the model? Is there any additional suggestions for overcoming that problem?

Thank you

I think it would be nice to have colours indicating when something has been added, replaced or deleted. Sometimes I have to re-read a generated edit multiple times to finally realise nothing changed.

2 Likes

Some feedback: The token amount is extremely limited for edits. You can only apply edits to trivial files while the ones most tedious to edit does not fit into the limits. Also since the instructions are counted in the tokens, precise instructions reduces the value got out of the edits since it can only edit even more trivial files. It’s a bit counterintuitive since the bigger the file, the more you likely need instructions.

Maybe the endpoint should be able to stream through the file so that it stays within the token limits?

Would be important that there were a structured way to give example inputs & outputs. Now it’s up to guess work and tricks how it should be presented in the optimal manner.

Also looks like if the editable content is a bit longer, like 200+ lines, the Codex is incapable of doing anything meaningful to it. It might add an empty line or change one function invocation, but that’s about it. Feels like the longer the editable code, the less capable Codex becomes. This makes it hard to run any instructions in scale.

1 Like

I posted a separate thread about this yesterday before I found this thread. Is there currently a bug with the two-pane editors, Insert and Edit? I’ve tested on several devices and they all appear to be bugged, replacing the prompt text automatically with the result text. Is this change of behavior intended?

2 Likes

Yea definitely, I’m currently having this strange behavior in edit, where it’s completely replacing the input with the output and not just that it’s like appending it or something…

2 Likes

I asked for it to “reverse the spelling” of text. Here are the results (oof)

As someone who is a native english speaker, If someone asked me to “reverse the spelling” I honestly wouldn’t have a clue what they’re expecting me to do. That makes no sense at all, try being more specific like

reversing the order or the letters/words?
reversing the capitalization?
replacing the words with their best antonym?

I ask it to do all kinds of things. I test out so much that i have a bunch of saved personal data sets. Hows your experience with other tests?

I’d love the ability to have a mode kind of like Insert, except it spits out text that is meant to “summarize” the code. You could use that to synthesize large diffs and/or generate PR descriptions, or even just to create general tech documentation

1 Like

The tools works amazingly well, helping to expand on existing ideas

Would be awesome to add a button that copies the response

1 Like

Thank you, text-davinci-edit-001

1 Like
  1. Adjustible text area widths (i.e., slide the middle gutter horizontally to resize)
  2. Line numbers in -code

Thank you!

Insert mode is great, but when trying to [insert] in a list with a final number it will fill the space and if you put a too low number with duplicate (e.g. with input:

How to make a delicious hot chocolate:

[insert]
4. Enjoy the hot chocolate

Gave output (approx as I can’t find in history and happens intermittently):

How to make a delicious hot chocolate:

1. Heat 1 1/2 cups of milk in a small saucepan over medium-high heat.

2. When the milk starts to simmer, remove it from the heat and add 1/2 cup of chocolate chips. Stir until all the chips are melted.

3. Pour the melted chocolate into a mug and add a pinch of cinnamon, a dash of vanilla extract, and 1 tablespoon of sugar. Stir until everything is combined.

4. (Had another 4. inserted by GPT3)

4. Enjoy the hot chocolate //note this is a duplicate "4"

And if you give input as [insert] 9. It will fluff fill as many steps as it needs

So far it’s pretty good but has still some issues.
Also the usability is weak (at least for me). First code highlighting would be great as well as code lines.
Next I don’t think, two windows are needed. I would prefer one and show something like git diff. After submitting the changed code is in the window, where I can either accept or reject. If I accept I can do my changes (if I need) and submit another task. I sometimes forgot to copied the created code. Submit button and Settings belong together for me and would also create some vertical space. And as I see, the worst thing, after switching mode back and forth it resets some of the settings. Maybe that’s the case why my results are not great, as I sometimes forgot to change to codex.

Well, things can get out of hand if the number goes too high. It gets bored and repeats itself.

How to make a delicious hot chocolate:

1. Gather the ingredients you will need:
-Milk
-Chocolate powder or syrup
-Whipped cream (optional)
-Marshmallows (optional)
-Cinnamon (optional)
2. Heat the milk in a saucepan on medium heat.
3. When the milk is hot, add the desired amount of chocolate powder or syrup.
4. Stir until the powder or syrup is completely dissolved.
5. Pour the hot chocolate into a mug.
6. Add whipped cream, marshmallows, and/or cinnamon to the top, if desired.
7. Serve the hot chocolate while hot.
8. Optionally, add a straw for easier drinking.
9. Optionally, add a spoon for stirring in additional ingredients or for stirring the hot chocolate while drinking.
10. Optionally, sprinkle some cocoa powder on top of the hot chocolate.
11. Optionally, add a candy cane or a stick of cinnamon to the top of the mug.
12. Optionally, add a few drops of peppermint extract to the hot chocolate.
13. Optionally, top the hot chocolate with a sprinkle of nutmeg or ground cinnamon.
14. Optionally, sprinkle some mini marshmallows on top of the hot chocolate.
15. Optionally, add a few drops of vanilla extract to the hot chocolate.
16. Optionally, top the hot chocolate with a sprinkle of crushed candy canes.
17. Optionally, add a few drops of almond extract to the hot chocolate.
18. Optionally, top the hot chocolate with a sprinkle of crushed nuts.
19. Optionally, add a few drops of orange extract to the hot chocolate.
20. Optionally, top the hot chocolate with a sprinkle of coconut flakes.
21. Optionally, add a few drops of raspberry extract to the hot chocolate.
22. Optionally, add a few drops of hazelnut extract to the hot chocolate.
23. Optionally, top the hot chocolate with a sprinkle of chocolate chips.
24. Optionally, add a few drops of peppermint extract to the hot chocolate.
25. Optionally, add a few drops of caramel extract to the hot chocolate.
26. Optionally, top the hot chocolate with a sprinkle of crushed candy canes.
27. Optionally, add a few drops of mint extract to the hot chocolate.
28. Optionally, add a few drops of hazelnut extract to the hot chocolate.
29. Optionally, top the hot chocolate with a sprinkle of marshmallow bits.
30. Optionally, add a few drops of almond extract to the hot chocolate.
31. Optionally, add a few drops of vanilla extract to the hot chocolate.
32. Optionally, top the hot chocolate with a sprinkle of mini chocolate chips.
33. Optionally, add a few drops of cinnamon extract to the hot chocolate.

34. Enjoy the hot chocolate!

Hi. I am running into issues with the output repeating lines (including the prompt).

I have been using the edit function to test proofreading chapters of one of my novels. I have noticed a couple of minor issues. Sometimes it will put unusual indicators into the text. In one case it prefaced a chapter with “#American English” and put four carriage returns and the word “end” at the conclusion of another chapter.
In some cases it will return the text spaced exactly as it was originally. In others with will suddenly insert two or more carriage returns between paragraphs. In one case it suddenly inserted six carriage returns between two paragraphs.
Overall, I find the fucntion seems to work well for what I was trying to do. I did discover somewhat humerously that the system favors British English over American English - changing spellings of certain words.