Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -237,7 +237,7 @@ def chunk_python_file_content(content, char_limit=1572):
|
|
237 |
|
238 |
# Add method definition to the current chunk if it fits
|
239 |
if current_chunk_size + method_def_size <= char_limit:
|
240 |
-
current_chunk += f"{method_def.strip()}\n"
|
241 |
current_chunk_size += method_def_size
|
242 |
else:
|
243 |
# Start a new chunk if the method definition exceeds the limit
|
|
|
237 |
|
238 |
# Add method definition to the current chunk if it fits
|
239 |
if current_chunk_size + method_def_size <= char_limit:
|
240 |
+
current_chunk += f"# This is a class method of class: {class_node.name}\n{method_def.strip()}\n"
|
241 |
current_chunk_size += method_def_size
|
242 |
else:
|
243 |
# Start a new chunk if the method definition exceeds the limit
|