tocolib¶
A multipurpose utility library for Python 2 and 3.
The library namespace is tocoli
. For information on
available packages, modules and functionality see Structure.
Highlights¶
Sorting dictionaries¶
Sort a ‘list’ of ‘dict’ by simply defining the keys you like to sort by in order from last to first.
Example:
>>> dicts = [{'firstname': 'Bob', 'lastname': 'Abel'}, {'firstname': 'Alice', 'lastname': 'Bond'}, {'firstname': 'Carol', 'lastname': 'Bond'}, {'firstname': 'Bob', 'lastname': 'Bond'}, {'firstname': 'Carol', 'lastname': 'Abel'}, {'firstname': 'Alice', 'lastname': 'Abel'}]>>> from tocoli.sort import sort_dicts_by_value >>> sort_dicts_by_value(dicts, ['lastname', 'firstname']) [{'firstname': 'Alice', 'lastname': 'Abel'}, {'firstname': 'Bob', 'lastname': 'Abel'}, {'firstname': 'Carol', 'lastname': 'Abel'}, {'firstname': 'Alice', 'lastname': 'Bond'}, {'firstname': 'Bob', 'lastname': 'Bond'}, {'firstname': 'Carol', 'lastname': 'Bond'}]
A Domain Specific Language for intuitive function calls¶
The
dsl
package provides a coherent style to access the tocolib modules and functions as module or static class functions.Example:
>>> from tocoli.dsl import sort>>> sort.dicts.by.value(dicts, ['lastname', 'firstname']) [{'firstname': 'Alice', 'lastname': 'Abel'}, {'firstname': 'Bob', 'lastname': 'Abel'}, {'firstname': 'Carol', 'lastname': 'Abel'}, {'firstname': 'Alice', 'lastname': 'Bond'}, {'firstname': 'Bob', 'lastname': 'Bond'}, {'firstname': 'Carol', 'lastname': 'Bond'}]>>> sort.dicts.by.similarity(dicts, 'Karol', ['firstname']) [{'firstname': 'Carol', 'lastname': 'Bond'}, {'firstname': 'Carol', 'lastname': 'Abel'}, {'firstname': 'Alice', 'lastname': 'Bond'}, {'firstname': 'Alice', 'lastname': 'Abel'}, {'firstname': 'Bob', 'lastname': 'Abel'}, {'firstname': 'Bob', 'lastname': 'Bond'}]
Powerful mapping¶
Use recursive mapping to apply functions to nested data structures.
Example:
>>> from tocoli.dsl import map>>> def upper(item, parent): return item.upper()>>> map.recursive(dicts, upper) [{'firstname': 'BOB', 'lastname': 'ABEL'}, {'firstname': 'ALICE', 'lastname': 'BOND'}, {'firstname': 'CAROL', 'lastname': 'BOND'}, {'firstname': 'BOB', 'lastname': 'BOND'}, {'firstname': 'CAROL', 'lastname': 'ABEL'}, {'firstname': 'ALICE', 'lastname': 'ABEL'}]>>> map_keys = (map.DEFAULT | map.DICT_KEY) ^ map.DICT_VALUE >>> map.recursive(dicts, upper, map_keys) [{'FIRSTNAME': 'Bob', 'LASTNAME': 'Abel'}, {'FIRSTNAME': 'Alice', 'LASTNAME': 'Bond'}, {'FIRSTNAME': 'Carol', 'LASTNAME': 'Bond'}, {'FIRSTNAME': 'Bob', 'LASTNAME': 'Bond'}, {'FIRSTNAME': 'Carol', 'LASTNAME': 'Abel'}, {'FIRSTNAME': 'Alice', 'LASTNAME': 'Abel'}]
What’s New¶
- Changed minimum requirement: passlib>=1.7.0
- The former
dsl
module is now an own subpackage. - The keys parameter notation for sorting functions changed.
- There are new flags paramter options for mapping functions.
For more detailed information on current changes check the CHANGELOG.md
Structure¶
Namespace¶
tocoli
- root- The tocolib wraps the
six
library (Python 2 and 3 compatibility utilities) at the root. Thus allsix
packages and modules are also available under the root namespace.
Subpackages¶
dsl
- a domain specific language for tocolib- Python, like it should be. The module contains a domain specific language for common functions like filtering, sorting, mapping and more. All functions have a consistent API and results.
Modules¶
auth
- common authetication helpers- Its dangerous out there. This module is all about passwords, hashes, salts, tokens and api keys.
cmp
- compare utilities- For those who like to compare apples with pears. Make different data types comparable.
enc
- encoding functions- Encoding without pain. Provides universal encoding functions.
filter
- filter functions- The good ones go into the pot, the bad ones go into your crop. Advanced functions to filter dictionaries or lists of strings.
fn
- common lambda functions- To Be or not to Be: That is the question! Short value extractor functions and more.
join
- join/reduce/folding functions- Bring together what belongs together.
map
- mapping functions- It’s still magic even if you know how it’s done. Map data by applying any higher-order function to it.
ratio
- ratio functions- Comparisons make unhappy, but can be quite useful. Provides ratio functions for varios purposes.
regex
- regular expression utilities- Find what you are searching for. Generate common regular expressions.
sort
- sort functions- Chuck Norris is able to sort black pens by color. Sort data by value or keys.
spell
- spelling utilities- Life doesn’t come with spell-check, but tocolib does.
test
- testing and benchmarking- Tests cant prove the absence of bugs. Thus test as good as you can.
type
- type conversion utilities- What doesn’t fit is made to fit. Universal type transformations.
Contents¶
tocoli package¶
Subpackages¶
tocoli.dsl package¶
-
class
tocoli.dsl.filter.
dicts
[source]¶ -
class
by
[source]¶ -
static
key
(iterable, keys, all_keys=False)¶ Returns a ‘list’ of ‘dict’ whose dictionaries contain at least one of the specified keys.
-
static
value
(iterable, keywords, keys=None, all_keys=False)¶ Returns a ‘list’ of ‘dict’ whose dictionaries contain at least one of the keywords as value in the specified keys.
-
static
-
class
-
class
tocoli.dsl.sort.
dicts
[source]¶ -
class
by
[source]¶ -
static
similarity
(iterable, keyword, keys, values=<function first_kwarg>, default=None, sequentially=True, reverse=False, weights=(1, 1), case_sensitive=False)¶ Returns a sorted ‘list’ of ‘dict’.
-
static
value
(iterable, keys, values=<function first_kwarg>, default=None, sequentially=True, reverse=False)¶ Sort a list of dictionaries as you like!
Sort a ‘list’ of ‘dict’ by value. For simple sorting define keys as ‘list’ of ‘str’, where the strings are keynames. The functional values parameter behaves like the functional key parameter from the built-in sorted function.
Examples
Simple sort by a key:
>>> dicts = [{'name': 'Eve'}, {'name': 'Alice', 'email': 'alice@example.com'}, {'email': 'bob@example.com', 'name': 'Bob'}]
>>> sort_dicts_by_value(dicts, ['name']) [{'name': 'Alice', 'email': 'alice@example.com'}, {'email': 'bob@example.com', 'name': 'Bob'}, {'name': 'Eve'}]
Advanced sort for multiple keys and custom
values
function:>>> dicts = [{'price': 100}, {'price': 50, 'shipping': 40}, {'shipping': 5, 'price': 55}]
>>> def total(price, shipping): return price + shipping
>>> sort_dicts_by_value(dicts, ['price', 'shipping'], values=total, default=0, sequentially=False) [{'price': 55, 'shipping': 5}, {'price': 50, 'shipping': 40}, {'price': 100}]
Sort dictionaries with non string keys:
>>> dicts = [{1: False}, {'right': True, 1: False}, {1: True, 'right': True}]
>>> def both(left, right): return left and right
>>> sort_dicts_by_value(dicts, [{'key': 1, 'alias': 'left'}, 'right'], values=both, default=False, sequentially=False, reverse=True) [{1: True, 'right': True}, {1: False}, {1: False, 'right': True}]
Parameters: - iterable (list(dict)) – The input dictonaries.
- keys (list(string or dict)) –
Sort by defined keys. If you have non string keys then keys should be a ‘dict’ instead of a ‘list’ with plain keys, which defines an alternative keyname for the non string key (e.g.
keys={'key': 1: alias: 'one'}
instead ofkeys=[1]
). Note: Those dictionaries which do not contain any key of keys will be removed from the result.- Options:
'key'
: defines the key'alias'
: alternative keyname for non string key names'sort'
: sort order (ASCENDING
orDESCENDING
)
- values (function(**kwargs) -> value) – Returns the value to sort by.
Defaults to the first value of given keywords (unordered). The
values function receives the defined keys as
**kwargs
. Thus it is possible to process the values easily by their name (e.g.lambda firstname, lastname: firstname + ' ' + lastname
). Note: Take the default and the sequentially parameter into account, when you specify a custom values function. In sequential mode you have to expect different keywords (e.g.lambda **kwargs: …
). - default (value) – Default value. Defaults to
None
. Defines the default value which is passed to thevalues
function if a specified key fromkeys
is not present orNone
. - sequentially (bool) – Run in sequence. Defaults to True.
If
True
each key inkeys
gets sorted one after the other else runs in batch mode and passes allkeys
to thevalues
function. Note: The keys get sorted in reverse order. Thus the first key gets sorted as last and vice versa. - reverse (bool) – Reverse sorting. Defaults to False.
Reverses sotring order for each key of keys idependently if the
sequentially parameter is
True
else reverses the sorted ‘list’ as whole.
Returns: - A ‘list’ of ‘dict’.
Note: Those dictionaries which do not contain any key of keys will be removed from the result.
Return type: list
-
static
-
class
tocoli.py2 package¶
Submodules¶
tocoli.auth module¶
-
tocoli.auth.
encrypt_api_key
(user_id, secret_key)[source]¶ Encrypts a user id into an api key (token). The generated api key has no expiration time.
-
tocoli.auth.
encrypt_token
(user_id, secret_key, expiration=1800)[source]¶ Encrypts a user id into a timed token. Default expiration time is 30 minutes.
-
tocoli.auth.
generate_salt
(length=10, chars='ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghijklmnopqrstuvwxyz')[source]¶ Generates a salt. Defaults to a random salt from [A-Z0-9a-z].
-
tocoli.auth.
verify_api_key
(api_key, secret_key)[source]¶ Verifies a given api key (token). Returns the decoded user id or None.
tocoli.cmp module¶
tocoli.enc module¶
-
tocoli.enc.
decode
(input, encoding='utf-8', errors='strict', detect='utf-8')[source]¶ Decode any string. Returns a unicode decoded string otherwise the input.
Use this function to decode an encoded string. Its recommended to use this function as early as possible in your data flow, when you received data from an external resource (e.g. stdin, file, API, â¦). Once decoded you have access to the encoded information and can operate on it. This func- tion is a universal wrapper for the built-in codecs.decode() function.
Examples
Default encoding utf-8:
>>> decode('café') u'café' # utf-8 decoded string
Non default encoding:
>>> decode('café', 'latin-1') u'café' # utf-8 decoded string
Advanced codec support:
>>> decode('Y2Fmw6k=\n', 'base64') u'café' # utf-8 decoded string
Parameters: - input (str) – Any string you like to decode. The string can be a byte string or a unicode decoded string. The function makes sure to treat the input type in the correct manner.
- encoding (Optional[str]) – Input encoding. Defaults to utf-8. Defines the encoding of the input.
- errors (Optional[str]) –
Error handling schemes. Defaults to ‘strict’ These string values are predefined:
’strict’ - raise a ValueError error (or a subclass) ‘ignore’ - ignore the character and continue with the next ‘replace’ - replace with a suitable replacement character;Python will use the official U+FFFD REPLACEMENT CHARACTER for the builtin Unicode codecs on decoding and ‘?’ on encoding.- ’xmlcharrefreplace’ - Replace with the appropriate XML
- character reference (only for encoding).
- ’backslashreplace’ - Replace with backslashed escape sequences
- (only for encoding).
- detect (Optional[str]) – Inner encoding. Defaults to utf-8. This parameter defines the recursive decoding type (e.g. contains a base64 encoded string inside another encoded string, which might be a utf-8 or something else). If the given inner decoding type is not correct, then the function tries to detect the encoding auto- matically.
Returns: unicode (python2) str (python3): Encoded byte string.
-
tocoli.enc.
encode
(input, encoding='utf-8', errors='strict', input_encoding='utf-8')[source]¶ Encode any string. Returns a byte string otherwise the input.
Use this funtion to encode strings you like to write to any kind of output (e.g. stdout, file, API, â¦). This is useful to exchange information in a standardized way (the encoding). This function is a universal wrapper for the built-in codecs.encode() function.
Examples
Default usage:
>>> encode('café') b'café' # utf-8 encoded byte string
Transform encoding:
>>> encode('café', 'utf-8', input_encoding='latin-1') b'café' # utf-8 encoded byte string
Advanced codec support:
>>> encode('café', 'base64') b'Y2Fmw6k=\n' # base64 encoded byte string # inner encoding is always utf-8
Parameters: - input (str) – Any string you like to encode. The string can be a byte string or a unicode decoded string. The function makes sure to treat the input type in the correct manner.
- encoding (Optional[str]) – Output encoding. Defaults to utf-8. Defines the encoding for the resulting byte string.
- errors (Optional[str]) –
Error handling schemes. Defaults to ‘strict’ These string values are predefined:
’strict’ - raise a ValueError error (or a subclass) ‘ignore’ - ignore the character and continue with the next ‘replace’ - replace with a suitable replacement character;Python will use the official U+FFFD REPLACEMENT CHARACTER for the builtin Unicode codecs on decoding and ‘?’ on encoding.- ’xmlcharrefreplace’ - Replace with the appropriate XML
- character reference (only for encoding).
- ’backslashreplace’ - Replace with backslashed escape sequences
- (only for encoding).
- input_encoding (Optional[str]) – Given encoding. Defaults to utf-8. Set this parameter if your input is not encoded as utf-8.
Returns: str (python2) bytes (python3): Encoded byte string.
tocoli.filter module¶
-
tocoli.filter.
clean
(str, include='', alpha='a-zA-Z', numeric='0-9')[source]¶ Filter unwanted characters. Returns the filtered string.
Examples
>>> clean('1.20€') '120'
>>> clean('1.20€', '.') '1.20'
>>> clean('1.20€', '.€') '1.20€'
>>> clean('Hello', alpha='a-z') 'ello'
Parameters: - str (str) – input string
- include (str) – Regular-expression raw string. Defaults to ‘’. This parameter defines which additional characters to include to the result.
- alpha (str) – Regular-expression raw string. Defaults to ‘a-zA-Z’. This parameter defines which alpha characters should be in the result.
- numeric (str) – Regular-expression raw string. Defaults to ‘0-9’. This parameter defines which numeric characters should be in the result.
Returns: string which only contains accepted characters.
Return type: str
-
tocoli.filter.
filter_dict_by_key
(d, keys, all_keys=False)[source]¶ Returns this ‘dict’ when it contains at least one of the specified keys else None.
-
tocoli.filter.
filter_dict_by_value
(d, keywords, keys=None, all_keys=False)[source]¶ Returns this ‘dict’ when it contains at least one of the keywords as value in the specified keys else None.
-
tocoli.filter.
filter_dicts_by_keys
(iterable, keys, all_keys=False)[source]¶ Returns a ‘list’ of ‘dict’ whose dictionaries contain at least one of the specified keys.
-
tocoli.filter.
filter_dicts_by_values
(iterable, keywords, keys=None, all_keys=False)[source]¶ Returns a ‘list’ of ‘dict’ whose dictionaries contain at least one of the keywords as value in the specified keys.
-
tocoli.filter.
filter_strings_by_keywords
(iterable, keywords, case_sensitive=False)[source]¶ Filter strings by exact keywords. Returns a new list.
tocoli.fn module¶
-
tocoli.fn.
key
(iterable, value=None, sort=False, reverse=False, first=False, position=0)[source]¶ Generic key getter. Returns one or more keys.
tocoli.join module¶
tocoli.map module¶
tocoli.ratio module¶
-
tocoli.ratio.
equal
(str1, str2, nominator='max')[source]¶ A simple ratio function based on the equality.
-
tocoli.ratio.
meta
(str1, str2, ratios, weights)[source]¶ A meta ratio function. Returns a weighted meta ratio.
The Wiesendahl ratio is a meta ratio which combines a weighted ratio of given ratio functions.
Parameters: - str1 (str) – first string
- str2 (str) – second string
- ratios (list(function(str, str) -> float)) – ratio functions This parameter is a list of ratio functions.
- weights (list(float)) – list of weights Each weight gets applied to its corresponding function.
Returns: the combined and weighted meta ratio
Return type: float
tocoli.regex module¶
-
class
tocoli.regex.
Anchors
[source]¶ -
BEGINNING
= '^'¶
-
END
= '$'¶
-
NOT_WORD_BOUNDARY
= '\\B'¶
-
WORD_BOUNDARY
= '\\b'¶
-
-
class
tocoli.regex.
CharClass
[source]¶ -
ANY
= '.'¶
-
DIGIT
= '\\d'¶
-
NOT_DIGIT
= '\\D'¶
-
NOT_WHITESPACE
= '\\S'¶
-
NOT_WORD
= '\\W'¶
-
WHITESPACE
= '\\s'¶
-
WORD
= '\\w'¶
-
-
class
tocoli.regex.
Escaped
[source]¶ -
CARRIAGE_RETURN
= '\\r'¶
-
FORM_FEED
= '\\f'¶
-
LINE_FEED
= '\\n'¶
-
NULL
= '\\0'¶
-
TAB
= '\\t'¶
-
VERTICAL_TAB
= '\\v'¶
-
-
class
tocoli.regex.
QuantifiedRe
(expr=None)[source]¶ Bases:
tocoli.regex.Re
-
class
tocoli.regex.
Substitution
[source]¶ -
AFTER_MATCH
= "$'"¶
-
BEFORE_MATCH
= '$`'¶
-
DOLLAR
= '$$'¶
-
MATCH
= '$&'¶
-
tocoli.sort module¶
-
tocoli.sort.
sort_dicts_by_similarity
(iterable, keyword, keys, values=<function first_kwarg>, default=None, sequentially=True, reverse=False, weights=(1, 1), case_sensitive=False)[source]¶ Returns a sorted ‘list’ of ‘dict’.
-
tocoli.sort.
sort_dicts_by_value
(iterable, keys, values=<function first_kwarg>, default=None, sequentially=True, reverse=False)[source]¶ Sort a list of dictionaries as you like!
Sort a ‘list’ of ‘dict’ by value. For simple sorting define keys as ‘list’ of ‘str’, where the strings are keynames. The functional values parameter behaves like the functional key parameter from the built-in sorted function.
Examples
Simple sort by a key:
>>> dicts = [{'name': 'Eve'}, {'name': 'Alice', 'email': 'alice@example.com'}, {'email': 'bob@example.com', 'name': 'Bob'}]
>>> sort_dicts_by_value(dicts, ['name']) [{'name': 'Alice', 'email': 'alice@example.com'}, {'email': 'bob@example.com', 'name': 'Bob'}, {'name': 'Eve'}]
Advanced sort for multiple keys and custom
values
function:>>> dicts = [{'price': 100}, {'price': 50, 'shipping': 40}, {'shipping': 5, 'price': 55}]
>>> def total(price, shipping): return price + shipping
>>> sort_dicts_by_value(dicts, ['price', 'shipping'], values=total, default=0, sequentially=False) [{'price': 55, 'shipping': 5}, {'price': 50, 'shipping': 40}, {'price': 100}]
Sort dictionaries with non string keys:
>>> dicts = [{1: False}, {'right': True, 1: False}, {1: True, 'right': True}]
>>> def both(left, right): return left and right
>>> sort_dicts_by_value(dicts, [{'key': 1, 'alias': 'left'}, 'right'], values=both, default=False, sequentially=False, reverse=True) [{1: True, 'right': True}, {1: False}, {1: False, 'right': True}]
Parameters: - iterable (list(dict)) – The input dictonaries.
- keys (list(string or dict)) –
Sort by defined keys. If you have non string keys then keys should be a ‘dict’ instead of a ‘list’ with plain keys, which defines an alternative keyname for the non string key (e.g.
keys={'key': 1: alias: 'one'}
instead ofkeys=[1]
). Note: Those dictionaries which do not contain any key of keys will be removed from the result.- Options:
'key'
: defines the key'alias'
: alternative keyname for non string key names'sort'
: sort order (ASCENDING
orDESCENDING
)
- values (function(**kwargs) -> value) – Returns the value to sort by.
Defaults to the first value of given keywords (unordered). The
values function receives the defined keys as
**kwargs
. Thus it is possible to process the values easily by their name (e.g.lambda firstname, lastname: firstname + ' ' + lastname
). Note: Take the default and the sequentially parameter into account, when you specify a custom values function. In sequential mode you have to expect different keywords (e.g.lambda **kwargs: …
). - default (value) – Default value. Defaults to
None
. Defines the default value which is passed to thevalues
function if a specified key fromkeys
is not present orNone
. - sequentially (bool) – Run in sequence. Defaults to True.
If
True
each key inkeys
gets sorted one after the other else runs in batch mode and passes allkeys
to thevalues
function. Note: The keys get sorted in reverse order. Thus the first key gets sorted as last and vice versa. - reverse (bool) – Reverse sorting. Defaults to False.
Reverses sotring order for each key of keys idependently if the
sequentially parameter is
True
else reverses the sorted ‘list’ as whole.
Returns: - A ‘list’ of ‘dict’.
Note: Those dictionaries which do not contain any key of keys will be removed from the result.
Return type: list
tocoli.spell module¶
-
class
tocoli.spell.
Dictionary
[source]¶ -
latin
= {'strict': {u'\xe1': u'a|\xe1|\xe4', u'\xfc': u'u|\xfa|ue|\xfce|\xfc', u'tt': u'tt|t', u'cc': u'cc|ck|c|k', u's': u'ss|s|z|c', u'\xf6': u'o|\xf3|\xf6', u'rr': u'rr|r', u'as': u'as|\xe1s|a|\xe1|s', u'z': u'z|c|s|ss', u'es': u'es|e|s', u'a': u'a|\xe1|\xe4', u'c': u'cc|c|z', u'b': u'b|v', u'e': u'e|\xe9', u'\xe4': u'a|\xe1|\xe4', u'g': u'g|j', u'v': u'v|b', u'\xe9': u'e|\xe9', u'k': u'k|c|q', u'j': u'j|g|y|c|h', u'\xed': u'i|\xed|y', u'l': u'll|l', u'o': u'o|\xf3|\xf6', u'n': u'n|nn|\xf1', u'\xf1': u'n|\xf1', u'i': u'i|\xed|y', u'\xf3': u'o|\xf3|\xf6', u'r': u'rr|r', u'u': u'u|\xfa|ue|\xfce|\xfc', u't': u'tt|t', u'nn': u'nn|n|\xf1', u'y': u'y|ll|i', u'\xfa': u'u|\xfa|ue|\xfce|\xfc', u'os': u'os|o|s|a', u'll': u'll|l|j|y'}, 'wide': {u'sch': u'ssh|sch|sh|ch|sc|h|s', u'cc': u'cc|c|k|s|z|q|x|h', u'll': u'll|l|j|y|ii|i', u'yi': u'yi|hi|i|y|ji|xi', u'\xe1': u'a|\xe1|\xe4|o|\xf3', u'b': u'b|v|w', u'd': u'd|t', u'\xe9': u'e|\xe9|i', u'h': u'h|g|x', u'j': u'j|g|y|c|h', u'\xed': u'i|\xed|y|e|l', u'l': u'll|l|j|i', u'n': u'nn|n|\xf1|m', u'\xf1': u'nn|n|\xf1|m', u'i': u'i|\xed|y|e|l', u'\xf3': u'o|\xf3|\xf6|u|a|\xe1', u'r': u'r|rr', u't': u'tt|d|t', u'v': u'v|b|w', u'x': u'cc|ch|ck|ks|c|j|s|x|z', u'z': u'z|c|s', u'ai': u'ai|i|y', u'is': u'is|\xeds|i|\xed|s|ls', u'ay': u'ay|i|y', u'ie': u'ie|\xede|i\xe9|i|e|le', u'es': u'es|\xe9s|e|s|al', u'rr': u'rr|r', u'nn': u'nn|n|\xf1|m', u'y': u'y|ll|i|j', u'ji': u'ji|j\xed|hi|h\xed|xi|x\xed|y|i|\xed', u'a': u'a|\xe1|\xe4|o|\xf3|e', u'sz': u'sz|s|z', u'c': u'cc|c|k|s|z|q|x|h', u'e': u'e|\xe9|i', u'\xe4': u'a|\xe1|\xe4|o|\xf3', u'g': u'g|j|h|c|q', u'ss': u'ss|s|\xdf', u'k': u'ca|k|c|q', u'm': u'm|n', u'o': u'o|\xf3|\xf6|u|a|\xe1', u'\xfc': u'ue|\xfce|u|\xfa|\xfc|v|w|a', u'q': u'q|k|c', u's': u'ss|c|s|z|\xdf|th', u'sh': u'ssh|sch|sh|ch|sc|h|s|ge', u'u': u'ue|\xfce|u|\xfa|\xfc|v|w|a', u'w': u'w|v|b|u', u'\xf6': u'o|\xf3|\xf6|u|a|\xe1', u'sc': u'ssc|sch|sc|sz|c|s', u'ou': u'ou|\xf3u|o\xfa|o|u', u'\xfa': u'ue|\xfce|u|\xfa|\xfc|v|w|a', u'os': u'os|\xf3s|o|\xf3|s|a', u'tt': u'tt|d|t', u'se': u'sse|ss\xe9|se|s\xe9|e|s'}}¶
-