summaryrefslogtreecommitdiffstats
path: root/etc/tool
diff options
context:
space:
mode:
authorHeiner Lohaus <heiner@lohaus.eu>2023-10-07 19:00:45 +0200
committerHeiner Lohaus <heiner@lohaus.eu>2023-10-07 19:00:45 +0200
commitdfdb759639479da640701fe0db716d4455b7ae38 (patch)
tree607297dd731568653d11421038b23861b5a9a4fa /etc/tool
parentImprove code by AI (diff)
downloadgpt4free-dfdb759639479da640701fe0db716d4455b7ae38.tar
gpt4free-dfdb759639479da640701fe0db716d4455b7ae38.tar.gz
gpt4free-dfdb759639479da640701fe0db716d4455b7ae38.tar.bz2
gpt4free-dfdb759639479da640701fe0db716d4455b7ae38.tar.lz
gpt4free-dfdb759639479da640701fe0db716d4455b7ae38.tar.xz
gpt4free-dfdb759639479da640701fe0db716d4455b7ae38.tar.zst
gpt4free-dfdb759639479da640701fe0db716d4455b7ae38.zip
Diffstat (limited to '')
-rw-r--r--etc/tool/improve_code.py (renamed from etc/tool/improve_file.py)7
1 files changed, 5 insertions, 2 deletions
diff --git a/etc/tool/improve_file.py b/etc/tool/improve_code.py
index cef41354..9a940b51 100644
--- a/etc/tool/improve_file.py
+++ b/etc/tool/improve_code.py
@@ -22,7 +22,10 @@ Improve the code in this file:
```py
{code}
```
-Don't remove anything. Add type hints if possible.
+Don't remove anything.
+Add typehints if possible.
+Don't add any typehints to kwargs.
+Don't remove license comments.
"""
print("Create code...")
@@ -30,7 +33,7 @@ response = []
for chunk in g4f.ChatCompletion.create(
model=g4f.models.gpt_35_long,
messages=[{"role": "user", "content": prompt}],
- timeout=0,
+ timeout=300,
stream=True
):
response.append(chunk)