This project is a branch of langchain-openai on QPython.
langchain-openai
This package contains the LangChain integrations for OpenAI through their openai SDK.
Installation and Setup
- Install the LangChain partner package
pip install langchain-openai
- Get an OpenAI api key and set it as an environment variable (
OPENAI_API_KEY)
Chat model
See a usage example.
from langchain_openai import ChatOpenAI
If you are using a model hosted on Azure, you should use different wrapper for that:
from langchain_openai import AzureChatOpenAI
For a more detailed walkthrough of the Azure wrapper, see here
Text Embedding Model
See a usage example
from langchain_openai import OpenAIEmbeddings
If you are using a model hosted on Azure, you should use different wrapper for that:
from langchain_openai import AzureOpenAIEmbeddings
For a more detailed walkthrough of the Azure wrapper, see here
LLM (Legacy)
LLM refers to the legacy text-completion models that preceded chat models. See a usage example.
from langchain_openai import OpenAI
If you are using a model hosted on Azure, you should use different wrapper for that:
from langchain_openai import AzureOpenAI
For a more detailed walkthrough of the Azure wrapper, see here
Metadata
Release files for langchain-openai-aipy 0.3.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| langchain_openai_aipy-0.3.9.tar.gz | 54.9 kB | Without provenance | Details for langchain_openai_aipy-0.3.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| langchain_openai_aipy-0.3.9-py3-none-any.whl | Python 3 | none | any | Details for langchain_openai_aipy-0.3.9-py3-none-any.whl |
Total release size: 115.1 kB
Release files / langchain_openai_aipy-0.3.9.tar.gz
| Download URL | langchain_openai_aipy-0.3.9.tar.gz |
|---|---|
| Size | 54.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
df10ddc575bff37e5666e02b7cfc0c2ced809e7a45ba85af8a77fe18794ab710
|
|
BLAKE2b-256 checksum How to use checksums |
1d7894d8bd499b65f75c54e5ef39ef8262ef256281b349e6325581d1ae834b63
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.7
|
Release files / langchain_openai_aipy-0.3.9-py3-none-any.whl
| Download URL | langchain_openai_aipy-0.3.9-py3-none-any.whl |
|---|---|
| Size | 60.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1d365128883530b3f488da05e533e2f739c73494d8cb90cf3f05a9c903d2b787
|
|
BLAKE2b-256 checksum How to use checksums |
5f4208a9fda9605e3dabfad7f63c5f373a4a0f40f514bcf1bd845712c97c7819
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.7
|
Security for langchain-openai-aipy 0.3.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.