Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
@@ -52,7 +52,7 @@ llm = ChatOpenAI(
|
|
52 |
|
53 |
# Function to generate a more appropriate name based on content
|
54 |
def generate_name_based_on_content(text,industry):
|
55 |
-
prompt = f"Generate a meaningful file name for the following content: {text[:
|
56 |
response = llm([HumanMessage(content=prompt)]).content
|
57 |
|
58 |
# Extract the generated file name and clean it
|
|
|
52 |
|
53 |
# Function to generate a more appropriate name based on content
|
54 |
def generate_name_based_on_content(text,industry):
|
55 |
+
prompt = f"Generate a meaningful file name for the following content: {text[:400]} based on the given industry {industry}" # Truncate text to first 200 characters
|
56 |
response = llm([HumanMessage(content=prompt)]).content
|
57 |
|
58 |
# Extract the generated file name and clean it
|