aboutsummaryrefslogtreecommitdiff
path: root/taggen.py
diff options
context:
space:
mode:
Diffstat (limited to 'taggen.py')
-rw-r--r--taggen.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/taggen.py b/taggen.py
new file mode 100644
index 0000000..3d36e87
--- /dev/null
+++ b/taggen.py
@@ -0,0 +1,15 @@
+import re
+
+def tag_gen(input_str):
+ input_str = input_str.lower()
+ input_str = re.sub(r'aii', '', input_str)
+ input_str = re.sub(r'20\d{2}-\d{2}', '', input_str)
+ input_str = re.sub(r'[pb]\d+', '', input_str)
+ input_str = re.sub(r'\d', '', input_str)
+ input_str = re.sub(r'blok', '', input_str)
+ input_str = re.sub(r'programmeren c', 'programmeren', input_str)
+ input_str = re.sub(r'stylofoon', '', input_str)
+ input_str = re.sub(r'[-]', '', input_str)
+ input_str = re.sub(r'\s+', ' ', input_str)
+ return input_str.strip()
+