<commit_before>// Brief: Bot logic
// Primary responsibility: Top level logic layer for bot

package main

import (
	"log"

	bmul "github.com/julwrites/BotMultiplexer"
)

func HelpMessage(env *bmul.SessionData) {
	env.Res.Message = "Hello %s! Give me a Bible reference and I'll give you the passage!" //\nHere are some other things I can do:\n/tms - Get a card from the Navigators' Topical Memory System\n/version - Choose your preferred Bible version\n/dailydevo - Get reading material right now\n/subscribe - Subscribe to / Unsubscribe from daily reading material\n/search - Search for a passage, lexicon entry, word or phrase\n"
}

func RunCommands(env *bmul.SessionData) {
	switch env.Msg.Command {
	default:
		GetBiblePassage(env)
	}
}

func HandleBotLogic(env *bmul.SessionData) {
	RunCommands(env)

	log.Printf("Commands run, resulting message: %s", env.Res.Message)
	if len(env.Res.Message) == 0 {
		log.Printf("This message was not handled by bot")
		HelpMessage(env)
	}
}
<commit_msg>Formatting help message for personalization<commit_after>// Brief: Bot logic
// Primary responsibility: Top level logic layer for bot

package main

import (
	"fmt"
	"log"

	bmul "github.com/julwrites/BotMultiplexer"
)

func HelpMessage(env *bmul.SessionData) {
	env.Res.Message = fmt.Sprintf("Hello %s! Give me a Bible reference and I'll give you the passage!", env.User.Firstname)
	//\nHere are some other things I can do:\n/tms - Get a card from the Navigators' Topical Memory System\n/version - Choose your preferred Bible version\n/dailydevo - Get reading material right now\n/subscribe - Subscribe to / Unsubscribe from daily reading material\n/search - Search for a passage, lexicon entry, word or phrase\n"
}

func RunCommands(env *bmul.SessionData) {
	switch env.Msg.Command {
	default:
		GetBiblePassage(env)
	}
}

func HandleBotLogic(env *bmul.SessionData) {
	RunCommands(env)

	log.Printf("Commands run, resulting message: %s", env.Res.Message)
	if len(env.Res.Message) == 0 {
		log.Printf("This message was not handled by bot")
		HelpMessage(env)
	}
}

{'fraction_non_alphanumeric': 0.10587663914521613, 'fraction_numerical': 0.0009713453132588635, 'mean_word_length': 4.255102040816326, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '2377786', 'n_tokens_mistral': 681, 'n_tokens_neox': 668, 'n_words': 218}