Prevented a log from being tracked, made some minor fixes.
This commit is contained in:
parent
6eb63097fa
commit
ba126bbce3
3
.gitignore
vendored
3
.gitignore
vendored
@ -169,4 +169,5 @@ cython_debug/
|
||||
#.idea/
|
||||
|
||||
/tokenizer_vocab.txt
|
||||
/logs/core_dreams.txt
|
||||
/logs/core_dreams.txt
|
||||
/logs/best_dream.txt
|
@ -47,6 +47,8 @@ def home():
|
||||
<body>
|
||||
<h1>🌸 Ruby's Dashboard</h1>
|
||||
<p><b>Vocabulary Size:</b> {{ vocab_size }}</p>
|
||||
<h3>🏆 Highest Scoring Dream</h3>
|
||||
<p><b>{{ best_dream }}</b></p>
|
||||
|
||||
<h3>🧠 Recent Daydreams</h3>
|
||||
<ul>
|
||||
@ -68,11 +70,10 @@ def home():
|
||||
{{ err }}
|
||||
{% endfor %}
|
||||
</pre>
|
||||
<h3>🏆 Highest Scoring Dream</h3>
|
||||
<p><b>{{ best_dream }}</b></p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
""", dreams=dreams[::-1], messages=messages[::-1], errors=errors[::-1], vocab_size=vocab_size)
|
||||
""", best_dream=best_dream, dreams=dreams[::-1], messages=messages[::-1], errors=errors[::-1], vocab_size=vocab_size)
|
||||
|
||||
|
||||
def start_dashboard():
|
||||
|
@ -1,5 +1,6 @@
|
||||
from datetime import datetime
|
||||
|
||||
|
||||
class RubyState:
|
||||
def __init__(self):
|
||||
self.last_message_time = datetime.utcnow()
|
||||
|
@ -250,4 +250,8 @@ class RubyTrainer:
|
||||
if len(set(words)) > len(words) * 0.75:
|
||||
score += 1 # diversity bonus
|
||||
|
||||
word_counts = {w: words.count(w) for w in set(words)}
|
||||
if any(count >= 3 for count in word_counts.values()):
|
||||
score -= 1 # repetition penalty
|
||||
|
||||
return score # max 5.0
|
||||
|
Loading…
x
Reference in New Issue
Block a user