Git Product home page Git Product logo

patrikzeros-chatgpt-api-ui's Introduction

🍜 About me

Hey I am Patrik Žúdel, also known as Zero.

Professional esports player. I have a genuine passion for exploring various subjects and constantly broadening my knowledge through learning. Ramen enjoyer.

👨‍🎓 Education

  • Bachelors in Computer Science @ STU FEI

🥇 Achievements


patrikzeros-chatgpt-api-ui's People

Contributors

lmeerwood avatar patrikzudel avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

patrikzeros-chatgpt-api-ui's Issues

Ability to rebind Enter to send the message without the history

  • I have read all open and closed Issues and confirm that this is not a duplicate.

Is your feature request related to a problem? Please describe.

The default action for sending messages [Enter] is to send message with the history. But that uses a lot of tokens in long conversations and the user is billed per token.

Describe the solution you'd like

It would be useful to add ability to rebind default action [enter] to send the message without the history in the settings.

Describe alternatives you've considered

Alternative is to add keyboard shortcut for sending the message without the history.

Or add ability to select message, from which to start the history. So the entire history is not sent.

Or add a lock button, so the uses doesn't accidentally send the message with the history.

Additional context

src/App.svelte:591

The "ENTER" key does not work as it should

  • I have read all open and closed Issues and confirm that this is not a duplicate.

Describe the bug
"I'm not sure if it's actually a bug or intentional, but when typing a message and hitting "ENTER" instead of sending the message, it just creates a new line, like when we press (SHIFT+ENTER)."

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
I hope it works as it should, when typing a message and hitting "ENTER" it should send our request and not break to a new line. It should work like ChatGPT or any other chat bot does

Screenshots
N/A

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Chrome
  • Version 111

Smartphone (please complete the following information):

  • Device: N/A
  • OS: N/A
  • Browser: N/A
  • Version: N/A

Additional context
N/A

Better error messaging

Currently, the error message is more confused than me

There was an error. Maybe the API key is wrong? Or the servers could be down?

The error message should instead be specific, so users can understand what the problem is. It can be figured out by digging into the dev console, but might as well surface it. For example, if its the token issue, that chat is never going to recover until msgs are deleted, so the user should know.

If your Issue will not be using a template it will be deleted.

So far almost no issues have been correctly written and too often its very hard to discern what the actual issue is and how to replicate it.

The point of the template is for users to fill it, not to delete it without even bothering to read it.
You should only delete the parts that are irrelevant to your issue/request.

When you are describing a:

  • Bug: provide info on how to replicate the bug.
    • Just saying "This doesn't work for me [picture], why?" is not a bug report. You need to provide all the information that is implied in the template.
  • Feature request: Describe what you want to happen, and how it should look and where it should be located.
    • For example, saying "I want the UI to be better" is not a feature request as it is too abstract and gives no feedback. You could literally say you want it to be the "best" and it would hold the same value as no one can understand what it actually means. Say what, where and how you want something improved specifically.

The model: GPT4 does not exist

  • I have read all open and closed Issues and confirm that this is not a duplicate.

Describe the bug
When GPT4-8k or GPT4-32k is selected in the settings menu, and a message is sent, the system responds with a message that "gpt-4 does not exist" or "gpt4-32k does not exist"

To Reproduce
Steps to reproduce the behavior:

  1. Go to settings in the bottom right
  2. Choose either of the two GPT4 models
  3. Send a message
  4. System responds with - The model: GPT4 does not exist

Expected behavior
GPT4 is supposed to reply as expected

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows
  • Browser Firefox
  • Version 111

Additional context
GPT3.5 Turbo works as expected.

Multiple Completions Support

Allow for multiple chats to work simultaneously. It would greatly increase productivity to have multiple chats running at once as the completions are taking place. I believe it currently gets messed up when you try to do this and combines both results at the same time as it's answering.

Can't run the app locally with the provided command, throws error

  • I have read all open and closed Issues and confirm that this is not a duplicate.

Describe the bug
Can't run the app locally with the provided command, throws error

To Reproduce
Steps to reproduce the behavior:

  1. Clone the repo
  2. cd inside
  3. npm run dev

Expected behavior
A clear and concise description of what you expected to happen.
The app to start running locally

Screenshots
If applicable, add screenshots to help explain your problem.

> [email protected] dev /Users/sachit/Documents/Documents - Sachit’s MacBook Pro/Misc/Code/PatrikZeros-ChatGPT-API-UI
> vite

internal/modules/cjs/loader.js:1172
      throw new ERR_REQUIRE_ESM(filename, parentPath, packageJsonPath);
      ^

0 info it worked if it ends with ok
3 info using [email protected]
4 verbose run-script [ 'predev', 'dev', 'postdev' ]
Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: /Users/sachit/Documents/Documents - Sachit’s MacBook Pro/Misc/Code/PatrikZeros-ChatGPT-API-UI/node_modules/vite/bin/vite.js
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1172:13)
    at Module.load (internal/modules/cjs/loader.js:1000:32)
    at Function.Module._load (internal/modules/cjs/loader.js:899:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)
    at internal/main/run_main_module.js:18:47 {
  code: 'ERR_REQUIRE_ESM'
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] dev: `vite`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/sachit/.npm/_logs/2023-03-18T06_58_22_195Z-debug.log

Desktop (please complete the following information):

  • OS: [e.g. iOS] MacOS Ventura
  • Version [e.g. 22] Newest

Markdown formatted copy paste button

When paragraphs of output are copied into another word document like google docs, the formatting becomes difficult to work with i.e. dark background and there is no spacing in between the paragraphs.. Please try it out.

On another note could you please add a non-dark mode and also a copy icon next to the bin icon next to every prompt just like in native chatgpt client to facilitate ease of copying? Thank you

Allow scroll up while generation takes place

  • I have read all open and closed Issues and confirm that this is not a duplicate.

PROBLEM:

When the api streams data to the interface, in the regular chatgpt UI from openai we are able to scroll up while generation takes place. Unfortunately, when trying to scroll up in this ui, it scroll back down when a new token is generated.

SOLUTION:

Allow scroll up while generation takes place while still scrolling down with new text generation only if the user hasn't scrolled up during generation.

gpt-4 8k and 32k not available

  • I have read all open and closed Issues and confirm that this is not a duplicate.

I just cloned the repo to test it out. the 3.5 turbo works great but when i changed to either gpt4 option it states that they are not available. I don't know if this is a feature waiting to happen, an issue with the client or backend, so i reported it.

The error the client gives is: The model: gpt-4 does not exist

The way i repeated this was to just goto the settings and change from gpt3.5 to gpt4 8k or 32k. Then i just create a new prompt and it gives the above error code in the web client

I can see issue #21 is where the feature to change model was added.

Expected behavior
The gpt4 model options would work

Desktop

  • OS: EndevourOS (arch linux base)
  • Browser chromium
  • Version 111.0.5563.146 (Official Build) Arch Linux (64-bit)
  • Docker: version 23.0.2, build 569dd73db1
    gpt-issue

Unable to close a chat session unless another chat session exists

  • I have read all open and closed Issues and confirm that this is not a duplicate.

PROBLEM

The chats from the chat pane can only be closed if another chat exists. So if you have only 1 active chat in the pane, you will have to click on new chat to spawn a new chat and only then will you be able to close the old one.

STEPS TO REPRODUCE

Steps to reproduce the behavior:

  1. Delete all chat sessions
  2. Try to click on x to close the last remaining chat
  3. Action cannot be performed
  4. Click on new chat to spawn a new session
  5. Now the x can be clicked on the old chat to close it

EXPECTED BEHAVIOUR

When you try close the last remaining chat session, it should allow the action and start a new empty chat instead

SCREENSHOT

Screenshot (9)

Azure support request

  • I have read all open and closed Issues and confirm that this is not a duplicate.

Is your feature request related to a problem? Please describe.
I want to use GPT4-32k but only have access through azure API

Describe the solution you'd like
add support for azure API endpoints and keys

Bug Report - Deleting all messages causes site malfunction and prevents reloading

To reproduce the issue, clear all chats including the default empty chat. This will cause the site to stop responding. Reloading the page will result in a blank display. The only way to recover the site's functionality is by deleting site data.

This issue is particularly concerning for new users who may attempt to clear their test conversations and accidentally encounter this problem.

Standalone chat-memory / history prompt module

Hi, I like your project as one of the first that I've seen that takes token budget into consideration. I have been looking into this for awhile, outlining what I think could make a useful standalone library for chat-memory. I'm curious if you would be interested in working on this together?

I've outlined and started here: https://github.com/neural-loop/chat-memory/blob/main/SPEC.md

Here is the general overview that I've been looking at

  • Multiple buffers
    • messages (a log of prompts,response, timestamp, userid, token count)
    • medium term (a summarized version)
    • long term (a very condensed history)
    • a buffer is set via config (example 4096), and a person could set say 30% allocated to long term and 50% medium term, and 20% to messages)
  • Keyword tagging
    • messages are tagged with keywords
    • prompts containing the keywords will pull in those messages to the returning history prompt
  • Configurable Storage options
    • localStorage
    • database / sqlite / cloud
  • Configurable Summary & Keywords

I have been playing around with some code for this in python and javascript over the last week, but it's still in a conceptual space. Seems it could be useful to un-tether this from the specific implementations, as multiple people are working on similar tasks / chatbot type interfaces.

ability to change category names

I'd like to be able to change the chat category names from the default auto generated ones like you can on the regular chatgpt interface.

Allow scroll up while generation takes place

Hi there! Is there a way to scroll to the top of ChatGpt's message in the UI? Currently, the page keeps scrolling down every time a new character is printed. It would be great to be able to see the beginning of ChatGpt's output while it's still typing. Thanks!

Token lengths becomes too long after some conversations.

After some conversations, OpenAI consistently returned the following error message.

"This model's maximum context length is 4096 tokens. However, your messages resulted in 4358 tokens. Please reduce the length of the messages."

This may be caused by the history. It is need to restrict the history length.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.