trained by a team of researcher at Meta AI. My primary function is to assist and converse with users like you, answering questions and engaging in discussion to the best of my ability. I'm here to help and provide information on a wide range of topics, so feel free to ask me anything!", additional_kwargs={}, example=False)# Setting additional parameters: temperature, max_tokens, top_pchat = ChatFireworks(model="accounts/fireworks/models/llama-v2-13b-chat", model_kwargs={"temperature":1, "max_tokens": 20, "top_p": 1})system_message = SystemMessage(content="You are to chat with the user.")human_message = HumanMessage(content="How's the weather today?")chat([system_message, human_message])    AIMessage(content="Oh hello there! *giggle* It's such a beautiful day today, isn", additional_kwargs={}, example=False)Simple Chat ChainYou can use chat models on fireworks, with system prompts and memory.from langchain.chat_models import ChatFireworksfrom langchain.memory import ConversationBufferMemoryfrom langchain.schema.runnable import RunnablePassthroughfrom langchain.prompts import ChatPromptTemplate, MessagesPlaceholderllm = ChatFireworks(model="accounts/fireworks/models/llama-v2-13b-chat", model_kwargs={"temperature":0, "max_tokens":64, "top_p":1.0})prompt = ChatPromptTemplate.from_messages([    ("system", "You are a helpful chatbot that speaks like a pirate."),    MessagesPlaceholder(variable_name="history"),    ("human", "{input}")])Initially, there is no chat memorymemory = ConversationBufferMemory(return_messages=True)memory.load_memory_variables({})    {'history': []}Create a simple chain with memorychain = RunnablePassthrough.assign(    history=memory.load_memory_variables | (lambda x: x["history"])) | prompt | llm.bind(stop=["\n\n"])Run the chain with a simple question, expecting an answer aligned with the system message provided.inputs = {"input": "hi im bob"}response = chain.invoke(inputs)response    AIMessage(content="Ahoy there, me hearty! Yer a fine lookin'
Fireworks accelerates product development on generative AI by creating an innovative AI experiment and production platform.
Fireworks accelerates product development on generative AI by creating an innovative AI experiment and production platform. ->: trained by a team of researcher at Meta AI. My primary function is to assist and converse with users like you, answering questions and engaging in discussion to the best of my ability. I'm here to help and provide information on a wide range of topics, so feel free to ask me anything!", additional_kwargs={}, example=False)# Setting additional parameters: temperature, max_tokens, top_pchat = ChatFireworks(model="accounts/fireworks/models/llama-v2-13b-chat", model_kwargs={"temperature":1, "max_tokens": 20, "top_p": 1})system_message = SystemMessage(content="You are to chat with the user.")human_message = HumanMessage(content="How's the weather today?")chat([system_message, human_message])    AIMessage(content="Oh hello there! *giggle* It's such a beautiful day today, isn", additional_kwargs={}, example=False)Simple Chat ChainYou can use chat models on fireworks, with system prompts and memory.from langchain.chat_models import ChatFireworksfrom langchain.memory import ConversationBufferMemoryfrom langchain.schema.runnable import RunnablePassthroughfrom langchain.prompts import ChatPromptTemplate, MessagesPlaceholderllm = ChatFireworks(model="accounts/fireworks/models/llama-v2-13b-chat", model_kwargs={"temperature":0, "max_tokens":64, "top_p":1.0})prompt = ChatPromptTemplate.from_messages([    ("system", "You are a helpful chatbot that speaks like a pirate."),    MessagesPlaceholder(variable_name="history"),    ("human", "{input}")])Initially, there is no chat memorymemory = ConversationBufferMemory(return_messages=True)memory.load_memory_variables({})    {'history': []}Create a simple chain with memorychain = RunnablePassthrough.assign(    history=memory.load_memory_variables | (lambda x: x["history"])) | prompt | llm.bind(stop=["\n\n"])Run the chain with a simple question, expecting an answer aligned with the system message provided.inputs = {"input": "hi im bob"}response = chain.invoke(inputs)response    AIMessage(content="Ahoy there, me hearty! Yer a fine lookin'