Urbit / Docs

4a: exotic bases

++po

Phonetic base

Container core for providing phonetic syllables and name generators for the Urbit naming system. The two faces, sis and dex, are available to the contained arms.

Source

    ~/  %po
    =+  :-  ^=  sis                                       ::  prefix syllables
        'dozmarbinwansamlitsighidfidlissogdirwacsabwissib\
        /rigsoldopmodfoglidhopdardorlorhodfolrintogsilmir\
        /holpaslacrovlivdalsatlibtabhanticpidtorbolfosdot\
        /losdilforpilramtirwintadbicdifrocwidbisdasmidlop\
        /rilnardapmolsanlocnovsitnidtipsicropwitnatpanmin\
        /ritpodmottamtolsavposnapnopsomfinfonbanmorworsip\
        /ronnorbotwicsocwatdolmagpicdavbidbaltimtasmallig\
        /sivtagpadsaldivdactansidfabtarmonranniswolmispal\
        /lasdismaprabtobrollatlonnodnavfignomnibpagsopral\
        /bilhaddocridmocpacravripfaltodtiltinhapmicfanpat\
        /taclabmogsimsonpinlomrictapfirhasbosbatpochactid\
        /havsaplindibhosdabbitbarracparloddosbortochilmac\
        /tomdigfilfasmithobharmighinradmashalraglagfadtop\
        /mophabnilnosmilfopfamdatnoldinhatnacrisfotribhoc\
        /nimlarfitwalrapsarnalmoslandondanladdovrivbacpol\
        /laptalpitnambonrostonfodponsovnocsorlavmatmipfip'
        ^=  dex                                           ::  suffix syllables
        'zodnecbudwessevpersutletfulpensytdurwepserwylsun\
        /rypsyxdyrnuphebpeglupdepdysputlughecryttyvsydnex\
        /lunmeplutseppesdelsulpedtemledtulmetwenbynhexfeb\
        /pyldulhetmevruttylwydtepbesdexsefwycburderneppur\
        /rysrebdennutsubpetrulsynregtydsupsemwynrecmegnet\
        /secmulnymtevwebsummutnyxrextebfushepbenmuswyxsym\
        /selrucdecwexsyrwetdylmynmesdetbetbeltuxtugmyrpel\
        /syptermebsetdutdegtexsurfeltudnuxruxrenwytnubmed\
        /lytdusnebrumtynseglyxpunresredfunrevrefmectedrus\
        /bexlebduxrynnumpyxrygryxfeptyrtustyclegnemfermer\
        /tenlusnussyltecmexpubrymtucfyllepdebbermughuttun\
        /bylsudpemdevlurdefbusbeprunmelpexdytbyttyplevmyl\
        /wedducfurfexnulluclennerlexrupnedlecrydlydfenwel\
        /nydhusrelrudneshesfetdesretdunlernyrsebhulryllud\
        /remlysfynwerrycsugnysnyllyndyndemluxfedsedbecmun\
        /lyrtesmudnytbyrsenwegfyrmurtelreptegpecnelnevfes'
    |%

++ind

Parse suffix

Produces the byte of the right-hand syllable a.

Accepts

a is an atom.

Produces

A unit.

Source

      ++  ind  ~/  %ind
               |=  [email protected]
               =+  b=0
               |-  ^-  (unit @)
               ?:(=(256 b) ~ ?:(=(a (tod b)) [~ b] $(b +(b))))

Examples

    > (ind:po 'zod')
    [~ u=0]

    > (ind:po 'zam')
    ~

    > (ind:po 'del')
    [~ u=37]

++ins

Parse prefix

Produces the byte of the left-hand phonetic syllable a.

Accepts

a is an atom.

Produces

A unit of an atom.

Source

      ++  ins  ~/  %ins
               |=  [email protected]
               =+  b=0
               |-  ^-  (unit @)
               ?:(=(256 b) ~ ?:(=(a (tos b)) [~ b] $(b +(b))))

Examples

    > (ins:po 'mar')
    [~ u=1]

    > (ins:po 'son')
    [~ u=164]

    > (ins:po 'pit')
    [~ u=242]

    > (ins:po 'pok')
    ~

++tod

Fetch suffix

Produces the phonetic suffix syllable from index a within dex as an atom.

Accepts

a is an atom

Produces

An atom.

Source

      ++  tod  ~/  %tod
               |=([email protected] ?>((lth a 256) (cut 3 [(mul 3 a) 3] dex)))

Examples

    > `@t`(tod:po 1)
    'nec'

    > `@t`(tod:po 98)
    'dec'

    > `@t`(tod:po 0)
    'zod'

    > `@t`(tod:po 150)
    'ryg'

    > `@t`(tod:po 255)
    'fes'

    > `@t`(tod:po 256)
    ! exit

++tos

Fetch prefix

Produces the phonetic prefix syllable from index a within sis as an atom.

Accepts

a is an atom.

Produces

An atom.

Source

      ++  tos  ~/  %tos
               |=([email protected] ?>((lth a 256) (cut 3 [(mul 3 a) 3] sis)))

Examples

    > `@t`(tos:po 0)
    'doz'

    > `@t`(tos:po 120)
    'fab'

    > `@t`(tos:po 43)
    'pid'

    > `@t`(tos:po 253)
    'mat'