<commit_before>#!/bin/sh

PID=`ps -ef | grep "hypermind" | grep "server.go" | grep -v grep | awk '{print $2}'`
if [ -z $PID ]; then
	echo "The server has yet to launch."
else
	kill $PID
	echo "The server has stopped!"
fi
DIR=`pwd`
LOG_DIR=$DIR/logs
if [ ! -d "$LOG_DIR" ]; then
	echo "Creating dir '$LOG_DIR' ..."
	mkdir "$LOG_DIR"
fi
go run $DIR/server.go 2>&1 | cronolog "$LOG_DIR/hypermind.log.%Y-%m-%d" &
echo "The server has been launched."<commit_msg>Update deploy.sh: kill current process via server port.<commit_after>#!/bin/sh

SERVER_PORT="9091"
PID=`ps -ef | grep "hypermind" | grep "server" | grep -v grep | awk '{print $2}'`
if [ -z $PID ]; then
	PID=`lsof -i:$SERVER_PORT | grep "a.out" | awk '{print $2}'`
fi
if [ -z $PID ]; then
	echo "The server has yet to launch."
else
	kill $PID
	echo "The server has stopped!"
fi
DIR=`pwd`
LOG_DIR=$DIR/logs
if [ ! -d "$LOG_DIR" ]; then
	echo "Creating dir '$LOG_DIR' ..."
	mkdir "$LOG_DIR"
fi
go run $DIR/server.go -port=$SERVER_PORT 2>&1 | cronolog "$LOG_DIR/hypermind.log.%Y-%m-%d" &
echo "The server has been launched. (port=$SERVER_PORT)"
{'fraction_non_alphanumeric': 0.18322698268003645, 'fraction_numerical': 0.010027347310847767, 'mean_word_length': 3.9237668161434978, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3450692', 'n_tokens_mistral': 460, 'n_tokens_neox': 416, 'n_words': 137}