openai-api Questions
2
Solved
I'm exploring the capabilities of the Whisper API and was wondering if it can be used to generate an .SRT file with transcriptions. From what I understand, this transcription to .SRT can be achieve...
Gerianne asked 2/10, 2023 at 20:2
4
I want to use Chat GPT Turbo api directly in react native (expo) with word by word stream here is working example without stream
fetch(`https://api.openai.com/v1/chat/completions`, {
body: JSON.s...
Sherrer asked 23/3, 2023 at 17:37
4
I am working on a react native chat app, and I would like to use openai api to implement auto replying.
There is stream available from openai's api, but it uses SSE, which seems not working well in...
Sunbow asked 28/12, 2023 at 8:9
4
In order to make a fine-tuned ChatGPT model, we need to upload a JSON file of training data. The OpenAI doc for file upload is here:
https://platform.openai.com/docs/api-reference/files/upload
But....
Repent asked 18/5, 2023 at 21:9
2
I am currently working on a way to implement the openai-node package into my Next.js application. Because of the long generation times of OpenAI completions, I want to make use of streaming (which ...
Pneumothorax asked 12/4, 2023 at 19:6
4
Solved
I am currently working on a chatbot, and as I am using Windows 11 it does not let me migrate to newer OpenAI library or downgrade it. Could I replace the ChatCompletion function with something else...
Sanative asked 17/11, 2023 at 23:9
2
I see there are ways of doing various image generation here: https://platform.openai.com/docs/api-reference/images
But I'm just trying to sent chat gpt a png file, ask "what is this?" or ...
Rickettsia asked 30/9, 2023 at 4:58
3
Solved
I tried executing a langchain agent. I want to save the output from verbose into a variable, but all I can access from the agent.run is only the final answer.
How can I save the verbose output to a...
Garratt asked 5/6, 2023 at 11:31
8
I want to stream the results of a completion via OpenAI's API.
The doc's mention using server-sent events - it seems like this isn't handled out of the box for flask so I was trying to do it client...
Brammer asked 30/8, 2022 at 19:20
2
I am using the OpenAI API to get embeddings for a bunch of sentences. And by a bunch of sentences, I mean a bunch of sentences, like thousands. Is there a way to make it faster or make it do the em...
Paratroops asked 24/12, 2022 at 11:12
5
Solved
Here is the full code. It runs perfectly fine on https://learn.deeplearning.ai/ notebook. But when I run it on my local machine, I get an error about
ImportError: Could not import docarray python ...
Nonu asked 11/8, 2023 at 1:41
4
I am experimenting with the GPT API by OpenAI and am learning how to use the GPT-3.5-Turbo model. I found a quickstart example on the web:
def generate_chat_completion(messages, model="gpt-3.5...
Benighted asked 16/4, 2023 at 3:42
4
Working with OpenAI API and below is my simple code, but getting deprecation warning for 'steam_to_file' method.
Code -
from openai import OpenAI
from pathlib import Path
client = OpenAI(
api_key...
Hypocrite asked 7/2 at 5:47
5
Getting error while importing Ollama from 'llama_index.llms' in Linux OS.
from llama_index.llms import Ollama
response = llm.complete(f"What is code?")
print(response)
I installed Olla...
Marmoreal asked 5/3 at 5:37
7
According to openAI's documentation,
https://platform.openai.com/docs/guides/chat/chat-vs-completions
you should get token usage from the response. However, I am currently working making the API ca...
Oldenburg asked 23/3, 2023 at 15:14
4
On occasion I'm getting a rate limit error without being over my rate limit. I'm using the text completions endpoint on the paid api which has a rate limit of 3,000 requests per minute. I am using ...
Williamswilliamsburg asked 18/2, 2023 at 17:5
9
I am trying to make a request to the openai API with the following code in express nodeJS:
import { Configuration, OpenAIApi } from "openai";
const configuration = new Configuration({
o...
Anuria asked 7/1, 2023 at 15:38
14
I've installed openai on my laptop with pip install openai.
Have installed on my laptop and after installed on the same folder where my code file is. But when I try to run the code I get ImportErro...
Multistage asked 14/4, 2022 at 14:22
5
Solved
I am trying to use the OpenAI Python SDK, I installed the latest version via pip and verified that it is installed via pip list. Now when I go to run the code and make a simple request I get an err...
Ecklund asked 10/11, 2023 at 18:45
2
Solved
I am using Python Flask app for chat over data. In the console I am getting streamable response directly from the OpenAI since I can enable streming with a flag streaming=True.
The problem is, that...
Sedgewick asked 18/5, 2023 at 20:53
2
I am working on a web application that will serve as the help system for one of my companies existing products. One of the features I have implemented is a chatbot that is powered by an Azure Open ...
Beverly asked 9/10, 2023 at 20:16
2
Solved
import os
from langchain.llms import OpenAI
import bs4
import langchain
from langchain import hub
from langchain.document_loaders import UnstructuredFileLoader
from langchain.embeddings import Open...
Poleaxe asked 27/11, 2023 at 8:1
2
Solved
I am trying to put together a simple "Q&A with sources" using Langchain and a specific URL as the source data. The URL consists of a single page with quite a lot of information on it....
Crore asked 15/6, 2023 at 11:31
2
Solved
I read the LangChain Quickstart.
There is a demo inside:
from langchain.llms import OpenAI
from langchain.chat_models import ChatOpenAI
llm = OpenAI()
chat_model = ChatOpenAI()
llm.predict("...
Casares asked 22/8, 2023 at 6:30
1
I've previously built a pdf searching tool in LangChain which uses the
chain.run(input_documents=, question=) syntax to ask the model questions along with context from that pdf.
I want to integrate...
Cliff asked 19/7, 2023 at 10:20
1 Next >
© 2022 - 2024 — McMap. All rights reserved.