Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: API Tutorial does not match expected output #2763

Closed
Tadashi-Hikari opened this issue Apr 20, 2024 · 3 comments
Closed

bug: API Tutorial does not match expected output #2763

Tadashi-Hikari opened this issue Apr 20, 2024 · 3 comments
Assignees
Labels
type: bug Something isn't working

Comments

@Tadashi-Hikari
Copy link

Tadashi-Hikari commented Apr 20, 2024

Describe the bug
Response to template code is incorret

Steps to reproduce
Steps to reproduce the behavior:

  1. Run a Jan.ai server using the tinyllama-1.1b model
  2. Go to https://jan.ai/api-reference
  3. Select either Python or Clojure as the target language
  4. Scroll down to the chat completions
  5. Copy the template code directly into an IDE and run

Expected behavior
A simple JSON response, matching the response shown on the API Reference page

Actual behavior
The returned response data is included in the attached text files

Environment details

  • Operating System: Windows 11
  • Jan Version: 4.11
  • Processor: Intel Core i7
  • RAM: 32GB
  • GPU: Nvidia 2080 TI (12GB)
  • VSCode, Behavior happened with multiple models. Using GPU acceleration & Nitro extension

Logs
See attached text
clojure response.txt
python response.txt
Screenshot 2024-04-20 173904
Screenshot 2024-04-20 173952

@Tadashi-Hikari Tadashi-Hikari added the type: bug Something isn't working label Apr 20, 2024
@Propheticus
Copy link

This is a streaming response. Set stream false and then you get all content in one go instead of separate tokens.

@Tadashi-Hikari
Copy link
Author

Tadashi-Hikari commented Apr 20, 2024

Thank you. that fixed it. Is there a note we can make on the API section of the website to show this?

@Tadashi-Hikari Tadashi-Hikari changed the title bug: [DESCRIPTION] bug: API Tutorial does not match expected output Apr 21, 2024
@louis-jan
Copy link
Contributor

Thank you for the API example bug report. We will update the example request.

@Van-QA Van-QA moved this to Planned in Jan & Cortex Apr 23, 2024
@irfanpena irfanpena moved this from Planned to In Progress in Jan & Cortex May 14, 2024
@irfanpena irfanpena mentioned this issue May 14, 2024
3 tasks
@Van-QA Van-QA added this to the v0.4.13 🌾 Broken Rice milestone May 15, 2024
@Van-QA Van-QA moved this from In Progress to QA in Jan & Cortex May 15, 2024
@Van-QA Van-QA closed this as completed May 16, 2024
@github-project-automation github-project-automation bot moved this from QA to Done in Jan & Cortex May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working
Projects
Archived in project
Development

No branches or pull requests

7 participants