Giter VIP home page Giter VIP logo

gpt-computer-assistant's Introduction

Upsonic | Self-Driven Autonomous Python Libraries

The Upsonic is designed to help data scientists and ML engineers efficiently manage and automate maintenance-free utility library creation. It provides a simple, easy-to-use Python interface to interact with the Upsonic platform. Website | Discord | Twitter

Features

  • Easy serialization of functions and classes, making them readily available for reuse across different projects.
  • Automatic documentation generation for effortless maintenance and readability.
  • Support for both direct and modular function importation from the library.
  • Streamlined version control and collaboration features, allowing teams to work together seamlessly.

Easiest Library View

Usponic proveides an dashboard for your team members. Everyone can access to the dashboard by their user status. After the accessing they can easily view the top libraries and automaticaly generated connections codes. image

Automaticaly Documentation

In Upsonic On-Prem dashboard we have automaticaly generated documentation for your each function, class, object or variables. For this you can use OpenAI GPT integration or a self-hosted Google Gemma model in your installation. They are making your documentations automaticaly. Also you can easily search your content.

  • Documentation
  • Time Complexity
  • Mistakes
  • Required Test Tyoes
  • Security Analyses
  • Tags

image

Installation

You need to install the Upsonic container.

Installing and Running On-Prem Container

Once the container is up and running, you can install the Upsonic Python Client Library on your local system using the pip package manager:

# pip install upsonic

Usage

Here's an updated quickstart guide to get you up and running with your container:

from upsonic import UpsonicOnPrem
upsonic = UpsonicOnPrem('https://your-server-address:5000', 'ACK_****************')



def sum(a, b):
    return a + b

upsonic.dump("math.basics.sum", sum)



math = upsonic.load_module("math")

math.basics.sum(5, 2)

Documentation

You can find detailed documentation, including advanced usage and API reference, in the official Upsonic Documentation .

Contributing

We welcome contributions to the Upsonic Python Client Library!

Support & Questions

For any questions or if you encounter an issue, please reach out to our support team at [email protected] or open an issue on the project's GitHub page.

Supporters

Bugra Kocaturk
Buğra Kocatürk
AWS Solution Architect

AWS Netherlands
Linkedin
Lemi Orhan Engin
Lemi Orhan Engin
CTO

Craftgate
Linkedin
Mehmet Emin Ozturk
Mehmet Emin Öztürk
Data Team Lead & Kaggle Master
Trendyol Group
Linkedin
Firat Gonen
Fırat Gönen
Chief data Officer & Kaggle Grandmaster 3X
Figopara
Linkedin
Arda Batuhan Demir
Arda Batuhan Demir
Senior DevOps Engineer

Lyrebird Studio
Linkedin
Hasan Ramazan Yurt
Hasan Ramazan Yurt
ML Engineer & Technical Founder
Nicky ai
Linkedin
Sezer Yavuzer Bozkır
Sezer Yavuzer Bozkır
Sr. Python Developer

Petleo
Linkedin
Ozan Günceler
Ozan Günceler
CTO
BSM Consultancy Limited
Linkedin
Mustafa Namoğlu
Mustafa Namoğlu
Co-Founder

İkas
Linkedin
Bünyamin Ergen
Bünyamin Ergen
AI Engineer & Python Developer & Top Ai Voice
eTaşın
Linkedin
Serdar İlarslan
Serdar İlarslan
Sr. Python developer

Easysize
Linkedin
Burak Emre Kabakçı
Burak Emre Kabakçı
Sr. Staff Software Engineer & Maker
LiveRamp
Linkedin
Ozge Oz
Ozge Oz
Partner

QNBEYOND Ventures
Linkedin
Emre Keskin
Emre Keskin
Staff Software Engineer

Oplog
Linkedin
Emrah Samdan
Emrah Şamdan
Senior product manager


Linkedin
Halil İbrahim Yıldırım
Halil İbrahim Yıldırım
Head of data science


Linkedin

Advisors

Talha Kılıç
Talha Kılıç
Tech Lead Bigdata


Emre Doğaner
Emre Doğaner
Fractional CMO for B2B SAAS

Funnelepic
Linkedin
Enes Akar
Enes Akar
CEO


Upstash
Linkedin

Customers

wears exar

gpt-computer-assistant's People

Contributors

abhinavcode13 avatar afsalafzz-pro avatar aykutgk avatar bathiatuss avatar davdadev avatar dawoodtouseef avatar deepsource-autofix[bot] avatar deepsource-io[bot] avatar eltociear avatar franzmartyn avatar gokborayilmaz avatar hkxtor avatar hryurt avatar koolendasheppi avatar kramstyles avatar mideky-hub avatar msclock avatar mumtazvurall avatar nekoouo avatar onuratakan avatar tc999 avatar ucaninek avatar vietnguyengit 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  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

gpt-computer-assistant's Issues

Why just Ubuntu?

This seems to work fine on any Linux distro that can run Python 3.9 (tested on Arch), so I'm not sure why the documentation is "Windows, macOS, and Ubuntu" instead of "Windows, macOS, and Linux"

error running after clean install

After insurng a clean install with the latest python 3.12.4, I cannot run computerassistant. I get the following error stack. I have gone through all the dependencies as well as I am able, but haven't found anything obvious. Any idea what might be wrong?

Traceback (most recent call last):
File "", line 198, in run_module_as_main
File "", line 88, in run_code
File "M:\Software\python\Scripts\computerassistant.exe_main
.py", line 4, in
File "M:\Software\python\Lib\site-packages\gpt_computer_assistant_init
.py", line 5, in
from .tooler import Tool
File "M:\Software\python\Lib\site-packages\gpt_computer_assistant\tooler.py", line 2, in
from langchain.tools import tool
File "M:\Software\python\Lib\site-packages\langchain\tools_init_.py", line 23, in
from langchain_core.tools import BaseTool, StructuredTool, Tool, tool
File "M:\Software\python\Lib\site-packages\langchain_core\tools.py", line 34, in
from langchain_core.callbacks import (
File "M:\Software\python\Lib\site-packages\langchain_core\callbacks_init_.py", line 22, in
from langchain_core.callbacks.manager import (
File "M:\Software\python\Lib\site-packages\langchain_core\callbacks\manager.py", line 29, in
from langsmith.run_helpers import get_run_tree_context
File "M:\Software\python\Lib\site-packages\langsmith\run_helpers.py", line 40, in
from langsmith import client as ls_client
File "M:\Software\python\Lib\site-packages\langsmith\client.py", line 52, in
from langsmith import env as ls_env
File "M:\Software\python\Lib\site-packages\langsmith\env_init_.py", line 3, in
from langsmith.env.runtime_env import (
File "M:\Software\python\Lib\site-packages\langsmith\env_runtime_env.py", line 10, in
from langsmith.utils import get_docker_compose_command
File "M:\Software\python\Lib\site-packages\langsmith\utils.py", line 31, in
from langsmith import schemas as ls_schemas
File "M:\Software\python\Lib\site-packages\langsmith\schemas.py", line 69, in
class Example(ExampleBase):
File "M:\Software\python\Lib\site-packages\pydantic\v1\main.py", line 286, in new
cls.try_update_forward_refs()
File "M:\Software\python\Lib\site-packages\pydantic\v1\main.py", line 807, in try_update_forward_refs
update_model_forward_refs(cls, cls.fields.values(), cls.config.json_encoders, localns, (NameError,))
File "M:\Software\python\Lib\site-packages\pydantic\v1\typing.py", line 554, in update_model_forward_refs
update_field_forward_refs(f, globalns=globalns, localns=localns)
File "M:\Software\python\Lib\site-packages\pydantic\v1\typing.py", line 520, in update_field_forward_refs
field.type
= evaluate_forwardref(field.type_, globalns, localns or None)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "M:\Software\python\Lib\site-packages\pydantic\v1\typing.py", line 66, in evaluate_forwardref
return cast(Any, type_)._evaluate(globalns, localns, set())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: ForwardRef._evaluate() missing 1 required keyword-only argument: 'recursive_guard'

Segmentation fault (core dumped) - Ubuntu

Hi ! 👋

I have [1] 1427530 segmentation fault (core dumped) computerassistant error while trying to interact with computerassistant.

When I ask a question, it answers well but crash just after.

Here is an example while asking "how are you ?"

~ computerassistant

[09:59:17] Upsonic active                                                                                                                                                   on_prem.py:130
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see https://github.com/pypa/pip/issues/5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
Collecting AppOpener==1.7
  Using cached appopener-1.7-py3-none-any.whl (12 kB)
Requirement already satisfied: wheel in /usr/lib/python3/dist-packages (from AppOpener==1.7) (0.37.1)
Requirement already satisfied: regex in /usr/local/lib/python3.10/dist-packages (from AppOpener==1.7) (2024.5.15)
Requirement already satisfied: psutil in /usr/lib/python3/dist-packages (from AppOpener==1.7) (5.9.0)
ERROR: Could not find a version that satisfies the requirement pywin32 (from appopener) (from versions: none)
ERROR: No matching distribution found for pywin32
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see https://github.com/pypa/pip/issues/5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
Collecting AppOpener==1.7
  Using cached appopener-1.7-py3-none-any.whl (12 kB)
Requirement already satisfied: wheel in /usr/lib/python3/dist-packages (from AppOpener==1.7) (0.37.1)
Requirement already satisfied: regex in /usr/local/lib/python3.10/dist-packages (from AppOpener==1.7) (2024.5.15)
Requirement already satisfied: psutil in /usr/lib/python3/dist-packages (from AppOpener==1.7) (5.9.0)
ERROR: Could not find a version that satisfies the requirement pywin32 (from appopener) (from versions: none)
ERROR: No matching distribution found for pywin32
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see https://github.com/pypa/pip/issues/5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
Requirement already satisfied: duckduckgo-search==5.3.0 in /usr/local/lib/python3.10/dist-packages (5.3.0)
Requirement already satisfied: click>=8.1.7 in /usr/local/lib/python3.10/dist-packages (from duckduckgo-search==5.3.0) (8.1.7)
Requirement already satisfied: orjson>=3.10.0 in /usr/local/lib/python3.10/dist-packages (from duckduckgo-search==5.3.0) (3.10.3)
Requirement already satisfied: curl-cffi>=0.6.2 in /usr/local/lib/python3.10/dist-packages (from duckduckgo-search==5.3.0) (0.6.4)
Requirement already satisfied: cffi>=1.12.0 in ./.local/lib/python3.10/site-packages (from curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (1.16.0)
Requirement already satisfied: certifi>=2024.2.2 in ./.local/lib/python3.10/site-packages (from curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (2024.2.2)
Requirement already satisfied: pycparser in ./.local/lib/python3.10/site-packages (from cffi>=1.12.0->curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (2.22)
Profile: None
pygame 2.5.2 (SDL 2.28.2, Python 3.10.12)
Hello from the pygame community. https://www.pygame.org/contribute.html
Imported all libraries
QWidget::setLayout: Attempting to set QLayout "" on MainWindow "", which already has a layout
Recording started...
State updated: talking
Recording stopped
Audio saved as voice_input.wav
ON RECORDING STOPPED
State updated: thinking
State updated: thinking
HTTP Request: POST https://api.openai.com/v1/audio/transcriptions "HTTP/1.1 200 OK"
HISTORY DB /home/lebaron/.local/lib/python3.10/site-packages/gpt_computer_assistant/utils/artifacts/history_default.db
LLM INPUT USER: How are you today?
HISTORY DB /home/lebaron/.local/lib/python3.10/site-packages/gpt_computer_assistant/utils/artifacts/history_default.db
HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 200 OK"
HISTORY DB /home/lebaron/.local/lib/python3.10/site-packages/gpt_computer_assistant/utils/artifacts/history_default.db
THE LAST MESSAGES I'm functioning perfectly, thank you! How can I help you today?
HTTP Request: POST https://api.openai.com/v1/audio/speech "HTTP/1.1 200 OK"
State updated: talking
State updated: idle
[1]    1427530 segmentation fault (core dumped)  computerassistant

OS information :

~ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04.4 LTS
Release:        22.04
Codename:       jammy

Python information :

~ python3 --version
Python 3.10.12

Openassistant version :

~ pip3 show gpt-computer-assistant
Name: gpt-computer-assistant
Version: 0.8.9
Summary: GPT

Thanks for the great project ! :smile:

Add Qwen-VL model?

Qwen-VL (ArXiv, GitHub, HugingFace) shows very promising results on various tasks, would it be possible to add it to the project or at least consider it?

I have not read the full source code, but from what I've seen it should be pretty straight forward, I could probably do it when I've a bit of time.

UI Improvement

I noticed one of the latest builds shows improvement to input box. Is this pertaining to making it mult-line for readability on bigger responses? I upgraded but did not see any changes to the input box overall.

TypeError: ForwardRef._evaluate() missing 1 required keyword-only argument: 'recursive_guard'

Hi, I am using python 3.12.4. After installing the gpt computer assistant in command, I failed to run it in command, it shows below codes:

C:\Users\90471>computerassistant
Traceback (most recent call last):
File "", line 198, in run_module_as_main
File "", line 88, in run_code
File "D:\Program Files\PYTHON\Scripts\computerassistant.exe_main
.py", line 4, in
File "D:\Program Files\PYTHON\Lib\site-packages\gpt_computer_assistant_init
.py", line 5, in
from .tooler import Tool
File "D:\Program Files\PYTHON\Lib\site-packages\gpt_computer_assistant\tooler.py", line 1, in
from langchain.tools import tool
File "D:\Program Files\PYTHON\Lib\site-packages\langchain\tools_init_.py", line 23, in
from langchain_core.tools import BaseTool, StructuredTool, Tool, tool
File "D:\Program Files\PYTHON\Lib\site-packages\langchain_core\tools.py", line 34, in
from langchain_core.callbacks import (
File "D:\Program Files\PYTHON\Lib\site-packages\langchain_core\callbacks_init_.py", line 22, in
from langchain_core.callbacks.manager import (
File "D:\Program Files\PYTHON\Lib\site-packages\langchain_core\callbacks\manager.py", line 29, in
from langsmith.run_helpers import get_run_tree_context
File "D:\Program Files\PYTHON\Lib\site-packages\langsmith\run_helpers.py", line 40, in
from langsmith import client as ls_client
File "D:\Program Files\PYTHON\Lib\site-packages\langsmith\client.py", line 52, in
from langsmith import env as ls_env
File "D:\Program Files\PYTHON\Lib\site-packages\langsmith\env_init_.py", line 3, in
from langsmith.env.runtime_env import (
File "D:\Program Files\PYTHON\Lib\site-packages\langsmith\env_runtime_env.py", line 10, in
from langsmith.utils import get_docker_compose_command
File "D:\Program Files\PYTHON\Lib\site-packages\langsmith\utils.py", line 31, in
from langsmith import schemas as ls_schemas
File "D:\Program Files\PYTHON\Lib\site-packages\langsmith\schemas.py", line 69, in
class Example(ExampleBase):
File "D:\Program Files\PYTHON\Lib\site-packages\pydantic\v1\main.py", line 286, in new
cls.try_update_forward_refs()
File "D:\Program Files\PYTHON\Lib\site-packages\pydantic\v1\main.py", line 807, in try_update_forward_refs
update_model_forward_refs(cls, cls.fields.values(), cls.config.json_encoders, localns, (NameError,))

File "D:\Program Files\PYTHON\Lib\site-packages\pydantic\v1\typing.py", line 554, in update_model_forward_refs
update_field_forward_refs(f, globalns=globalns, localns=localns)
File "D:\Program Files\PYTHON\Lib\site-packages\pydantic\v1\typing.py", line 520, in update_field_forward_refs
field.type
= evaluate_forwardref(field.type_, globalns, localns or None)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Program Files\PYTHON\Lib\site-packages\pydantic\v1\typing.py", line 66, in evaluate_forwardref
return cast(Any, type_)._evaluate(globalns, localns, set())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: ForwardRef._evaluate() missing 1 required keyword-only argument: 'recursive_guard'

I'm not good at coding. Can anyone help? Thanks.

Can't find model.

I have created an API key via openai's website but the console outputs an error:
openai.NotFoundError: Error code: 404 - {'error': {'message': 'The model `gpt-4o` does not exist or you do not have access to it.', 'type': 'invalid_request_error', 'param': None, 'code': 'model_not_found'}}

I cant understand if my api key is gpt3.5 or gpt4.

some depdency is missing and cannot install per README.md

Errors with installtion:

C:\Users\jeffrey>pip3 install gpt-computer-assistant WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip. Please see pypa/pip#5599 for advice on fixing the underlying issue. To avoid this problem you can invoke Python with '-m pip' instead of running pip directly. Defaulting to user installation because normal site-packages is not writeable Collecting gpt-computer-assistant Downloading gpt_computer_assistant-0.6.12.tar.gz (163 kB) |████████████████████████████████| 163 kB 163 kB/s ERROR: Could not find a version that satisfies the requirement langgraph==0.0.55 (from gpt-computer-assistant) (from ver sions: 0.0.8) ERROR: No matching distribution found for langgraph==0.0.55 (from gpt-computer-assistant)

after install langgraph with command pip3 install langgraph==0.0.55, a new error occurred as follows:

C:\Users\jeffrey>pip3 install gpt-computer-assistant
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip. Please see pypa/pip#5599 for advice on fixing the underlying issue. To avoid this problem you can invoke Python with '-m pip' instead of running pip directly. Defaulting to user installation because normal site-packages is not writeable WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'Prox yError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/gpt-computer-assistant/ WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'Prox yError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/gpt-computer-assistant/ WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'Prox yError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/gpt-computer-assistant/ WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'Prox yError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/gpt-computer-assistant/ WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'Prox yError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/gpt-computer-assistant/ ERROR: Could not find a version that satisfies the requirement gpt-computer-assistant==0.6.12 (from versions: none) ERROR: No matching distribution found for gpt-computer-assistant==0.6.12

run command pip3 install gpt-computer-assistant==0.6.12 to install but still with above error.

Enviroment:

system: Win10

C:\Users\jeffrey>pip --version
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of
Please see pypa/pip#5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
pip 24.0 from C:\Users\jeffrey\AppData\Roaming\Python\Python38\site-packages\pip (python 3.8)

Adding Gemini 1.5-Pro/Flash

Hi, any plans to add Google's LLMs? Both are multimodal and have a very useful free tier for the API, so a lot of people use it.

Bug: object has no attribute 'should_paint'

Hello! I have issue with

  File "C:\Users\kosli\AppData\Roaming\Python\Python312\site-packages\gpt_computer_assistant\gpt_computer_assistant.py", line 226, in paintEvent
    if not self.should_paint:
           ^^^^^^^^^^^^^^^^^
AttributeError: 'MainWindow' object has no attribute 'should_paint'

How to fix that? Do I miss something?

ole32 Windows

when launching computerassistant the error occurs and I have no idea why, I have ole32.dll in my C:\Windows\System32 folder.
OSError: ctypes.util.find_library() did not manage to locate a library called 'ole32'

Defaults to ffmpeg, then crashes

AppData\Local\Programs\Python\Python311\Lib\site-packages\pydub\utils.py:170: RuntimeWarning: Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work
  warn("Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work", RuntimeWarning)
pygame 2.5.2 (SDL 2.28.3, Python 3.11.5)
Hello from the pygame community. https://www.pygame.org/contribute.html
Imported all libraries
Loading font
C:\Users\Schooi\AppData\Local\Programs\Python\Python311\Lib\site-packages\gpt_computer_assistant\utils\media\SF-Pro-Text-Bold.otf
QWidget::setLayout: Attempting to set QLayout "" on MainWindow "", which already has a layout
Traceback (most recent call last):
  File "C:\Users\Schooi\AppData\Local\Programs\Python\Python311\Lib\site-packages\gpt_computer_assistant\gpt_computer_assistant.py", line 343, in paintEvent
    if not self.should_paint:
           ^^^^^^^^^^^^^^^^^
AttributeError: 'MainWindow' object has no attribute 'should_paint'

That is the error I get. The installation goes very well, and I get that only after running computerassistant on cmd.

How can i run it?

just installed the app,how i start it?
theres no launcher,i cant start it on cmd or python terminal

Making wide input box and wrapping

Awesome project! Is it possible to have a bigger display that can wrap lines instead of a single line? Would be so beneficial when reading responses that have a lot of text.

Thanks! Keep up the awesome work!

Chat Gpt Model

Great work of code!!! But I don't have a Chat-gpt4o api key and it's giving me errors when I connect to using the 3.5 version api

Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'Authorization required, but no authorization protocol specified\n'

Eror:
Traceback (most recent call last):
File "/home/dukhanin/venvs/gpt-computer-assistant/bin/computerassistant", line 5, in
from gpt_computer_assistant.start import start
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/gpt_computer_assistant/init.py", line 5, in
from .tooler import Tool
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/gpt_computer_assistant/tooler.py", line 5, in
from .agent.agent import custom_tools
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/gpt_computer_assistant/agent/init.py", line 2, in
from .assistant import *
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/gpt_computer_assistant/agent/assistant.py", line 11, in
from ..screen.shot import *
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/gpt_computer_assistant/screen/shot.py", line 2, in
import pyautogui
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/pyautogui/init.py", line 246, in
import mouseinfo
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/mouseinfo/init.py", line 223, in
_display = Display(os.environ['DISPLAY'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/Xlib/display.py", line 80, in init
self.display = _BaseDisplay(display)
^^^^^^^^^^^^^^^^^^^^^
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/Xlib/display.py", line 62, in init
display.Display.init(*(self, ) + args, **keys)
File "/home/dukhanin/venvs/gpt-computer-assistant/lib/python3.12/site-packages/Xlib/protocol/display.py", line 129, in init
raise error.DisplayConnectionError(self.display_name, r.reason)
Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'Authorization required, but no authorization protocol specified\n'

OS: ubuntu 24, using venv

how to configure profile?

I'm stuck here, and there's no guide for configuring profiles in the readme

C:\Users\me>computerassistant                                                                                  Profile: None                                                                                                           [23:13:40] Upsonic active                                                                                on_prem.py:130 

Fully localized suggestion

I believe this project has huge potential to have an option to be fully local and private. For example adding LM Studio integration to allow any downloaded LLM or VLM like Phi-3 Vision. And integrating xVASynth or XTTS(Local TTS).

MacOS Sonoma 14.5 Screen Recording Permissions?

Hey @onuratakan. I'm trying to run it but it seems like no matter what I do, GPT assistant is unable to see the contents of my screen. I got a feeling that this has to do with the fact that I need to give permissions to the application to do screenshots/screen recordings, however, I'm not sure what is the "application" nam that I should be giving permissions to on my Mac.

I already have the following, but what should I be adding so that GPT Computer Assistant is able to "see"?
image

Adding Documentation and Improving Code Quality.

Proposal: Improve Code Documentation

Description

Hello and good day. I would love to propose adding comprehensive code documentation, which impacts readability and maintainability to the codebase. I propose enhancing it by adding comments, docstrings, and Sphinx documentation.

Goals

  1. Improve code readability for contributors.
  2. Facilitate understanding of complex logic.
  3. Enable automatic documentation generation.

Areas to Address

  • #99
  • #100
  • Set up Sphinx for API documentation.
  • Provide initial PRs for adding comments and docstrings to key modules.

If this is considered, I'd love to be a part of the contribution, study the code, add comments, docstrings (numpy) and sphinx documentation. If possible and approved, PEP8 code style can be employed.

Please let me know if this proposal aligns with the project's goals, and if there are any specific guidelines or preferences to follow while implementing these changes.

Bug: OSError: ctypes.util.find_library() did not manage to locate a library called 'ole32'

Hi!

After running computerassistant, I faced this error rigth here at the end of the logs:

Requirement already satisfied: pycparser in c:\users\sans\appdata\local\programs\python\python312\lib\site-packages (from cffi>=1.12.0->curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (2.22)
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Scripts\computerassistant.exe\__main__.py", line 7, in <module>
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\gpt_computer_assistant\start.py", line 19, in start
    from .gpt_computer_assistant import QApplication, MainWindow, sys
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\gpt_computer_assistant\gpt_computer_assistant.py", line 9, in <module>
    from .gui.button import *
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\gpt_computer_assistant\gui\button.py", line 5, in <module>
    from ..audio.record import *
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\gpt_computer_assistant\audio\__init__.py", line 1, in <module>
    from .record import *
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\gpt_computer_assistant\audio\record.py", line 15, in <module>
    import soundcard as sc
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\soundcard\__init__.py", line 13, in <module>
    from soundcard.mediafoundation import *
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\soundcard\mediafoundation.py", line 19, in <module>
    _ole32 = _ffi.dlopen('ole32')
             ^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\cffi\api.py", line 150, in dlopen
    lib, function_cache = _make_ffi_library(self, name, flags)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\cffi\api.py", line 832, in _make_ffi_library
    backendlib = _load_backend_lib(backend, libname, flags)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Sans\AppData\Local\Programs\Python\Python312\Lib\site-packages\cffi\api.py", line 827, in _load_backend_lib
    raise OSError(msg)
OSError: ctypes.util.find_library() did not manage to locate a library called 'ole32'
PS C:\Users\Sans>

How to fix that error? Do I miss something else?

After startup, a window appears then report an error message, and the window close itself.

After startup, a window appears then an error message appears, and the window close itself.

`C:\Windows\System32>computerassistant
[14:06:52] Upsonic active on_prem.py:130
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see pypa/pip#5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Requirement already satisfied: AppOpener==1.7 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (1.7)
Requirement already satisfied: wheel in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (0.43.0)
Requirement already satisfied: psutil in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (5.9.6)
Requirement already satisfied: pywin32 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (306)
Requirement already satisfied: regex in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (2023.10.3)
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see pypa/pip#5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Requirement already satisfied: AppOpener==1.7 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (1.7)
Requirement already satisfied: wheel in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (0.43.0)
Requirement already satisfied: psutil in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (5.9.6)
Requirement already satisfied: pywin32 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (306)
Requirement already satisfied: regex in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from AppOpener==1.7) (2023.10.3)
WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see pypa/pip#5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Requirement already satisfied: duckduckgo-search==5.3.0 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (5.3.0)
Requirement already satisfied: click>=8.1.7 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from duckduckgo-search==5.3.0) (8.1.7)
Requirement already satisfied: curl-cffi>=0.6.2 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from duckduckgo-search==5.3.0) (0.6.4)
Requirement already satisfied: orjson>=3.10.0 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from duckduckgo-search==5.3.0) (3.10.3)
Requirement already satisfied: colorama in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from click>=8.1.7->duckduckgo-search==5.3.0) (0.4.6)
Requirement already satisfied: cffi>=1.12.0 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (1.15.1)
Requirement already satisfied: certifi>=2024.2.2 in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (2024.6.2)
Requirement already satisfied: pycparser in c:\users\test\appdata\local\programs\python\python311\lib\site-packages (from cffi>=1.12.0->curl-cffi>=0.6.2->duckduckgo-search==5.3.0) (2.21)
Profile: None
pygame 2.5.2 (SDL 2.28.3, Python 3.11.0)
Hello from the pygame community. https://www.pygame.org/contribute.html
Imported all libraries
Loading font
C:\Users\test\AppData\Local\Programs\Python\Python311\Lib\site-packages\gpt_computer_assistant\utils\media\SF-Pro-Text-Bold.otf
QWidget::setLayout: Attempting to set QLayout "" on MainWindow "", which already has a layout
Traceback (most recent call last):
File "C:\Users\test\AppData\Local\Programs\Python\Python311\Lib\site-packages\gpt_computer_assistant\gpt_computer_assistant.py", line 394, in paintEvent
if not self.should_paint:
^^^^^^^^^^^^^^^^^
AttributeError: 'MainWindow' object has no attribute 'should_paint'

C:\Windows\System32>`

aio.py:39: RuntimeWarning: Proactor event loop does not implement add_reader family of methods required.

Error message on Windows 11 :
C:\Users\adam\anaconda3\envs\gpt_comp_env\Lib\site-packages\curl_cffi\aio.py:39: RuntimeWarning:
Proactor event loop does not implement add_reader family of methods required.
Registering an additional selector thread for add_reader support.
To avoid this warning use:
asyncio.set_event_loop_policy(WindowsSelectorEventLoopPolicy())

I found that this is because the asynchronous IO event loop (ProactorEventLoop) on Windows does not support the add_reader and add_writer methods. The solution is to set the WindowsSelectorEventLoopPolicy at the beginning of your program.Can add the following code at the top of aio.py:

import os
import asyncio

if os.name == 'nt':
    asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())

to avoid issues with unsupported read/write methods in ProactorEventLoop.
Additionally, the spelling error in the warning message has been corrected (from "Curlm alread closed!" to "Curlm already closed!").

Suggestions for new UI design.

Using PyQT webkit or something like that to render the UI using Chromium engine and styling it using Html/CSS seems a pretty good idea to me. It allows for a better UI design and UX.

Also, personally I think the UI is very mobile-like. I mean it doesn't look like a desktop application. It would be cool if you expanded the screen size by a lot and then utilizing all the empty spaces properly with an intuitive design.

Also I just discovered this repo and I'm going to look into it, so maybe I'll create a PR for the same. Cool project though.

Also I think calling this project something like GPA (GPT Assistant) is kinda cool since GPA matches with GTA and GPT both. But yeah anyways cool project, appreciate the work.

Does Not Work

عزیزان دل این چرا بالا میاد ولی کار نمیکنه

به من مبتدی کمک کنین مرسی

Request for Docker

Think this way, we could all avoid library incompatibility issues and enjoy it with even greater with fellow internet buds.

Assistant unusable LLM Issues - Windows 10

Hello, I made a GitHub account just to post this , so I hope I can get some help.

I am running into some very frustrating issues on Windows (64 bit) when trying to use this assistant, I can't get it to give me any output, all I can do is launch the app via CMD.

I am very interested in testing this application, The application has access to my API key and I'm a premium open ai user. I am also from Australia I'm not sure if this affects what models are useable through my API key
(right now none of the models work).

Things I've tried:
reset API Key
tried all available models in the application
disable VPN
tried to update URL in settings

This is what happens when I try to use any version of gpt 4 including 4o:

HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 404 Not Found"
Error in process_text Error code: 404 - {'error': {'message': 'The model gpt-4o does not exist or you do not have access to it.', 'type': 'invalid_request_error', 'param': None, 'code': 'model_not_found'}}
Updating from thread EXCEPTION: Error code: 404 - {'error': {'message': 'The model gpt-4o does not exist or you do not have access to it.', 'type': 'invalid_request_error', 'param': None, 'code': 'model_not_found'}}
State updated: idle

This is what happens when I try to use gpt 3.5:

C:\Users\jack\AppData\Local\Programs\Python\Python312\Lib\site-packages\gpt_computer_assistant\utils\artifacts\history_default.db
HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 429 Too Many Requests"
Retrying request to /chat/completions in 0.932674 seconds
HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 429 Too Many Requests"
Retrying request to /chat/completions in 1.678915 seconds
HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 429 Too Many Requests"
Retrying request to /chat/completions in 3.818514 seconds

This is what happens when I try to use the other models including groq:

EXCEPTION: HTTPConnectionPool(host='localhost', port=11434): Max retries exceeded with url: /api/chat (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x00000253CC3C4F20>: Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it'))

This what happens when I try to change url in settings (not sure if you have to do this, just playing around for solution):

NameError: name 'save_openai_url' is not defined. Did you mean: 'load_openai_url'?

Any assistance is much appreciated, I understand this is a work in progress and is temperamental.
Amazing work so far!

PortAudio library not found

When launching computerassistant, I get this error :

Traceback (most recent call last):
  File "/home/molives/.local/bin/computerassistant", line 8, in <module>
    sys.exit(start())
  File "/home/molives/.local/lib/python3.10/site-packages/gpt_computer_assistant/start.py", line 19, in start
    from .gpt_computer_assistant import QApplication, MainWindow, sys
  File "/home/molives/.local/lib/python3.10/site-packages/gpt_computer_assistant/gpt_computer_assistant.py", line 8, in <module>
    from .gui.button import *
  File "/home/molives/.local/lib/python3.10/site-packages/gpt_computer_assistant/gui/button.py", line 4, in <module>
    from ..audio.record import *
  File "/home/molives/.local/lib/python3.10/site-packages/gpt_computer_assistant/audio/__init__.py", line 1, in <module>
    from .record import *
  File "/home/molives/.local/lib/python3.10/site-packages/gpt_computer_assistant/audio/record.py", line 4, in <module>
    import sounddevice as sd
  File "/home/molives/.local/lib/python3.10/site-packages/sounddevice.py", line 71, in <module>
    raise OSError('PortAudio library not found')
OSError: PortAudio library not found

I fixed it by installing the libportaudio2 package in Ubuntu 22.04.
I think it would be a good idea to either install it from pip (I don't even know if this is possible) or to list it as a necessary package for Ubuntu.

Add comments to important functions

Extract and add code comments to important functions. Try to understand the code parts and what is their purpose also their connections and other things. After that just add small comments. Some times if you want you can add multiple commands in one part via ```

Local bin path configuration issue

Bug raised by one of the users: cc @MahdyMusave

WARNING: The script dotenv is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script mprof is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script openai is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script langsmith is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script upsonic is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script langchain-server is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
WARNING: The script computerassistant is installed in '/home/seyadkali/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
mitmproxy 10.2.3 requires mitmproxy-rs<0.6,>=0.5.1, which is not installed.
mitmproxy 10.2.3 requires urwid-mitmproxy<2.2,>=2.1.1, which is not installed.
censys 2.2.12 requires requests>=2.29.0, but you have requests 2.28.2 which is incompatible.
crackmapexec 5.4.0 requires aioconsole<0.4.0,>=0.3.3, but you have aioconsole 0.7.0 which is incompatible.
crackmapexec 5.4.0 requires masky<0.2.0,>=0.1.1, but you have masky 0.2.0 which is incompatible.
crackmapexec 5.4.0 requires minikerberos==0.3.3, but you have minikerberos 0.4.4 which is incompatible.
crackmapexec 5.4.0 requires neo4j<5.0.0,>=4.1.1, but you have neo4j 5.2.dev0 which is incompatible.
crackmapexec 5.4.0 requires paramiko<3.0.0,>=2.7.2, but you have paramiko 3.4.0 which is incompatible.
crackmapexec 5.4.0 requires pypsrp<0.8.0,>=0.7.0, but you have pypsrp 0.8.1 which is incompatible.
crackmapexec 5.4.0 requires termcolor<2.0.0,>=1.1.0, but you have termcolor 2.4.0 which is incompatible.
crackmapexec 5.4.0 requires xmltodict<0.13.0,>=0.12.0, but you have xmltodict 0.13.0 which is incompatible.
aioquic 1.0.0 requires cryptography>=42.0.0, but you have cryptography 41.0.3 which is incompatible.
theharvester 4.6.0 requires aiodns==3.1.1, but you have aiodns 3.2.0 which is incompatible.
theharvester 4.6.0 requires aiohttp==3.9.3, but you have aiohttp 3.9.1 which is incompatible.
theharvester 4.6.0 requires aiosqlite==0.20.0, but you have aiosqlite 0.17.0 which is incompatible.
theharvester 4.6.0 requires censys==2.2.11, but you have censys 2.2.12 which is incompatible.
theharvester 4.6.0 requires certifi==2024.2.2, but you have certifi 2023.11.17 which is incompatible.
theharvester 4.6.0 requires netaddr==1.2.1, but you have netaddr 0.10.1 which is incompatible.
theharvester 4.6.0 requires playwright==1.42.0, but you have playwright 0.0.0 which is incompatible.
theharvester 4.6.0 requires python-dateutil==2.9.0.post0, but you have python-dateutil 2.9.0 which is incompatible.
theharvester 4.6.0 requires requests==2.31.0, but you have requests 2.28.2 which is incompatible.
theharvester 4.6.0 requires retrying==1.3.4, but you have retrying 1.3.3 which is incompatible.
theharvester 4.6.0 requires setuptools==69.2.0, but you have setuptools 68.1.2 which is incompatible.
theharvester 4.6.0 requires shodan==1.31.0, but you have shodan 1.30.1 which is incompatible.
theharvester 4.6.0 requires slowapi==0.1.9, but you have slowapi 0.1.4 which is incompatible.
theharvester 4.6.0 requires uvicorn==0.28.0, but you have uvicorn 0.29.0 which is incompatible.
fastapi 0.110.0 requires starlette<0.37.0,>=0.36.3, but you have starlette 0.37.2 which is incompatible.
mitmproxy 10.2.3 requires aioquic<0.10,>=0.9.24, but you have aioquic 1.0.0 which is incompatible.
mitmproxy 10.2.3 requires asgiref<3.8,>=3.2.10, but you have asgiref 3.8.1 which is incompatible.
mitmproxy 10.2.3 requires pyOpenSSL<24.1,>=22.1, but you have pyopenssl 24.1.0 which is incompatible.

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.