silvanocerza commited on
Commit
61f90d6
1 Parent(s): d94b965

Change component name

Browse files
Files changed (1) hide show
  1. main.py +3 -3
main.py CHANGED
@@ -152,13 +152,13 @@ def search(question: str) -> GeneratedAnswer:
152
 
153
  query_pipeline.add_component("docs_retriever", retriever)
154
  query_pipeline.add_component("prompt_builder", prompt_builder)
155
- query_pipeline.add_component("gpt35", generator)
156
  query_pipeline.add_component("answer_builder", answer_builder)
157
 
158
  query_pipeline.connect("docs_retriever.documents", "prompt_builder.documents")
159
- query_pipeline.connect("prompt_builder.prompt", "gpt35.prompt")
160
  query_pipeline.connect("docs_retriever.documents", "answer_builder.documents")
161
- query_pipeline.connect("gpt35.replies", "answer_builder.replies")
162
  res = query_pipeline.run({"query": question})
163
  return res["answer_builder"]["answers"][0]
164
 
 
152
 
153
  query_pipeline.add_component("docs_retriever", retriever)
154
  query_pipeline.add_component("prompt_builder", prompt_builder)
155
+ query_pipeline.add_component("llm", generator)
156
  query_pipeline.add_component("answer_builder", answer_builder)
157
 
158
  query_pipeline.connect("docs_retriever.documents", "prompt_builder.documents")
159
+ query_pipeline.connect("prompt_builder.prompt", "llm.prompt")
160
  query_pipeline.connect("docs_retriever.documents", "answer_builder.documents")
161
+ query_pipeline.connect("llm.replies", "answer_builder.replies")
162
  res = query_pipeline.run({"query": question})
163
  return res["answer_builder"]["answers"][0]
164