The Modal LLM wrapper class which will accept your deployed web endpoint’s URL.
Copy
Ask AI
from langchain_community.llms import Modalendpoint_url = "https://ecorp--custom-llm-endpoint.modal.run" # REPLACE ME with your deployed Modal web endpoint's URLllm = Modal(endpoint_url=endpoint_url)llm_chain = LLMChain(prompt=prompt, llm=llm)question = "What NFL team won the Super Bowl in the year Justin Beiber was born?"llm_chain.run(question)
Assistant
Responses are generated using AI and may contain mistakes.