theprotaganist / gpt-j Goto Github PK
View Code? Open in Web Editor NEWA GPT-J API to use with python3 to generate text, blogs, code, and more
License: MIT License
A GPT-J API to use with python3 to generate text, blogs, code, and more
License: MIT License
Exception has occurred: JSONDecodeError
Expecting value: line 1 column 1 (char 0)
During handling of the above exception, another exception occurred:
During handling of the above exception, another exception occurred:
File "C:\Users\Lia\testing\test.py", line 28, in
res = simple_completion(prompt, length=Max, temp=temperature, top_p=top_probability, top_k=top_k, rep=rep)
I'm unable to extract step_383500.tar.zstd.
I have a pretty simple issue.
This type of this file is Express Zip File Compression but when I try to open it with said tool, it claims that the file is not supported. I tried searching up the file type and got nothing. How am I suppose to decompress this file.
Hi,
I am getting the following error from context_setting.completion API.
I have tried both basic and adv example but similar issue.
Any pointers on how to resolve this?
Thanks!
/usr/lib/python3.7/json/decoder.py in raw_decode(self, s, idx)
353 obj, end = self.scan_once(s, idx)
354 except StopIteration as err:
--> 355 raise JSONDecodeError("Expecting value", s, err.value) from None
356 return obj, end
JSONDecodeError: Expecting value: line 1 column 1 (char 0)
=================================================================
My code based on your example:
from gpt_j.Basic_api import simple_completion
prompt = "def perfect_square(num):"
Max = 200
temperature = 0.6
top_probability = 1.0
top_k = 1
rep = 0.216
res = context_setting.completion(prompt,
user=User,
bot=Bot,
max_tokens=max_tokens,
temperature=temperature,
top_p=top_probability,
top_k=top_k,
rep=repetition)
print(res)
Hello, I am creating a chatbot with this API. I was wondering how I can add a stop sequence so it doesn't keep on generating text after the response.
Thank you very much!
i'm new to python. can i use some help?
Can you update how to fix this issue?
I am working on GPT-J to generate prompts and I am unable to run the code.
During handling of the above exception, another exception occurred:
I am getting the following error when I tried running python basic_usage_template.py
and python advanced_usage_template.py
Traceback (most recent call last):
File "/hdd2/srinath/gpt-j/advanced_usage_template.py", line 58, in <module>
response = context_setting.completion(prompt,
File "/hdd2/srinath/anaconda3/envs/SD_Aug/lib/python3.10/site-packages/gpt_j/gptj_api.py", line 67, in completion
self.response = generate(f"{self.new_prompt} {user}: {self.main_intention}", token_max_length=max_tokens, temperature=temperature, top_p=top_p, top_k=top_k, rep=rep)
File "/hdd2/srinath/anaconda3/envs/SD_Aug/lib/python3.10/site-packages/gpt_j/Gptj.py", line 12, in generate
result = URL.json()
File "/hdd2/srinath/anaconda3/envs/SD_Aug/lib/python3.10/site-packages/requests/models.py", line 975, in json
raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
My python version is 3.10.6
Getting an HTTP error: [WinError 10061] No connection could be made because the target machine actively refused it'
Has anyone else been suddenly getting this message? 'Sorry, the public API is limited to around 20 queries per every 30 minutes'
Could you open source the package? It would be nice for users to be able to make modifications to the package that can then later be pushed to the main. Thank you in advance!
I can see that you're making requests to "https://playground-api.forefront.link/" and it seems like this is not responding.
Is the language filter seen as necessary for this package?
Or would it be better to add an adjustable level, it just flagged "knife" for me.
hi, how can I train it with my own training data through gogle colab?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.