
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Superduper allows users to work with openai API models.
pip install superduper_openai
Class | Description |
---|---|
superduper_openai.model.OpenAIEmbedding | OpenAI embedding predictor. |
superduper_openai.model.OpenAIChatCompletion | OpenAI chat completion predictor. |
superduper_openai.model.OpenAIImageCreation | OpenAI image creation predictor. |
superduper_openai.model.OpenAIImageEdit | OpenAI image edit predictor. |
superduper_openai.model.OpenAIAudioTranscription | OpenAI audio transcription predictor. |
superduper_openai.model.OpenAIAudioTranslation | OpenAI audio translation predictor. |
from superduper_openai.model import OpenAIEmbedding
model = OpenAIEmbedding(identifier='text-embedding-ada-002')
model.predict('Hello, world!')
from superduper_openai.model import OpenAIChatCompletion
model = OpenAIChatCompletion(model='gpt-3.5-turbo', prompt='Hello, {context}')
model.predict('Hello, world!')
from superduper_openai.model import OpenAIImageCreation
model = OpenAIImageCreation(
model="dall-e",
prompt="a close up, studio photographic portrait of a {context}",
response_format="url",
)
model.predict("cat")
import io
from superduper_openai.model import OpenAIImageEdit
model = OpenAIImageEdit(
model="dall-e",
prompt="A celebration party at the launch of {context}",
response_format="url",
)
with open("test/material/data/rickroll.png", "rb") as f:
buffer = io.BytesIO(f.read())
model.predict(buffer, context=["superduper"])
import io
from superduper_openai.model import OpenAIAudioTranscription
with open('test/material/data/test.wav', 'rb') as f:
buffer = io.BytesIO(f.read())
buffer.name = 'test.wav'
prompt = (
'i have some advice for you. write all text in lower-case.'
'only make an exception for the following words: {context}'
)
model = OpenAIAudioTranscription(identifier='whisper-1', prompt=prompt)
model.predict(buffer, context=['United States'])
import io
from superduper_openai.model import OpenAIAudioTranslation
with open('test/material/data/german.wav', 'rb') as f:
buffer = io.BytesIO(f.read())
buffer.name = 'test.wav'
prompt = (
'i have some advice for you. write all text in lower-case.'
'only make an exception for the following words: {context}'
)
e = OpenAIAudioTranslation(identifier='whisper-1', prompt=prompt)
resp = e.predict(buffer, context=['Emmerich'])
buffer.close()
FAQs
Superduper allows users to work with openai API models.
We found that superduper-openai demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.