Updated the Readme for Version 2.0
Browse files
README.md
CHANGED
|
@@ -9,6 +9,8 @@ tags:
|
|
| 9 |
---
|
| 10 |
|
| 11 |
TLDR;
|
|
|
|
|
|
|
| 12 |
- The model is quite fun to play with as it seems pretty competent:
|
| 13 |
- It's much better than bigger general models but not perfect.
|
| 14 |
- It shows a good understanding about coding:
|
|
@@ -18,7 +20,6 @@ TLDR;
|
|
| 18 |
- Getting what you want from the model can be a hit or miss:
|
| 19 |
- Sometimes you'll have to fight extensively with the way you write the prompt to get what you want.
|
| 20 |
- Sometimes you won't be able to make the model do what you want.
|
| 21 |
-
- When dealing with coding problems it fails completely.
|
| 22 |
|
| 23 |
---------------------------------------------------------------
|
| 24 |
|
|
@@ -35,7 +36,7 @@ Next there are some examples to show what the model is currently capable of.
|
|
| 35 |
|
| 36 |
The first example shows a non-trivial example of the model generating code.
|
| 37 |
(Depending on the complexity of the required task the generated code might not work. For example, making the model write code to move the square
|
| 38 |
-
around has proven to be quite difficult.)
|
| 39 |
```
|
| 40 |
Below is an instruction that describes a task. Write a response that appropriately completes the request.
|
| 41 |
|
|
@@ -185,8 +186,7 @@ if __name__ == '__main__':
|
|
| 185 |
'''
|
| 186 |
```
|
| 187 |
|
| 188 |
-
Finally
|
| 189 |
-
The model clearly needs more work in order to deal with these tasks, or perhaps this task is too complicated for its size.
|
| 190 |
```
|
| 191 |
Below is an instruction that describes a task, paired with an input that provides further context. Write a response that appropriately completes the request.
|
| 192 |
|
|
@@ -229,16 +229,17 @@ Only one valid answer exists.
|
|
| 229 |
|
| 230 |
|
| 231 |
### Response:
|
| 232 |
-
Certainly, here is
|
| 233 |
'''python
|
| 234 |
class Solution:
|
| 235 |
-
|
| 236 |
-
|
| 237 |
-
|
| 238 |
-
|
| 239 |
-
|
| 240 |
-
|
| 241 |
-
|
| 242 |
-
|
|
|
|
| 243 |
'''
|
| 244 |
```
|
|
|
|
| 9 |
---
|
| 10 |
|
| 11 |
TLDR;
|
| 12 |
+
- Updated to V2:
|
| 13 |
+
- Now it can solve Leetcode problems, still far from being perfect.
|
| 14 |
- The model is quite fun to play with as it seems pretty competent:
|
| 15 |
- It's much better than bigger general models but not perfect.
|
| 16 |
- It shows a good understanding about coding:
|
|
|
|
| 20 |
- Getting what you want from the model can be a hit or miss:
|
| 21 |
- Sometimes you'll have to fight extensively with the way you write the prompt to get what you want.
|
| 22 |
- Sometimes you won't be able to make the model do what you want.
|
|
|
|
| 23 |
|
| 24 |
---------------------------------------------------------------
|
| 25 |
|
|
|
|
| 36 |
|
| 37 |
The first example shows a non-trivial example of the model generating code.
|
| 38 |
(Depending on the complexity of the required task the generated code might not work. For example, making the model write code to move the square
|
| 39 |
+
around has proven to be quite difficult, the latest version can produce valid code for this.)
|
| 40 |
```
|
| 41 |
Below is an instruction that describes a task. Write a response that appropriately completes the request.
|
| 42 |
|
|
|
|
| 186 |
'''
|
| 187 |
```
|
| 188 |
|
| 189 |
+
Finally an easy leetcode problem. The latest version of the model can solve the problem (with a O(n^2) solution).
|
|
|
|
| 190 |
```
|
| 191 |
Below is an instruction that describes a task, paired with an input that provides further context. Write a response that appropriately completes the request.
|
| 192 |
|
|
|
|
| 229 |
|
| 230 |
|
| 231 |
### Response:
|
| 232 |
+
Certainly, here is a potential way to implement a program in Python that addresses the problem at hand.
|
| 233 |
'''python
|
| 234 |
class Solution:
|
| 235 |
+
def twoSum(self, nums: List[int], target: int) -> List[int]:
|
| 236 |
+
l = []
|
| 237 |
+
for i in range(len(nums)):
|
| 238 |
+
if target-nums[i] in l:
|
| 239 |
+
return [l.index(target-nums[i]), i]
|
| 240 |
+
else:
|
| 241 |
+
l.append(nums[i])
|
| 242 |
+
return [-1,-1]
|
| 243 |
+
```
|
| 244 |
'''
|
| 245 |
```
|