ascend-runitback 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ascend/__init__.py +0 -0
- ascend/__main__.py +19 -0
- ascend/hypergamy_meme.py +75 -0
- ascend/models.py +16 -0
- ascend/songs.py +17 -0
- ascend/stats.py +72 -0
- ascend/titles.py +47 -0
- ascend/translator.py +645 -0
- ascend_runitback-0.1.0.dist-info/METADATA +530 -0
- ascend_runitback-0.1.0.dist-info/RECORD +13 -0
- ascend_runitback-0.1.0.dist-info/WHEEL +5 -0
- ascend_runitback-0.1.0.dist-info/licenses/LICENSE +674 -0
- ascend_runitback-0.1.0.dist-info/top_level.txt +1 -0
ascend/__init__.py
ADDED
|
File without changes
|
ascend/__main__.py
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import argparse
|
|
2
|
+
import sys
|
|
3
|
+
|
|
4
|
+
from .translator import translate_sentence
|
|
5
|
+
|
|
6
|
+
def main():
|
|
7
|
+
parser = argparse.ArgumentParser(description="Translate text into BP slang.")
|
|
8
|
+
parser.add_argument("text", nargs="*", help="Text to translate")
|
|
9
|
+
args = parser.parse_args()
|
|
10
|
+
|
|
11
|
+
text = " ".join(args.text) if args.text else sys.stdin.read()
|
|
12
|
+
translated = translate_sentence(text)
|
|
13
|
+
if translated is None:
|
|
14
|
+
parser.error("provide non-empty text to translate")
|
|
15
|
+
|
|
16
|
+
print(translated)
|
|
17
|
+
|
|
18
|
+
if __name__ == "__main__":
|
|
19
|
+
main()
|
ascend/hypergamy_meme.py
ADDED
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import random
|
|
2
|
+
|
|
3
|
+
_HYPERGAMY_MESSAGES = ("there's no hope.", "its so jover.", "hypergamy comes for us all.")
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
def make_hypergamy_meme_ascii(color=False):
|
|
7
|
+
width, height = 82, 33
|
|
8
|
+
canvas = [[" "] * width for _ in range(height)]
|
|
9
|
+
colored_cells = {}
|
|
10
|
+
|
|
11
|
+
women_y = (2, 7, 12, 17, 22, 27)
|
|
12
|
+
men_y = women_y
|
|
13
|
+
woman_x, man_x = 9, 74
|
|
14
|
+
start_x, target_x, target_y = woman_x + 4, 68, 3
|
|
15
|
+
|
|
16
|
+
for woman_y_pos in women_y:
|
|
17
|
+
start_y = woman_y_pos + 1
|
|
18
|
+
previous_y = start_y
|
|
19
|
+
|
|
20
|
+
for x in range(start_x, target_x):
|
|
21
|
+
progress = (x - start_x) / (target_x - start_x)
|
|
22
|
+
y = round(start_y + (target_y - start_y) * progress)
|
|
23
|
+
stroke = "-" if y == previous_y else "/"
|
|
24
|
+
canvas[y][x] = stroke
|
|
25
|
+
previous_y = y
|
|
26
|
+
|
|
27
|
+
canvas[target_y][target_x] = ">"
|
|
28
|
+
|
|
29
|
+
def draw_figure(x, y, figure, group):
|
|
30
|
+
for row_offset, row in enumerate(figure):
|
|
31
|
+
for column_offset, char in enumerate(row):
|
|
32
|
+
canvas[y + row_offset][x + column_offset] = char
|
|
33
|
+
if char != " ":
|
|
34
|
+
colored_cells[(x + column_offset, y + row_offset)] = group
|
|
35
|
+
|
|
36
|
+
woman = (" O ", "/|\\", "/_\\", "| |")
|
|
37
|
+
man = (" O ", "/|\\", "| |", "/ \\")
|
|
38
|
+
|
|
39
|
+
for y in women_y:
|
|
40
|
+
draw_figure(woman_x, y, woman, "women")
|
|
41
|
+
|
|
42
|
+
for y in men_y:
|
|
43
|
+
draw_figure(man_x, y, man, "men")
|
|
44
|
+
|
|
45
|
+
ansi = {"women": "\033[95m", "men": "\033[96m"}
|
|
46
|
+
reset = "\033[0m"
|
|
47
|
+
output = []
|
|
48
|
+
|
|
49
|
+
for y, row in enumerate(canvas):
|
|
50
|
+
last = len(row)
|
|
51
|
+
while last and row[last - 1] == " ":
|
|
52
|
+
last -= 1
|
|
53
|
+
|
|
54
|
+
rendered = []
|
|
55
|
+
active_color = None
|
|
56
|
+
|
|
57
|
+
for x, char in enumerate(row[:last]):
|
|
58
|
+
next_color = ansi.get(colored_cells.get((x, y))) if color else None
|
|
59
|
+
|
|
60
|
+
if next_color != active_color:
|
|
61
|
+
if active_color:
|
|
62
|
+
rendered.append(reset)
|
|
63
|
+
if next_color:
|
|
64
|
+
rendered.append(next_color)
|
|
65
|
+
active_color = next_color
|
|
66
|
+
|
|
67
|
+
rendered.append(char)
|
|
68
|
+
|
|
69
|
+
if active_color:
|
|
70
|
+
rendered.append(reset)
|
|
71
|
+
|
|
72
|
+
output.append("".join(rendered))
|
|
73
|
+
|
|
74
|
+
output.append(random.choice(_HYPERGAMY_MESSAGES))
|
|
75
|
+
return "\n".join(output)
|
ascend/models.py
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
def pick_model(category):
|
|
2
|
+
models = {
|
|
3
|
+
"runway": "Bella Hadid",
|
|
4
|
+
"editorial": "Vittoria Ceretti",
|
|
5
|
+
"classic": "Kate Moss",
|
|
6
|
+
"angel": "Adriana Lima",
|
|
7
|
+
"high-fashion": "Anok Yai"
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
if not isinstance(category, str):
|
|
11
|
+
raise ValueError("Category must be a string")
|
|
12
|
+
|
|
13
|
+
if category not in models:
|
|
14
|
+
raise ValueError("Invalid model category")
|
|
15
|
+
|
|
16
|
+
return models[category]
|
ascend/songs.py
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
|
|
2
|
+
def pick_song(category):
|
|
3
|
+
songs = {
|
|
4
|
+
"gym": ("METAMORPHOSIS", "INTERWORLD"),
|
|
5
|
+
"study": ("Memory Reboot", "VØJ, Narvent"),
|
|
6
|
+
"edit": ("Murder In My Mind", "Kordhell"),
|
|
7
|
+
"chill": ("After Dark", "Mr.Kitty"),
|
|
8
|
+
"BPCORE": ("Love Potions", "BJ Lips")
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
if not isinstance(category, str):
|
|
12
|
+
return None
|
|
13
|
+
|
|
14
|
+
if category not in songs:
|
|
15
|
+
return None
|
|
16
|
+
|
|
17
|
+
return songs[category]
|
ascend/stats.py
ADDED
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
|
|
2
|
+
import random
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
def make_stat_card(activity, level):
|
|
6
|
+
"""
|
|
7
|
+
Create a fictional stat card for an everyday activity.
|
|
8
|
+
Scores depend on the selected level from 1 to 10.
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
if not isinstance(activity, str):
|
|
12
|
+
raise TypeError("Activity must be a string.")
|
|
13
|
+
|
|
14
|
+
if activity.strip() == "":
|
|
15
|
+
raise ValueError("Activity cannot be empty.")
|
|
16
|
+
|
|
17
|
+
if type(level) is not int:
|
|
18
|
+
raise TypeError("Level must be an integer.")
|
|
19
|
+
|
|
20
|
+
if level < 1 or level > 10:
|
|
21
|
+
raise ValueError("Level must be between 1 and 10.")
|
|
22
|
+
|
|
23
|
+
activity_name = activity.strip()
|
|
24
|
+
activity_lower = activity_name.lower()
|
|
25
|
+
|
|
26
|
+
if activity_lower == "studying":
|
|
27
|
+
labels = ["Focus", "Studymaxxing", "Exam Aura"]
|
|
28
|
+
elif activity_lower == "gym":
|
|
29
|
+
labels = ["Strength", "Gymmaxxing", "Physique Aura"]
|
|
30
|
+
elif activity_lower == "gaming":
|
|
31
|
+
labels = ["Reaction Time", "Gamer Aura", "Clutch Factor"]
|
|
32
|
+
elif activity_lower == "cooking":
|
|
33
|
+
labels = ["Chef Energy", "Flavor Aura", "Kitchenmaxxing"]
|
|
34
|
+
elif activity_lower == "sleeping":
|
|
35
|
+
labels = ["Rest", "Dreammaxxing", "Sleep Aura"]
|
|
36
|
+
else:
|
|
37
|
+
labels = ["Effort", "Maxxing", "Aura"]
|
|
38
|
+
|
|
39
|
+
minimum_score = (level - 1) * 10 + 1
|
|
40
|
+
maximum_score = level * 10
|
|
41
|
+
|
|
42
|
+
scores = []
|
|
43
|
+
|
|
44
|
+
for label in labels:
|
|
45
|
+
score = random.randint(minimum_score, maximum_score)
|
|
46
|
+
scores.append(score)
|
|
47
|
+
|
|
48
|
+
overall_aura = sum(scores) // len(scores)
|
|
49
|
+
|
|
50
|
+
if level <= 3:
|
|
51
|
+
rank = "NPC Energy"
|
|
52
|
+
elif level <= 6:
|
|
53
|
+
rank = "Aura Apprentice"
|
|
54
|
+
elif level <= 9:
|
|
55
|
+
rank = "Certified Maxxer"
|
|
56
|
+
else:
|
|
57
|
+
rank = "Final Boss Aura"
|
|
58
|
+
|
|
59
|
+
card = "================================\n"
|
|
60
|
+
card += " ASCEND STAT CARD\n"
|
|
61
|
+
card += "================================\n"
|
|
62
|
+
card += "Activity: " + activity_name + "\n"
|
|
63
|
+
card += "Level: " + str(level) + "/10\n\n"
|
|
64
|
+
|
|
65
|
+
for i in range(len(labels)):
|
|
66
|
+
card += labels[i] + ": " + str(scores[i]) + "/100\n"
|
|
67
|
+
|
|
68
|
+
card += "\nOverall Aura: " + str(overall_aura) + "/100\n"
|
|
69
|
+
card += "Rank: " + rank + "\n"
|
|
70
|
+
card += "================================"
|
|
71
|
+
|
|
72
|
+
return card
|
ascend/titles.py
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import random
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
def make_title(activity, outcome):
|
|
5
|
+
"""Return a random edit title, or None for invalid inputs."""
|
|
6
|
+
if not isinstance(activity, str) or not isinstance(outcome, str):
|
|
7
|
+
return None
|
|
8
|
+
|
|
9
|
+
activity = activity.strip().lower()
|
|
10
|
+
phrases = {
|
|
11
|
+
"win": [
|
|
12
|
+
"ascension confirmed",
|
|
13
|
+
"brutal mog",
|
|
14
|
+
"halo activated",
|
|
15
|
+
"psl went up",
|
|
16
|
+
"chadlite unlocked",
|
|
17
|
+
"mog streak started",
|
|
18
|
+
],
|
|
19
|
+
"loss": [
|
|
20
|
+
"its over",
|
|
21
|
+
"pure cope",
|
|
22
|
+
"never began",
|
|
23
|
+
"got mogged",
|
|
24
|
+
"brutal failo",
|
|
25
|
+
"psl dropped",
|
|
26
|
+
],
|
|
27
|
+
"grind": [
|
|
28
|
+
"ascension pending",
|
|
29
|
+
"mogging in progress",
|
|
30
|
+
"softmaxxing arc",
|
|
31
|
+
"halo under construction",
|
|
32
|
+
"psl gains pending",
|
|
33
|
+
"mewing streak",
|
|
34
|
+
],
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
if not activity or outcome not in phrases:
|
|
38
|
+
return None
|
|
39
|
+
|
|
40
|
+
phrase = random.choice(phrases[outcome])
|
|
41
|
+
subject = f"{activity}maxxing"
|
|
42
|
+
frames = [
|
|
43
|
+
f"pov {subject} {phrase}",
|
|
44
|
+
f"{subject} update {phrase}",
|
|
45
|
+
f"{phrase} after {subject}",
|
|
46
|
+
]
|
|
47
|
+
return random.choice(frames)
|