Git Product home page Git Product logo

anki-quick-ai's People

Contributors

chuanqixu 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

Watchers

 avatar

Forkers

marquiswang

anki-quick-ai's Issues

An error occurred with version 23.10

Error information:
An error occurred. Please start Anki while holding down the shift key, which will temporarily disable the add-ons you have installed.
If the issue only occurs when add-ons are enabled, please use the Tools > Add-ons menu item to disable some add-ons and restart Anki, repeating until you discover the add-on that is causing the problem.
When you've discovered the add-on that is causing the problem, please report the issue to the add-on author.
Debug info:
Anki 23.10 (51a10f09) Python 3.9.15 Qt 6.5.3 PyQt 6.5.3
Platform: macOS-14.1.1-arm64-arm-64bit
Flags: frz=True ao=True sv=3
Add-ons, last update check: 2023-11-08 13:40:58
Add-ons possibly involved: ⁨Anki Quick AI⁩

Caught exception:
Traceback (most recent call last):
File "/Users/alanus/Library/Application Support/Anki2/addons21/547821970/controller.py", line 171, in run_add_on
run_dialog = RunDialog(parent)
File "/Users/alanus/Library/Application Support/Anki2/addons21/547821970/gui/run_dialog.py", line 15, in init
self.initUI()
File "/Users/alanus/Library/Application Support/Anki2/addons21/547821970/gui/run_dialog.py", line 65, in initUI
layout.addWidget(self.run_button, 0, Qt.AlignCenter) # align button to the center
AttributeError: type object 'Qt' has no attribute 'AlignCenter'

Unable to select model: "API key is not valid"

Hi there,

Thanks for taking the time to develop this!

I'd like to try it out, but after entering my OpenAI API Key via the add-on config, I can't seem to select a model - the add-on continually indicates "API key is not valid" and does not provide a dropdown to select a model. I've recreated the API key via https://platform.openai.com/api-keys, so I'm fairly confident I'm using a valid API key. Screenshot provided below::

image

In addition, trying to use the prompt interface yields the following error:

Anki 23.12.1 (1a1d4d54)  (ao)
Python 3.9.15 Qt 6.6.1 PyQt 6.6.1
Platform: Windows-10-10.0.22621

Traceback (most recent call last):
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\controller.py", line 66, in run
    self.initial_response()
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\controller.py", line 92, in initial_response
    self.response(prompt)
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\controller.py", line 76, in response
    response = call_openai(self.model, prompt, self.system_prompt, **self.ai_config)
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\ai.py", line 15, in call_openai
    completion = openai.ChatCompletion.create(
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\lib\openai\api_resources\chat_completion.py", line 25, in create
    return super().create(*args, **kwargs)
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\lib\openai\api_resources\abstract\engine_api_resource.py", line 153, in create
    response, _, api_key = requestor.request(
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\lib\openai\api_requestor.py", line 298, in request
    resp, got_stream = self._interpret_response(result, stream)
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\lib\openai\api_requestor.py", line 700, in _interpret_response
    self._interpret_response_line(
  File "C:\Users\qpmch\AppData\Roaming\Anki2\addons21\547821970\lib\openai\api_requestor.py", line 763, in _interpret_response_line
    raise self.handle_error_response(
openai.error.InvalidRequestError: invalid model ID

===Add-ons (active)===
(add-on provided name [Add-on folder, installed at, version, is config changed])
'' ['readwise-anki-gpt', 0, 'None', '']
Anki Quick AI ['547821970', 2023-11-29T22:37, 'None', mod]

===IDs of active AnkiWeb add-ons===
547821970

===Add-ons (inactive)===
(add-on provided name [Add-on folder, installed at, version, is config changed])

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.