langchain/docs/snippets/get_started/quickstart/import_llms.mdx

13 lines
199 B
Plaintext
Raw Normal View History

```python
from langchain.llms import OpenAI
from langchain.chat_models import ChatOpenAI
llm = OpenAI()
chat_model = ChatOpenAI()
llm.predict("hi!")
>>> "Hi"
chat_model.predict("hi!")
>>> "Hi"
```