You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-**Data, Media & Entertainment:** Alpha Vantage (stocks and finance info) with ChartJS, Github, Foursquare, Last.fm, New York Times, Trakt.tv (movies/TV), Twitch, Tumblr (OAuth 1.0a example), Web Scraping
90
91
-**Maps and Location:** Google Maps, HERE Maps
@@ -108,7 +109,7 @@ I also tried to make it as **generic** and **reusable** as possible to cover mos
108
109
- Hosted: No need to install, see the MongoDB Atlas section
109
110
110
111
-[Node.js 22.12+](http://nodejs.org)
111
-
- Highly recommended: Use/Upgrade your NodeJS to the latest NodeJS 22 LTS version.
112
+
- Highly recommended: Use/Upgrade your Node.js to the latest Node.js 22 LTS version.
112
113
- Command Line Tools
113
114
- <imgsrc="https://upload.wikimedia.org/wikipedia/commons/1/1b/Apple_logo_grey.svg"height="17"> **Mac OS X:**[Xcode](https://itunes.apple.com/us/app/xcode/id497799835?mt=12) (or **OS X 10.9+**: `xcode-select --install`)
114
115
- <imgsrc="https://upload.wikimedia.org/wikipedia/commons/8/87/Windows_logo_-_2021.svg"height="17"> **Windows:**[Visual Studio Code](https://code.visualstudio.com) + [Windows Subsystem for Linux - Ubuntu](https://learn.microsoft.com/en-us/windows/wsl/install) OR [Visual Studio](https://www.visualstudio.com/products/visual-studio-community-vs)
@@ -1023,7 +1024,7 @@ You now have a choice - to include your JavaScript code in Pug templates or have
1023
1024
1024
1025
But it's also understandable if you want to take the easier road. Most of the time you don't even care about performance during hackathons, you just want to _"get shit done"_ before the time runs out. Well, either way, use whichever approach makes more sense to you. At the end of the day, it's **what** you build that matters, not **how** you build it.
1025
1026
1026
-
If you want to stick all your JavaScript inside templates, then in `layout.pug` - your main template file, add this to `head` block.
1027
+
If you want to stick all your JavaScript inside templates, then in `layout.pug` - your main template file, add this to the `head` block.
// This is the system prompt that instructs the LLM on how to classify the customer message
1586
+
// into the appropriate department.
1587
+
constmessageClassifierSystemPrompt=`You are a customer service classifier for an e-commerce platform. Your role is to identify the primary issue described by the customer and return the result in JSON format. Carefully analyze the customer's message and select one of the following departments as the classification result:
1588
+
1589
+
Order Tracking and Status
1590
+
Returns and Refunds
1591
+
Payments and Billing Issues
1592
+
Account Management
1593
+
Product Inquiries
1594
+
Technical Support
1595
+
Shipping and Delivery Issues
1596
+
Promotions and Discounts
1597
+
Marketplace Seller Support
1598
+
Feedback and Complaints
1599
+
1600
+
Provide the output in this JSON structure:
1601
+
1602
+
{
1603
+
"department": "<selected_department>"
1604
+
}
1605
+
Replace <selected_department> with the name of the most relevant department from the list above. If the inquiry spans multiple categories, choose the department that is most likely to address the customer's issue promptly and effectively.`;
error='TogetherAI API key is not set in environment variables.';
1528
1700
}elseif(!togetherAiModel){
1529
1701
error='TogetherAI model is not set in environment variables.';
1530
1702
}elseif(!inputText.trim()){
1531
-
error='Please enter a message to classify.';
1703
+
error='Please enter the customer message to classify.';
1532
1704
}else{
1533
1705
try{
1534
-
constsystemPrompt=`You are a customer service classifier for an e-commerce platform. Your role is to identify the primary issue described by the customer and return the result in JSON format. Carefully analyze the customer's message and select one of the following departments as the classification result:
1535
-
1536
-
Order Tracking and Status
1537
-
Returns and Refunds
1538
-
Payments and Billing Issues
1539
-
Account Management
1540
-
Product Inquiries
1541
-
Technical Support
1542
-
Shipping and Delivery Issues
1543
-
Promotions and Discounts
1544
-
Marketplace Seller Support
1545
-
Feedback and Complaints
1546
-
1547
-
Provide the output in this JSON structure:
1548
-
1549
-
{
1550
-
"department": "<selected_department>"
1551
-
}
1552
-
Replace <selected_department> with the name of the most relevant department from the list above. If the inquiry spans multiple categories, choose the department that is most likely to address the customer's issue promptly and effectively.`;
0 commit comments