Spaces:
Sleeping
Sleeping
Commit
·
0ffd7f7
1
Parent(s):
136dbfa
Upload Chatbot.py
Browse files- Chatbot.py +1 -1
Chatbot.py
CHANGED
@@ -76,7 +76,7 @@ def initialize_index():
|
|
76 |
logger.info("initialize_index start")
|
77 |
text_splitter = TokenTextSplitter(separator="。", chunk_size=1500
|
78 |
, chunk_overlap=DEFAULT_CHUNK_OVERLAP
|
79 |
-
, tokenizer=tiktoken.
|
80 |
node_parser = SimpleNodeParser(text_splitter=text_splitter)
|
81 |
service_context = ServiceContext.from_defaults(node_parser=node_parser)
|
82 |
d = 1536
|
|
|
76 |
logger.info("initialize_index start")
|
77 |
text_splitter = TokenTextSplitter(separator="。", chunk_size=1500
|
78 |
, chunk_overlap=DEFAULT_CHUNK_OVERLAP
|
79 |
+
, tokenizer=tiktoken.encoding_for_model("gpt-3.5-turbo").encode)
|
80 |
node_parser = SimpleNodeParser(text_splitter=text_splitter)
|
81 |
service_context = ServiceContext.from_defaults(node_parser=node_parser)
|
82 |
d = 1536
|